Skip to content

This repo implements a tic tac toe ai player using Monte Carlo Tree Search algorithm, against which we can play..

Notifications You must be signed in to change notification settings

VanIro/MCTS-Tic-Tac-Toe

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MCTS-Tic-Tac-Toe

This repo implements a tic tac toe ai player using Monte Carlo Tree Search algorithm, against which we can play..

Monte Carlo Tree Search(MCTS)

Unlike minimax algorithm, which needs to create a complete game tree from a game state to take the optimal decision, MCTS just expands the better parts of the tree based on a certain number of simulations(the more the better).MCTS is much more computationally efficient than the minimax algorithm(even with $\alpha \beta$ -pruning). The simulation just chooses randomly amongst possible moves and hence no heuristic or any complex information about the game is required. Also this technique is very general.

In this case, with just 90 simulations per move(it can be reduced further, towards the later stages of the game as there will be less choices to evaluate), the ai is playing very good and I haven't won against it. You are encouraged to try against it...

Below is a sample of a game:

image

image

About

This repo implements a tic tac toe ai player using Monte Carlo Tree Search algorithm, against which we can play..

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages