Skip to content

Design: Token Gaiden v1 — multi-generation Tokegotchi RPG in the Tokade tab#21

Merged
bjamba merged 3 commits into
mainfrom
feature/tokade-tab-design
May 13, 2026
Merged

Design: Token Gaiden v1 — multi-generation Tokegotchi RPG in the Tokade tab#21
bjamba merged 3 commits into
mainfrom
feature/tokade-tab-design

Conversation

@bjamba
Copy link
Copy Markdown
Owner

@bjamba bjamba commented May 13, 2026

Docs + design assets only. Captures the design that came out of an extended back-and-forth across all six system layers + sprite system + animation rig.

Terminology

  • Tokade — the macOS app (existing brand, unchanged)
  • Tokade tab — the new tab (the container; could host other games later)
  • Token Gaiden — the v1 game inside the tab (this RPG)
  • Tokegotchi — the creature you raise across generations

What this proposes

Token Gaiden is a small RPG fed by real Claude Code telemetry:

  • Token consumption ages the Tokegotchi (model-weighted: Opus ×4 faster than Haiku)
  • Tool calls drop themed stat items (Bash → STR, Edit → DEX, WebFetch → INT, etc.)
  • File edits drop food (HP recovery); skill invocations drop SP potions
  • Projects (cwds) become regions, with language-seeded flavor and LoC-step discovery
  • Encounters mix passive auto-resolve combat with active turn-based modals (user toggle)
  • Two quest flavors: prescriptive NPC quests + implicit system achievements
  • Two-track death: peaceful natural death (no revive), HP=0 has a 24h Critical state with Revive Stone
  • 30 in-game skills: 20 combat + 10 D&D-style RPG skills for branching dialog
  • Bloodline inheritance: 30% peak stats, 100% reputation, partial skills, partial appearance

The long-term score is how many days each Tokegotchi lived, recorded in a Hall of Fame.

What's in the PR

Design docs

  • `docs/02-design/TOKADE_TAB.md` — full v1 spec: player experience, tab layout sketch, all six system layers with concrete numbers, 49 v1 cosmetics across 9 slots, sprite + animation system summary
  • `docs/adr/0005-token-gaiden-rpg-system.md` — eight architectural decisions: matrix-as-runtime, role-parameterized palette, cosmetic z-order composition, rig-based animation, state persistence, telemetry → game translation, single-game scope, region seeding

Design assets (`design/tokegotchi/`)

  • Base sprite SVG at 32×54 with named part groups for animation
  • 11 hair styles, 49 cosmetic items (hat / eyewear / shirt / pants / belt / cape / held)
  • `compose.py`, `pixelate.swift`, `bake.swift`, `render_matrix.swift`, `render.sh` — the design-time pipeline
  • `anatomy-overlay.svg` — region + anchor map for cosmetic authoring
  • 36+ reference renders (idle, walk-A, walk-B animation frames + cosmetic variations including the "weird" set)

Implementation plan

After merge, implementation lands on a fresh `productionize/token-gaiden-v1` branch following the file layout in the ADR.

🤖 Generated with Claude Code

bjamba and others added 3 commits May 13, 2026 12:11
docs/02-design/TOKADE_TAB.md
- Vision, out-of-scope, ASCII tab layout
- Tokegotchi: vitals (Energy, Hunger, Mood), mood-state mapping table,
  speech lines, age tracking, persistence at ~/.tokade/history/tokegotchi.json
- Achievements: 24 v1 badges across Volume, Model coverage, Tools+skills,
  Rhythm, Budget, Project flavor, Tokegotchi-linked
- Telemetry contract pointer to ADR

docs/adr/0005-tokade-tab-data-architecture.md
- TelemetrySnapshot value type as the single read interface
- Game protocol; @mainactor; one-file-per-game registration via allGames
- GameStateStore actor as the single write interface (~/.tokade/games/, 0600)
- File layout under Sources/Tokade/Tokade/
- Persistence rules
- Three CLAUDE.md rules to add when v1 ships
- Alternatives considered

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Captures the design that came out of an extended discussion across all
six system layers: tick economy, state model, regions, encounters,
aging/death, and skills.

docs/02-design/TOKADE_TAB.md (rewritten from premature draft)
  - Player experience + game loop
  - Tab layout sketch
  - Six layers with concrete numbers, formulas, and tables
  - 49 v1 cosmetic items across 9 slots
  - Sprite + animation system summary (links to ADR)
  - Open questions deferred to v2+

docs/adr/0005-tokade-tab-rpg-system.md (replaces premature 0005)
  - Matrix-as-runtime, SVG-as-design pipeline
  - Palette parameterization by role (not RGB)
  - Cosmetic composition via z-ordered placeholders
  - Rig-based animation (per-part transforms)
  - State persistence at ~/.tokade/games/tokegotchi.json
  - TickProcessor for telemetry-to-game translation
  - Alternatives considered

design/tokegotchi/
  - Full sprite design folder: base SVG, compose.py, pixelate.swift,
    bake.swift, render_matrix.swift, render.sh
  - hair-styles/ (11 styles)
  - shirt-styles/ (4 styles) + pants-styles/ (4 styles) + belt-styles/ (2 styles)
  - cosmetics/ (hat / eyewear / cape / held — 18 items)
  - anatomy-overlay.svg (region + anchor map)
  - animation/ (idle, walk-A, walk-B reference renders)

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- Tokade = the macOS app (unchanged)
- Tokade tab = the container tab in the app
- Token Gaiden = the v1 game in the Tokade tab (multi-generation RPG saga)
- Tokegotchi = the creature you raise (one per save, ancestors in Hall of Fame)

Renames the ADR file 0005-tokade-tab-rpg-system.md → 0005-token-gaiden-rpg-system.md
and updates header + terminology section. Updates the design doc header,
vision, tab layout, and Hall of Fame copy to match.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@bjamba bjamba changed the title Design: Tokade tab v1 (Tokegotchi + Achievements) — docs only Design: Token Gaiden v1 — multi-generation Tokegotchi RPG in the Tokade tab May 13, 2026
@bjamba bjamba merged commit b5691f5 into main May 13, 2026
1 check failed
@bjamba bjamba deleted the feature/tokade-tab-design branch May 13, 2026 23:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant