@fernado03/zoo-flow 0.5.3 → 0.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +81 -78
- package/bin/zoo-flow.js +398 -50
- package/docs/architecture.md +380 -0
- package/docs/bloat-control.md +49 -0
- package/docs/command-design.md +38 -0
- package/docs/command-flow.md +133 -0
- package/docs/comparison.md +86 -0
- package/docs/context-packs.md +35 -0
- package/docs/dogfood/01-small-library.md +28 -0
- package/docs/dogfood/02-web-app.md +29 -0
- package/docs/dogfood/03-mixed-monorepo.md +29 -0
- package/docs/mode-rules.md +86 -0
- package/docs/npm-publishing.md +79 -0
- package/docs/out-of-scope/mainstream-issue-trackers-only.md +25 -0
- package/docs/out-of-scope/question-limits.md +18 -0
- package/docs/out-of-scope/setup-skill-verify-mode.md +15 -0
- package/docs/overview.md +61 -0
- package/docs/philosophy.md +73 -0
- package/docs/quality-scorecard.md +23 -0
- package/docs/skill-maintenance.md +32 -0
- package/docs/skills-index.md +61 -0
- package/docs/team-mode.md +46 -0
- package/docs/token-budget.md +22 -0
- package/docs/troubleshooting.md +288 -0
- package/examples/demo-transcripts/01-small-tweak.md +37 -0
- package/examples/demo-transcripts/02-unknown-bug-fix.md +37 -0
- package/examples/demo-transcripts/03-new-feature.md +37 -0
- package/examples/demo-transcripts/04-refactor.md +37 -0
- package/examples/demo-transcripts/05-review-and-verify.md +37 -0
- package/examples/feature-flow.md +117 -0
- package/examples/fix-flow.md +139 -0
- package/package.json +16 -5
- package/quality/scorecard.json +88 -0
- package/quality/token-budget.exceptions.json +13 -0
- package/scripts/bundle.ps1 +135 -0
- package/scripts/check-golden-transcripts.js +69 -0
- package/scripts/check-package-links.js +72 -0
- package/scripts/check-package-manifest.js +70 -0
- package/scripts/eval-routing.js +149 -0
- package/scripts/score-quality.js +292 -0
- package/scripts/test-doctor.js +107 -0
- package/scripts/test-project-shapes.js +99 -0
- package/scripts/token-budget.js +105 -0
- package/templates/full/.roo/commands/caveman.md +1 -1
- package/templates/full/.roo/commands/diagnose.md +2 -1
- package/templates/full/.roo/commands/explore.md +2 -2
- package/templates/full/.roo/commands/feature.md +1 -1
- package/templates/full/.roo/commands/fix.md +1 -1
- package/templates/full/.roo/commands/grill-me.md +2 -1
- package/templates/full/.roo/commands/grill-with-docs.md +2 -1
- package/templates/full/.roo/commands/handoff.md +2 -1
- package/templates/full/.roo/commands/improve-codebase-architecture.md +2 -1
- package/templates/full/.roo/commands/prototype.md +1 -1
- package/templates/full/.roo/commands/refactor.md +1 -1
- package/templates/full/.roo/commands/review.md +11 -0
- package/templates/full/.roo/commands/setup-matt-pocock-skills.md +1 -1
- package/templates/full/.roo/commands/tdd.md +1 -1
- package/templates/full/.roo/commands/to-issues.md +2 -1
- package/templates/full/.roo/commands/to-prd.md +2 -1
- package/templates/full/.roo/commands/triage.md +1 -1
- package/templates/full/.roo/commands/tweak.md +1 -1
- package/templates/full/.roo/commands/update-docs.md +1 -1
- package/templates/full/.roo/commands/verify.md +11 -0
- package/templates/full/.roo/commands/write-a-skill.md +2 -1
- package/templates/full/.roo/commands/zoom-out.md +2 -1
- package/templates/full/.roo/rules/01-command-protocol.md +1 -1
- package/templates/full/.roo/rules/04-context-economy.md +3 -5
- package/templates/full/.roo/rules-code-tweaker/01-completion.md +14 -8
- package/templates/full/.roo/rules-custom-orchestrator/00-routing.md +43 -11
- package/templates/full/.roo/rules-custom-orchestrator/01-delegation-message.md +11 -7
- package/templates/full/.roo/rules-system-architect/02-completion.md +6 -2
- package/templates/full/.roo/skills/engineering/README.md +2 -0
- package/templates/full/.roo/skills/engineering/commit-and-document/SKILL.md +1 -2
- package/templates/full/.roo/skills/engineering/grill-with-docs/ADR-FORMAT.md +1 -1
- package/templates/full/.roo/skills/engineering/grill-with-docs/CONTEXT-FORMAT.md +7 -32
- package/templates/full/.roo/skills/engineering/grill-with-docs/SKILL.md +1 -1
- package/templates/full/.roo/skills/engineering/improve-codebase-architecture/SKILL.md +3 -3
- package/templates/full/.roo/skills/engineering/review/SKILL.md +111 -0
- package/templates/full/.roo/skills/engineering/scaffold-context/SKILL.md +66 -0
- package/templates/full/.roo/skills/engineering/scaffold-context/templates/writing-patterns.md +17 -0
- package/templates/full/.roo/skills/engineering/setup-matt-pocock-skills/SKILL.md +3 -3
- package/templates/full/.roo/skills/engineering/setup-matt-pocock-skills/domain.md +2 -3
- package/templates/full/.roo/skills/engineering/tdd/SKILL.md +2 -0
- package/templates/full/.roo/skills/engineering/tweak/SKILL.md +2 -1
- package/templates/full/.roo/skills/engineering/verify/SKILL.md +80 -0
- package/templates/full/.roo/skills/in-progress/README.md +0 -1
- package/templates/full/.roomodes +3 -3
- package/templates/full/.zoo-flow/START_HERE.md +8 -61
- package/templates/full/.zoo-flow/evals/no-regression-checklist.md +4 -2
- package/templates/full/.zoo-flow/evals/routing-cases.jsonl +20 -0
- package/templates/full/.zoo-flow/evals/routing-cases.md +27 -3
- package/templates/full/.zoo-flow/project-profile.json +24 -0
- package/tests/fixtures/bad-routing-cases/bad-json.jsonl +1 -0
- package/tests/fixtures/bad-routing-cases/bad-mode.jsonl +1 -0
- package/tests/fixtures/bad-routing-cases/missing-command.jsonl +1 -0
- package/tests/fixtures/doctor/bad-built-in-delegation/fixture.json +1 -0
- package/tests/fixtures/doctor/bad-mode-slug/fixture.json +1 -0
- package/tests/fixtures/doctor/bad-skill-wrapper/fixture.json +1 -0
- package/tests/fixtures/doctor/bad-zoo-path/fixture.json +1 -0
- package/tests/fixtures/doctor/helper-missing-mode/fixture.json +1 -0
- package/tests/fixtures/doctor/helper-not-permitted/fixture.json +1 -0
- package/tests/fixtures/doctor/manual-good-template/fixture.json +1 -0
- package/tests/fixtures/doctor/missing-command/fixture.json +1 -0
- package/tests/fixtures/doctor/missing-roomodes/fixture.json +1 -0
- package/tests/fixtures/doctor/missing-skill/fixture.json +1 -0
- package/tests/fixtures/project-shapes/cli-tool/cmd/root.go +1 -0
- package/tests/fixtures/project-shapes/cli-tool/fixture.json +1 -0
- package/tests/fixtures/project-shapes/cli-tool/package.json +1 -0
- package/tests/fixtures/project-shapes/data-pipeline/fixture.json +1 -0
- package/tests/fixtures/project-shapes/data-pipeline/pipelines/invoices.py +1 -0
- package/tests/fixtures/project-shapes/data-pipeline/pyproject.toml +2 -0
- package/tests/fixtures/project-shapes/library/fixture.json +1 -0
- package/tests/fixtures/project-shapes/library/package.json +1 -0
- package/tests/fixtures/project-shapes/library/src/index.ts +1 -0
- package/tests/fixtures/project-shapes/monorepo/fixture.json +1 -0
- package/tests/fixtures/project-shapes/monorepo/package.json +1 -0
- package/tests/fixtures/project-shapes/monorepo/packages/core/index.ts +1 -0
- package/tests/fixtures/project-shapes/monorepo/packages/web/index.ts +1 -0
- package/tests/fixtures/project-shapes/serverless/fixture.json +1 -0
- package/tests/fixtures/project-shapes/serverless/functions/webhook.ts +1 -0
- package/tests/fixtures/project-shapes/serverless/package.json +1 -0
- package/tests/fixtures/project-shapes/web-app/app/routes/index.tsx +1 -0
- package/tests/fixtures/project-shapes/web-app/fixture.json +1 -0
- package/tests/fixtures/project-shapes/web-app/package.json +1 -0
- package/tests/golden-transcripts/01-small-tweak-golden.md +21 -0
- package/tests/golden-transcripts/02-diagnosis-golden.md +26 -0
- package/tests/golden-transcripts/03-verification-golden.md +24 -0
- package/tests/golden-transcripts/04-review-golden.md +26 -0
- package/tests/golden-transcripts/05-feature-planning-golden.md +23 -0
- package/templates/full/.roo/skills/in-progress/review/SKILL.md +0 -39
package/README.md
CHANGED
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
# Zoo Flow
|
|
2
2
|
|
|
3
|
-
> **Workflow control plane for [Zoo Code](https://docs.zoocode.dev/).**
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
3
|
+
> **Workflow control plane for [Zoo Code](https://docs.zoocode.dev/).**
|
|
4
|
+
|
|
5
|
+
Zoo Flow is a Zoo Code workflow-control template.
|
|
6
|
+
|
|
7
|
+
It does not try to be a giant skills pack. It makes Zoo Code predictable:
|
|
8
|
+
free-form requests are routed through Custom Orchestrator, risky work gets
|
|
9
|
+
planning gates, implementation stays in Code Tweaker, architecture stays in
|
|
10
|
+
System Architect, and every command follows a small command/skill contract.
|
|
9
11
|
|
|
10
12
|
For the deeper rationale, see [`docs/overview.md`](docs/overview.md)
|
|
11
13
|
and [`docs/philosophy.md`](docs/philosophy.md).
|
|
@@ -34,54 +36,37 @@ npx @fernado03/zoo-flow@latest init --force
|
|
|
34
36
|
A timestamped backup is always written to `.zoo-flow-backup/` before
|
|
35
37
|
overwrite.
|
|
36
38
|
|
|
37
|
-
After install, reload VS Code (Command Palette → **Developer: Reload
|
|
38
|
-
Window**) and open Zoo Code.
|
|
39
|
+
After install, reload VS Code (Command Palette → **Developer: Reload
|
|
40
|
+
Window**) and open Zoo Code.
|
|
41
|
+
|
|
42
|
+
## Validate Install
|
|
43
|
+
|
|
44
|
+
Use this inside a project after install or update:
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
npx @fernado03/zoo-flow@latest doctor
|
|
48
|
+
```
|
|
39
49
|
|
|
40
50
|
> **Note**: `.roomodes`, `.roo/commands/`, and `.roo/rules-{mode-slug}/`
|
|
41
51
|
> are kept as-is because they are the official Zoo Code configuration
|
|
42
52
|
> paths. Zoo Flow does not introduce a `.zoo/` directory.
|
|
43
53
|
|
|
44
|
-
## Using Zoo Flow
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
[`.zoo-flow/START_HERE.md`](templates/full/.zoo-flow/START_HERE.md)
|
|
49
|
-
|
|
50
|
-
That file explains first-run initialization, when to run
|
|
51
|
-
`/scaffold-context`, when to run `/setup-matt-pocock-skills`, and how
|
|
52
|
-
to start normal work from Custom Orchestrator mode.
|
|
53
|
-
|
|
54
|
-
For daily use, start in Custom Orchestrator mode and describe the
|
|
55
|
-
task normally. Slash commands are optional power-user shortcuts.
|
|
56
|
-
|
|
57
|
-
## Using it
|
|
54
|
+
## Using Zoo Flow
|
|
55
|
+
|
|
56
|
+
First run:
|
|
58
57
|
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
58
|
+
- Run `/scaffold-context` when the project needs local context docs.
|
|
59
|
+
- Run `/setup-matt-pocock-skills` when tracker or triage config is needed.
|
|
60
|
+
|
|
61
|
+
Daily use:
|
|
62
62
|
|
|
63
|
-
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
63
|
+
- Start in `custom-orchestrator`, describe the task normally.
|
|
64
|
+
- The orchestrator proposes a plain-language workflow; approve by number.
|
|
65
|
+
- Or type a slash command directly (`/tweak`, `/fix`, etc.) to bypass routing.
|
|
66
|
+
- Explicit slash commands count as approval. Free-form requests do not.
|
|
67
|
+
- **Clickable choices must not include slash commands or mode names.**
|
|
68
68
|
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
- **Direct slash command from any mode.** The host switches you to
|
|
72
|
-
the command's configured mode and runs it, bypassing the
|
|
73
|
-
orchestrator entirely. Use this when you already know which
|
|
74
|
-
workflow you want.
|
|
75
|
-
|
|
76
|
-
> /tweak fix the typo in `README`
|
|
77
|
-
|
|
78
|
-
When Zoo Flow asks a workflow question, reply by typing the number,
|
|
79
|
-
for example `1`.
|
|
80
|
-
|
|
81
|
-
Zoo Flow may show numbered options, but those options should be
|
|
82
|
-
plain-language choices only. They should not contain slash commands,
|
|
83
|
-
mode names, or executable routing text. See
|
|
84
|
-
[`docs/troubleshooting.md`](docs/troubleshooting.md#clickable-suggestions-can-route-incorrectly).
|
|
69
|
+
For team usage, see `docs/team-mode.md`.
|
|
85
70
|
|
|
86
71
|
## Update
|
|
87
72
|
|
|
@@ -93,17 +78,17 @@ Backs up your current `.roomodes` and `.roo/` to
|
|
|
93
78
|
`.zoo-flow-backup/<timestamp>/`, then replaces them with the latest
|
|
94
79
|
template. Preview with `--dry-run`.
|
|
95
80
|
|
|
96
|
-
##
|
|
81
|
+
## Token discipline
|
|
97
82
|
|
|
98
|
-
Zoo Flow
|
|
83
|
+
Zoo Flow keeps always-loaded rules small. Domain docs (`.zoo-flow/CONTEXT.md`, `.zoo-flow/docs/adr/`) are never read by default — only when the task touches domain language, public behavior, or architecture seams. Agents search before broad reads, use targeted line ranges when possible, and avoid re-reading unchanged files. All runtime files have tiered token budgets enforced by `scripts/token-budget.js`.
|
|
99
84
|
|
|
100
85
|
## Modes
|
|
101
86
|
|
|
102
|
-
| Slug | Name | Role | Edits allowed | Delegation |
|
|
103
|
-
| --------------------- | --------------------- | ---------------------------------------------------------- | ---------------------------------------------- | ------------------------------------------- |
|
|
104
|
-
| `custom-orchestrator` | 🪃 Custom Orchestrator | Router. Picks workflow, delegates, waits for the user. | None | `new_task` to
|
|
105
|
-
| `system-architect` | 🏗️ System Architect | Planning, diagnosis, refactor design, exploration,
|
|
106
|
-
| `code-tweaker` | ⚡ Code Tweaker | Implementation, TDD, docs
|
|
87
|
+
| Slug | Name | Role | Edits allowed | Delegation |
|
|
88
|
+
| --------------------- | --------------------- | ---------------------------------------------------------- | ---------------------------------------------- | ------------------------------------------- |
|
|
89
|
+
| `custom-orchestrator` | 🪃 Custom Orchestrator | Router. Picks workflow, delegates, waits for the user. | None | `new_task` to Zoo Flow modes only |
|
|
90
|
+
| `system-architect` | 🏗️ System Architect | Planning, diagnosis, refactor design, exploration, review. | Markdown, `.scratch/`, `docs/` | `switch_mode` to `code-tweaker` |
|
|
91
|
+
| `code-tweaker` | ⚡ Code Tweaker | Implementation, TDD, verify, docs, prototypes, commits. | Full repo edits within the assigned command | `switch_mode` to `system-architect` |
|
|
107
92
|
|
|
108
93
|
Modes are defined in
|
|
109
94
|
[`templates/full/.roomodes`](templates/full/.roomodes). The detailed
|
|
@@ -123,12 +108,14 @@ run directly inside `system-architect` or `code-tweaker` when needed.
|
|
|
123
108
|
| `/tdd` | `code-tweaker` | Test-first implementation loop. |
|
|
124
109
|
| `/prototype` | `code-tweaker` | Throwaway prototype to settle a design uncertainty. |
|
|
125
110
|
| `/update-docs` | `code-tweaker` | Reconcile docs with code reality. |
|
|
126
|
-
| `/commit-and-document` | `code-tweaker` | Stage, message, commit, journal — pauses for approval. |
|
|
127
|
-
| `/
|
|
128
|
-
| `/
|
|
129
|
-
| `/
|
|
130
|
-
| `/
|
|
131
|
-
| `/
|
|
111
|
+
| `/commit-and-document` | `code-tweaker` | Stage, message, commit, journal — pauses for approval. |
|
|
112
|
+
| `/verify` | `code-tweaker` | Run targeted tests, typecheck, lint, or build checks. |
|
|
113
|
+
| `/fix` | `system-architect` | Diagnose → implement → post-mortem chain. |
|
|
114
|
+
| `/feature` | `system-architect` | Sharpen → optional prototype → PRD → issues → TDD chain. |
|
|
115
|
+
| `/refactor` | `system-architect` | Plan and stage architecture changes. |
|
|
116
|
+
| `/explore` | `system-architect` | Map unfamiliar code before touching it. |
|
|
117
|
+
| `/triage` | `system-architect` | Clean and prioritize an issue queue. |
|
|
118
|
+
| `/review` | `system-architect` | Review a diff or branch before commit. |
|
|
132
119
|
|
|
133
120
|
### Helper (run directly when needed)
|
|
134
121
|
|
|
@@ -140,27 +127,31 @@ run directly inside `system-architect` or `code-tweaker` when needed.
|
|
|
140
127
|
| `/to-prd` | `system-architect` | Turn sharpened context into a PRD. |
|
|
141
128
|
| `/to-issues` | `system-architect` | Slice a PRD into issues. |
|
|
142
129
|
| `/zoom-out` | `system-architect` | Pull back to architectural altitude. |
|
|
143
|
-
| `/handoff` |
|
|
144
|
-
| `/grill-me` |
|
|
145
|
-
| `/caveman` |
|
|
130
|
+
| `/handoff` | `system-architect` | Produce a clean handoff package for another agent or human. |
|
|
131
|
+
| `/grill-me` | `system-architect` | Adversarial Q&A to sharpen an idea. |
|
|
132
|
+
| `/caveman` | modeless | Ultra-compressed communication style utility. |
|
|
146
133
|
| `/write-a-skill` | `code-tweaker` | Author a new skill following the bucket layout. |
|
|
147
134
|
| `/setup-matt-pocock-skills` | `code-tweaker` | One-shot setup helper for the bundled skill set. |
|
|
148
135
|
|
|
149
|
-
Command files live in
|
|
150
|
-
[`templates/full/.roo/commands/`](templates/full/.roo/commands).
|
|
136
|
+
Command files live in
|
|
137
|
+
[`templates/full/.roo/commands/`](templates/full/.roo/commands).
|
|
138
|
+
`/caveman` intentionally has no `mode:` because it changes communication style, not workflow authority.
|
|
151
139
|
|
|
152
140
|
## Worked examples
|
|
153
141
|
|
|
154
|
-
- [`examples/fix-flow.md`](examples/fix-flow.md)
|
|
155
|
-
- [`examples/feature-flow.md`](examples/feature-flow.md)
|
|
142
|
+
- [`examples/fix-flow.md`](examples/fix-flow.md)
|
|
143
|
+
- [`examples/feature-flow.md`](examples/feature-flow.md)
|
|
144
|
+
- [`examples/demo-transcripts/`](examples/demo-transcripts/)
|
|
156
145
|
|
|
157
146
|
## How this is different
|
|
158
147
|
|
|
159
|
-
Zoo Flow is not a methodology and not a giant skills pack. It is a
|
|
160
|
-
thin Zoo-native control plane: three modes, a routing matrix, and a
|
|
161
|
-
path-safety contract that turn into a predictable workflow. For a
|
|
162
|
-
longer comparison with adjacent projects, see
|
|
163
|
-
[`docs/comparison.md`](docs/comparison.md).
|
|
148
|
+
Zoo Flow is not a methodology and not a giant skills pack. It is a
|
|
149
|
+
thin Zoo-native control plane: three modes, a routing matrix, and a
|
|
150
|
+
path-safety contract that turn into a predictable workflow. For a
|
|
151
|
+
longer comparison with adjacent projects, see
|
|
152
|
+
[`docs/comparison.md`](docs/comparison.md).
|
|
153
|
+
|
|
154
|
+
For command-addition rules, see [`docs/command-design.md`](docs/command-design.md).
|
|
164
155
|
|
|
165
156
|
## Manual install
|
|
166
157
|
|
|
@@ -168,13 +159,25 @@ If you would rather copy the template by hand:
|
|
|
168
159
|
|
|
169
160
|
```sh
|
|
170
161
|
git clone https://github.com/Fernado03/zoo-flow.git /tmp/zoo-flow
|
|
171
|
-
cp /tmp/zoo-flow/templates/full/.roomodes .
|
|
172
|
-
cp -R /tmp/zoo-flow/templates/full/.roo .
|
|
173
|
-
cp -R /tmp/zoo-flow/templates/full/.zoo-flow .
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
162
|
+
cp /tmp/zoo-flow/templates/full/.roomodes .
|
|
163
|
+
cp -R /tmp/zoo-flow/templates/full/.roo .
|
|
164
|
+
cp -R /tmp/zoo-flow/templates/full/.zoo-flow .
|
|
165
|
+
touch .gitignore
|
|
166
|
+
grep -qxF "# Zoo Flow — generated config (never committed)" .gitignore 2>/dev/null || {
|
|
167
|
+
printf "\n# Zoo Flow — generated config (never committed)\n" >> .gitignore
|
|
168
|
+
printf ".roomodes\n.roo/\n.zoo-flow/\n" >> .gitignore
|
|
169
|
+
}
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
Windows uses `git clone ... C:\Temp\zoo-flow` and `Copy-Item` (including `Copy-Item -Recurse` for `.roo\` and `.zoo-flow\`) instead. Add `.roomodes`, `.roo/`, and `.zoo-flow/` to `.gitignore`.
|
|
173
|
+
|
|
174
|
+
## Development
|
|
175
|
+
|
|
176
|
+
Before publishing, run:
|
|
177
|
+
|
|
178
|
+
```bash
|
|
179
|
+
npm run release:check
|
|
180
|
+
```
|
|
178
181
|
|
|
179
182
|
## Migration
|
|
180
183
|
|