Expand description
LLM-JSON autofixer — ports payload_fixer.py.
Parses a raw JSON string from an LLM, applying tolerant fixes:
- normalize smart (curly) quotes to straight quotes,
- on parse failure, strip trailing commas and retry,
- wrap a bare top-level object into a one-element list.
Returns Ok(Vec<Value>) on success, or an A2uiError (Parse for serde
failures, Validation for a non-list/non-object top level).
Functions§
- parse_
and_ fix - Parse and autofix a raw LLM JSON payload into a list of JSON values.