dsh-pstack 0.0.0-stage → 0.1.0
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/LICENSE +22 -0
- package/README.md +158 -2
- package/assets/agents/comment-sicko.md +32 -0
- package/assets/agents/poteto-agent.md +8 -0
- package/assets/docs/guide/01-setup.md +64 -0
- package/assets/docs/guide/02-poteto-mode.md +139 -0
- package/assets/docs/guide/03-understand.md +79 -0
- package/assets/docs/guide/04-design.md +133 -0
- package/assets/docs/guide/05-build-and-clean.md +83 -0
- package/assets/docs/guide/06-verify-and-ship.md +152 -0
- package/assets/docs/guide/07-overnight.md +122 -0
- package/assets/docs/guide/08-principles.md +72 -0
- package/assets/docs/guide/09-make-it-yours.md +100 -0
- package/assets/docs/guide/10-recipes-and-pitfalls.md +180 -0
- package/assets/docs/guide/README.md +38 -0
- package/assets/docs/harness/dsh.md +65 -0
- package/assets/docs/pstack-models.example.md +23 -0
- package/assets/skills/architect/SKILL.md +81 -0
- package/assets/skills/architect/references/design-red-flags.md +57 -0
- package/assets/skills/architect/references/rationale-template.md +35 -0
- package/assets/skills/architect/references/runner-prompt.md +20 -0
- package/assets/skills/arena/SKILL.md +50 -0
- package/assets/skills/automate-me/SKILL.md +105 -0
- package/assets/skills/benchmark-checklist/SKILL.md +41 -0
- package/assets/skills/blast-radius/SKILL.md +52 -0
- package/assets/skills/bro/SKILL.md +9 -0
- package/assets/skills/correct/SKILL.md +34 -0
- package/assets/skills/create-formal-verification-skill/SKILL.md +43 -0
- package/assets/skills/create-verification-skill/SKILL.md +46 -0
- package/assets/skills/create-verification-skill/references/feature-map-example/README.md +47 -0
- package/assets/skills/create-verification-skill/references/feature-map-example/create-note.md +39 -0
- package/assets/skills/create-verification-skill/references/feature-map-example/search.md +45 -0
- package/assets/skills/figure-it-out/SKILL.md +54 -0
- package/assets/skills/how/SKILL.md +38 -0
- package/assets/skills/how/references/explainer-prompt.md +55 -0
- package/assets/skills/how/references/explorer-prompt.md +35 -0
- package/assets/skills/in-your-own-words/SKILL.md +9 -0
- package/assets/skills/interrogate/SKILL.md +69 -0
- package/assets/skills/interrogate/references/code-quality-review.md +47 -0
- package/assets/skills/interrogate/references/lead-judgment.md +39 -0
- package/assets/skills/interrogate/references/reviewer-prompt.md +62 -0
- package/assets/skills/interrogate/references/rubric.md +77 -0
- package/assets/skills/ketchup/SKILL.md +45 -0
- package/assets/skills/maintain-formal-verification-skill/SKILL.md +60 -0
- package/assets/skills/maintain-verification-skill/SKILL.md +41 -0
- package/assets/skills/no-comments/SKILL.md +26 -0
- package/assets/skills/poteto-help/SKILL.md +161 -0
- package/assets/skills/poteto-help/references/prompting.md +51 -0
- package/assets/skills/poteto-help/references/recipes.md +51 -0
- package/assets/skills/poteto-mode/SKILL.md +153 -0
- package/assets/skills/poteto-mode/playbooks/authoring-a-skill.md +12 -0
- package/assets/skills/poteto-mode/playbooks/autonomous-run.md +13 -0
- package/assets/skills/poteto-mode/playbooks/autopilot-full.md +25 -0
- package/assets/skills/poteto-mode/playbooks/autopilot-stack.md +12 -0
- package/assets/skills/poteto-mode/playbooks/babysit.md +23 -0
- package/assets/skills/poteto-mode/playbooks/bug-fix.md +15 -0
- package/assets/skills/poteto-mode/playbooks/eval.md +25 -0
- package/assets/skills/poteto-mode/playbooks/feature.md +21 -0
- package/assets/skills/poteto-mode/playbooks/hillclimb.md +21 -0
- package/assets/skills/poteto-mode/playbooks/investigation.md +14 -0
- package/assets/skills/poteto-mode/playbooks/multi-phase-plan.md +155 -0
- package/assets/skills/poteto-mode/playbooks/opening-a-pr.md +34 -0
- package/assets/skills/poteto-mode/playbooks/orchestrate.md +112 -0
- package/assets/skills/poteto-mode/playbooks/pause-safely.md +10 -0
- package/assets/skills/poteto-mode/playbooks/perf-issue.md +25 -0
- package/assets/skills/poteto-mode/playbooks/prototype.md +14 -0
- package/assets/skills/poteto-mode/playbooks/refactoring.md +16 -0
- package/assets/skills/poteto-mode/playbooks/runtime-forensics.md +11 -0
- package/assets/skills/poteto-mode/playbooks/session-pickup.md +11 -0
- package/assets/skills/poteto-mode/playbooks/shipping.md +12 -0
- package/assets/skills/poteto-mode/playbooks/trace-forensics.md +14 -0
- package/assets/skills/poteto-mode/playbooks/visual-parity.md +11 -0
- package/assets/skills/poteto-mode/playbooks/worktree-cleanup.md +12 -0
- package/assets/skills/poteto-mode/references/bugbot-triage.md +142 -0
- package/assets/skills/poteto-mode/scripts/bootstrap.ts +62 -0
- package/assets/skills/poteto-mode/scripts/bun.lock +67 -0
- package/assets/skills/poteto-mode/scripts/check-plan.mjs +205 -0
- package/assets/skills/poteto-mode/scripts/check-plan.test.ts +96 -0
- package/assets/skills/poteto-mode/scripts/orch/orch.test.ts +761 -0
- package/assets/skills/poteto-mode/scripts/orch/orch.ts +590 -0
- package/assets/skills/poteto-mode/scripts/orch/store.ts +1677 -0
- package/assets/skills/poteto-mode/scripts/package.json +16 -0
- package/assets/skills/poteto-mode/scripts/watch-pr/cli.test.ts +224 -0
- package/assets/skills/poteto-mode/scripts/watch-pr/cli.ts +223 -0
- package/assets/skills/poteto-mode/scripts/watch-pr/fakes.test-helper.ts +129 -0
- package/assets/skills/poteto-mode/scripts/watch-pr/github.test.ts +436 -0
- package/assets/skills/poteto-mode/scripts/watch-pr/github.ts +718 -0
- package/assets/skills/poteto-mode/scripts/watch-pr/policy.test.ts +420 -0
- package/assets/skills/poteto-mode/scripts/watch-pr/policy.ts +836 -0
- package/assets/skills/poteto-mode/scripts/watch-pr/render.ts +169 -0
- package/assets/skills/poteto-mode/scripts/watch-pr/tsconfig.json +13 -0
- package/assets/skills/poteto-mode/scripts/watch-pr/types.compile.ts +93 -0
- package/assets/skills/poteto-mode/scripts/watch-pr/types.ts +413 -0
- package/assets/skills/poteto-mode/scripts/watch-pr/watch-pr +6 -0
- package/assets/skills/poteto-mode/scripts/worktree-audit.sh +127 -0
- package/assets/skills/principle-attack-the-premise/SKILL.md +23 -0
- package/assets/skills/principle-boundary-discipline/SKILL.md +36 -0
- package/assets/skills/principle-build-the-lever/SKILL.md +26 -0
- package/assets/skills/principle-encode-lessons-in-structure/SKILL.md +13 -0
- package/assets/skills/principle-exhaust-the-design-space/SKILL.md +11 -0
- package/assets/skills/principle-experience-first/SKILL.md +21 -0
- package/assets/skills/principle-explain-the-number/SKILL.md +19 -0
- package/assets/skills/principle-fix-root-causes/SKILL.md +23 -0
- package/assets/skills/principle-foundational-thinking/SKILL.md +23 -0
- package/assets/skills/principle-guard-the-context-window/SKILL.md +14 -0
- package/assets/skills/principle-laziness-protocol/SKILL.md +12 -0
- package/assets/skills/principle-make-operations-idempotent/SKILL.md +24 -0
- package/assets/skills/principle-migrate-callers-then-delete-legacy-apis/SKILL.md +16 -0
- package/assets/skills/principle-minimize-reader-load/SKILL.md +20 -0
- package/assets/skills/principle-model-the-domain/SKILL.md +26 -0
- package/assets/skills/principle-never-block-on-the-human/SKILL.md +17 -0
- package/assets/skills/principle-outcome-oriented-execution/SKILL.md +23 -0
- package/assets/skills/principle-prove-it-works/SKILL.md +24 -0
- package/assets/skills/principle-redesign-from-first-principles/SKILL.md +18 -0
- package/assets/skills/principle-separate-before-serializing-shared-state/SKILL.md +18 -0
- package/assets/skills/principle-sequence-verifiable-units/SKILL.md +19 -0
- package/assets/skills/principle-subtract-before-you-add/SKILL.md +20 -0
- package/assets/skills/principle-test-behavior-not-implementation/SKILL.md +22 -0
- package/assets/skills/principle-type-system-discipline/SKILL.md +15 -0
- package/assets/skills/recall/SKILL.md +37 -0
- package/assets/skills/reflect/SKILL.md +70 -0
- package/assets/skills/reflect/references/divergent-reviewer.md +38 -0
- package/assets/skills/reflect/references/judgment-reviewer.md +37 -0
- package/assets/skills/reflect/references/synthesizer.md +56 -0
- package/assets/skills/reflect/references/tooling-reviewer.md +48 -0
- package/assets/skills/setup-pstack/SKILL.md +76 -0
- package/assets/skills/sharpen/SKILL.md +18 -0
- package/assets/skills/show-me-your-work/SKILL.md +84 -0
- package/assets/skills/show-me-your-work/references/decision-log-template.tsv +1 -0
- package/assets/skills/show-me-your-work/scripts/log.sh +42 -0
- package/assets/skills/swarm/SKILL.md +41 -0
- package/assets/skills/tdd/SKILL.md +44 -0
- package/assets/skills/teach/SKILL.md +23 -0
- package/assets/skills/technical-writing/SKILL.md +108 -0
- package/assets/skills/typescript-best-practices/SKILL.md +32 -0
- package/assets/skills/typescript-best-practices/references/patterns.md +328 -0
- package/assets/skills/unslop/SKILL.md +64 -0
- package/assets/skills/why/SKILL.md +100 -0
- package/assets/skills/why/references/epistemics.md +71 -0
- package/assets/skills/why/references/investigator-prompt.md +84 -0
- package/assets/skills/why/references/source-playbook.md +17 -0
- package/assets/skills/why/references/sources/code-archaeology.md +51 -0
- package/assets/skills/why/references/sources/databricks.md +70 -0
- package/assets/skills/why/references/sources/datadog.md +97 -0
- package/assets/skills/why/references/sources/incident-postmortem.md +5 -0
- package/assets/skills/why/references/sources/linear.md +48 -0
- package/assets/skills/why/references/sources/notion.md +55 -0
- package/assets/skills/why/references/sources/sentry.md +66 -0
- package/assets/skills/why/references/sources/slack.md +17 -0
- package/assets/skills/why/references/synthesizer-prompt.md +129 -0
- package/cordis.patch.yml +20 -0
- package/dist/LICENSE +22 -0
- package/dist/README.md +159 -0
- package/dist/assets/agents/comment-sicko.md +32 -0
- package/dist/assets/agents/poteto-agent.md +8 -0
- package/dist/assets/docs/guide/01-setup.md +64 -0
- package/dist/assets/docs/guide/02-poteto-mode.md +139 -0
- package/dist/assets/docs/guide/03-understand.md +79 -0
- package/dist/assets/docs/guide/04-design.md +133 -0
- package/dist/assets/docs/guide/05-build-and-clean.md +83 -0
- package/dist/assets/docs/guide/06-verify-and-ship.md +152 -0
- package/dist/assets/docs/guide/07-overnight.md +122 -0
- package/dist/assets/docs/guide/08-principles.md +72 -0
- package/dist/assets/docs/guide/09-make-it-yours.md +100 -0
- package/dist/assets/docs/guide/10-recipes-and-pitfalls.md +180 -0
- package/dist/assets/docs/guide/README.md +38 -0
- package/dist/assets/docs/harness/dsh.md +65 -0
- package/dist/assets/docs/pstack-models.example.md +23 -0
- package/dist/assets/skills/architect/SKILL.md +81 -0
- package/dist/assets/skills/architect/references/design-red-flags.md +57 -0
- package/dist/assets/skills/architect/references/rationale-template.md +35 -0
- package/dist/assets/skills/architect/references/runner-prompt.md +20 -0
- package/dist/assets/skills/arena/SKILL.md +50 -0
- package/dist/assets/skills/automate-me/SKILL.md +105 -0
- package/dist/assets/skills/benchmark-checklist/SKILL.md +41 -0
- package/dist/assets/skills/blast-radius/SKILL.md +52 -0
- package/dist/assets/skills/bro/SKILL.md +9 -0
- package/dist/assets/skills/correct/SKILL.md +34 -0
- package/dist/assets/skills/create-formal-verification-skill/SKILL.md +43 -0
- package/dist/assets/skills/create-verification-skill/SKILL.md +46 -0
- package/dist/assets/skills/create-verification-skill/references/feature-map-example/README.md +47 -0
- package/dist/assets/skills/create-verification-skill/references/feature-map-example/create-note.md +39 -0
- package/dist/assets/skills/create-verification-skill/references/feature-map-example/search.md +45 -0
- package/dist/assets/skills/figure-it-out/SKILL.md +54 -0
- package/dist/assets/skills/how/SKILL.md +38 -0
- package/dist/assets/skills/how/references/explainer-prompt.md +55 -0
- package/dist/assets/skills/how/references/explorer-prompt.md +35 -0
- package/dist/assets/skills/in-your-own-words/SKILL.md +9 -0
- package/dist/assets/skills/interrogate/SKILL.md +69 -0
- package/dist/assets/skills/interrogate/references/code-quality-review.md +47 -0
- package/dist/assets/skills/interrogate/references/lead-judgment.md +39 -0
- package/dist/assets/skills/interrogate/references/reviewer-prompt.md +62 -0
- package/dist/assets/skills/interrogate/references/rubric.md +77 -0
- package/dist/assets/skills/ketchup/SKILL.md +45 -0
- package/dist/assets/skills/maintain-formal-verification-skill/SKILL.md +60 -0
- package/dist/assets/skills/maintain-verification-skill/SKILL.md +41 -0
- package/dist/assets/skills/no-comments/SKILL.md +26 -0
- package/dist/assets/skills/poteto-help/SKILL.md +161 -0
- package/dist/assets/skills/poteto-help/references/prompting.md +51 -0
- package/dist/assets/skills/poteto-help/references/recipes.md +51 -0
- package/dist/assets/skills/poteto-mode/SKILL.md +153 -0
- package/dist/assets/skills/poteto-mode/playbooks/authoring-a-skill.md +12 -0
- package/dist/assets/skills/poteto-mode/playbooks/autonomous-run.md +13 -0
- package/dist/assets/skills/poteto-mode/playbooks/autopilot-full.md +25 -0
- package/dist/assets/skills/poteto-mode/playbooks/autopilot-stack.md +12 -0
- package/dist/assets/skills/poteto-mode/playbooks/babysit.md +23 -0
- package/dist/assets/skills/poteto-mode/playbooks/bug-fix.md +15 -0
- package/dist/assets/skills/poteto-mode/playbooks/eval.md +25 -0
- package/dist/assets/skills/poteto-mode/playbooks/feature.md +21 -0
- package/dist/assets/skills/poteto-mode/playbooks/hillclimb.md +21 -0
- package/dist/assets/skills/poteto-mode/playbooks/investigation.md +14 -0
- package/dist/assets/skills/poteto-mode/playbooks/multi-phase-plan.md +155 -0
- package/dist/assets/skills/poteto-mode/playbooks/opening-a-pr.md +34 -0
- package/dist/assets/skills/poteto-mode/playbooks/orchestrate.md +112 -0
- package/dist/assets/skills/poteto-mode/playbooks/pause-safely.md +10 -0
- package/dist/assets/skills/poteto-mode/playbooks/perf-issue.md +25 -0
- package/dist/assets/skills/poteto-mode/playbooks/prototype.md +14 -0
- package/dist/assets/skills/poteto-mode/playbooks/refactoring.md +16 -0
- package/dist/assets/skills/poteto-mode/playbooks/runtime-forensics.md +11 -0
- package/dist/assets/skills/poteto-mode/playbooks/session-pickup.md +11 -0
- package/dist/assets/skills/poteto-mode/playbooks/shipping.md +12 -0
- package/dist/assets/skills/poteto-mode/playbooks/trace-forensics.md +14 -0
- package/dist/assets/skills/poteto-mode/playbooks/visual-parity.md +11 -0
- package/dist/assets/skills/poteto-mode/playbooks/worktree-cleanup.md +12 -0
- package/dist/assets/skills/poteto-mode/references/bugbot-triage.md +142 -0
- package/dist/assets/skills/poteto-mode/scripts/bootstrap.ts +62 -0
- package/dist/assets/skills/poteto-mode/scripts/bun.lock +67 -0
- package/dist/assets/skills/poteto-mode/scripts/check-plan.mjs +205 -0
- package/dist/assets/skills/poteto-mode/scripts/check-plan.test.ts +96 -0
- package/dist/assets/skills/poteto-mode/scripts/orch/orch.test.ts +761 -0
- package/dist/assets/skills/poteto-mode/scripts/orch/orch.ts +590 -0
- package/dist/assets/skills/poteto-mode/scripts/orch/store.ts +1677 -0
- package/dist/assets/skills/poteto-mode/scripts/package.json +16 -0
- package/dist/assets/skills/poteto-mode/scripts/watch-pr/cli.test.ts +224 -0
- package/dist/assets/skills/poteto-mode/scripts/watch-pr/cli.ts +223 -0
- package/dist/assets/skills/poteto-mode/scripts/watch-pr/fakes.test-helper.ts +129 -0
- package/dist/assets/skills/poteto-mode/scripts/watch-pr/github.test.ts +436 -0
- package/dist/assets/skills/poteto-mode/scripts/watch-pr/github.ts +718 -0
- package/dist/assets/skills/poteto-mode/scripts/watch-pr/policy.test.ts +420 -0
- package/dist/assets/skills/poteto-mode/scripts/watch-pr/policy.ts +836 -0
- package/dist/assets/skills/poteto-mode/scripts/watch-pr/render.ts +169 -0
- package/dist/assets/skills/poteto-mode/scripts/watch-pr/tsconfig.json +13 -0
- package/dist/assets/skills/poteto-mode/scripts/watch-pr/types.compile.ts +93 -0
- package/dist/assets/skills/poteto-mode/scripts/watch-pr/types.ts +413 -0
- package/dist/assets/skills/poteto-mode/scripts/watch-pr/watch-pr +6 -0
- package/dist/assets/skills/poteto-mode/scripts/worktree-audit.sh +127 -0
- package/dist/assets/skills/principle-attack-the-premise/SKILL.md +23 -0
- package/dist/assets/skills/principle-boundary-discipline/SKILL.md +36 -0
- package/dist/assets/skills/principle-build-the-lever/SKILL.md +26 -0
- package/dist/assets/skills/principle-encode-lessons-in-structure/SKILL.md +13 -0
- package/dist/assets/skills/principle-exhaust-the-design-space/SKILL.md +11 -0
- package/dist/assets/skills/principle-experience-first/SKILL.md +21 -0
- package/dist/assets/skills/principle-explain-the-number/SKILL.md +19 -0
- package/dist/assets/skills/principle-fix-root-causes/SKILL.md +23 -0
- package/dist/assets/skills/principle-foundational-thinking/SKILL.md +23 -0
- package/dist/assets/skills/principle-guard-the-context-window/SKILL.md +14 -0
- package/dist/assets/skills/principle-laziness-protocol/SKILL.md +12 -0
- package/dist/assets/skills/principle-make-operations-idempotent/SKILL.md +24 -0
- package/dist/assets/skills/principle-migrate-callers-then-delete-legacy-apis/SKILL.md +16 -0
- package/dist/assets/skills/principle-minimize-reader-load/SKILL.md +20 -0
- package/dist/assets/skills/principle-model-the-domain/SKILL.md +26 -0
- package/dist/assets/skills/principle-never-block-on-the-human/SKILL.md +17 -0
- package/dist/assets/skills/principle-outcome-oriented-execution/SKILL.md +23 -0
- package/dist/assets/skills/principle-prove-it-works/SKILL.md +24 -0
- package/dist/assets/skills/principle-redesign-from-first-principles/SKILL.md +18 -0
- package/dist/assets/skills/principle-separate-before-serializing-shared-state/SKILL.md +18 -0
- package/dist/assets/skills/principle-sequence-verifiable-units/SKILL.md +19 -0
- package/dist/assets/skills/principle-subtract-before-you-add/SKILL.md +20 -0
- package/dist/assets/skills/principle-test-behavior-not-implementation/SKILL.md +22 -0
- package/dist/assets/skills/principle-type-system-discipline/SKILL.md +15 -0
- package/dist/assets/skills/recall/SKILL.md +37 -0
- package/dist/assets/skills/reflect/SKILL.md +70 -0
- package/dist/assets/skills/reflect/references/divergent-reviewer.md +38 -0
- package/dist/assets/skills/reflect/references/judgment-reviewer.md +37 -0
- package/dist/assets/skills/reflect/references/synthesizer.md +56 -0
- package/dist/assets/skills/reflect/references/tooling-reviewer.md +48 -0
- package/dist/assets/skills/setup-pstack/SKILL.md +76 -0
- package/dist/assets/skills/sharpen/SKILL.md +18 -0
- package/dist/assets/skills/show-me-your-work/SKILL.md +84 -0
- package/dist/assets/skills/show-me-your-work/references/decision-log-template.tsv +1 -0
- package/dist/assets/skills/show-me-your-work/scripts/log.sh +42 -0
- package/dist/assets/skills/swarm/SKILL.md +41 -0
- package/dist/assets/skills/tdd/SKILL.md +44 -0
- package/dist/assets/skills/teach/SKILL.md +23 -0
- package/dist/assets/skills/technical-writing/SKILL.md +108 -0
- package/dist/assets/skills/typescript-best-practices/SKILL.md +32 -0
- package/dist/assets/skills/typescript-best-practices/references/patterns.md +328 -0
- package/dist/assets/skills/unslop/SKILL.md +64 -0
- package/dist/assets/skills/why/SKILL.md +100 -0
- package/dist/assets/skills/why/references/epistemics.md +71 -0
- package/dist/assets/skills/why/references/investigator-prompt.md +84 -0
- package/dist/assets/skills/why/references/source-playbook.md +17 -0
- package/dist/assets/skills/why/references/sources/code-archaeology.md +51 -0
- package/dist/assets/skills/why/references/sources/databricks.md +70 -0
- package/dist/assets/skills/why/references/sources/datadog.md +97 -0
- package/dist/assets/skills/why/references/sources/incident-postmortem.md +5 -0
- package/dist/assets/skills/why/references/sources/linear.md +48 -0
- package/dist/assets/skills/why/references/sources/notion.md +55 -0
- package/dist/assets/skills/why/references/sources/sentry.md +66 -0
- package/dist/assets/skills/why/references/sources/slack.md +17 -0
- package/dist/assets/skills/why/references/synthesizer-prompt.md +129 -0
- package/dist/cordis.patch.yml +20 -0
- package/dist/index.d.mts +16 -0
- package/dist/index.mjs +172 -0
- package/dist/index.mjs.map +1 -0
- package/dist/paths-Bbai4CaT.mjs +16 -0
- package/dist/paths-Bbai4CaT.mjs.map +1 -0
- package/dist/subagent.d.mts +130 -0
- package/dist/subagent.mjs +436 -0
- package/dist/subagent.mjs.map +1 -0
- package/package.json +92 -3
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
# Route work through `/poteto-mode`
|
|
2
|
+
|
|
3
|
+
`/poteto-mode` is the front door. You give it a goal, it matches one of twenty-three playbooks, copies that playbook's steps into the todo list, and calls the other skills as the steps need them. In this page you learn what a good prompt looks like, and how little of one you actually need.
|
|
4
|
+
|
|
5
|
+

|
|
6
|
+
|
|
7
|
+
## What happens to your prompt
|
|
8
|
+
|
|
9
|
+
```mermaid
|
|
10
|
+
flowchart TD
|
|
11
|
+
A[Your prompt] --> B[poteto-mode]
|
|
12
|
+
B --> C[Read the Principles section]
|
|
13
|
+
C --> D{Match the task}
|
|
14
|
+
D -->|Read-only question| E[Investigation]
|
|
15
|
+
D -->|Defect| F[Bug fix]
|
|
16
|
+
D -->|New behavior| G[Feature]
|
|
17
|
+
D -->|Structure only| H[Refactoring]
|
|
18
|
+
D -->|Measured slowness| I[Perf issue]
|
|
19
|
+
D -->|Large work or no match| J[figure-it-out]
|
|
20
|
+
E --> K[Verify and report]
|
|
21
|
+
F --> K
|
|
22
|
+
G --> K
|
|
23
|
+
H --> K
|
|
24
|
+
I --> K
|
|
25
|
+
J --> K
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
The diagram shows the common routes. There are also playbooks for hillclimbing a metric, diagnosing runtime symptoms and captured traces, prototypes, visual parity, authoring and evaluating skills, autonomous runs, opening a PR, babysitting a PR or stack to merge-ready, shipping a verified stack, running a PR queue or a stack on autopilot, orchestrating project-scale programs, session pickup, pausing safely, multi-phase plans, and worktree cleanup. The [playbook directory](../../skills/poteto-mode/playbooks/) has the full set.
|
|
29
|
+
|
|
30
|
+
## Say the goal, not the ceremony
|
|
31
|
+
|
|
32
|
+
You don't write a spec. You say what's wrong or what you want, plus anything you already know that saves the agent time:
|
|
33
|
+
|
|
34
|
+
```text
|
|
35
|
+
/poteto-mode users get two notifications after a retry. repro first, then fix and verify.
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
That's a Bug fix prompt. "repro first" is a real constraint, not politeness, and the playbook honors it. Watch the todo list fill with the Bug fix steps. A skipped step stays visible with `skip: <reason>`.
|
|
39
|
+
|
|
40
|
+
## What goes in a prompt
|
|
41
|
+
|
|
42
|
+
A useful prompt carries up to five things, and each one fits in a sentence:
|
|
43
|
+
|
|
44
|
+
- **The goal.** Say what's wrong, or what you want.
|
|
45
|
+
- **The done check.** It must be able to pass or fail. "Make it better" and "work on it for an hour" aren't checks.
|
|
46
|
+
- **The proof you want to see.** Ask for the real command output, a video of the flow, the stored value, or a before-and-after number.
|
|
47
|
+
- **What you already know.** A symptom, a repro step, a log line, or a link saves the agent a search.
|
|
48
|
+
- **The real constraints.** "repro first", "don't change any code yet", "zero behavior change", and "let me review before proceeding" each change what the agent does.
|
|
49
|
+
|
|
50
|
+
Here's one prompt with all five:
|
|
51
|
+
|
|
52
|
+
```text
|
|
53
|
+
/poteto-mode the csv export drops its last row since yesterday's deploy. failing job id is 4812. repro first, then fix. done means the 60k-row fixture exports every row. show me the row counts before and after.
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
Two things are worth leaving out:
|
|
57
|
+
|
|
58
|
+
- **The how.** Say what to achieve, and leave the agent room to find a better path than the one you'd pick. The same goes for a list of skills, covered in the pitfall below.
|
|
59
|
+
- **Your theory of the cause, at first.** A stated guess narrows the search to wherever you pointed. Let the agent restate the problem before you share your hunch.
|
|
60
|
+
|
|
61
|
+
For a noisy report, such as a long thread or a vague bug, make the restatement the first step:
|
|
62
|
+
|
|
63
|
+
```text
|
|
64
|
+
/poteto-mode read this thread. restate the underlying issue in your own words, in plain english. don't change any code yet.
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
A misreading shows up in the restatement, before any code exists. Correct it there, and it costs you one message instead of one wrong fix. For the restatement alone, with no playbook, run [`/in-your-own-words`](../../skills/in-your-own-words/SKILL.md). It restates what the agent thinks your goals are and what problem you're trying to solve.
|
|
68
|
+
|
|
69
|
+
When you're unsure whether a prompt is aimed right, run [`/sharpen`](../../skills/sharpen/SKILL.md) on it before you send it:
|
|
70
|
+
|
|
71
|
+
```text
|
|
72
|
+
/sharpen write a migration guide for the v2 config format.
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
The agent says what a top professional would do that you didn't ask for, the rawest material they would start from, the methods and tools they would use, and what other than you or the agent would show the result is right. Then it rewrites your prompt to ask for exactly that, deeper but not bigger, and leaves your choices open. It doesn't do the task. Read the rewrite, then send it, for example with `/poteto-mode`.
|
|
76
|
+
|
|
77
|
+
## Follow up short
|
|
78
|
+
|
|
79
|
+
When the conversation already carries the context, the prompt shrinks to almost nothing. All of these are enough:
|
|
80
|
+
|
|
81
|
+
```text
|
|
82
|
+
/poteto-mode do it
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
```text
|
|
86
|
+
continue
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
```text
|
|
90
|
+
keep going until done
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
Short works because the playbook holds the structure, and `/poteto-mode` applies to that turn. [Set up pstack](./01-setup.md#run-your-first-task) shows how to start one. Your words carry the intent, and the skill carries the rigor.
|
|
94
|
+
|
|
95
|
+
## Switch tasks with "new task"
|
|
96
|
+
|
|
97
|
+
A long chat accumulates context from the last task. When you change subjects, say so:
|
|
98
|
+
|
|
99
|
+
```text
|
|
100
|
+
/poteto-mode new task. figure out why the cache entry survives logout. don't change any code yet.
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
"new task" tells `/poteto-mode` to re-match rather than continue the prior playbook. "don't change any code yet" pins this one to Investigation. Without those two phrases, a mode mid-Feature tends to treat your question as the next feature step.
|
|
104
|
+
|
|
105
|
+
## Give parallel work its own machine
|
|
106
|
+
|
|
107
|
+
If you run several agents against one repository on one computer, they will fight over the working tree, the ports, and the build output. The cleanest isolation is a [worktree subagent](https://cursor.com/docs/subagents#cloud-subagents). Each one gets its own worktree and branch, so it can install dependencies, run your app, and record video of the result without touching your machine. Ask the parent chat to hand the work to a worktree subagent.
|
|
108
|
+
|
|
109
|
+
When the work has to stay local, ask for a worktree up front:
|
|
110
|
+
|
|
111
|
+
```text
|
|
112
|
+
/poteto-mode new task. branch off <base> in a fresh worktree, then port the parser change there.
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
Each task in its own branch and worktree means no agent stomps another's files. Worktrees cost disk and machine resources, so a laptop runs only a handful at once. The [Opening a PR playbook](../../skills/poteto-mode/playbooks/opening-a-pr.md) already works from a worktree for code changes, so mostly you only say this when a specific base or location matters.
|
|
116
|
+
|
|
117
|
+
Worktrees accumulate. When disk gets tight, ask:
|
|
118
|
+
|
|
119
|
+
```text
|
|
120
|
+
/poteto-mode what's eating my disk? prune the worktrees that are safe to prune.
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
The [Worktree cleanup playbook](../../skills/poteto-mode/playbooks/worktree-cleanup.md) classifies every worktree by merge state, uncommitted work, and which chats still touch it. It deletes only what that evidence clears and pauses for your call on anything holding uncommitted work.
|
|
124
|
+
|
|
125
|
+
## Leave it running
|
|
126
|
+
|
|
127
|
+
When you step away, say what done means and go:
|
|
128
|
+
|
|
129
|
+
```text
|
|
130
|
+
/poteto-mode im stepping away. keep going until the migration check reports zero old callers. log your decisions.
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
Work you'll review later routes through [`/figure-it-out`](../../skills/figure-it-out/SKILL.md), which designs the run's phases and keeps a [`/show-me-your-work`](../../skills/show-me-your-work/SKILL.md) decision log. [Run work while you sleep](./07-overnight.md) covers the full overnight contract.
|
|
134
|
+
|
|
135
|
+
**Pitfall:** don't enumerate skills in your prompt ("use /how, then /architect, then /arena..."). The playbook already sequences them, and a hand-written sequence usually reorders or drops steps the playbook would have kept. Name a skill only when you want to override a specific choice.
|
|
136
|
+
|
|
137
|
+
Read [`poteto-mode`](../../skills/poteto-mode/SKILL.md) itself for the full routing rules.
|
|
138
|
+
|
|
139
|
+
Next: [Understand the code](./03-understand.md).
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
# Understand the code before changing it
|
|
2
|
+
|
|
3
|
+
Editing code you don't understand is how subtle regressions ship, and that's as true for the agent as for you. Agents usually fail in one of two ways. They misread what you want, or they don't have the context to do the work right. [What goes in a prompt](./02-poteto-mode.md#what-goes-in-a-prompt) handles the first. This page handles the second.
|
|
4
|
+
|
|
5
|
+
pstack gives you four ways in. `/how` explains what the code does now. `/why` digs up the reasons it's shaped that way. `/teach` blends both into one explanation. `/recall` rebuilds your own recent context on a topic. Each one also makes the agent explain itself in words you can check. That's how you supervise an agent that may know the code better than you do.
|
|
6
|
+
|
|
7
|
+

|
|
8
|
+
|
|
9
|
+
## Start with a read-only investigation
|
|
10
|
+
|
|
11
|
+
When the cause is unclear, ask for findings, not a fix:
|
|
12
|
+
|
|
13
|
+
```text
|
|
14
|
+
/poteto-mode investigate why background jobs time out every few hours. give me what we know, what data you used, and your best hypotheses. don't change any code yet.
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
"don't change any code yet" routes this to the [Investigation playbook](../../skills/poteto-mode/playbooks/investigation.md). It runs `/how`, adds `/why` for questions about motivation, and returns a cited explanation. For a choice between options, it returns a recommendation with a trade-offs table. Asking "what data you used" makes the agent separate its evidence from its guesses. When the findings point at a fix, start the fix as a new task.
|
|
18
|
+
|
|
19
|
+
## Trace behavior with `/how`
|
|
20
|
+
|
|
21
|
+
```text
|
|
22
|
+
/how do we dedupe notifications? is there an n+1 when we look up subscribers?
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
Ask the question you actually have. [`/how`](../../skills/how/SKILL.md) reads the code and answers at the level of a senior engineer onboarding you onto the subsystem, with the runtime flow, the key types, and the non-obvious parts. For a big subsystem it fans out two to four read-only explorers first. For a narrow question it just reads and explains.
|
|
26
|
+
|
|
27
|
+
## Dig up history with `/why`
|
|
28
|
+
|
|
29
|
+
```text
|
|
30
|
+
/why was the retry limit set to five? does the reason still hold?
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
[`/why`](../../skills/why/SKILL.md) starts from source control, then queries whatever evidence categories your MCPs expose, such as the issue tracker, long-form docs, team chat, observability, error tracking, and analytics, all in parallel. The report cites everything, separates direct evidence from inference, and says "appears to" when the record is thin. A null result gets reported too, because "nobody wrote down why" is itself an answer.
|
|
34
|
+
|
|
35
|
+
The two compose naturally. `do why first then how` is a good prompt when you suspect the history explains the mess.
|
|
36
|
+
|
|
37
|
+
## Actually understand it with `/teach`
|
|
38
|
+
|
|
39
|
+
```text
|
|
40
|
+
/teach me how this PR changes retries. convince me it fixes the cause and not the symptom.
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
[`/teach`](../../skills/teach/SKILL.md) is for when a summary isn't enough. It runs `/how` and `/why`, for a small change maybe just one of them, and weaves the findings into a plain explanation that builds up diagram by diagram. The "convince me" framing is worth reusing. It turns the explanation into an argument you can test instead of a tour.
|
|
44
|
+
|
|
45
|
+
It works on the agent's own choices too:
|
|
46
|
+
|
|
47
|
+
```text
|
|
48
|
+
/teach me why you implemented it this way and not with a queue. what did you trade off, and why?
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
Teaching helps the agent as much as you. An agent that has to explain its work must read the code and back each claim with evidence, instead of stating it confidently and moving on.
|
|
52
|
+
|
|
53
|
+
## Rebuild your own context with `/recall`
|
|
54
|
+
|
|
55
|
+
```text
|
|
56
|
+
/recall catch me up on the export work from last week
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
[`/recall`](../../skills/recall/SKILL.md) mines your own recent chats plus the shared record (issues, prior fixes, errors still firing) and hands back a brief on where things stand and what's next. Your old chats hold context that a fresh agent lacks, so start new work on an old topic by loading it first, then hand over the new input:
|
|
60
|
+
|
|
61
|
+
```text
|
|
62
|
+
/recall my work on the virtualized list from yesterday, then read this bug report.
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
If you want to resume one specific chat, that's the Session pickup playbook below, not `/recall`.
|
|
66
|
+
|
|
67
|
+
## Take over prior work with Session pickup
|
|
68
|
+
|
|
69
|
+
When another agent (or you, last week) left a branch mid-flight:
|
|
70
|
+
|
|
71
|
+
```text
|
|
72
|
+
/poteto-mode take over this branch. read the decision log, figure out what's done, and continue from there. don't redo finished work.
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
The [Session pickup playbook](../../skills/poteto-mode/playbooks/session-pickup.md) treats the prior trail as authoritative. It reconstructs the branch state and decisions, names the resume point, and verifies inherited claims against the original goal instead of re-deriving everything from scratch.
|
|
76
|
+
|
|
77
|
+
**Pitfall:** don't skip this page's skills because "the agent will read the code anyway." An agent that starts editing without a traced model tends to fix the symptom at the first plausible spot. `/how` first is cheaper than the second bug.
|
|
78
|
+
|
|
79
|
+
Next: [Design the change](./04-design.md).
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
# Design before you write code
|
|
2
|
+
|
|
3
|
+
One attempt at a hard design locks in the first shape the model thought of. `/architect` settles types and boundaries before implementation. `/arena` runs several attempts at the same brief and merges the best parts. `/interrogate` has other models try to break the result. When the job is coverage rather than design synthesis, `/swarm` fans out slices or races and aggregates their results.
|
|
4
|
+
|
|
5
|
+
The two most common design mistakes are taking the agent's first design and polishing a plan that no code has tested. This page fixes both. You plan through code. Prototypes answer the open questions, a README or tutorial sets the target, and the written plan comes last.
|
|
6
|
+
|
|
7
|
+

|
|
8
|
+
|
|
9
|
+
## Settle the shape with `/architect`
|
|
10
|
+
|
|
11
|
+
```text
|
|
12
|
+
/architect design the import pipeline before writing any code. i care most about how callers use it.
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
[`/architect`](../../skills/architect/SKILL.md) grounds itself first, running `/how` over the code the design touches and `/why` when it moves ownership or layers. Then it runs `/arena` to produce competing design sketches, with the caller's usage written first in each, followed by types, signatures, and a module map.
|
|
16
|
+
|
|
17
|
+
By default it proceeds straight from the synthesized design into implementation. If you want to see the design first, say so:
|
|
18
|
+
|
|
19
|
+
```text
|
|
20
|
+
/architect with checkpoint. stop and show me before implementing.
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
The design isn't sacred once code starts. If implementation shows the same workaround in unrelated places, or types that only compile with `any` or forced casts, `/architect` treats that as proof the design is wrong. It scraps the sketch and starts over instead of patching around it.
|
|
24
|
+
|
|
25
|
+
## Fan out attempts with `/arena`
|
|
26
|
+
|
|
27
|
+
```text
|
|
28
|
+
/arena take my prompt to the arena verbatim. i want to compare their proposals with yours.
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
[`/arena`](../../skills/arena/SKILL.md) is the general tool underneath. N subagents attempt the same design or code brief in parallel, each writing to its own worktree or directory. A read-only judge, on a different model family when your configuration allows one, scores every candidate against a rubric. The coordinator reads each candidate end to end, picks a base, grafts in the best ideas from the losers, and verifies the result.
|
|
32
|
+
|
|
33
|
+
```mermaid
|
|
34
|
+
flowchart LR
|
|
35
|
+
A[One task] --> B[Configured panel]
|
|
36
|
+
B --> C[Candidate 1]
|
|
37
|
+
B --> D[Candidate 2]
|
|
38
|
+
B --> E[Candidate N]
|
|
39
|
+
C --> F[Cross-judge]
|
|
40
|
+
D --> F
|
|
41
|
+
E --> F
|
|
42
|
+
F --> G[Pick a base]
|
|
43
|
+
G --> H[Graft the best parts]
|
|
44
|
+
H --> I[Verify]
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
The panel comes from your [`/setup-pstack`](../../skills/setup-pstack/SKILL.md) configuration, and you can adjust it per task. Ask for more candidates when the decision matters, fewer when it doesn't:
|
|
48
|
+
|
|
49
|
+
```text
|
|
50
|
+
/arena this, 5 candidates. the cache key format is expensive to change later.
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
## Cover slices and races with `/swarm`
|
|
54
|
+
|
|
55
|
+
```text
|
|
56
|
+
/swarm check every package under packages/ against its check.sh. one worker per package. one report.
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
[`/swarm`](../../skills/swarm/SKILL.md) fans N workers across independent slices, coverage matrices, gauntlet lanes, exploration partitions, or declared race arms. Each worker gets its own scope and check, then reports `PASS`, `ISSUES`, or `BLOCKED`. The parent waits for the workers and returns one compact report with any gaps or dropouts.
|
|
60
|
+
|
|
61
|
+
Reach for it when parallelism buys coverage or lets independent checks race. `/arena` gives every worker the same design or code brief, then picks a base and grafts the best parts. `/swarm` covers slices or runs a race with a selection rule declared up front. It does not use the base-selection and grafting ceremony.
|
|
62
|
+
|
|
63
|
+
## Break it with `/interrogate`
|
|
64
|
+
|
|
65
|
+
```text
|
|
66
|
+
/interrogate the whole branch, but skeptically. no nitpicks unless it's an actual bug or regression.
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
[`/interrogate`](../../skills/interrogate/SKILL.md) sends the same diff, intent, and rubric to reviewers on different model families. Model diversity is the point. Different models have different blind spots, so a finding two models raise independently is high-confidence signal. The lead sorts everything into `Act on`, `Consider`, `Noted`, and `Dismissed`, with a reason for each dismissal, and applies nothing automatically.
|
|
70
|
+
|
|
71
|
+
Read the dismissals too. The lead is a pragmatic senior engineer, not an oracle, and you can override it.
|
|
72
|
+
|
|
73
|
+
## Prototype instead of debating
|
|
74
|
+
|
|
75
|
+
Never take the first design. Ask for a few, and pick from evidence you can see:
|
|
76
|
+
|
|
77
|
+
```text
|
|
78
|
+
/poteto-mode prototype a few options for the new dropdown menu. take screenshots or videos for me to compare.
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
The [Prototype playbook](../../skills/poteto-mode/playbooks/prototype.md) builds throwaway sketches in a scratch directory, puts the variants behind one switcher, drives each one, and captures screenshots or timings. It also works for behavior and algorithms, not just UI. Prototypes are planning with code. They let the agent answer its own open questions by running something instead of asking you, and they leave room for an option you wouldn't have thought of.
|
|
82
|
+
|
|
83
|
+
The same idea scales up to a real design. Pair `/architect` with prototypes and keep a review gate:
|
|
84
|
+
|
|
85
|
+
```text
|
|
86
|
+
/poteto-mode we need rate limiting for external webhooks. /architect it first, and answer open questions with prototypes. let me review before proceeding.
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
Don't spend reviewers on an abstract plan. `/interrogate` belongs on a diff. Point adversarial review at a plan with no code behind it and the reviewers invent theoretical risks and edge cases that will never happen. Let prototypes settle the questions, then review what got built.
|
|
90
|
+
|
|
91
|
+
## Write the README first for shared code
|
|
92
|
+
|
|
93
|
+
For a package or API that other code will use, start with the doc a user would read:
|
|
94
|
+
|
|
95
|
+
```text
|
|
96
|
+
/poteto-mode write a tutorial for how i would use the new config package first. then /teach me why it beats the current one.
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
Writing the tutorial first forces the caller's view. You describe the API to a hypothetical user and work back to the implementation. The doc also becomes a concrete target the agent checks its own work against. Name [`/technical-writing`](../../skills/technical-writing/SKILL.md) when the doc itself matters, so a tutorial stays a tutorial instead of drifting into reference and explanation at once.
|
|
100
|
+
|
|
101
|
+
## Plan after the design settles
|
|
102
|
+
|
|
103
|
+
pstack has no planning skill, on purpose. When you do want a written plan, ask for it once the design is settled:
|
|
104
|
+
|
|
105
|
+
```text
|
|
106
|
+
/poteto-mode turn this design into a plan. small verifiable PRs, each with its own verification steps.
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
The [Multi-phase plan playbook](../../skills/poteto-mode/playbooks/multi-phase-plan.md) settles any remaining open questions by prototype, then writes one section per PR, each ending in proof that the change works. A passing test suite alone doesn't count as that proof. The plan is the deliverable. The playbook doesn't implement it, and it names which execution playbook should run it next.
|
|
110
|
+
|
|
111
|
+
For a migration, state the bar in the prompt:
|
|
112
|
+
|
|
113
|
+
```text
|
|
114
|
+
/poteto-mode plan the migration of our ui library to the new styling system. small verifiable PRs, each with visual regression checks. the result must match the original exactly, bugs included.
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
"bugs included" keeps the migration from quietly fixing things on the way, which would make the old and new output impossible to compare. For a project that spans many days, you can commit the plan to the repo for a while so other agents see the work in progress. Delete it when the work lands.
|
|
118
|
+
|
|
119
|
+
## How much design work does a task deserve?
|
|
120
|
+
|
|
121
|
+
You might be wondering whether every change needs this. No. Most changes need none of it. A rough ladder:
|
|
122
|
+
|
|
123
|
+
- A small, finished change you're unsure about needs `/interrogate` alone.
|
|
124
|
+
- A change that crosses function boundaries or moves ownership earns `/architect`, which brings `/arena` with it.
|
|
125
|
+
- A standalone decision where independent attempts would help, like naming, formats, or an algorithm, is `/arena` directly.
|
|
126
|
+
- A coverage matrix, set of parallel checks, or race with declared arms is `/swarm`.
|
|
127
|
+
- An open question you could answer by running something, like a layout, a timing, or an approach, gets a prototype, not a debate.
|
|
128
|
+
- A contested design that's expensive to reverse gets `/architect`, then `/interrogate` before shipping.
|
|
129
|
+
- Work that spans several PRs gets a plan, written after the design settles.
|
|
130
|
+
|
|
131
|
+
`/poteto-mode` already applies this ladder. Boundary-crossing work triggers `/architect` on its own, so you reach for these directly mainly when you want more or less scrutiny than the default.
|
|
132
|
+
|
|
133
|
+
Next: [Build and clean the change](./05-build-and-clean.md).
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
# Build the change and clean the diff
|
|
2
|
+
|
|
3
|
+
The build playbooks share one discipline. Say what you observed, and let the playbook demand the evidence. This page shows what to put in the prompt for each common build task, then the cleanup habit that keeps diffs reviewable.
|
|
4
|
+
|
|
5
|
+
## Prompt each build playbook with what you know
|
|
6
|
+
|
|
7
|
+
A bug prompt states the symptom and asks for a reproduction first:
|
|
8
|
+
|
|
9
|
+
```text
|
|
10
|
+
/poteto-mode this command emits two records after a retry. repro first, then fix and verify.
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
A feature prompt states the behavior and what must not change:
|
|
14
|
+
|
|
15
|
+
```text
|
|
16
|
+
/poteto-mode add a --json flag. text output stays byte-identical. verify both forms.
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
A refactoring prompt pins behavior before structure moves:
|
|
20
|
+
|
|
21
|
+
```text
|
|
22
|
+
/poteto-mode move parsing into one module, zero behavior change. record the current output first and prove it's unchanged after.
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
A perf prompt states the measurement, not an impression:
|
|
26
|
+
|
|
27
|
+
```text
|
|
28
|
+
/poteto-mode startup takes 1.8s on this fixture. trace it, fix the measured cause, show me before and after.
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
Each of these routes to its playbook ([Bug fix](../../skills/poteto-mode/playbooks/bug-fix.md), [Feature](../../skills/poteto-mode/playbooks/feature.md), [Refactoring](../../skills/poteto-mode/playbooks/refactoring.md), [Perf issue](../../skills/poteto-mode/playbooks/perf-issue.md)), and the playbook supplies the steps you didn't type: reproduce before fixing, name the data shape before implementing, pin behavior before restructuring, profile before optimizing.
|
|
32
|
+
|
|
33
|
+
For sustained improvement of one number, there's the [Hillclimb playbook](../../skills/poteto-mode/playbooks/hillclimb.md). Give it the metric, a target, and a floor on attempts, and it loops one hypothesis at a time with a frozen measurement harness. It keeps wins and reverts everything else.
|
|
34
|
+
|
|
35
|
+
Both perf playbooks run [`/benchmark-checklist`](../../skills/benchmark-checklist/SKILL.md) on their numbers. Perf issue vets its baseline and every number after it, and Hillclimb vets its harness before freezing it. [Verify and ship](./06-verify-and-ship.md#vet-a-measured-number-with-benchmark-checklist) shows when to type it yourself.
|
|
36
|
+
|
|
37
|
+
Sometimes you want the cause before any fix. For a live symptom, such as a leak, an idle CPU spin, or a visual glitch, the [Runtime forensics playbook](../../skills/poteto-mode/playbooks/runtime-forensics.md) instruments the running process. For a profile you already captured, the [Trace forensics playbook](../../skills/poteto-mode/playbooks/trace-forensics.md) reads the artifact and maps the hot frame to source. Both return a diagnosis, not a fix:
|
|
38
|
+
|
|
39
|
+
```text
|
|
40
|
+
/poteto-mode here's a cpuprofile from the slow startup. tell me where the time goes and which source lines own it. no fix yet.
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
## Write the failing test first with `/tdd`
|
|
44
|
+
|
|
45
|
+
When a bug has a cheap local test path, the whole prompt can be two words:
|
|
46
|
+
|
|
47
|
+
```text
|
|
48
|
+
/tdd implement
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
In context, that's enough. [`/tdd`](../../skills/tdd/SKILL.md) writes the smallest test that fails for the intended reason, then the fix, then reruns the test. If a test would need broad harness setup or brittle mocks, the skill says so and uses the closest executable check instead. Don't force a test where a real command is stronger evidence.
|
|
52
|
+
|
|
53
|
+
## Load the TypeScript rules by name
|
|
54
|
+
|
|
55
|
+
[`typescript-best-practices`](../../skills/typescript-best-practices/SKILL.md) turns the type-system principles into concrete rules: discriminated unions, `unknown` at boundaries, exhaustive variants, schema-derived types. It doesn't load on its own, so type `/typescript-best-practices` when a task touches `.ts` or `.tsx` files.
|
|
56
|
+
|
|
57
|
+
## Clean before you commit
|
|
58
|
+
|
|
59
|
+
The [Opening a PR playbook](../../skills/poteto-mode/playbooks/opening-a-pr.md) runs the pre-commit cleanup on the diff before each commit and applies [`/unslop`](../../skills/unslop/SKILL.md) to the PR description and commit bodies. No single skill does this here. Ask for the same outcome in plain words: remove narrating comments, unsupported guards, dead compatibility paths, and unrelated edits.
|
|
60
|
+
|
|
61
|
+
For prose, `/unslop` takes a target and any extra rules you have:
|
|
62
|
+
|
|
63
|
+
```text
|
|
64
|
+
/unslop the readme changes, no emdashes
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
You'll develop your own shorthand. The skill reads intent fine from terse prompts like `unslop that, tighten it`.
|
|
68
|
+
|
|
69
|
+
## Strip the comments with `/no-comments`
|
|
70
|
+
|
|
71
|
+
Comments need their own pass, and not from the agent that wrote them. An author defends its comments the way you'd defend yours. So before review, hand them to fresh eyes:
|
|
72
|
+
|
|
73
|
+
```text
|
|
74
|
+
/no-comments the diff
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
[`/no-comments`](../../skills/no-comments/SKILL.md) spawns [Comment Sicko](../../agents/comment-sicko.md), a read-only reviewer with a short keep list: license headers, doc comments on a public API, links that explain what code can't, behavior forced by an external dependency you can't reshape. Everything else goes. A surprise in your own code gets no such pass. The comment comes back as a refactor flag, and `/no-comments` fixes the flags it accepts at the root cause. When a comment claims a constraint, "do not remove", the skill offers to encode the claim as a type, test, or lint. Either way, the comment comes out.
|
|
78
|
+
|
|
79
|
+
The division of labor is worth keeping straight. The pre-commit cleanup removes slop from the code, `/unslop` cleans it out of prose, and `/no-comments` hands the comments to a reviewer who didn't write them.
|
|
80
|
+
|
|
81
|
+
**Pitfall:** cleanup is not optional polish. A diff with narrating comments and defensive dead weight reads as unfinished to reviewers, and the extra code is where the next bug hides. If the diff feels padded, say `strip the slop` before you commit, not after review calls it out.
|
|
82
|
+
|
|
83
|
+
Next: [Verify and ship](./06-verify-and-ship.md).
|
|
@@ -0,0 +1,152 @@
|
|
|
1
|
+
# Verify the result and open a PR
|
|
2
|
+
|
|
3
|
+
"It compiles" is not evidence. The [Prove It Works principle](../../skills/principle-prove-it-works/SKILL.md) makes the agent check the real artifact before it reports success, and your job is to make "the real artifact" checkable. This page covers stating a finish condition, vetting a measured number, generating a verification skill for your app, formally verifying a property tests rarely reach, opening the PR, and driving it to merged.
|
|
4
|
+
|
|
5
|
+
Verification is the slowest step in most agent work, because it's the step that usually waits on a human. Make the agent able to do it, and you stop being the bottleneck. Skip it, and running more agents only gets you more unchecked work to review.
|
|
6
|
+
|
|
7
|
+

|
|
8
|
+
|
|
9
|
+
## State the finish condition up front
|
|
10
|
+
|
|
11
|
+
Put what done means in the first prompt, in whatever words fit:
|
|
12
|
+
|
|
13
|
+
```text
|
|
14
|
+
/poteto-mode add json output to this command. text output stays byte-identical, the json parses, both run against the sample project. show me the evidence.
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
Now the agent has three checks it can run, not a mood to satisfy. When the reply comes back, it should carry the exact commands and outputs. If a check couldn't run, a good reply says "inconclusive". A confident reply without evidence is a warning sign.
|
|
18
|
+
|
|
19
|
+
Match the check to the change:
|
|
20
|
+
|
|
21
|
+
- A CLI change runs the real command.
|
|
22
|
+
- A UI change walks the changed flow in the running app. When it must match a reference pixel for pixel, the [Visual parity playbook](../../skills/poteto-mode/playbooks/visual-parity.md) diffs screenshots against a frozen baseline instead of judging by eye.
|
|
23
|
+
- A parser or migration replays a saved input.
|
|
24
|
+
- A perf change compares before and after profiles.
|
|
25
|
+
- A storage change reads back the written value.
|
|
26
|
+
|
|
27
|
+
Ask for the proof as an artifact you can inspect yourself: the failing test and then the passing one, a before-and-after video, the trace, the screenshot. If the fix already merged, ask for the same check again on main. An artifact beats a plausible explanation, because you can challenge it without replaying the whole run.
|
|
28
|
+
|
|
29
|
+
For a small diff you don't fully trust, [`/blast-radius`](../../skills/blast-radius/SKILL.md) finds what it could break elsewhere. It finds the one fact that makes the change safe and proves that fact by running code, not by arguing for it.
|
|
30
|
+
|
|
31
|
+
## Vet a measured number with `/benchmark-checklist`
|
|
32
|
+
|
|
33
|
+
A before-and-after number is the easiest evidence to get wrong by accident. A warm cache, a debug build on one side, or work that never ran inside the timed region can each produce a convincing speedup. Before you report or act on a number, type:
|
|
34
|
+
|
|
35
|
+
```text
|
|
36
|
+
/benchmark-checklist vet the export speedup before it goes in the pr
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
[`/benchmark-checklist`](../../skills/benchmark-checklist/SKILL.md) asks seven questions and wants evidence from a run for each:
|
|
40
|
+
|
|
41
|
+
1. What limits the number, and why isn't it double?
|
|
42
|
+
2. Did every side run tuned the way production runs?
|
|
43
|
+
3. Does the result break a physical limit, like disk bandwidth or core count?
|
|
44
|
+
4. Did anything error or return wrong output?
|
|
45
|
+
5. Does it reproduce over alternating runs, with a median and a range?
|
|
46
|
+
6. Does it matter end to end, on the path a user waits on?
|
|
47
|
+
7. Did the work actually happen inside the timed region?
|
|
48
|
+
|
|
49
|
+
The verdict comes back as faster, slower, no measurable difference, or inconclusive, with the run count, range, and limiter. It says inconclusive when it can't name the limiter or a side ran untuned. `/poteto-mode` already runs the checklist inside the Perf issue and Hillclimb playbooks, so you type it yourself when you measured something outside them, or when someone else's number looks too good. It's the working form of the [Explain the Number principle](../../skills/principle-explain-the-number/SKILL.md).
|
|
50
|
+
|
|
51
|
+
## Create a project verification skill
|
|
52
|
+
|
|
53
|
+
The UI bullet above hides a real requirement. The agent needs a scripted way to drive your app. If your project has one, great. If not, run:
|
|
54
|
+
|
|
55
|
+
```text
|
|
56
|
+
/create-verification-skill
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
[`/create-verification-skill`](../../skills/create-verification-skill/SKILL.md) interviews the repository, not you. It works out what a user touches, how the app launches locally, what can drive it (an existing harness first, otherwise browser and CDP, a PTY, or plain HTTP), what evidence proves behavior, and whether two instances can run side by side. It asks you only what the code can't answer.
|
|
60
|
+
|
|
61
|
+
It writes `.dsh/skills/verify-<app>/`, agent-facing instructions with exact Launch, Doctor, Drive, Evidence, and Cleanup sections, a Helpers section for any script it ships, plus a feature map under `features/` that indexes what the app does and what result proves each feature works. The skill ships a [worked feature-map example](../../skills/create-verification-skill/references/feature-map-example/) with a README index and one file per feature using the four required H2s. Before handing it over, the generator proves the skill once end to end: launch, doctor check, drive one feature, capture evidence, clean up, then confirm the evidence survived the cleanup. If that proof fails, don't use the output.
|
|
62
|
+
|
|
63
|
+
From then on, "verify it in the app" is a step any agent can execute, in this repo, with no setup conversation. Name it in the prompt when you want the proof in a specific form:
|
|
64
|
+
|
|
65
|
+
```text
|
|
66
|
+
/poteto-mode build the bulk-archive action. use /verify-<app> to verify your changes and show me a video and screenshots as proof.
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
```text
|
|
70
|
+
/poteto-mode repro this with /verify-<app>. if it repros on main, fix it and show me a video as proof.
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
Once the verify skill works, a [`/swarm`](../../skills/swarm/SKILL.md) can split a full pass by feature-map entry and aggregate the results. A swarm of verifiers also confirms a perf win over a big enough sample, or fuzzes the app for regressions before a PR ships.
|
|
74
|
+
|
|
75
|
+
Treat the verification skill as infrastructure, not a one-off. Commit it, so every person and every agent on the team drives the app the same way. Then [build the lever](../../skills/principle-build-the-lever/SKILL.md). When agents keep writing throwaway scripts to click through the app, ask for a small control CLI that the skill calls instead. Agents spend fewer tokens, and every run becomes repeatable. A CLI that agents use well has these traits:
|
|
76
|
+
|
|
77
|
+
- A few composable commands, each doing real work, rather than many thin ones.
|
|
78
|
+
- A `--dry-run` option on anything destructive.
|
|
79
|
+
- Subcommands that reveal features gradually instead of all at once.
|
|
80
|
+
- Error messages that say what to do instead.
|
|
81
|
+
- Rich `--help` text.
|
|
82
|
+
- Machine-readable output, such as JSON.
|
|
83
|
+
|
|
84
|
+
While you're there, make the dev setup repeatable too: seeded data, test users, and one command that brings the environment up the same way every time.
|
|
85
|
+
|
|
86
|
+
## Keep the verification skill honest
|
|
87
|
+
|
|
88
|
+
Apps change, and feature maps go out of date. Run this at least once a day, ideally from a scheduled automation so nobody has to remember:
|
|
89
|
+
|
|
90
|
+
```text
|
|
91
|
+
/maintain-verification-skill
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
[`/maintain-verification-skill`](../../skills/maintain-verification-skill/SKILL.md) audits the generated skill: one read-only source reader per feature in parallel, then one live pass that drives every mapped feature. It ends in exactly one of three outcomes. `clean` means full coverage and nothing to ship. `changed` means one PR of proven corrections, confined to the verification skill's own directory. `blocked` names the blocker. It never edits product code. If the live pass catches a product regression, it reports the regression instead of hiding it with a doc edit.
|
|
95
|
+
|
|
96
|
+
## Prove a property with a formal verification skill
|
|
97
|
+
|
|
98
|
+
A verification skill proves the paths you drive. Some bugs live on paths nobody drives: two retries that overlap, a lock that expires mid-write, a state change that arrives out of order. Tests rarely reach those cases. For code where such a bug is costly, run:
|
|
99
|
+
|
|
100
|
+
```text
|
|
101
|
+
/create-formal-verification-skill
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
[`/create-formal-verification-skill`](../../skills/create-formal-verification-skill/SKILL.md) picks the target from the code: a promise the code makes, where a break harms users and tests rarely reach the case that breaks it. It picks the strongest target, not the easiest to verify. Name an area or a bug to start there instead:
|
|
105
|
+
|
|
106
|
+
```text
|
|
107
|
+
/create-formal-verification-skill the job lease and retry logic. a job must never run twice at once.
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
The question picks the tool. Whether events can happen in a bad order suits a model checker over a small model of the design, and TLA+ is the default for that in any language. Whether the code behaves for every input suits a verifier that runs on the code. If no verifier runs on your language, the agent says so and tests the real code with generated inputs, not a hand-written model of the function. A property that must hold at every size can need a proof. The agent tells you which tool it chose and why.
|
|
111
|
+
|
|
112
|
+
It verifies one property and shows that property failing on a broken variant of the code, because a check you've never seen fail proves nothing. When the current code already breaks the property, you get the counterexample as a short sequence of steps in your code's terms. The property stays as stated, so the finding stays a finding. Product code doesn't change unless you ask.
|
|
113
|
+
|
|
114
|
+
It writes a project-local skill that tells the next agent whether a change touches the verified code, how to run the check with one command, and how to tell a real bug from a modeling error. Before handing it over, the generator follows that skill once on a scratch change that breaks the property, and the check must catch it. The handoff says what was verified, with which tool and bounds, what the check found, and what it doesn't cover. A pass covers the model or the bound, not the whole system.
|
|
115
|
+
|
|
116
|
+
The skill also records which code each check covers and the commit where the check last matched it. Merges and refactors that skip the skill can leave the check passing on a description of code that's gone. After them, run [`/maintain-formal-verification-skill`](../../skills/maintain-formal-verification-skill/SKILL.md). It updates the verification from the code, reruns it, shows that each updated check can still fail, and tells you whether each failure is drift in the verification or a bug in the code.
|
|
117
|
+
|
|
118
|
+
## Open the PR
|
|
119
|
+
|
|
120
|
+
```text
|
|
121
|
+
/poteto-mode open the pr. small ordered commits, evidence in the description.
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
The [Opening a PR playbook](../../skills/poteto-mode/playbooks/opening-a-pr.md) works from a worktree, rebases the work into small ordered commits, cleans the diff, unslops the prose, and returns the PR link. Five narrow PRs beat one fat one, and stacked follow-ups beat a growing branch.
|
|
125
|
+
|
|
126
|
+
## Drive the PR to merge-ready with Babysit
|
|
127
|
+
|
|
128
|
+
An open PR starts collecting blockers immediately. Checks fail, reviewers comment, trunk moves. Hand that churn to the [Babysit playbook](../../skills/poteto-mode/playbooks/babysit.md):
|
|
129
|
+
|
|
130
|
+
```text
|
|
131
|
+
/poteto-mode babysit this pr. get it green.
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
Babysit watches the PR, with a bundled watcher on GitHub or the Origin CLI when it's available, and takes blockers in order: conflicts, then review threads, then CI. Every known fix batches into one push, so the checks restart once instead of after every fix. The comment triage is skeptical, because humans and bots file real catches and noise in the same list. A real finding gets a fix, and noise gets dismissed with the disproof posted on the thread. When all you want is status, ask smaller and Babysit answers without starting the loop:
|
|
135
|
+
|
|
136
|
+
```text
|
|
137
|
+
/poteto-mode check on pr 123. anything outstanding?
|
|
138
|
+
```
|
|
139
|
+
|
|
140
|
+
Babysit stops at merge-ready. It never merges, even with everything green, because merging is a different decision.
|
|
141
|
+
|
|
142
|
+
## Land the stack with Shipping
|
|
143
|
+
|
|
144
|
+
Green is not the same as safe. When you're ready to land, say so:
|
|
145
|
+
|
|
146
|
+
```text
|
|
147
|
+
/poteto-mode land the stack.
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
The [Shipping playbook](../../skills/poteto-mode/playbooks/shipping.md) verifies each PR independently before it arms anything. One fresh agent per PR proves the behavior live, and the agent that judges a change is never the one that wrote it. Then Shipping lands only the contiguous verified run from the bottom, one PR at a time through GitHub by default or Origin when its CLI is available, and reports the first PR that breaks the chain. A verified PR sitting above an unverified one waits, because merging it would pull the gap in underneath.
|
|
151
|
+
|
|
152
|
+
Next: [Run work while you sleep](./07-overnight.md).
|