docs: the reply contract has one parser and no legacy shape (V-397)
This commit is contained in:
@@ -263,9 +263,14 @@ the cascade rather than transitioning the wrong item.
|
|||||||
|
|
||||||
## LLM output contract
|
## LLM output contract
|
||||||
|
|
||||||
All phrasing paths emit `{"response":"...","mood":"..."}` (parsed in `replier_llm.go` and
|
All phrasing paths emit `{"response":"...","mood":"..."}`, with fallback to plain text when
|
||||||
`internal/phraser/llmphraser.go`), with fallback to plain text and the legacy
|
the model skips the JSON. **One parser, `parseResponseMood` in
|
||||||
`{"body","summary"}`. Mood is a fixed enum. Router prompt is a separate contract:
|
`internal/phraser/parse.go`**, and every path reaches it: the six `LLMPhraser` methods,
|
||||||
|
`PhraseWorld`, and `Replier.PhraseReply`, which `cmd/mavend/replier_llm.go` wraps — that file
|
||||||
|
holds the stub fallback and no parsing of its own. The legacy `{"body","summary"}` fallback
|
||||||
|
was deleted on 2026-08-06 (V-397): it was the contract before `{"response","mood"}` replaced
|
||||||
|
it, no prompt asks for that shape, the GBNF cannot emit it, and no test covered it.
|
||||||
|
Mood is a fixed enum. Router prompt is a separate contract:
|
||||||
`[{"intent":<enum>, key?, value?, text?, verb?}, ...]`, 7 intents (`fact, reminder,
|
`[{"intent":<enum>, key?, value?, text?, verb?}, ...]`, 7 intents (`fact, reminder,
|
||||||
note, query, act, chat, system`). `llm/check_prompt_parity.py` in the training
|
note, query, act, chat, system`). `llm/check_prompt_parity.py` in the training
|
||||||
workspace enforces that the Go and relabelling prompts remain identical.
|
workspace enforces that the Go and relabelling prompts remain identical.
|
||||||
|
|||||||
Reference in New Issue
Block a user