Hi all! just wanted to know what i could represent as the training data for the computer to learn to play a game of tic-tac-toe against a human. cheers!

anubis
—
2004-11-20T12:40:30Z —
#2

maybe you could explain a little more how your AI system works ?

NomadRock
—
2004-11-20T14:55:00Z —
#3

If you wanted AI to play tic-tac-toe you would just have it check all possible solutions, there aren't many. You can use magic square techniques to speed this up, but on modern computers slow algorithms for this will go faster than the user can click.

anubis
—
2004-11-20T17:41:32Z —
#4

better yet... precompute the whole game and save it to disk. the game tree for tic tac toe is very small so you won't have a problem with space

ShadowHawk
—
2004-11-23T07:45:19Z —
#5

Well precomputing is not really much of an AI is it. It is more a lookup table. From the formulation of the question i guess that the AI used is some sort of learning AI ( NN or genetic ) for that just make a programm that creates all the game possible states and then trian it with that. It is faster to create a programm for the testdata then to make the testdata yourself.

rego
—
2004-11-23T10:37:23Z —
#6

thank you shadowhawk that is what i meant! i will be using the back propagtion algorithm for NNs and ID3 for decision tree learning! i would be interested in using genetic learning but im not sure if it can be used for learning to play games!

many thanks!

ShadowHawk
—
2004-11-23T11:17:14Z —
#7

Be sure to post your game ( with code ) when it is done so other people can learn from it if they want. At least if u dont object to that. I for 1 would like to know how u solved the issue that a square in the game can be either black-white-open i only made a NN ( as a simple test ) to determine if a player had won or not.

anubis
—
2004-11-23T21:19:22Z —
#8

for tic tac toe you would usually use some sort of minimax/negamax algorithm and running that beforehand is as much AI as it is to use it while the game is running. of course it might be far more fun to write a programm that actually learns how to play the game... i guess i just wasn't sure what the intention of the OP was so i suggested the obvious

I was thinking candidate-elimination algorithm, Back-Propagation and Q-Learning but i don't know if these wil work!

Many Thanks

SnprBoB86
—
2004-11-27T16:48:10Z —
#13

Tic-Tac-Toe is far too simple to really get a good trial out of any more complex AI techniques. Why don't you pick something a little bit more complicated while stile simplistic in rules such as Reversi or Checkers or some other boardgame? With perfect play, Tic-Tac-Toe is always a draw... it is really quite uninteresting...

rego
—
2004-11-28T11:53:20Z —
#14

yeah i know but im already half way into the course and i cant change now - would be too much work!

NomadRock
—
2004-11-28T19:34:13Z —
#15

You need to sit down and learn what those algorithms are. Worrying about changing games is the least of your problems. If you understood the techniques you could apply them to any simple game in minutes. Try reading your textbook, and talking with your proffessor.