bitbully
This module provides the Connect Four AI agent "BitBully" with opening book support.
BitBully
A Connect Four AI agent with opening book support.
Source code in src/bitbully/bitbully.py
__init__(opening_book='default')
Initializes the BitBully agent with the specified opening book.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
opening_book
|
Literal['default', '8-ply', '12-ply', '12-ply-dist'] | None
|
The type of opening book to use. Options are: - "default": Uses the default 12-ply distance-based opening book. - "8-ply": Uses an 8-ply opening book. - "12-ply": Uses a 12-ply opening book. - "12-ply-dist": Uses a 12-ply distance-based opening book. - None: No opening book will be used. |
'default'
|
Source code in src/bitbully/bitbully.py
score_next_moves(board)
Scores all possible moves for the given board state.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
board
|
Board
|
The current board state. |
required |
Returns:
| Type | Description |
|---|---|
list[int]
|
list[int]: A list of scores for each column (0-6). |