mirror of
https://github.com/openai/codex.git
synced 2026-08-24 13:20:07 +00:00
## Why Code Mode rendered document-local `$ref` values as `unknown`, hiding referenced input and structured-output shapes from generated TypeScript declarations. ## What changed - Resolve fragment-only JSON Pointer references against the root schema, including escaped and percent-encoded pointer segments. - Preserve `$ref` siblings as intersections and parenthesize unions used in `allOf` intersections. - Bound recursive and repeated expansion, intermediate rendering work, and final output size, falling back to `unknown` when a limit is reached or a reference cannot be resolved safely. ## Testing Add unit coverage for recursive, escaped, nested-resource, dangling, and oversized references, plus integration coverage for generated Code Mode tool descriptions and MCP structured output types. GitOrigin-RevId: 95c6aa32e25325b5be9359dfac3b3328e5e7a499