chat mode: json_output toggle to return clean extracted JSON
For JSON-producing system prompts (e.g. LTX prompt-relay), json_output=true pulls the JSON object out of the reply (strips reasoning/prose/code-fences via _parse_json, which handles nested schemas and reasoning-then-JSON) and returns it re-serialized; falls back to raw text if none parses. agent_bridge gains --json-output. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -58,6 +58,9 @@ node — feed an image (and optionally a second), write your own `system_prompt`
|
||||
and read the model's text from the `analysis` output. Reuses the same model dropdown, quant,
|
||||
and auto-download as the judge, so it's a one-node abliterated VLM for captioning, tagging,
|
||||
Q&A, prompt-from-image, etc. (CLI: `agent_bridge.py --mode chat --user-prompt "..."`).
|
||||
Set **`json_output=true`** for JSON-producing system prompts — it extracts the JSON object
|
||||
from the reply (stripping any reasoning, prose, or ```fences) and returns it clean and
|
||||
re-serialized (falls back to raw text if none parses). Works even with `enable_thinking` on.
|
||||
|
||||
## Performance / speed
|
||||
|
||||
|
||||
Reference in New Issue
Block a user