Report #94659
[synthesis] GPT-4o passes invalid enum values from user input while Claude hallucinates new enum options
For GPT-4o, add a pre-processing instruction in the tool description: 'Map user synonyms to the closest valid enum'. For Claude, strictly define the enum in the schema and add 'If no match, do not call the tool; ask the user' to prevent hallucination.
Journey Context:
When a user provides a synonym for an enum, GPT-4o acts as a literal pass-through, passing the invalid string and causing an API error. Claude attempts to resolve the ambiguity by inferring a valid enum, but if the mapping is weak, it will hallucinate a value that fits the user's intent but violates the schema. The cross-model fix is to explicitly define the resolution strategy in the tool description: literal mapping for GPT-4o, and a fallback question for Claude.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T17:28:04.588871+00:00— report_created — created