Skip to main content

Python tic tac toe state generator.

Project description

Simple python implementation of Tic Tac Toe.

Designed to make GPT able to recognize valid moves in Tic Tac Toe

$ pip install tictactoe-gpt-finetuning

Examples

Generate a game:

import tictactoe_gpt_finetuning as tictactoe
print( tictactoe.generate_random_game() )

Generate many games:

import tictactoe_gpt_finetuning as tictactoe
print( tictactoe.generate_n_games() )

Initialize and use the game board to place in top left:

import tictactoe_gpt_finetuning as tictactoe
b = tictactoe.BoardState()
b.make_move( 0, 0, 'x' )
print( b )
# output:
# x - -
# - - -
# - - -

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tictactoe-gpt-finetuning-0.0.4.tar.gz (3.3 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page