/wave-orchestrator:benefit-contractfrom wave-orchestrator
Writes a benefit contract for behaviour-changing waves before acceptance criteria exist. Produces Benefit AC, authority census, and integration count in .wave/ben.md.
Ships in wave-orchestrator. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
You write the contract that says what the wave is for, before anyone writes a criterion, a design or a test.
A wave can run every gate green and still deliver nothing. The component is built, its tests pass, the alignment check says the build matches the spec — and the behaviour the wave was for never happens, because something that was already there still decides the outcome, or because nothing outside the new directory ever calls the new code.
RED and GREEN are written from the same brief, so a wrong brief produces a green suite. The output-alignment check compares the build with the spec, not the outcome with reality. Mutation testing measures the tests that exist. None of them asks whether the user's day changed.
That question is this phase's only job. You run when the wave changes existing behaviour.
Write .wave/ben.md with three sections and, at the end, the line:
BEN-VERIFIED red=<n> authorities=<n>
red is the number of failing benefit tests and must be at least 1.
authorities is the number of rows in the census and must be at least 1.
Exactly one sentence. Not a list, not a paragraph.
Three rules, all checkable:
Then back it with one named, executing test. You write it, you run it, and it fails — for the right reason, which you state. A test that fails because a file does not exist yet is not evidence about the benefit; a test that fails because the outcome does not happen is.
If the benefit can only be observed end to end, say so and name the command. [TEET] will run it.
Name the decision the feature influences. One decision, in plain words.
Then list, by reading code, every existing component that already decides that same outcome. For each one:
| Column | What goes in it |
|---|---|
| Location | file and symbol |
| How it decides | the rule it applies |
| Input | what it reads to decide |
| On disagreement | what happens when it and the new feature want different outcomes |
| Resolution | which one wins today, and why |
The census must include the authority that produces the outcome the Benefit AC names. That is what makes the two artifacts interlock: if the Benefit AC says a returning user lands on a narrowed list, the census has to name whatever decides today what that list shows.
authorities is never 0. A feature that influences a decision nothing makes today is a new decision, and the census says exactly that, in one row.
Count the files the wave expects to change outside the feature's own directory.
A behaviour-changing wave with a count of 0 or 1 has been hosted, not integrated. That is a finding, not an achievement. It needs a written justification naming the existing mechanism that will carry the behaviour to the rest of the system.
"Untouched" is not a score. Write the blast-radius table so that every row answers one question — must this change, and why not? — and a row that answers "no" carries the reason.
[BEN-CLOSE]A separate team, with fresh eyes, writes .wave/ben-close.md after the last hardening phase and before the version bump. It does four things:
BENEFIT: DELIVERED only when the test passed and neither list holds an unjustified item. Otherwise BENEFIT: UNDELIVERED, followed by the reasons.UNDELIVERED does not block the wave. It is recorded, printed in the scorecard and announced once at the close. Never edit the Benefit AC to turn the verdict green — that is the one move this whole phase exists to make visible.
Feature: remember my last search filters.
Benefit AC — wrong:
The filter-persistence service writes the active filter set to storage whenever it changes.
The subject is the new component, the verb is what the code does, and it names the thing being built. It would be green the moment the service exists, whether or not anyone's screen ever changes.
Benefit AC — right:
A returning user opens the results page and finds it already narrowed the way they left it, without touching the filter bar.
No new symbol; the subject is the user; the verb is what the user no longer has to do.
Backing test. Open the results page, apply two filters, end the session, start a new one, open the results page again, assert the visible result set is the narrowed one and the filter controls show those two values. It fails today because the page comes back unfiltered. That is the right reason.
Authority census. Who already decides what that page shows on load?
| Location | How it decides | Input | On disagreement | Resolution |
|---|---|---|---|---|
| route definition | supplies default query parameters when none are in the URL | the route's own defaults | the defaults overwrite a restored filter set | route wins — it runs first |
| results container, on mount | clears the filter state to "show everything" | none | the clear runs after a restore and erases it | container wins — it runs last |
| server list endpoint | applies a role-based default filter when the request carries none | the caller's role | a restored client filter is sent, so this branch is not reached | client wins when it sends filters |
| response cache | serves the previous unfiltered payload for a short window | the request URL | a restored filter changes the URL, so the entry misses | no conflict |
authorities=4. The second row is the one that matters: something already in the system resets exactly what the feature is trying to restore. That row is the reason the wave is not simply "add a service".
Integration count. If the plan changes only files inside the new service's own directory, the count is 0 and the feature is hosted, not integrated — nothing would ever ask it for the remembered filters. The honest plan changes the results container (to ask, and to stop clearing) and the route definition (to stop overwriting): count 2, with a blast-radius row for the endpoint and the cache saying why neither must change.
At the close. The orphan-state sweep asks whether anything outside the service's directory reads the stored filter set; if the answer is nothing, the feature is writing to a drawer no one opens. The defeat list picks up the comment someone added during GREEN — "the container still clears on mount; we restore after it" — and turns it into a requirement: either a named test pins that order, or the verdict says so.
UNDELIVERED.What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub harshvardhan86/claude-wave-plugin --plugin wave-orchestrator7 skills in this plugin
/ac-writerUse as the first phase of a wave. Drafts brutal, testable acceptance criteria for a feature. Each AC must be falsifiable by a real-world test. Output written to .wave/ac.md./design-reviewerUse after AC and before RED for any wave that ships UI or changes existing behaviour. Audits component APIs against installed dist files, writes a per-route mockup and visual ACs to .wave/dr.md./green-implUse after RED is verified failing. Writes the minimum code to make RED tests pass, then verifies on a live stack with Playwright screenshots before any hand-off. Implements the verify-before-scan rule./red-testsUse after DR and before any production code is written. Writes failing tests that encode the AC and DR visual assertions, then proves they fail by running them. RED phase of TDD — strict, no exceptions./teet-verifyUse only after the user has approved the GREEN screenshot. Performs True End-to-End Testing across backend, frontend, DB, and external services with computed-style and boundingBox assertions, producing the final wave evidence pack./wave-orchestratorUse when shipping a feature end-to-end. Routes between the canonical v2 framework (31 phase rows, 18 always and 13 conditional) and the trimmed 5-phase demo subset. Invoked by /wave-orchestrator:wave-start.Other plugins' skills for the same job