fix(orchestration): tolerate raw control characters in model JSON
Deploy Canina / deploy (push) Successful in 36s

This commit is contained in:
devops committed 2026-10-19 14:13:00 +00:00
1 parent 4c3f8de1fb
commit bf53f2e17c
2 files changed
+5 -1

No files matched your search

@@ -37,7 +37,7 @@ def parse_structured_response(text: str) -> dict[str, Any]:
start, end = cleaned.find("{"), cleaned.rfind("}")
if start >= 0 and end > start:
cleaned = cleaned[start : end + 1]
parsed = json.loads(cleaned)
parsed = json.loads(cleaned, strict=False)
if not isinstance(parsed, dict):
raise ValueError("Model response must be a JSON object")
parsed.setdefault("summary", "")