Private
Public Access
feat(directives): scavenge from nagent_review_20260608/: 5 directives
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
# parse_failure_visible_to_conversation
|
||||
|
||||
## v1
|
||||
|
||||
**Why this iteration:** Lifted from `conductor/tracks/nagent_review_20260608/nagent_takeaways_20260608.md:171-178` (Pattern 6 — "Visible retry on protocol failure — turn errors into conversation data"). The nagent pattern: bad output + `<system>` correction appended to the conversation; `MAX_FORMAT_RETRIES = 3`; the conversation is greppable for every retry.
|
||||
**Source:** `conductor/tracks/nagent_review_20260608/nagent_takeaways_20260608.md:171-178`
|
||||
|
||||
---
|
||||
**Lifted:** 2026-07-02 (scavenge pass — directive library expansion from nagent_review track)
|
||||
@@ -0,0 +1,21 @@
|
||||
# Parse failures become conversation data — the bad output and the system correction are appended so the next call sees them
|
||||
|
||||
## The visibility contract
|
||||
|
||||
When a model's output fails to parse (malformed tool call, broken tag, missing closing delimiter), the failure is NOT silently retried inside the loop. The loop:
|
||||
|
||||
1. Appends the bad output to the conversation as a quoted block, with a system-level correction message ("Invalid format: {parse_error}. Respond only with valid tags.").
|
||||
2. Lets the next call see its own previous failure + the correction.
|
||||
3. Increments a visible counter so the user (and Tier 2 code review) can spot persistent parse failures.
|
||||
|
||||
Per `conductor/tracks/nagent_review_20260608/nagent_takeaways_20260608.md:171-178`: the nagent pattern is `MAX_FORMAT_RETRIES = 3` + the bad output + the `<system>` correction are appended to the conversation. "The user can grep the conversation for `<system>` to find every retry."
|
||||
|
||||
## Why
|
||||
|
||||
Silent retries hide the model's actual failure mode. If the model keeps emitting bad XML because it misunderstood the schema, a silent retry loop burns context without the user (or Tier 2) ever seeing *what* the model is getting wrong. Surfacing the failure in the conversation makes the loop debuggable and gives the user a chance to fix the prompt.
|
||||
|
||||
## What this means in practice
|
||||
|
||||
- The diagnostic panel shows the last N parse failures: the model output + the error message + the timestamp.
|
||||
- A persistent parse failure (> 3 retries) escalates: the conversation pauses with a "fix your prompt or accept this garbage" dialog.
|
||||
- The conversation file is greppable for parse failures (`grep "<system>Invalid"`); the JSON-L comms log is not sufficient on its own.
|
||||
Reference in New Issue
Block a user