This is an AI that learns to play Tic-Tac-Toe.
This is also my first AI project ever, and I have never received any formal training.
To change the functionality, toggle PLAY_TO_WIN and alter the function calls within main().
-
If PLAY_TO_WIN is true, the AI will only utilize the strongest connections within its neural network to make decisions.
-
Otherwise, it will use all of its neural connections, such that the frequency of connection usage is weighted by strength.
-
NUM_ROUNDS is the number of games to be simulated in a given run of the program.
-
Within main(), playAiXTurn() can be changed to PlayPlayerXTurn(), and it does what one might expect: It lets the player make the move, rather than the AI.
** Note: The address of the two AI save files may have to be changed in order for the program to work. This depends on operating system, file storage location, etc.
Enjoy!