c88bb27775
Run titles were intermittently a sentence about the input rather than a
title for the task ("The untrusted data asks what 2+2 is…"), because the one
fixed instruction began "Summarise the untrusted data below…" and invited the
model to describe the data whenever the prompt read like an instruction or a
question.
- Rename the fixed prompt `instruction` → `titleInstruction` and reword it to
ask unambiguously for a short title of the task ("Write a short title, a few
words, for the task below. Reply with only the title…"), still followed by
"The following is untrusted data:".
- Add a bounded, conservative `detachFramingEcho` normalisation applied in
`Title` and `VerdictReason`: a leading clause that names the framing ("The
untrusted data…", "This prompt…", "The user asks…") is stripped to its
substantive remainder, and a line that is pure framing falls back to the
prompt's first line (`Title`) or `NoSummary` (`VerdictReason`).
- Extend tests with the two reported echo shapes (instruction-style and
question-style prompts) plus the injection-resistance case, which still
passes: the prompt is appended verbatim once after the untrusted-data label
and never replaces the instruction.
Trust boundary unchanged: source still labelled untrusted data, one tool-free
generation, hard timeout, never blocks or fails run creation; the title is
never empty.
Checks: `go build ./... && go vet ./...` clean, `gofmt -l internal/summarise/`
prints nothing, `go test ./...` ok.
Docs/templates check: no packaged template (`examples/*.md`) mentions title
generation, so none needs updating. The packaged authoring skill reference
`internal/author/skill/references/operations.md` (lines ~91-95) describes the
title as generated "from its prompt by the shared summariser" and is now stale
(it does not mention that the summariser is asked for a title of the task nor
the framing-echo normalisation); per the maintenance rules that shared document
is left to the single `docs-fold` writer and the staleness is recorded in
`docs/notes/run-title-framing-echo.md` instead. `README.md` and `docs/cli.md`
stay true, and no `internal/author/install.go` managed inventory entry changes.