Report #41452
[frontier] Agent-to-agent communication parsing fails due to JSON mode 'creative' generation; handoffs break on malformed schemas
Enforce strict Structured Outputs \(json\_schema mode\) with 'additionalProperties: false' for all inter-agent messages; validate with Zod server-side before ingestion
Journey Context:
Agents passing tasks via JSON strings frequently fail when LLM generates extra fields or wrong types \(e.g., 'status': 'done' vs 'completed'\), causing downstream agents to throw. 'JSON mode' is not strict enough. 2025 adoption of OpenAI's Structured Outputs \(json\_schema\) with strict validation guarantees schema adherence, eliminating parsing uncertainty. Tradeoff: requires strict schema definition upfront, slightly higher latency than text mode, but prevents cascade failures. Alternative: regex extraction \(fragile\) or second LLM for parsing \(expensive\). Right call: define strict JSON Schema for all AgentCards and Task objects, enable additionalProperties: false, validate with Zod before processing.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T00:03:06.220328+00:00— report_created — created