diff --git a/pstack/.cursor-plugin/plugin.json b/pstack/.cursor-plugin/plugin.json index f170fbd..d66206b 100644 --- a/pstack/.cursor-plugin/plugin.json +++ b/pstack/.cursor-plugin/plugin.json @@ -1,7 +1,7 @@ { "name": "pstack", "displayName": "pstack", - "version": "0.11.14", + "version": "0.12.0", "description": "if you want to go fast, go deep first. pstack helps you write less, but higher quality code. rigorous agent workflows you can parallelize with confidence.", "author": { "name": "Lauren Tan" diff --git a/pstack/README.md b/pstack/README.md index 90d6fd6..f4b4462 100644 --- a/pstack/README.md +++ b/pstack/README.md @@ -159,6 +159,8 @@ architect: design this instrumentation to be high signal with no false p this first. arena: /arena take my prompt to the arena verbatim. i want to compare their proposals with yours. +swarm: /swarm check every package under packages/ against its check.sh. one worker per + package. one report. interrogate: /interrogate review this pr. tdd: /tdd implement unslop: can we unslop and tighten the new changes? diff --git a/pstack/docs/guide/01-setup.md b/pstack/docs/guide/01-setup.md index e0269a0..8f30116 100644 --- a/pstack/docs/guide/01-setup.md +++ b/pstack/docs/guide/01-setup.md @@ -24,7 +24,7 @@ Run: You only override what you care about. A role with no line in the rule keeps the skill's default. To restore a default later, delete that role's line, or just run `/setup-pstack` again. -You might be wondering what happens if you use Auto. Set a role to `inherit-parent` or `auto` and pstack omits the subagent `model` field, so the subagent inherits your parent chat model. Both values mean the same thing, and neither is a model slug. For a panel role the value is a list, and one subagent runs per entry, so the list length sets the panel size. +You might be wondering what happens if you use Auto. Set a role to `inherit-parent` or `auto` and pstack omits the subagent `model` field, so the subagent inherits your parent chat model. Both values mean the same thing, and neither is a model slug. For a panel role the value is a list, and one subagent runs per entry, so the list length sets the panel size. Setup also configures `swarm workers`, the default model for every `/swarm` worker unless a race names a model for each arm. ## Accept the verification offer, or don't diff --git a/pstack/docs/guide/04-design.md b/pstack/docs/guide/04-design.md index b7fd716..681d39c 100644 --- a/pstack/docs/guide/04-design.md +++ b/pstack/docs/guide/04-design.md @@ -1,6 +1,6 @@ # Design before you write code -One attempt at a hard design locks in the first shape the model thought of. These three skills exist so that doesn't happen. `/architect` settles types and boundaries before implementation. `/arena` runs several attempts in parallel and merges the best parts. `/interrogate` has other models try to break the result. +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. ![Three robots draft competing bridge models at their own tables under /architect, /arena, and /interrogate panels, while a judge robot with a clipboard inspects skeptically.](./images/design.jpg) @@ -24,7 +24,7 @@ By default it proceeds straight from the synthesized design into implementation. /arena take my prompt to the arena verbatim. i want to compare their proposals with yours. ``` -[`/arena`](../../skills/arena/SKILL.md) is the general tool underneath. N subagents attempt the same task 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. +[`/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. ```mermaid flowchart LR @@ -46,6 +46,16 @@ The panel comes from your [`/setup-pstack`](../../skills/setup-pstack/SKILL.md) /arena this, 5 candidates. the cache key format is expensive to change later. ``` +## Cover slices and races with `/swarm` + +```text +/swarm check every package under packages/ against its check.sh. one worker per package. one report. +``` + +[`/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. + +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. + ## Break it with `/interrogate` ```text @@ -63,6 +73,7 @@ You might be wondering whether every change needs this. No. Most changes need no - A small, finished change you're unsure about needs `/interrogate` alone. - A change that crosses function boundaries or moves ownership earns `/architect`, which brings `/arena` with it. - A standalone decision where independent attempts would help, like naming, formats, or an algorithm, is `/arena` directly. +- A coverage matrix, set of parallel checks, or race with declared arms is `/swarm`. - A contested design that's expensive to reverse gets `/architect`, then `/interrogate` before shipping. `/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. diff --git a/pstack/docs/guide/06-verify-and-ship.md b/pstack/docs/guide/06-verify-and-ship.md index e87418c..2a84d2a 100644 --- a/pstack/docs/guide/06-verify-and-ship.md +++ b/pstack/docs/guide/06-verify-and-ship.md @@ -34,10 +34,12 @@ The UI bullet above hides a real requirement. The agent needs a scripted way to [`/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. -It writes `.cursor/skills/verify-/`, agent-facing instructions with exact Launch, Doctor, Drive, Evidence, and Cleanup sections, plus a feature map under `features/` that indexes what the app does and what result proves each feature works. Before handing it over, the generator proves the skill once end to end: launch, doctor check, drive one feature, capture evidence, clean up. If that proof fails, don't use the output. +It writes `.cursor/skills/verify-/`, agent-facing instructions with exact Launch, Doctor, Drive, Evidence, and Cleanup sections, 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. If that proof fails, don't use the output. From then on, "verify it in the app" is a step any agent can execute, in this repo, with no setup conversation. +Once the verify skill works, a [`/swarm`](../../skills/swarm/SKILL.md) can split a full pass by feature-map entry and aggregate the results. + ## Keep the verification skill honest Apps change and feature maps rot. When yours drifts, run: diff --git a/pstack/docs/guide/10-recipes-and-pitfalls.md b/pstack/docs/guide/10-recipes-and-pitfalls.md index 053401f..81176d6 100644 --- a/pstack/docs/guide/10-recipes-and-pitfalls.md +++ b/pstack/docs/guide/10-recipes-and-pitfalls.md @@ -20,6 +20,14 @@ ask /arena for a second opinion on this thread and our approach Your current design becomes one candidate among several, and the synthesis tells you whether the panel found something better or confirmed what you had. Cheap insurance before a costly commitment. +## Check independent slices in parallel + +```text +/swarm check every package under packages/ against its check.sh. one worker per package. one report. +``` + +Each worker owns one package. The parent waits for every slice and returns one `PASS`, `ISSUES`, or `BLOCKED` report instead of raw worker dumps. + ## Review a branch skeptically ```text @@ -67,6 +75,7 @@ You rarely need more words. You need the right name, and [the principles page](. - **Enumerating skills in the prompt.** "use /how then /architect then /arena" reorders steps the playbook already sequences. State the goal and constraints. Name a skill only to override a default. - **A vague finish condition.** "make it better" gives `/loop` nothing to check. Give a command or artifact that can pass or fail. - **Parallel agents in one worktree.** They overwrite each other and the diff becomes archaeology. Say "own worktree per attempt" and the isolation is free. +- **Using `/arena` for coverage.** `/arena` repeats one design or code brief, then picks a base and grafts the best parts. `/swarm` partitions slices or declared race arms and aggregates one report. - **Accepting every review comment.** Bots and humans both file real catches and noise in one list. `/interrogate` sorts findings into act-on and dismissed buckets with reasons, and you can override either way. - **Treating `auto` as a model slug.** `auto` and `inherit-parent` mean "omit the model field so the subagent inherits the parent chat model." [Setup](./01-setup.md) covers the roles. - **Reporting success off a green build.** A build proves it compiles. Ask for the real command, flow, stored value, or profile, and expect the evidence in the reply. diff --git a/pstack/docs/guide/README.md b/pstack/docs/guide/README.md index ab39e21..f6fd3e8 100644 --- a/pstack/docs/guide/README.md +++ b/pstack/docs/guide/README.md @@ -7,7 +7,7 @@ Here's what you'll learn: 1. [Set up pstack](./01-setup.md). Install the plugin and pick your models. 2. [Route work through `/poteto-mode`](./02-poteto-mode.md). Give it a goal and watch it pick a playbook. 3. [Understand the code](./03-understand.md). `/how`, `/why`, `/teach`, and `/recall` before you edit anything. -4. [Design the change](./04-design.md). `/architect`, `/arena`, and `/interrogate` before code locks in a shape. +4. [Design the change](./04-design.md). `/architect`, `/arena`, `/swarm`, and `/interrogate` before code locks in a shape. 5. [Build and clean the change](./05-build-and-clean.md). The build playbooks, `/tdd`, and `/unslop`. 6. [Verify and ship](./06-verify-and-ship.md). Prove behavior on the real app, then open a focused PR. 7. [Run work while you sleep](./07-overnight.md). An overnight contract and a decision log you can audit.