Home » Forum Home » General

Topic: PentAI openings book
Replies: 31   Views: 208,856   Pages: 3   Last Post: Apr 14, 2014, 2:31 AM by: cropleyb

Search Forum

Back to Topic List
Replies: 31   Views: 208,856   Pages: 3   [ Previous | 1 2 3 | Next ]
zoeyk

Posts: 2,220
Registered: Mar 4, 2007
From: San Francisco
Age: 45
Home page
Re: PentAI openings book
Posted: Apr 1, 2014, 5:13 AM

> How many moves into a game should an openings book(s)
> go?

at least to P1's 3rd,.. the more the better of course,.. but every time you add a new level to the move tree the amount of input time increases massively,.. comes down to how much time the opening book designer has. but the main lines like the wedge and boston variants should be put in much more than just first 3 moves for examples.


> I presume that the moves made by P1 that post are
> good ones too, so I can create a P1 book as well?

Im not sure what you meant here...


> Whether we call it one book or two, it amounts to the
> same thing - positions where P1 is to move always
> have a total number of pieces on the board that is
> even, for P2 the total is odd.

not sure what this means, trying to imagine what you mean, and am finding myself slow here...

> However, how the AI players use the book for P1 and
> P2 could be different.

I would need an example to grasp what you mean here.



> Each sized board should have its own openings book(s).

yes makes sense,.. as to 13 grid there are players who have a good understanding. i am not one of them. s3v3n brf and others at BK play that a bit, so I think they may have discovered some stuff.

however i do know a easy way.. from a programmers end. scan all games in the data base for games that go beyond 13x13. take that group of games and have a master look through them for the strong and interesting ones. that will be a solid basis to develop 13x13 opening book theory from.

> I don't really have much of an understanding of
> "Adzi" - I'm guessing that if the search depth and
> width, and position evaluation function are
> sufficient, it will find good moves. Against me, it
> regularly comes up with complex, innovative moves (it
> gets a bit frustrating sometimes )

Yes, maybe it will come up with adzi moves coincidentally. but to speak of adzi should understand its concept. As nosovs once said, "only a handful of players understand it". It would be impressive if there was a button for AI that said "Adzi style mode" or something. and that it actually adjusted it's concept and style to that form of play as a controlled stance purposely, with malice and forethought, even tho it had other methods and styles it could had taken.


> For "equivalent positions due to move ordering", I'll
> give an example:
> K10,L9,N10,L13 is identical to:
> K10,L13,N10,L9
> So in my understanding, that isn't a type of
> symmetry, it is exactly the same position.

ok, i stand corrected. same placement pattern, both brought about by different sequence. yes there is interesting problem in my program about this issue. record going to destination both ways, hit destination, and half the time when rewinding moves from where you came its goes back a sequence that you did not come from,.. which is very annoying glitch i must say....


> By translational symmetry, I mean positions that are
> the same but shifted sideways a bit.

I think i get it but almost want to ask for two image examples, but i guess your saying its a moot point any ways,.. so ill just assume i get you i guess.

Scire hostis animum - Intelligere ludum - Nosce te ipsum - Prima moventur conciliat - Nolite errare
zoeyk

Posts: 2,220
Registered: Mar 4, 2007
From: San Francisco
Age: 45
Home page
Re: PentAI openings book
Posted: Apr 1, 2014, 7:12 PM

I have updated the K9 and L9 openings. they have my stamp of approval as P1 perfect play as of 2014.

Scire hostis animum - Intelligere ludum - Nosce te ipsum - Prima moventur conciliat - Nolite errare
up2ng

Posts: 542
Registered: May 9, 2002
From: Northeast USA
Re: PentAI openings book
Posted: Apr 1, 2014, 8:17 PM

I've been extremely inactive around here for quite a while but I just happened to see this topic of an opening book being discussed and I found it very interesting. This is something I had been thinking of attempting for a long time, but was just never able to make it happen.

Just FYI, the opening book that the computer opponent mm_ai uses here at pente.org is still available to view as far as I know. It's been a while since I've googled for such things, but this ai used to be available on a very old webpage that was published by Mark Mammel, who created the ai. The ai was available to download as a Windows application, which can run on a local machine dozens or perhaps hundreds of times faster than playing against the ai here at pente.org. In addition, there are lots of very interesting documents and links to old pente newsletters and so on that you can find on Mark's old site. Once of these documents is a Word document which shows all of the opening moves that the AI knows, written in lots of little gridlike graphical images throughout the document. Unfortunately, many of those opening moves are quite poor, since they were taken from what was then a very limited knowledge base of various live games played by average players, pbem games, tournament games, and so on. If any of them were taken from the pente.org database, it would have been at the very beginning when there were very few games recorded, and again, the skill level of the players involved would have been questionable in some cases. In addition, the document itself is somewhat oudated now as these openings are "Rated" as strong for white, neutral, or strong for black, and in many cases the rating is clearly wrong based on today's knowledge of the game. Still, as a historical archive it is a very interesting read.

In my opinion, an opening book for an AI program that would potentially be used by many casual players and competitive players of many different skill levels should not be as limited as Zoey is suggesting. Many of these players might be playing against this AI primarily as a learning tool, and as such it would be important to expose these players to a variety of positions that they might encounter against future opponents.

I think the book should include 14 first move responses of:

L10, L9, M10, M9, M8, N10, N9, N8, N7, O10, O9, O8, O7 and O6

but with special attention paid to:

L10, L9, M9, N9, N8, O9, O8 and O7

Instead of thinking of white as always choosing the "best" move, I think it would be better to program the AI, or especially the opening book, to include a variety of moves so that a player can get a more full experience by playing against this AI over and over again. For example, at least as far as black's 4th move, I'd like to see at least 3 options for every possible move included in the opening book. In some cases, especially for the most complex first responses (L10, L9, M9, N9, N8), I'd like to see many more moves included by both sides, especially within the very early moves. For example, it's pretty difficult for white to actually play a losing 2nd move. So why not add some variety?

If we took just the five first responses of L10, L9, M9, N9 and N8 and created a tree of moves that included 3 options for every ply, we'd end up with 729 openings for each of these 5 first responses (3645 total entries). A bit cumbersome, but not totally outrageous.

To be more robust, I think it would be great if the earlier moves had even more options, since one of the weaknesses of an AI algorithm would be if it were to be forced off of the opening book very early and it was forced to evaluate an extremely early position accurately with almost no stones in play. For example, if these 5 opening moves had 5 choices for white's 2nd move and these each had 5 responses, then the 3rd moves had 4 each, the 4th moves had 3 each, the 5th moves had 2 each and the 6th move optimal choices were included, we would end up with 14,400 openings for each of these 5 first responses (72,000 total entries). This starts to get beyond what a couple of people could easily come up with manually and still have it be somewhat accurate, but not impossible.

If such a move tree could be created by experts through a combination of manual analysis, database mining and AI searching, it would be useful if each of these positions along the way were ranked and scored. Again, this would be done through some combination of expert opinion, database win% results and AI search scoring. If this were done, you could potentially include various game modes in your AI program (for white) such as "Always Choose The Best Line", or "Choose Randomly From Among All Known Winning Lines" or even "Intentionally Choose a Losing Move on Move #X", and so on.

Even in the regular AI algorithm portions of the program while playing out the midgame and endgame, I think that it would be useful if the AI could be set to different modes like this. Even something like having the AI pick from among its top 3 scoring moves in each position as long as each move is scored within a certain % of the score for it's optimal move would be useful to force a much broader sense of variety so that you do not always get stuck playing the same line against the AI since it always responds the same way (something that mm_ai suffers from unless you change it's search depth or something in the middle of a game).

Unfortunately, at this time I'm both extremely rusty with my knowledge of the game and also am unable to commit the time to such a project, but I do have a pretty clear vision for how such a project could be accomplished successfully. Hopefully I've been able to communicate some of that here.

Good luck!

zoeyk

Posts: 2,220
Registered: Mar 4, 2007
From: San Francisco
Age: 45
Home page
Re: PentAI openings book
Posted: Apr 1, 2014, 9:08 PM

I think neither me nor up2ng are wrong. we are just approaching the opening book concept from different thinking and goals.

It is true that P1 has many ways to skin the cat. and that there is more than one perfect play opening offense for P1.

There is a grand master player viktor barikyn that likes to play O10 as whites second vs all P2 first moves. good for him lol.

for me, when making a opening book, especially for P1, there are some things i must consider, since my name is going on it, and I have limited time due to having a kid and life in general.

1- When designing perfect play I try to list what i know best. in my developing history of playing seriously, I always try to pick one perfect P1 offense to each P2 attack. (this re-develops over time as we as a community discover exploits over the years). I like to have a singular path that is my go to, so that I can master that path. and i try to use the best one, meaning the one i have determined to be the path of least resistance or least struggle, most intuitive (for me). I realize the paths i chose are just my opinion.


2- When making a opening book, If I design multiple choices for P1, aside from not having as much experience in those paths, it doubles, triples, the time it takes me to write such a book. With time limitations being a factor, a single path is better than none. and a single strong path is better than a bunch of random poorly thought out paths. (in my humble opinion)



UP2NG SAID:
I think the book should include 14 first move responses of:

L10, L9, M10, M9, M8, N10, N9, N8, N7, O10, O9, O8, O7 and O6

but with special attention paid to:

L10, L9, M9, N9, N8, O9, O8 and O7





Yes Dean, I agree. You are very correct.

(However you failed to say special attention to K8 and M8 as needing special attention, they are just as important IMO. K8 as you know can directly attempt a K10 divergence, Draw, etc.. you know what i mean.)

And would be what i would do if writing such. I just haven't had time to get that far yet. K9 and L9 are most common and 2 of the strongest so is why i started there.

Scire hostis animum - Intelligere ludum - Nosce te ipsum - Prima moventur conciliat - Nolite errare
cropleyb

Posts: 19
Registered: Mar 11, 2014
Re: PentAI openings book
Posted: Apr 2, 2014, 4:33 AM

Hi again Zoek

I've removed some of this to keep it brief...

>> How many moves into a game should an openings book(s)
>> go?
>
>at least to P1's 3rd,.. the more the better of course,.. but every time you
>add a new level to the move tree the amount of input time increases
>massively,.. comes down to how much time the opening book designer
> has. but the main lines like the wedge and boston variants should be
> put in much more than just first 3 moves for examples.

Well I'll probably start with what you've put posted already, and add to it as everyone gets time. (including me )

>> I presume that the moves made by P1 that post are
>> good ones too, so I can create a P1 book as well?
>
>Im not sure what you meant here...

If your book is for P2's 3rd move, then I assume that means that P1s 2nd moves were close to optimal too?

>> Whether we call it one book or two, it amounts to the
>> same thing - positions where P1 is to move always
>> have a total number of pieces on the board that is
>> even, for P2 the total is odd.
>
>not sure what this means, trying to imagine what you mean, and am finding myself slow here...

P1 only uses the positions where it is P1's turn to move, P2 only uses the positions where it is P2's turn. So for example if the board is completely empty, it must be P1's turn, and an empty board should not appear in P2's book. From any position, we can tell whose turn it is to move by the total number of pieces on the board - even -> P1s turn; odd -> P2s turn. So the openings books for each player could be combined into one data structure, or not; there would still be a logical difference between the positions looked up by P1 and P2.

>> However, how the AI players use the book for P1 and
>> P2 could be different.
>
> I would need an example to grasp what you mean here.

Like we've been talking about - P1 just using the best move in the book for that position, versus P2 using psychological and/or statistical methods to choose which book move to make.

>> I don't really have much of an understanding of
>> "Adzi"

> Yes, maybe it will come up with adzi moves coincidentally.
> but to speak of adzi should understand its concept.

I'll be quiet about it then

> yes there is interesting problem in my program about
> this issue. record going to destination both ways, hit destination,
> and half the time when rewinding moves from where you came its goes
> back a sequence that you did not come from,.. which is very annoying
> glitch i must say....

You might like to implement a transposition table like I described -
look up each position to see if it has been searched already first.
If you use a hash table then the lookup is fairly quick.

>> By translational symmetry, I mean positions that are
>> the same but shifted sideways a bit.
>
> I think i get it but almost want to ask for two image examples,
> but i guess your saying its a moot point any ways,.. so ill just assume
> i get you i guess.

Here's a trivial example:
1. K10
compared with:
1. J10
It's the same position, but shifted one to the left. (I know P1 must play 1. at K10 with tournament rules; this is just an example)

Thanks again,
Bruce

cropleyb

Posts: 19
Registered: Mar 11, 2014
Re: PentAI openings book
Posted: Apr 2, 2014, 6:16 AM

Hi up2ng

[I've trimmed this heavily too]

> I've been extremely inactive around here for quite a while but I just happened to see this topic of an opening book being discussed and I found it very interesting.

Great

Thanks for the info about mm_ai.

> In my opinion, an opening book for an AI program that would potentially be used by many casual players and competitive players of many different skill levels should not be as limited as Zoey is suggesting.

The AI doesn't have to make a move from the book, it can default to doing a search that does or doesn't include the moves in the book, based on how well it is asked to play. Or there could be some knowledge about the strength of each move stored in the book, that could be used according to the selected skill level.

> Many of these players might be playing against this AI primarily as a learning tool, and as such it would be important to expose these players to a variety of positions that they might encounter against future opponents.

I have built in some selectably scalable randomness which hopefully deals with this.


> To be more robust, I think it would be great if the earlier moves had even more options, since one of the weaknesses of an AI algorithm would be if it were to be forced off of the opening book very early and it was forced to evaluate an extremely early position accurately with almost no stones in play.

If it gets out of the book, it can get back into it if the position matches one in the book exactly again; it is not a list of moves, it is a set of positions.
Even if it does get pushed out of the book, it should play fairly well. If it loses, the whole game can be stored in the book so next time it could play something better. Hypothetically

> If such a move tree could be created by experts through a combination of manual analysis, database mining and AI searching, it would be useful if each of these positions along the way were ranked and scored. Again, this would be done through some combination of expert opinion, database win% results and AI search scoring. If this were done, you could potentially include various game modes in your AI program (for white) such as "Always Choose The Best Line", or "Choose Randomly From Among All Known Winning Lines" or even "Intentionally Choose a Losing Move on Move #X", and so on.

At the moment, PentAI uses a probablistic approach with moves that have won more often given more weight, and the possibility of falling through to a normal search.

> Even in the regular AI algorithm portions of the program while playing out the midgame and endgame, I think that it would be useful if the AI could be set to different modes like this. Even something like having the AI pick from among its top 3 scoring moves in each position as long as each move is scored within a certain % of the score for it's optimal move would be useful to force a much broader sense of variety so that you do not always get stuck playing the same line against the AI since it always responds the same way (something that mm_ai suffers from unless you change it's search depth or something in the middle of a game).

Interesting idea, I think I'll try it out.

> Good luck!

Thanks,
Bruce

zoeyk

Posts: 2,220
Registered: Mar 4, 2007
From: San Francisco
Age: 45
Home page
Re: PentAI openings book
Posted: Apr 2, 2014, 8:29 AM

Hi Bruce,

My apologies in advance for my long winded rambling here, and or beating any dead horses.


The moves ive published, and any others i may offer, are of course open source. as such you may mix in other peoples moves too all you like for example. matters not to me. I only ask that if my moves are used in a opening book and but they are altered by having other's people's moves combined just make sure not to say on the app "opening book by Zoeyk" for example.



you said:
>If your book is for P2's 3rd move, then I assume that means that P1s 2nd moves were close to optimal too?



1- so far i didn't put P2 3rd move in that thread.

2- if I did, at minimum P2's 3rd(s) would be as optimal as I could muster. after that i may or may not address adding in weak P2 moves, and or medium strength ones.(but only for the purpose of P1 to then respond to with a strong 4th)

3- In Player 2's book Player 1 would not just play best moves. Player one would play bad moves, medium moves, and strong moves. because in that situation we know that since
player 2 is the computer, then Player 1 must be human, therefore player 1 (being a human) could make any kind of move, weak or strong. and as such the AI would have a P2 plan in the book for any level of offense Player 1 tries.

P2 functions on needing to have many paths, both due to Player 1 variables of play, but also to switch up with new tricks and illusions when the first attempt to trick P1 didn't work.(especially when the human P1 uses a singular path of strong play)

Player one does not rely on trickery, therefore Player one only requires a single path to win. (even tho P1 can win by multiple paths, it is not necessary, as fun as it may be.)

P2 has lost the game before the game started,... thus needs a larger and more unique data base to reference from to trick the human.


The only way i see to combine the two different opening books, is to put a value on the moves.

I.E.,
K10 white has sure win,
K9 unknown if white wins 50-50 odds,
K8 white has sure loss.

and visa versa for Black (P2)

and the 50-50 odds value is of course optional unlike the other two of a binary yes or no value.


That being said, putting values, on all moves in a singular data base (opening book) for both P1 and P2, seems like a lot of work (time). but maybe I'm wrong.

I dunno, maybe I'm thinking about this all wrong, I am not a programmer. I just play a lot of pente, and am familiar with the user end of a program, and can and do make my own personal data bases and opening books for the purpose of tournaments. most of which i keep private, as that proprietary info is my non-monetary bread and butter when trying to win so to speak.


The game data bases i have made, are both bad moves and good moves of both sides all smashed together in one file. if I tell my AI to use that, it will blindly and randomly pick a move that might be good, or might be bad. It doesn't know the difference. The only reason I am able to navigate such a data base I created is because I have a good memory and remember patterns and values when digging into such a file. My brain stores info differently than a AI.



You said:
P1 only uses the positions where it is P1's turn to move, P2 only uses the positions where it is P2's turn. So for example if the board is completely empty, it must be P1's turn, and an empty board should not appear in P2's book. From any position, we can tell whose turn it is to move by the total number of pieces on the board - even -> P1s turn; odd -> P2s turn. So the openings books for each player could be combined into one data structure, or not; there would still be a logical difference between the positions looked up by P1 and P2.




The AI knows whose turn it is, so the opening books can be combined, and the AI will be able to tell the difference between good moves and bad moves, with out telling it?
I mean i get that two opening books can be combined into one data structure, and work, as long as the AI knows how to read them as separate trees from one another.

But, your the programmer, not I. It's not really my place to say what you can and can't do when it is your field you have studied in, much much more than i have. I am just having trouble visualizing it, sorry.



Adzi:
When I spoke of adzi, I just meant, you brought it up, say you don't know much about it, and I proposed that you may be interested to discuss it to learn more since it seems to be of interest to you. I in know way meant that you should not speak of it until you fully under stand it or something. I think i worded my self poorly the last time and was too vague in my meaning.




you said:
Like we've been talking about - P1 just using the best move in the book for that position, versus P2 using psychological and/or statistical methods to choose which book move to make.



interesting. so, P2 AI will use psychological methods to decide which book move to make? tell me more about this. as i didn't know AI's could do this yet. im fascinated.



you said:
You might like to implement a transposition table like I described -




I'm not programmer, just retired pente master and beta tester, and data base designer/in-putter. I leave it to you guys two code that cool stuff



Thanks,
Zoey



P.S. Is your AI built? can I play against it to see if it can beat my P2 lines?

Scire hostis animum - Intelligere ludum - Nosce te ipsum - Prima moventur conciliat - Nolite errare
zoeyk

Posts: 2,220
Registered: Mar 4, 2007
From: San Francisco
Age: 45
Home page
Re: PentAI openings book
Posted: Apr 2, 2014, 9:08 AM

K9 library in text:



K10,K9,N10,J12,L8

K10,K9,N10,K12,L8

K10,K9,N10,L12,M8

K10,K9,N10,M12,N8

K10,K9,N10,N12,J8

K10,K9,N10,O12,N12

K10,K9,N10,G11,L8

K10,K9,N10,H11,L8

K10,K9,N10,J11,L8

K10,K9,N10,K11,M12

K10,K9,N10,L11,L12

K10,K9,N10,M11,N12

K10,K9,N10,N11,M12

K10,K9,N10,O11,M12

K10,K9,N10,J10,L8

K10,K9,N10,L10,L12

K10,K9,N10,M10,N8

K10,K9,N10,O10,N8

K10,K9,N10,F9,L8

K10,K9,N10,G9,M8

K10,K9,N10,H9,M8

K10,K9,N10,J9,L9

K10,K9,N10,L9,M9

K10,K9,N10,M9,L9

K10,K9,N10,N9,L10

K10,K9,N10,O9,M8

K10,K9,N10,G8,L8

K10,K9,N10,H8,M12

K10,K9,N10,J8,L10

K10,K9,N10,L8,J10

K10,K9,N10,M8,N8

K10,K9,N10,N8,M12

K10,K9,N10,O8,M12

K10,K9,N10,H7,N8

K10,K9,N10,J7,N8

K10,K9,N10,K7,L12

K10,K9,N10,L7,L12

K10,K9,N10,M7,L8

K10,K9,N10,N7,M12

K10,K9,N10,O7,M12

Scire hostis animum - Intelligere ludum - Nosce te ipsum - Prima moventur conciliat - Nolite errare
zoeyk

Posts: 2,220
Registered: Mar 4, 2007
From: San Francisco
Age: 45
Home page
Re: PentAI openings book
Posted: Apr 2, 2014, 9:18 AM

L9 library in text:





K10,L9,N10,L13,L8

K10,L9,N10,J12,L8

K10,L9,N10,K12,L8

K10,L9,N10,L12,L8

K10,L9,N10,M12,L8

K10,L9,N10,N12,L8

K10,L9,N10,O12,K8

K10,L9,N10,G11,L8

K10,L9,N10,H11,L8

K10,L9,N10,J11,L8

K10,L9,N10,K11,L8

K10,L9,N10,L11,L8

K10,L9,N10,M11,K12

K10,L9,N10,N11,K8

K10,L9,N10,O11,M12

K10,L9,N10,H10,L8

K10,L9,N10,J10,L8

K10,L9,N10,L10,L8

K10,L9,N10,M10,K8

K10,L9,N10,O10,K8

K10,L9,N10,G9,L8

K10,L9,N10,H9,L8

K10,L9,N10,J9,L8

K10,L9,N10,K9,M9

K10,L9,N10,M9,K9

K10,L9,N10,N9,M9

K10,L9,N10,O9,K8

K10,L9,N10,P9,L8

K10,L9,N10,J8,J10

K10,L9,N10,K8,M10

K10,L9,N10,L8,L10

K10,L9,N10,N8,L8

K10,L9,N10,O8,L8

K10,L9,N10,J7,K8

K10,L9,N10,K7,L12

K10,L9,N10,L7,L8

K10,L9,N10,M7,K12

K10,L9,N10,L6,L8

K10,L9,N10,L5,L8

Scire hostis animum - Intelligere ludum - Nosce te ipsum - Prima moventur conciliat - Nolite errare
cropleyb

Posts: 19
Registered: Mar 11, 2014
Re: PentAI openings book
Posted: Apr 2, 2014, 2:15 PM

>
>Hi Bruce,
>
>My apologies in advance for my long winded rambling here, and or beating any dead horses.

As long as they're already dead, I don't mind

>The moves ive published, and any others i may offer, are of course open source. as such you may mix in other peoples moves too all you like for example. matters not to me. I only ask that if my moves are used in a opening book and but they are altered by having other's people's moves combined just make sure not to say on the app "opening book by Zoeyk" for example.

No problem. If I use other sources as well, do you want to be acknowledged as a contributor? I check all acknowledgements with people before releasing them.

>you said:
>>If your book is for P2's 3rd move, then I assume that means that P1s 2nd moves were close to optimal too?
>
>1- so far i didn't put P2 3rd move in that thread.

Oops. I'm used to P1 being black. (that's my excuse)

>2- if I did, at minimum P2's 3rd(s) would be as optimal as I could muster. after that i may or may not address adding in weak P2 moves, and or medium strength ones.(but only for the purpose of P1 to then respond to with a strong 4th)

ok

>3- In Player 2's book Player 1 would not just play best moves. Player one would play bad moves, medium moves, and strong moves. because in that situation we know that since
>player 2 is the computer, then Player 1 must be human, therefore player 1 (being a human) could make any kind of move, weak or strong. and as such the AI would have a P2 plan in the book for any level of offense Player 1 tries.

ok, good point.

>P2 functions on needing to have many paths, both due to Player 1 variables of play, but also to switch up with new tricks and illusions when the first attempt to trick P1 didn't work.(especially when the human P1 uses a singular path of strong play)

So far my DB has been made up games mostly played by the AI versus either another instance of the AI or myself. If I were to replace this with lots of games by top players, then I'd get these P2 tricks for free.

>Player one does not rely on trickery, therefore Player one only requires a single path to win. (even tho P1 can win by multiple paths, it is not necessary, as fun as it may be.)
>
>P2 has lost the game before the game started,... thus needs a larger and more unique data base to reference from to trick the human.

I see what you mean. Again, if the opening book(s) are generated from lots of top games then there will presumably be a higher number of move options from each position where it was P2's turn than for positions where it was P1s turn.

>The only way i see to combine the two different opening books, is to put a value on the moves.
>
>I.E.,
>K10 white has sure win,
>K9 unknown if white wins 50-50 odds,
>K8 white has sure loss.
>
>and visa versa for Black (P2)
>
>and the 50-50 odds value is of course optional unlike the other two of a binary yes or no value.

At the moment I use the knowledge of who won how many games from making each previously played move, from any specific position. Hmmm. That sounds like I'm speaking goobledegook again so I'll make up an example:

Position X has occurred in 6 games so far. It was P2's turn:
In 2 games, P2 played G7. Both were lost by P2
In 1 game, P2 played F8, and won
In 1 game, P2 played E9, and lost
In 2 games, P2 played H4, one won, one lost

So if the players in all the games had good and similar ratings, and we were trying to play as well as we could, we would just go with F8. My program doesn't work that way at the moment, but it could.

Instead what it does is:
Assign a value to each of the moves from X. For each game won by P2, the value increases. For each lost by P2, it goes down. The value is also scaled by the rating of the best rated player to make that move.
So continuing the example, the values might be:

F8: 2
H4: 1
E9: 0.5
G7: 0.25

Total: 3.75

Randomly choose between these moves, based on these values; the higher the value, the more likely it is to be chosen. (generate a random real number between 0 and 3.75)
There is also a chance that the move will fall through to the normal search algorithm; this chance increases if there were less games that were won by P2.

>That being said, putting values, on all moves in a singular data base (opening book) for both P1 and P2, seems like a lot of work (time). but maybe I'm wrong.

If it involves a human such as yourself looking at each position, yeah it sounds like lots of work. Loading lots of top games would be much less work. I don't know which way would give a better result, there are bound to be mistakes in the openings book either way

>I dunno, maybe I'm thinking about this all wrong, I am not a programmer. I just play a lot of pente, and am familiar with the user end of a program, and can and do make my own personal data bases and opening books for the purpose of tournaments. most of which i keep private, as that proprietary info is my non-monetary bread and butter when trying to win so to speak.

Fair enough, and thanks for sharing what you have.

>The game data bases i have made, are both bad moves and good moves of both sides all smashed together in one file. if I tell my AI to use that, it will blindly and randomly pick a move that might be good, or might be bad. It doesn't know the difference. The only reason I am able to navigate such a data base I created is because I have a good memory and remember patterns and values when digging into such a file. My brain stores info differently than a AI.

You're most likely a human (actually, I am too )

>You said:
>>P1 only uses the positions where it is P1's turn to move, P2 only uses the positions where it is P2's turn. So for example if the board is completely empty, it must be P1's turn, and an empty board should not appear in P2's book. From any position, we can tell whose turn it is to move by the total number of pieces on the board - even -> P1s turn; odd -> P2s turn. So the openings books for each player could be combined into one data structure, or not; there would still be a logical difference between the positions looked up by P1 and P2.
>
>The AI knows whose turn it is, so the opening books can be combined, and the AI will be able to tell the difference between good moves and bad moves, with out telling it?
>I mean i get that two opening books can be combined into one data structure, and work, as long as the AI knows how to read them as separate trees from one another.
>
>But, your the programmer, not I. It's not really my place to say what you can and can't do when it is your field you have studied in, much much more than i have. I am just having trouble visualizing it, sorry.

Sorry if I ramble a bit.
BTW, another way of storing it potentially would be to group all the positions firstly by the move number(ply) into the game. Then you'd have maybe 15 or so collections of positions. That would be just another implementation detail.
(oops, there I go again)

>Adzi:
>When I spoke of adzi, I just meant, you brought it up, say you don't know much about it, and I proposed that you may be interested to discuss it to learn more since it seems to be of interest to you. I in know way meant that you should not speak of it until you fully under stand it or something. I think i worded my self poorly the last time and was too vague in my meaning.

OK, no problem. My very limited memory of it is it is something similar to 'initiative' in chess. Is that right? Has there been another thread on this topic that I should read?

>you said:
>Like we've been talking about - P1 just using the best move in the book for that position, versus P2 using psychological and/or statistical methods to choose which book move to make.
>
>interesting. so, P2 AI will use psychological methods to decide which book move to make? tell me more about this. as i didn't know AI's could do this yet. im fascinated.

PentAI doesn't do any of that explicitly yet. It probably never will, cool as it may be. *sigh*

>you said:
>You might like to implement a transposition table like I described -
>
>I'm not programmer, just retired pente master and beta tester, and data base designer/in-putter. I leave it to you guys two code that cool stuff

OK.

>Thanks,
>Zoey

Thank you too!

>P.S. Is your AI built? can I play against it to see if it can beat my P2 lines?

I think you are likely to crush it most if not all games, but you're most welcome to prove it. Where would you prefer to play?

Bruce

zoeyk

Posts: 2,220
Registered: Mar 4, 2007
From: San Francisco
Age: 45
Home page
Re: PentAI openings book
Posted: Apr 2, 2014, 10:18 PM

we can play live. if you see me in the lobby of visa versa then lets meet up to try out your AI.

~Z

Scire hostis animum - Intelligere ludum - Nosce te ipsum - Prima moventur conciliat - Nolite errare
cropleyb

Posts: 19
Registered: Mar 11, 2014
Re: PentAI openings book
Posted: Apr 4, 2014, 2:23 AM

Zoeyk, great, I'll keep an eye out.

I guess my request now is for a collection of games between top players, for 19x19 and/or 13x13 boards. I have done a bit of a search online, and haven't found anything so far. Does such a thing exist?

Thanks again,
Bruce

zoeyk

Posts: 2,220
Registered: Mar 4, 2007
From: San Francisco
Age: 45
Home page
Re: PentAI openings book
Posted: Apr 4, 2014, 5:53 AM

well,.. sorta.

I can give you all pente.org games of 1750+ vs 1750+ rated players from the conception of pente.org back in 1999 up till i believe 2007. 2007 till 2014 I would need to have rainwolf do a filtered extraction. the one I have was done by the previous owner Peter aka Dweebo.

Additionally, I can give you all Brainking.com games played, but I cant filter the ranks. you'll need to filter it on your own.

Also, at some point if your wanting to use that stuff you might want to jump on team speak with me and on a board, so I can explain some things about how some of the popular openings are false data. see thing is masters used certain Player 1 offenses for years, creating huge % of wins, then in the last few years we discovered forcing exploits, which caused all of us to now change several offenses for our Player 1. SO,.. if you don't know which of these I mean, and just dump all masters data base data into the AI, it will be not good for your AI. Is better you know these main lines to delete and or modify in the ratios if you know what I mean. Only the hand full of reds that play at BK tourneys are up to speed on this stuff. Most other players are in the dark about it, and or, not in the loop.

That being said, if I tell you the recent exploits we found for your AI, some other reds could become furious with me. So, I'll need to ponder the ethics of this, and maybe ask some opinions.

As to 13x13,.. I'm not sure I can extract THAT series of games by my secret method. I can do 19x19 tho. but, Mark Mammal has a program he wrote that can do it. I'll face book him and see if he has time.

Scire hostis animum - Intelligere ludum - Nosce te ipsum - Prima moventur conciliat - Nolite errare
zoeyk

Posts: 2,220
Registered: Mar 4, 2007
From: San Francisco
Age: 45
Home page
Re: PentAI openings book
Posted: Apr 4, 2014, 6:01 AM

just went to BK to check. Seems I will need to submit a membership fee to do my trick. My rook membership expired yesterday lol. I'll get around to that at some point. I'll let you know when I do. I hate paying money to that site. and in euros no less. Hate euros, always converts to way more in USD than I hope lol.

Scire hostis animum - Intelligere ludum - Nosce te ipsum - Prima moventur conciliat - Nolite errare
zoeyk

Posts: 2,220
Registered: Mar 4, 2007
From: San Francisco
Age: 45
Home page
Re: PentAI openings book
Posted: Apr 4, 2014, 6:05 AM

Ok i do know one way you can extract 13x13 games on your own, but cant say here I'll explain it on TS, as I would likely need to help you navigate it.

Scire hostis animum - Intelligere ludum - Nosce te ipsum - Prima moventur conciliat - Nolite errare
Replies: 31   Views: 208,856   Pages: 3   [ Previous | 1 2 3 | Next ]
Back to Topic List


Powered by Jive Software