eisterman 4998931cb0 Drop variant B, adopt Black-belt Exam defender, add one-sidedness metrics
- Remove variant B (Brown cap, +1 for higher beating lower) from rules,
  engine, bots and simulator; a higher belt beating a lower one gains 0.
- Final Exam: the defender fights as a Black belt (RULES.md v0.7). Ties to
  the defender and best-of-3 stay as simulator switches (`--exam`).
- Report stripe income per source as gains and losses.
- Add ten one-sidedness measures sampled at turn ends (lead gap, winner
  margin and lead share, halfway leader, last lead change, contention,
  rank swaps, leader Kumite losses, Exam challengers, winner pace).
- Plan: decisions D28-D33 and the detailed Phase 6.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-09-26 17:09:42 +02:00

Il Labirinto del Dojo

A small tabletop game (1–2 h, 3–8 players, best at 4), plus the tooling used to design and balance it.

Document What it is
RULES.md The rulebook (English working draft).
board/FORMAT.md How the board is written as text.
agents/plans/ Active work plan: decisions, phases, open questions.

Setup

Requires uv. It installs the pinned Python and all tools:

uv sync

Board

The board is authored as one 8x8 quadrant in board/quadrant.txt (tunnel links in board/legend.toml) and rotated into the full 16x16 board.

uv run dojo board validate                    # check the board against the rules, print stats
uv run dojo board render                      # print the full 16x16 board
uv run dojo board render -o board/board.txt   # regenerate the full board file (never edit it by hand)
uv run dojo board validate --quadrant other.txt --legend other.toml   # check another draft

validate exits with 0 when the board is fine (warnings allowed), 1 on rule violations, 2 when the file is malformed or missing.

Simulation

Plays many seeded games with bots and prints metrics per scenario. Every combination of the listed values is a scenario; game i of each scenario uses seed --seed + i, and the lineup rotates one seat per game. Bots: random, balanced, farmer, aggressive.

uv run dojo sim                                   # 4 players, current rules, 200 games
uv run dojo sim --games 1000 --csv games.csv      # more games; one CSV row per game
uv run dojo sim --exam c none a ac                # Final Exam options in force (rules: c), combinable
uv run dojo sim --players 3 4 6 8 --start 0 3     # player counts x start position
uv run dojo sim --kiai 2 1                        # Kiai +2 vs +1
uv run dojo sim --lineup farmer aggressive,farmer # several lineups (comma-separated seats)
uv run dojo sim --seed 42 --jobs 1                # other dice; single process

Minutes are estimated as 45 s per turn plus 30 s per Kumite.

Development

uv run pytest               # tests
uv run ruff check .         # lint
uv run ruff format .        # format
uvx pyright src tests       # type check
S
Description
No description provided
Readme 172 KiB
Languages
Python 52.2%
HTML 46.9%
CSS 0.9%