A Claude Code plugin that treats your project as a roguelike run

Roguelike

Your project is the run. Your Claude config is the deck. spire scans a repo, deals a starter deck of skills and rules for its class, then grows that deck as you clear rooms.

Beta

Systems

Developer toolsRoguelike (spire) is a Claude Code plugin that deals repo-local agent config as a deck, then grows it as you clear work.
AgenticA cheap-model curator may offer new cards after real work repeats, but you accept, skip, or prune at the campfire. Ascension never moves on its own.
Claude Agents SDKThe optional reward-loop curator uses the Claude Agent SDK. Without that soft dependency, the rest of the plugin still runs.
PythonScan, deck, reward-gate, curator, and ascension helpers are Python scripts the plugin shells out to.
YAMLClasses, detection rules, and community card packs are authored as markdown and YAML, not as new engine code.
SchemasThe durable save file (.spire/deck.json) and class detection inputs are structured contracts the engine reads and writes.
CLIOperators drive the run through /spire slash commands inside Claude Code.
TestingAscension can gate Stop on lint, tests, and coverage once you raise the tier yourself.
GitThe reward gate watches for new commits and meaningful activity before it bothers the curator at all.
Analogical reasoningSlay the Spire vocabulary (cards, relics, powers, classes, ascension) maps onto skills, CLAUDE.md rules, hooks, and repo archetypes without hiding the real files.

Run brief

Project brief

Beta

Problem

Claude config for a repo either stays generic forever or grows into an unreviewed pile of skills and rules with no feedback loop.

Outcome

A Claude Code plugin (spire) that scans a repo, deals a class-specific starter deck of skills and CLAUDE.md rules into that repo, then grows and prunes the deck through an opt-in reward and ascension loop.

Evidence

  • Public repo github.com/hhalperin/roguelike ships Acts 1-3: deterministic class scan, .spire/deck.json save file, Stop-hook reward loop with campfire review, and an A0-A20 ascension ladder.
  • Five starter classes (Defect, Silent, Ironclad, Watcher, Colorless) plus dual-class monorepo runs, with community card packs and /spire:shop already started.
  • The optional curator is a soft dependency on the Claude Agent SDK. Without it, every other command still works and the reward loop stays quiet.

Key decisions

  • Metaphor as map: Slay the Spire terms always resolve to real repo paths (skills, CLAUDE.md, hooks, .spire/deck.json).
  • Engine holds no project knowledge: everything learned is written into the target repository.
  • Human-governed growth: card offers default to skip, surface at campfire, and ascension never rises automatically.
  • Contribution surface is content: new classes and card packs in markdown and YAML, not new Python engine code.
3Acts shipped5ClassesA0-A20Ascension1Save file

The deck is the config

Roguelike is the public repo for spire, a Claude Code plugin that treats any project as a roguelike run. Cards are agent skills under .claude/skills. Relics are CLAUDE.md rules. Powers are hooks. Character class is a repo archetype detected at init. The save file is .spire/deck.json inside the target repo. Run /spire and it scans the tree, picks a class (Defect, Silent, Ironclad, Watcher, or Colorless), and deals a starter deck suited to that class. Monorepos with strong signals across two language families become dual-class runs that still share one deck.json. From there the deck grows on its own only when a Stop hook sees real work (a new commit or enough tool activity) and a cheap-model curator finds a genuinely repeated pattern. Offers surface at /spire:campfire for accept, skip, or prune. /spire:ascend raises an A0-A20 strictness ladder that rewrites only the plugin's own .claude/settings.json entry so lint, tests, and coverage start blocking Stop when you ask. The plugin holds zero project knowledge. Everything it learns about your project is written into your repo. Act 1 (starter deck), Act 2 (reward loop), and Act 3 (ascension) are shipped. Community card packs and /spire:shop are started. Adjacent agent tooling on this site includes Diagram-First, Modular Orchestration System, Drive Mode, and Agent CI/CD.

How it works

Two figures: how a /spire run deals and grows a deck inside a target repo, and how the optional reward loop decides whether to offer a card.

From scan to save file
1/spireClaude Code slash command
2Scandeterministic class detection
3Deal starter deckgateskills · CLAUDE.md relics · hooks
4Save file.spire/deck.json in the target repo
5Agent primitives.claude/skills · optional settings merge
The plugin is only the game engine. Class detection, starter cards and relics, and the durable save all land in the target repository.
Reward loop and campfire
1Stop hookreward_gate.pyalmost always a no-op
2Worth asking?gatenew commit or enough activity
3Curatoroptional Claude Agent SDKdefault to skip
4Pending offerpending-reward.json
5/spire:campfireaccept · skip · prune
Most Stop hooks do nothing. Only real work triggers a curator ask, and offers wait for /spire:campfire instead of interrupting mid-task.
Metaphor maps to filesCards are SKILL.md files, relics are CLAUDE.md rules, powers are hooks, and the save file is .spire/deck.json. The game language never replaces the real paths.
Zero project knowledge in the pluginThe engine writes everything it learns into the target repo. Run state lives under .spire/. Agent primitives stay under .claude/.
Ascension is opt-inA0 warns only. Higher tiers can block Stop on lint, tests, and coverage, but only when you run /spire:ascend.
Soft curator dependencyWithout the Claude Agent SDK, init, map, campfire pruning, shop, and ascend still work. The reward loop just stays quiet.