Bluff is a two-player, imperfect-information card game with experimental agents and a small web interface. The repository combines a Python game engine, several rule-based and learned agent prototypes, tournament tooling, and a FastAPI/WebSocket backend with a Next.js frontend.
- Game engine: card, hand, turn, challenge, draw, and terminal-state logic in
cards.pyandgame.py. - Agent prototypes: random, honest, card-counting, Bayesian, neural-policy, and hybrid bots under
bots/. - Training and analysis: PPO training code in
nn/and game logging and summary scripts inanalysis/. - Tournament runner:
test_bots.pyruns bot matchups and can write a game log. - Web interface: a FastAPI/WebSocket server and a Next.js client in
server.pyandfrontend/.
This is an active project and research prototype. The public branch contains implementation and experiment tooling, but does not establish that an agent is stronger than human players, solves the full game, or reliably adapts to real people. No peer-reviewed paper is included in this repository snapshot. Results should be accompanied by the code, configuration, and artifacts used to produce them.
With Python and the dependencies in requirements.txt installed:
python main.pyChoose a specific baseline with:
python main.py --bot bayesianRun a small bot tournament with:
python test_bots.py --games 20The tournament runner is an experiment script; this command is not a benchmark or evidence of agent strength. See docs/ for the rules, agent descriptions, training notes, and deployment setup.
| Path | Contents |
|---|---|
cards.py, game.py |
Cards and game state transitions |
bots/ |
Agent implementations |
nn/ |
Neural policy and training code |
analysis/ |
Game logs and evaluation summaries |
server.py, frontend/ |
Web application |
docs/ |
Project documentation |