|
| 1 | +# How to use these workorders |
| 2 | + |
| 3 | +> Audience: a coding agent (Claude Code, Cursor, Codex, etc.) **and** the |
| 4 | +> non-coding human directing it. |
| 5 | +
|
| 6 | +## TL;DR |
| 7 | + |
| 8 | +1. **Human**: Adapt `rules/user-context.template.md` for your project, save it as `~/.claude/rules/user-context.md`. |
| 9 | +2. **Human**: Read `workorders/01-scaffold.md`, replace the project-specific examples with yours. |
| 10 | +3. **Human**: Open a fresh Claude Code session, paste the adapted workorder, say *"You are the implementer. Follow this workorder. Ask me questions where you need decisions."* |
| 11 | +4. **Agent**: Reads workorder, asks questions, builds `.claude/` directory, runs the tests in the workorder, writes evidence to `~/Desktop/test-evidence-YYYYMMDD/`. |
| 12 | +5. **Human**: Reviews evidence (file paths in workorder §6), approves or sends back for fixes. |
| 13 | +6. **Repeat** for `workorders/02-skill-content.md` (writes the actual SKILL.md content). |
| 14 | + |
| 15 | +## Phase 1: scaffold |
| 16 | + |
| 17 | +What gets built: |
| 18 | + |
| 19 | +- `~/.claude/rules/` directory with 3 rule files (copy from `rules/` in this repo) + your adapted `user-context.md` |
| 20 | +- `~/.claude/hooks/` directory with 4 shell scripts (1 keyword-trigger + 3 validators) |
| 21 | +- `~/.claude/skills/<your-skill-name>/SKILL.md` placeholder |
| 22 | +- `~/.claude/settings.json` updated to register the 4 new hooks (without breaking your existing hooks) |
| 23 | + |
| 24 | +What you (the human) decide during scaffold: |
| 25 | + |
| 26 | +- **Skill name** (e.g., `<project>-production-standards`, or whatever fits your project) |
| 27 | +- **Trigger keywords** for your project's "new agent / upgrade / refactor" terms |
| 28 | +- **Whether to install globally (`~/.claude/`) or per-project (`<project>/.claude/`)** |
| 29 | +- **Names of any `verify-*` validation hooks** specific to your project's hard rules |
| 30 | + |
| 31 | +Estimated time: agent ~30-45 minutes, human ~5 minutes of decisions + 2 minutes of review. |
| 32 | + |
| 33 | +## Phase 2: skill content |
| 34 | + |
| 35 | +After scaffold passes, the SKILL.md is just a placeholder. Phase 2 fills it. |
| 36 | + |
| 37 | +What gets written into SKILL.md: |
| 38 | + |
| 39 | +- **Top-line hard rule**: "B-scenario reverse audit MUST use Read tool on existing code" |
| 40 | +- **Quality definition**: 0/1/75/100 score scale (0 = doesn't run, 75 = production complete, 100 = polished — pick your target) |
| 41 | +- **Agent type taxonomy**: 4 types (one-shot / short LLM / long no-LLM / long + LLM + GPU) |
| 42 | +- **3-scenario flow**: A (new), B (upgrade + reverse audit), C (large refactor with tag) |
| 43 | +- **21 baselines in 5 tiers** with examples for each |
| 44 | +- **Active thinking gap-filling**: agent must explicitly think "what else is missing" |
| 45 | +- **Gotchas**: 6 real incidents that hooks/skill prevent |
| 46 | +- **Design summary template**: structured output the agent produces for human approval |
| 47 | + |
| 48 | +What you decide during phase 2: |
| 49 | + |
| 50 | +- **The 21 baselines content** — what does production-ready mean *for your project*? My human's list is 80% transferable (timeout config, retry limits, resource cleanup, etc.) but 20% project-specific (e.g., "must call `notify_startup`" — your project might have a different scheduler protocol). |
| 51 | +- **Your real gotchas** — incidents your project actually had. Generic gotchas are useless. |
| 52 | +- **Existing agent classification table** — list your real agents and which type each one is. |
| 53 | + |
| 54 | +Estimated time: agent ~2-3 hours, human ~15 minutes of decisions + 10 minutes of review. |
| 55 | + |
| 56 | +## How to test that it actually works |
| 57 | + |
| 58 | +After both phases: |
| 59 | + |
| 60 | +1. Open a **new** Claude Code session (not the one that built the skill). |
| 61 | +2. Type: *"I want to upgrade `<your-existing-agent-name>` with `<new-feature>`."* |
| 62 | +3. Watch the agent's first response. It should: |
| 63 | + - Match your trigger keywords (you'll see the hook output in the session) |
| 64 | + - Activate the skill (`Skill(...) Successfully loaded skill`) |
| 65 | + - Use `Read` tool on the existing agent's code (this is the reverse-audit hard rule) |
| 66 | + - List what's missing in the existing agent (your 21 baselines) |
| 67 | + - Ask if you want to fix the missing items in this upgrade |
| 68 | + - **Not write any code yet** |
| 69 | + |
| 70 | +If the agent immediately starts writing code, the skill didn't activate. Check |
| 71 | +your `~/.claude/settings.json` and the keyword list. |
| 72 | + |
| 73 | +## What if my agent isn't Claude Code? |
| 74 | + |
| 75 | +The workorders use Claude Code-specific concepts: |
| 76 | + |
| 77 | +- `~/.claude/` directory layout |
| 78 | +- `SKILL.md` frontmatter convention |
| 79 | +- `settings.json` hook configuration |
| 80 | + |
| 81 | +If you're on Cursor / Codex / Gemini CLI / OpenCode, the directory layout and |
| 82 | +hook mechanism will differ. The **structure** (rules, hooks, skill, scaffold, |
| 83 | +content) transfers. The **paths and config syntax** don't. |
| 84 | + |
| 85 | +You'll need to adapt the workorder's commands to your agent's conventions. The |
| 86 | +21-baselines list and 3-scenario flow are agent-agnostic. |
| 87 | + |
| 88 | +## Recommended flow if you're starting fresh |
| 89 | + |
| 90 | +Don't try to do everything in one session. |
| 91 | + |
| 92 | +``` |
| 93 | +Day 1: Read workorder 01, fill out your user-context.md, decide your skill name |
| 94 | +Day 2: Run phase 1 with your agent, review, approve |
| 95 | +Day 3: Read workorder 02, decide your 21 baselines, decide your gotchas |
| 96 | +Day 4: Run phase 2 with your agent, review |
| 97 | +Day 5: Open a fresh session, do the trigger test |
| 98 | +Day 6+: Use it in real work, iterate when something feels off |
| 99 | +``` |
| 100 | + |
| 101 | +## When to *not* use this |
| 102 | + |
| 103 | +- You write your own code and have an existing engineering standards process — this workorder is overhead for you. |
| 104 | +- Your "project" is a single script — the 21-baseline tier system is overkill. |
| 105 | +- Your team already has CI / linting / code review covering the same ground — duplication. |
| 106 | + |
| 107 | +This workflow targets *non-coding humans running multi-agent pipelines* (or |
| 108 | +coding humans who specifically want to delegate the engineering standards |
| 109 | +layer). Outside that, simpler approaches exist. |
| 110 | + |
| 111 | +## Source |
| 112 | + |
| 113 | +These workorders were originally written for an AI video generation pipeline |
| 114 | +(see `README.md` for context). They're lightly desensitized — agent names and |
| 115 | +project specifics are kept as real examples; absolute paths are placeholdered. |
| 116 | + |
| 117 | +Adapting them to your project takes ~30 minutes of reading + ~30 minutes of |
| 118 | +deciding what to replace. |
0 commit comments