fix(storm-measure): check BOTH halves of the activation SC, not just the count delta
The SC asks two things of an effort: high run: that it discovered at least one dimension AND that the dimension list in the output brief is a TRUE SUPERSET of the interview-derived ones. activationCheck computed dimensions - dimensions_baseline >= 1 and returned ok on that alone. A count delta says nothing about membership: a run that dropped two interview dimensions and appended three discovered ones is +1 and passed the check while violating the second half outright. Supersetness was asserted only by Phase 4.5's prose contract that discovery appends - nothing read it. The stats record cannot carry the dimension names that would show it directly: names are free prose, and lib/exporters/field-allowlist.mjs denies prose by omission (question, project_dir, brief_path are already excluded for that reason). So the run attests membership with dimensions_baseline_preserved, a boolean set in a new Phase 4.5 step 5, and the gate refuses to call activation OK without it. An ABSENT attestation fails rather than falling back to the old count-only rule - otherwise legacy rows would keep passing on the defect. Producer side wired end to end: the record format, the measurement-fields prose (five fields -> six), the exporter allowlist, the jsonl-schemas fixture row, and the --activation-check comment in docs/storm-measurement.md. Review finding d2786604458207a5a73478cdcb6a54bbdb92141d (MINOR). Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01LuGhWAbWyRFBFeemfhxoVv
This commit is contained in:
parent
7d5e4fcbcc
commit
dc245af408
6 changed files with 145 additions and 14 deletions
|
|
@ -421,6 +421,14 @@ agent surfaced that no interview dimension claims.
|
|||
4. **Record the baseline.** Keep the interview-derived count as
|
||||
`dimensions_baseline` so the discovered delta is machine-readable against
|
||||
the final `dimensions` (Phase 8 stats).
|
||||
5. **Attest membership, not just the count.** Set
|
||||
`dimensions_baseline_preserved: true` only if EVERY interview-derived
|
||||
dimension is still on the final list — this phase appends, it never replaces.
|
||||
Set it `false` if any was dropped, merged away, or rewritten. A count delta
|
||||
cannot show this: dropping two interview dimensions and appending three
|
||||
discovered ones is `+1` and still not a superset, which is exactly what the
|
||||
Success Criterion forbids. `storm-measure.mjs --activation-check` reads the
|
||||
field and fails when it is absent, so omitting it is not the silent default.
|
||||
|
||||
Every outbound query generated from a discovered dimension passes
|
||||
`query-privacy-gate.mjs` before it leaves the machine — see the per-turn
|
||||
|
|
@ -737,6 +745,7 @@ Record format (one JSON line):
|
|||
"brief_path": "{brief_destination}",
|
||||
"dimensions": {N},
|
||||
"dimensions_baseline": {N},
|
||||
"dimensions_baseline_preserved": {true|false},
|
||||
"effort": "{low|standard|high}",
|
||||
"conv_turns": {N},
|
||||
"empty_turns": {N},
|
||||
|
|
@ -750,16 +759,20 @@ Record format (one JSON line):
|
|||
}
|
||||
```
|
||||
|
||||
**The five measurement fields (v5.10).** `effort` is the grouping key — the
|
||||
**The six measurement fields (v5.10).** `effort` is the grouping key — the
|
||||
resolved `phase_signal_result.effort` for the `research` phase, a
|
||||
low-cardinality label (`low|standard|high`), and the only axis on which a
|
||||
high-effort run can be compared against a standard one. The other four are
|
||||
numeric: `unique_sources` (distinct sources cited across the brief),
|
||||
high-effort run can be compared against a standard one. Four are numeric:
|
||||
`unique_sources` (distinct sources cited across the brief),
|
||||
`dimensions_baseline` (the interview-derived dimension count, so the Phase 4.5
|
||||
delta against `dimensions` is machine-readable), `conv_turns` (Phase 5 loop
|
||||
turns actually spent), and `empty_turns` (loop turns that returned no findings
|
||||
or no citations). On a standard run the loop never arms, so
|
||||
`dimensions_baseline == dimensions` and both turn counters are `0`.
|
||||
or no citations). The sixth is boolean: `dimensions_baseline_preserved`, the
|
||||
Phase 4.5 attestation (step 5) that every interview dimension survived onto the
|
||||
final list — the count delta cannot show membership, and the dimension NAMES
|
||||
that could are prose the exporter allowlist denies. On a standard run the loop
|
||||
never arms, so `dimensions_baseline == dimensions`, both turn counters are `0`,
|
||||
and `dimensions_baseline_preserved` is `true` (nothing touched the list).
|
||||
|
||||
If `${CLAUDE_PLUGIN_DATA}` is not set or not writable, skip tracking silently.
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue