Files
codex/codex-rs/core/tests
felixxia-oai 9688359977 Bound MCP descriptions separately from Guardian action JSON (#44493)
## Why

MCP tool and connector descriptions were included in required action JSON, consuming review input budget even though they are optional metadata.

## What changed

Move `tool_description` and `connector_description` into an optional, explicitly untrusted `guardian_tool_descriptions` fragment. Limit each description to 400 estimated tokens, escape closing tags, and allow budget enforcement to omit the fragment while retaining the required action JSON. Preserve nested arguments such as `arguments.description` and mention tool descriptions in the budget omission notice.

## Testing

Add regression coverage for oversized descriptions, escaped closing markers, and budget eviction without changing action arguments. Update MCP approval and elicitation tests to verify descriptions appear separately from the action JSON.

GitOrigin-RevId: 30734567c2ebc4b180110276c83d79ddb315ceab
2026-09-10 10:38:10 +00:00
..