|
| 1 | +# Workflow Transition Guide |
| 2 | + |
| 3 | +This document defines how to transition between development modes in the OCGS |
| 4 | +framework. It covers four paths: |
| 5 | + |
| 6 | +- **[Path A](#path-a-explore--hybrid)**: Pre-workflow `/explore` → Hybrid workflow |
| 7 | +- **[Path B](#path-b-explore--full-ocgs)**: Pre-workflow `/explore` → Full OCGS |
| 8 | +- **[Path C](#path-c-hybrid-discovery--full-ocgs)**: Hybrid Discovery → Full OCGS |
| 9 | +- **[Path D](#path-d-full-ocgs-prototype--production)**: Full OCGS `/prototype` → Production |
| 10 | + |
| 11 | +--- |
| 12 | + |
| 13 | +## Core Principle: Code Never Promotes |
| 14 | + |
| 15 | +**The number one rule across ALL transition paths:** |
| 16 | + |
| 17 | +> Prototype code is never refactored into production code. |
| 18 | +> Production code never imports from prototype directories. |
| 19 | +
|
| 20 | +This is not negotiable. Prototype code is written under relaxed standards: |
| 21 | +hardcoded values, no error handling, no architecture. Moving it into production |
| 22 | +creates technical debt that costs more to fix than a clean rewrite. Every path |
| 23 | +below follows this rule. |
| 24 | + |
| 25 | +**What promotes:** |
| 26 | +- Design insights and findings |
| 27 | +- Balance data that was empirically validated |
| 28 | +- Asset ideas (concept art, mood boards, placeholder specs) |
| 29 | +- Acceptance criteria that were validated in playtesting |
| 30 | + |
| 31 | +**What gets rewritten from scratch:** |
| 32 | +- All source code |
| 33 | +- Scene/level files |
| 34 | +- Configuration files (rewritten with production structure) |
| 35 | +- Asset placeholders (replaced with production-quality assets) |
| 36 | + |
| 37 | +--- |
| 38 | + |
| 39 | +## Path A: Explore → Hybrid |
| 40 | + |
| 41 | +**Trigger**: `/gate-check workflow-selection` returns Hybrid recommendation |
| 42 | +and user confirms. |
| 43 | + |
| 44 | +**Starting artifacts**: One or more reports in `prototypes/explore/*/REPORT.md` |
| 45 | +with PROMISING verdicts. |
| 46 | + |
| 47 | +### Steps |
| 48 | + |
| 49 | +1. **Archive exploration prototypes** |
| 50 | + ``` |
| 51 | + prototypes/explore/ → prototypes/archive/explore/[date]/ |
| 52 | + ``` |
| 53 | + This preserves the explore work for reference without cluttering the |
| 54 | + active prototype directory. |
| 55 | + |
| 56 | +2. **Promote the winning idea** |
| 57 | + Create an informal concept document at `design/concept.md` capturing: |
| 58 | + - The core question the winning prototype answered |
| 59 | + - Why it was chosen over alternatives |
| 60 | + - Key findings from the explore report |
| 61 | + - Estimated production effort |
| 62 | + |
| 63 | + This is NOT a formal GDD — it is a lightweight concept document for the |
| 64 | + Hybrid workflow's Discovery phase. |
| 65 | + |
| 66 | +3. **Enter Hybrid Discovery** |
| 67 | + The Hybrid workflow starts with its Discovery phase. If the winning |
| 68 | + prototype already answered the core mechanic question, you can: |
| 69 | + - Skip to `/hybrid-prototype [winning-idea]` to build a playable |
| 70 | + vertical slice |
| 71 | + - Or go directly to mapping systems with `/map-systems` |
| 72 | + - Or begin writing a GDD with `/design-system` |
| 73 | + |
| 74 | +4. **Reference explore findings** |
| 75 | + Include links to the archived explore reports in any GDD or decision |
| 76 | + document. The explore `REPORT.md` findings become the "Prior Art" that |
| 77 | + informs the GDD's rules and tuning knobs. |
| 78 | + |
| 79 | +### Artifact Map |
| 80 | + |
| 81 | +| Artifact | Action | Destination | |
| 82 | +|----------|--------|-------------| |
| 83 | +| `prototypes/explore/[idea]/REPORT.md` | Archive | `prototypes/archive/explore/[date]/[idea]/REPORT.md` | |
| 84 | +| `prototypes/explore/[idea]/code/` | Archive (never reuse) | `prototypes/archive/explore/[date]/[idea]/code/` | |
| 85 | +| Winning idea design insight | Promote | `design/concept.md` | |
| 86 | +| Balance/config data | Evaluate | Promote if proven, rewrite if uncertain | |
| 87 | +| Placeholder assets | Discard | Replace with new assets in `assets/` | |
| 88 | + |
| 89 | +--- |
| 90 | + |
| 91 | +## Path B: Explore → Full OCGS |
| 92 | + |
| 93 | +**Trigger**: `/gate-check workflow-selection` returns Full OCGS recommendation |
| 94 | +and user confirms. |
| 95 | + |
| 96 | +**Starting artifacts**: One or more reports in `prototypes/explore/*/REPORT.md` |
| 97 | +with PROMISING verdicts. |
| 98 | + |
| 99 | +### Steps |
| 100 | + |
| 101 | +1. **Archive exploration prototypes** (same as Path A) |
| 102 | + ``` |
| 103 | + prototypes/explore/ → prototypes/archive/explore/[date]/ |
| 104 | + ``` |
| 105 | + |
| 106 | +2. **Formalize the concept** |
| 107 | + Run `/brainstorm [winning-idea]` to produce a formal game concept document |
| 108 | + at `design/gdd/game-concept.md` with full MDA analysis, pillars, core loop, |
| 109 | + and player journey. |
| 110 | + |
| 111 | + The explore findings feed directly into the brainstorm — the core question |
| 112 | + has already been answered, so the concept document can be more specific |
| 113 | + than a typical brainstorm output. |
| 114 | + |
| 115 | +3. **Set up the engine** |
| 116 | + Run `/setup-engine [engine]` to pin the engine version, generate technical |
| 117 | + preferences, and populate engine reference docs. |
| 118 | + |
| 119 | +4. **Design the systems** |
| 120 | + Run `/map-systems` to enumerate all systems, then `/design-system` per |
| 121 | + system to write formal 8-section GDDs. The explore prototype's findings |
| 122 | + directly inform each GDD's rules, formulas, and tuning knobs. |
| 123 | + |
| 124 | +5. **Reference explore findings** |
| 125 | + Embed links to the archived explore `REPORT.md` files in the GDDs. For |
| 126 | + example, in the combat system GDD's "Tuning Knobs" section: "Prototype |
| 127 | + testing showed that damage values above 50 felt too punishing — validated |
| 128 | + range: 10-40." |
| 129 | + |
| 130 | +### Artifact Map |
| 131 | + |
| 132 | +| Artifact | Action | Destination | |
| 133 | +|----------|--------|-------------| |
| 134 | +| `prototypes/explore/[idea]/REPORT.md` | Archive, cross-reference | `prototypes/archive/explore/[date]/[idea]/REPORT.md` | |
| 135 | +| `prototypes/explore/[idea]/code/` | Archive (never reuse) | `prototypes/archive/explore/[date]/[idea]/code/` | |
| 136 | +| Winning idea | Formalize | `design/gdd/game-concept.md` (via `/brainstorm`) | |
| 137 | +| Prototype findings | Embed in GDDs | `design/gdd/[system].md` (Tuning Knobs, Edge Cases sections) | |
| 138 | +| Engine (none yet) | Set up | Via `/setup-engine` | |
| 139 | + |
| 140 | +--- |
| 141 | + |
| 142 | +## Path C: Hybrid Discovery → Full OCGS |
| 143 | + |
| 144 | +**Trigger**: Any of the conditions in [When to Switch to Full OCGS](hybrid-workflow.md#when-to-switch-to-full-ocgs) |
| 145 | +become true: team grows beyond 5, timeline exceeds 6 months, publisher |
| 146 | +requirements, or need for live ops / analytics / multiplayer. |
| 147 | + |
| 148 | +**Starting artifacts**: Hybrid Discovery artifacts — informal concept doc, |
| 149 | +prototypes in `prototypes/`, lightweight specs in `design/quick-specs/`. |
| 150 | + |
| 151 | +### Steps |
| 152 | + |
| 153 | +1. **Archive Discovery prototypes** |
| 154 | + ``` |
| 155 | + prototypes/[discovery-proto]/ → prototypes/archive/discovery/[date]/ |
| 156 | + ``` |
| 157 | + |
| 158 | +2. **Promote surviving designs to formal GDDs** |
| 159 | + For each system that was prototyped and validated: |
| 160 | + - Run `/design-system retrofit design/gdd/[system].md` to add the |
| 161 | + required 8 sections to any informal spec or bullet-point doc |
| 162 | + - Or run `/design-system [system]` from scratch if no document exists |
| 163 | + - Embed prototype findings (especially tuning knobs and edge cases) |
| 164 | + |
| 165 | +3. **Write ADRs for proven systems** |
| 166 | + Run `/architecture-decision` for each architectural choice that was |
| 167 | + implicitly made during prototyping: |
| 168 | + - Scene/state management approach |
| 169 | + - Data flow between systems |
| 170 | + - Save/load strategy |
| 171 | + - Input handling architecture |
| 172 | + |
| 173 | +4. **Recruit additional agents** |
| 174 | + Expand from the 4-role Hybrid roster to the full agent hierarchy. |
| 175 | + See [Slimmed Agent Hierarchy](hybrid-workflow.md#slimmed-agent-hierarchy-49--10) |
| 176 | + for which roles to add first. |
| 177 | + |
| 178 | +5. **Switch to `src/` with full coding standards** |
| 179 | + All new code goes into `src/` with doc comments, dependency injection, |
| 180 | + unit tests, and no hardcoded values. Do not move prototype code into |
| 181 | + `src/` — rewrite from scratch. |
| 182 | + |
| 183 | +6. **Enable all quality gates** |
| 184 | + - `/test-setup` to scaffold the test framework |
| 185 | + - `/qa-plan` to generate QA plans |
| 186 | + - `/gate-check` at every phase transition |
| 187 | + - Enable pre-commit hooks for validation |
| 188 | + |
| 189 | +### Artifact Map |
| 190 | + |
| 191 | +| Artifact | Action | Destination | |
| 192 | +|----------|--------|-------------| |
| 193 | +| `prototypes/[proto]/` | Archive | `prototypes/archive/discovery/[date]/` | |
| 194 | +| `design/concept.md` (informal) | Promote | `design/gdd/game-concept.md` (formalize) | |
| 195 | +| `design/quick-specs/*.md` | Retrofit | `design/gdd/[system].md` (via `/design-system retrofit`) | |
| 196 | +| Prototype code | Archive (never reuse) | `prototypes/archive/discovery/[date]/` | |
| 197 | +| Implicit architecture decisions | Document | `docs/architecture/adr-[*].md` (via `/architecture-decision`) | |
| 198 | + |
| 199 | +--- |
| 200 | + |
| 201 | +## Path D: Full OCGS Prototype → Production |
| 202 | + |
| 203 | +**Trigger**: A `/prototype` within the Full OCGS Phase 4 (Pre-Production) |
| 204 | +returns a PROCEED verdict and the creative director approves. |
| 205 | + |
| 206 | +**Starting artifacts**: `prototypes/[mechanic-name]/` with a `REPORT.md` |
| 207 | +and throwaway code. |
| 208 | + |
| 209 | +### Steps |
| 210 | + |
| 211 | +1. **Archive the prototype** |
| 212 | + ``` |
| 213 | + prototypes/[mechanic-name]/ → prototypes/archive/[date]-[mechanic-name]/ |
| 214 | + ``` |
| 215 | + |
| 216 | +2. **Update the GDD with prototype findings** |
| 217 | + Open the relevant system GDD at `design/gdd/[system].md` and add: |
| 218 | + - Updated tuning knobs and safe ranges based on prototype data |
| 219 | + - Edge cases discovered during prototyping |
| 220 | + - Acceptance criteria that were validated |
| 221 | + - Any formula adjustments found necessary |
| 222 | + |
| 223 | +3. **Create or update ADRs** |
| 224 | + If the prototype revealed architectural requirements: |
| 225 | + - Run `/architecture-decision` to record the decision |
| 226 | + - Or update an existing ADR if the decision refines a previous one |
| 227 | + |
| 228 | +4. **Create stories from prototype insights** |
| 229 | + Run `/create-stories [epic-slug]` with the prototype findings embedded |
| 230 | + in the story acceptance criteria. The prototype report's "If Proceeding" |
| 231 | + section is the direct input for implementation requirements. |
| 232 | + |
| 233 | +5. **Implement from scratch in `src/`** |
| 234 | + The production implementation is written in `src/` with full coding |
| 235 | + standards. The prototype code is reference only — do not copy, refactor, |
| 236 | + or import from it. |
| 237 | + |
| 238 | +### Artifact Map |
| 239 | + |
| 240 | +| Artifact | Action | Destination | |
| 241 | +|----------|--------|-------------| |
| 242 | +| `prototypes/[mechanic]/REPORT.md` | Archive, cross-reference | `prototypes/archive/[date]-[mechanic]/REPORT.md` | |
| 243 | +| `prototypes/[mechanic]/code/` | Archive (never reuse) | `prototypes/archive/[date]-[mechanic]/code/` | |
| 244 | +| Updated tuning ranges | Promote to GDD | `design/gdd/[system].md` (Tuning Knobs section) | |
| 245 | +| Discovered edge cases | Promote to GDD | `design/gdd/[system].md` (Edge Cases section) | |
| 246 | +| Architectural requirements | Promote to ADR | `docs/architecture/adr-[*].md` | |
| 247 | +| Implementation scope | Promote to stories | `production/epics/[slug]/story-[*].md` | |
| 248 | + |
| 249 | +--- |
| 250 | + |
| 251 | +## Quick Reference |
| 252 | + |
| 253 | +| What | Promote? | Rule | |
| 254 | +|------|----------|------| |
| 255 | +| Source code | Never | Rewrite from scratch | |
| 256 | +| Scenes / levels | Never | Rebuild from scratch | |
| 257 | +| Placeholder assets | Never | Replace with production assets | |
| 258 | +| Design insights | Always | Merge into GDDs or concept docs | |
| 259 | +| Tuning data | Evaluate | Promote if empirically validated; retest if uncertain | |
| 260 | +| Edge cases | Always | Document in GDD Edge Cases section | |
| 261 | +| Acceptance criteria | Always | Include in story files | |
| 262 | +| Architecture patterns | Evaluate | Document via ADR if proven; revisit if uncertain | |
| 263 | +| Config files | Never | Recreate with production structure | |
| 264 | +| Research notes | Always | Archive as-is for reference | |
| 265 | + |
| 266 | +--- |
| 267 | + |
| 268 | +## See Also |
| 269 | + |
| 270 | +- [`docs/hybrid-workflow.md`](hybrid-workflow.md) — Hybrid Discovery-Production workflow |
| 271 | +- [`docs/WORKFLOW-GUIDE.md`](WORKFLOW-GUIDE.md) — Full OCGS 7-phase workflow |
| 272 | +- `.opencode/skills/explore/SKILL.md` — Pre-workflow prototyping skill |
| 273 | +- `.opencode/skills/gate-check/SKILL.md` — Workflow Selection gate |
0 commit comments