reverse-document
What it does
This skill reads existing game code or a prototype and writes the design or technical document that was never written. It is for teams who built features without documents, or inherited a project with none.
When to use it
- βWhen a feature was built without a design document and the team needs one now.
- βWhen a team inherits a codebase with no documentation and needs to understand it.
- βWhen a prototype mechanic has to be formalized into a written design.
Skill link
https://github.com/Donchitos/Claude-Code-Game-Studios/blob/main/.claude/skills/reverse-document/SKILL.mdCopy it and paste it into your AI (Claude, ChatGPT or Cursor), asking it to follow the instructions.
How to use
The easiest way: copy the message and paste it into your AI. It reads the skill and follows the instructions.
Ready-to-paste message
For Claude Code, Codex or Cursor: run it in your project folder and the skill gets installed.
Download the SKILL.md and drop it into your agentβs skills folder.
Example of what to ask your AI
βWrite a design document for the combat code in src/gameplay/combat, based on what it actually does.β
5 new skills a week. 1 minute to read.
How it works
The skill takes a document type and a path to the code, reads the implementation, and writes the matching document: a design section, an architecture decision record or a concept note. It asks for confirmation before saving.
Technical content (original SKILL.md)
Original text by the author, straight from GitHub.
Reverse Documentation
This skill analyzes existing implementation (code, prototypes, systems) and generates appropriate design or architecture documentation. Use this when:
- You built a feature without writing a design doc first
- You inherited a codebase without documentation
- You prototyped a mechanic and need to formalize it
- You need to document "why" behind existing code
Workflow
Phase 1: Parse Arguments
Format: /reverse-document <type> <path>
Type options:
designβ Generate a game design document (GDD section)architectureβ Generate an Architecture Decision Record (ADR)conceptβ Generate a concept document from prototype
Path: Directory or file to analyze, under the code root β src/ Godot,
Assets/ Unity, Source/<Module>/ Unreal (.claude/docs/code-root-resolution.md)
src/gameplay/combat/β All combat-related code (Godot)Assets/Scripts/Core/EventSystem.csβ Specific file (Unity)Source/MyGame/Private/AI/β A module folder (Unreal)prototypes/stealth-mech/β Prototype directory
!bash "${CLAUDE_SKILL_DIR}/../../hooks/yaml-helper.sh" resolve_config --keys workflow,system_overrides,automation
Automation mode: Resolve modes.automation (project.local.yaml β
project.yaml β default collaborative). Every AskUserQuestion call and
every file write follows .claude/docs/automation-modes.md
(collaborative asks always Β· guided major-only Β· autonomous logs and proceeds;
automation_always_ask categories always prompt).
Resolved above β use as-is. No block β defaults in
.claude/docs/config-resolution.md.
Resolve the workflow tier for the target system: map <path> to a system
name, then use the system_overrides row for that system if the block above
lists one, else the project workflow value. It sets how much document is
generated β see Phase 5. Semantics of each tier are in
.claude/docs/workflow-modes.md.
Resolve the tier β do not assume it.
workflow-modes.mddefines what each tier means, but it cannot say what this project is set to; take that from the block above. The consequence is large here β atfullthis skill writes an 8-section GDD and atminimala one-page brief, so a wrong tier produces the wrong artifact entirely.
Examples:
/reverse-document design src/gameplay/magic-system
/reverse-document architecture Source/MyGame/Private/EntityComponent
/reverse-document concept prototypes/vehicle-combat
Phase 2: Analyze Implementation
Read and understand the code/prototype:
For design docs (GDD):
- Identify mechanics, rules, formulas
- Extract gameplay values (damage, cooldowns, ranges)
- Find state machines, ability systems, progression
- Detect edge cases handled in code
- Map dependencies (what systems interact?)
For architecture docs (ADR):
- Identify patterns (ECS, singleton, observer, etc.)
- Understand technical decisions (threading, serialization, etc.)
- Map dependencies and coupling
- Assess performance characteristics
- Find constraints and trade-offs
For concept docs (prototype analysis):
- Identify core mechanic
- Extract emergent gameplay patterns
- Note what worked vs what didn't
- Find technical feasibility insights
- Document player fantasy / feel
Phase 3: Ask Clarifying Questions
DO NOT just describe the code. ASK about intent:
Design questions:
- "I see a [resource] system that depletes during [activity]. Was this for:
- Pacing (prevent spam)?
- Resource management (strategic depth)?
- Or something else?"
- "The [mechanic] seems central. Is this a core pillar, or supporting feature?"
- "[Value] scales exponentially with [factor]. Intentional design, or needs rebalancing?"
Architecture questions:
- "You're using a service locator pattern. Was this chosen for:
- Testability (mock dependencies)?
- Decoupling (reduce hard references)?
- Or inherited from existing code?"
- "I see manual memory management instead of smart pointers. Performance requirement, or legacy?"
Concept questions:
- "The prototype emphasizes stealth over combat. Is that the intended pillar?"
- "Players seem to exploit the grappling hook for speed. Feature or bug?"
Phase 3b: Sufficiency Check β is there enough here to document?
Run this before Phase 4, and stop here if it fails. This skill infers a design from an implementation, so when the implementation is thin there is nothing to infer from β and the template below wi
FAQ
What document types can it write?
It can write a design section, an architecture decision record, or a concept document from a prototype.
Does it document the reasons behind the code?
It documents what the code does, and the reasons are inferred from the implementation, so review them.
Does it save files without asking?
No. Writes follow the project's automation setting, which can require your approval.
Details
Original description by the author
Generate missing design or architecture docs from existing implementation β works backwards from code and prototypes.
Popularity
- GitHub stars
- 33k
- Ranking position
- #8476
- License
- MIT
- Updated
- 10/18/2026
Comments
- β¦
More skills from this repository
adopt
33kChecks whether an existing game project's documents follow the studio template's formats, then writes a numbered migration plan to fix any gaps.
architecture-decision
33kWrites an architecture decision record for a technical choice, covering context, alternatives, and consequences, with review by the right technical roles.
architecture-review
33kChecks that your technical decisions cover every design requirement, do not conflict, and fit the engine version, with a clear pass or concern verdict.
art-bible
33kWrites an art bible that defines your game's visual identity, so asset production follows one clear set of style rules.
Similar skills
technical-documentation
394kHelps your agent write and review clear technical docs and agent instruction files, so people and AI tools can follow them easily.
architecture-decision-records
280kHas your agent record important project structure decisions. It helps to understand the reasoning behind choices and maintain a clear history of changes.
code-tour
280kLets your agent create step-by-step code walkthroughs with exact file and line references. Useful for intros, explanations, and reviews.