Known Limitations
Schema Complexity Limits
Extremely large and complex schemas (deep nesting, long descriptions, numerous fields) can exceed the underlying model's "state" limit, causing a BadRequestError
when the function is created or called. This is particularly common with schemas that have:
- More than 20+ fields at the root level
- Deep nesting beyond 3-4 levels
- Very long field descriptions (1000+ characters per field)
- Complex conditional logic using
anyOf
/oneOf
statements
Context Window Limits on Enums
Schemas with very long enum lists (64+ items) can hit the context window limit of the underlying LLM models, leading to failures or degraded performance. Consider breaking large enums into smaller, more focused schemas or using pattern matching instead.
Positional Schema Fragility
Schemas that rely on array indices to convey meaning (e.g., rates[1]
corresponds to a weight of 1 lb) are brittle and often lead to poor performance, as LLMs work best with semantic relationships. Use descriptive field names and object structures instead of positional arrays.
Only Object Type Schemas at Root Level
- Only object-type schemas are supported at the root level
- External
$schema
references are not supported - Schemas must have at least one property defined