Skip to content

This is a repo which develops a bot that can play guandan(a popular card game in Jiangsu, China).

Notifications You must be signed in to change notification settings

h3sun/guandan-bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

## Progress Log
### Week 1 – Monte Carlo Self-Play Demo ✅
- Implemented minimal Monte Carlo self-play loop (`rl_core/mc_selfplay_demo.py`)
- Studied MDP, Monte Carlo, and self-play mechanisms
- Next: connect to Guandan environment (`guandan_mcc/env`)

### Week 2 – Guandan Engine Foundations ✅
- Added pure-functional rule engine under `guandan_engine/` with card modeling, trump-aware pattern validation/comparison, tribute, and level progression helpers.
- Built a CLI helper (`python -m guandan_engine.ui_cli --trump-level 10 --cards "S2 H3 C4 S6 H10"`) for quick combo inspection plus a demo mode (`--demo --seed 0`) that shuffles a full hand and enumerates legal openings.
- Wrote initial pytest suite for the engine (`python -m pytest tests/test_guandan_engine.py`) covering wildcards, bombs, move gen, tribute, and level updates.
- Updated README usage instructions and established a `tmp/guandan-engine-plan.md` feature plan for future iterations.

### Command to run
```
python3 /Users/haihaosun/Desktop/focusing/github/guandan-bot/notes/rl_core/mc_selfplay_demo.py --episodes 5000 --env threecard --eps 0.2 --seed 0
```

About

This is a repo which develops a bot that can play guandan(a popular card game in Jiangsu, China).

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages