# Test Plan: SDD Dispatch Composition Guidance

## First, classify the failure type

Before designing tests, I need to know what failure this guidance addresses — because the form of verification depends on it.

This addition is a **positive recipe/contract**: it states what the dispatch IS (five ordered parts). Per "Match the Form to the Failure," recipes are the right form when the baseline failure is **wrong-shaped output** (the agent produces a dispatch, but it's bloated, buries the brief, restates the spec, or omits the report path) — NOT a discipline violation.

So my verification must answer two questions:
1. **Is there a real baseline failure?** (If dispatches are already well-shaped, deploy nothing.)
2. **Does this specific wording fix the failure without introducing new ones?**

The Iron Law applies: **no skill edit without a failing test first.** I watch dispatches fail the desired shape BEFORE accepting this wording.

## Method: Micro-tests before full scenarios

Because this is wording-shaping (not a discipline rule under pressure), I lead with micro-tests — cheap, high-rep, one API call per sample. Full pressure scenarios aren't the primary gate here; shape convergence is.

### Setup per sample
- **System prompt** = the realistic context the guidance lives in: the full SDD skill as it would actually be deployed (with the candidate addition for treatment arms, without it for control). Guidance is never tested in isolation.
- **User message** = a realistic task that tempts the failure: "Dispatch a subagent to implement Task 3 (the auth-token refresh endpoint). Here's the plan, the brief, and the interfaces from Tasks 1–2." I include a brief that contains real requirements, an ambiguity the agent must resolve, and prior-task interfaces — so all five slots are *exercisable*.

### Arms (each 5+ reps)

| Arm | Purpose |
|-----|---------|
| **A. No-guidance control** | REQUIRED. Does the failure even exist? If dispatches here are already well-shaped, stop — author nothing. |
| **B. Candidate wording** | The teammate's five-part recipe verbatim. |
| **C. Competing-incentive control** | Same as B, but the task adds pressure that tempts bloat: "make the dispatch fully self-contained so the subagent never needs other files." This is where recipes earn their keep — does the brief-pointer survive, or does the agent inline the whole brief? |

Run **5+ reps per arm** (single samples lie). I'll likely run 8 to read variance cleanly.

## Scoring

Score each dispatch **by reading it manually** — automated string-matching overstates hits (template echoes and quoted counter-examples masquerade as matches). I score programmatically only to flag candidates for manual read.

Per dispatch, record:

**Shape compliance (the five slots):**
- [ ] Task-fit line present and ≤1 sentence
- [ ] Brief introduced as authoritative requirements ("read this first") — and the brief is *pointed to*, not inlined
- [ ] Cross-task interfaces included (only those the brief can't know)
- [ ] Ambiguity resolution stated
- [ ] Report-file path present

**Failure symptoms (the thing the recipe should suppress):**
- [ ] Brief contents restated/inlined instead of referenced
- [ ] Spec/requirements duplicated into the prompt
- [ ] Verdict/instructions buried under narration
- [ ] Dispatch word count (proxy for bloat)

**Variance is a metric:** I record whether the 5–8 reps *converge* on the same dispatch shape. Five different interpretations = the wording isn't binding, even if each individually passes.

## Acceptance criteria

Deploy only if ALL hold:

1. **Control confirms a real failure.** Arm A exhibits the wrong-shape symptom (inlined brief / restated spec / missing report path) in a clear majority of reps. *If A is already clean, abort — the guidance is solving a non-problem.*

2. **Candidate fixes it.** Arm B hits all five slots in ≥ 8/8 reps (or my chosen N), with no inlined brief and no spec restatement.

3. **Candidate survives competing incentive.** Arm C — under the "self-contained" pressure — keeps the brief as a *pointer* in a strong majority of reps. This is the decisive test: if C inlines the brief, the recipe failed exactly where recipes are supposed to win, and the wording needs tightening before deploy.

4. **Reps converge.** Low variance in dispatch shape across B and C. Divergence means tighten the form, don't add words.

5. **No new failure introduced.** Compare B/C word counts and clarity against A — the recipe shouldn't trade bloat for a different bloat (e.g., agents writing prose *about* each of the five points).

## Notes on the wording itself (to watch for during scoring)

- Slot 3 ("interfaces the brief *cannot* know") and slot 4 ("resolution of *any* ambiguity") are **conditional** content. If a task has no cross-task interfaces or no ambiguity, the recipe shouldn't force the agent to invent them or emit empty slots. I'll add a no-ambiguity / no-prior-task variant to the user messages to check the conditionals key off an observable predicate rather than firing unconditionally.
- "read this first — it is your requirements" is doing the anti-restatement work. The C arm is precisely what proves whether that phrasing binds.

## If it fails

Treatment for a shaping miss is **a tighter contract, not a prohibition.** I would NOT add "don't inline the brief" — under the self-contained incentive that measurably backfires. Instead I'd restructure the slot so the brief can only appear as a path (e.g., make slot 2 literally a `brief_path:` field the agent fills), removing the negotiation entirely. Then re-run B and C.

Only after micro-tests pass would I confirm with a full SDD execution scenario as a final sanity gate.