Commit 787ae33
committed
test(harness): WD-5/WD-6 live transcript capture, and the four defects it caught
Layer 3, plan item 6. Claude Code headless (the one harness with attested
flags) through the LiteLLM gateway — no vendor credential; the key is read
from the proxy's own config at call time, enters the child env only, and is
never printed or passed in argv. Opt in with ....F. [100%]
=================================== FAILURES ===================================
_______________ test_s3_offer_once_then_decline_then_silence[3] ________________
packages/studyloop/tests/live/test_wind_down_transcripts.py:500: in test_s3_offer_once_then_decline_then_silence
assert not after_decline_hits, (
E AssertionError: second brains came back after the decline: ['turn 1: xtiles']
E assert not ['turn 1: xtiles']
=========================== short test summary info ============================
FAILED packages/studyloop/tests/live/test_wind_down_transcripts.py::test_s3_offer_once_then_decline_then_silence[3]
1 failed, 5 passed in 88.32s (0:01:28); artefacts
(per-state transcripts, summary.json, tool-routing.json) land under
gitignored reviews/.
The three gate checks, graded on real transcripts with the arbitrated
assertions and nothing stronger: sentence at most once across the whole
transcript; silence = no pinned sentence and no second-brain vocabulary in
assistant prose WHILE the D4 positive control holds (the transcript must
show channel: none
offer: False
sentence:
reason: provider is 'xtiles' but no 'xtiles' connector is attached this session actually ran, or a crashed run would pass
by absence); a declined offer leaves the stub log empty — with the xtiles
tools ALLOWED, so declining was a choice, not an inability. 3/3 for the
offer-once-then-decline state; one pre-response infra retry, flakes counted
in the artefact, never smoothed.
Capturing found four real defects; each is fixed here and visible in the
transcript evidence:
1. Protocol violation — the harness narrated the step ('Running the second
brain check now'). The protocol now opens step 5 with the silence rule
and names narration a violation.
2. Fabricated connector flag — given a literal '--connector xtiles' example,
the model passed it with NO server attached, manufacturing an offer. The
protocol now grounds the flag in the mcp__<server>__ tool names the
session can actually see, and calls it a statement of fact.
3. D2 exactly as the council predicted — the hermetic HOME hid the skill and
'Unknown skill: studyloop-xtiles-wind-down' killed an offer turn. The
world now runs the REAL Updated agent definitions.
shared: 0
kiro: 1
claude: 1
opencode: 0
codex: 0
pi: 0 into the isolated
home, which also exercises the installer for free.
4. A gateway bug — LiteLLM's anthropic-passthrough adapter (Bedrock invoke
path) dies on extended-thinking blocks ('Content block is not a text
block'), deterministic on thinking-length prompts. Worked around with
MAX_THINKING_TOKENS=0 in the harness env; proxy upgrade is the real fix.
Final capture: 6/6 pass, 0 flakes. WD-6's observation (records, never
gates): the P1b planner wording selected
xtiles_create_tiles_from_markdown_in_my_planner — matching the owner's hand
run. Spend recorded in the ledger: est $1.50, actual $4.45; the overrun is
Claude Code's ~30k-token own system prompt per call plus five debug
re-runs, both now named in the estimate file so the next one models them.1 parent ced3ad4 commit 787ae33
4 files changed
Lines changed: 580 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
148 | 148 | | |
149 | 149 | | |
150 | 150 | | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
151 | 160 | | |
152 | 161 | | |
153 | 162 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
53 | | - | |
| 53 | + | |
54 | 54 | | |
55 | 55 | | |
56 | 56 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
51 | | - | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
52 | 54 | | |
53 | 55 | | |
54 | 56 | | |
55 | 57 | | |
56 | 58 | | |
57 | | - | |
58 | | - | |
59 | | - | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
60 | 71 | | |
61 | 72 | | |
62 | 73 | | |
| |||
76 | 87 | | |
77 | 88 | | |
78 | 89 | | |
79 | | - | |
| 90 | + | |
| 91 | + | |
80 | 92 | | |
81 | 93 | | |
82 | 94 | | |
| |||
0 commit comments