How narayan-bhattarai/baghchal works
This repository is a single-script BaghChal reinforcement-learning application. Its main workflow trains role-specific agents in self-play against the custom game environment, saves learned models or Q-tables, and evaluates results through reward and win-rate visualizations; a separate terminal mode lets a person play against trained agents. The README documents Q-Learning, SARSA, Expected SARSA, and DQN, though the supplied excerpts show only parts of their implementations. Components share DQN.py because the tree contains no separate source modules; edges reflect README statements or visible training code.
Main entry points: DQN.py Self-Play Training
Components 11
Game
- BaghChal Environment
DQN.py
RL Training
- Self-Play Training
DQN.py - Q-Learning
DQN.py - SARSA
DQN.py - Expected SARSA
DQN.py - Deep Q-Network
DQN.py - Saved Models & Tables
DQN.py
Play & Evaluation
- Terminal Game
DQN.py - Performance Evaluation
DQN.py - Training Plots
DQN.py
Other components
- Human Player
Connections 10
- Self-Play Training → BaghChal Environment: uses game
README.md - Self-Play Training → Q-Learning: trains
README.md - Self-Play Training → SARSA: trains
README.md - Self-Play Training → Expected SARSA: trains
README.md - Self-Play Training → Deep Q-Network: trains
README.md - Self-Play Training → Saved Models & Tables: saves learned state
README.md - Performance Evaluation → Self-Play Training: evaluates performance
README.md - Performance Evaluation → Training Plots: plots results
README.md - Human Player → Terminal Game: plays against
README.md - Terminal Game → Saved Models & Tables: uses trained agents
README.md