Skip to content

tools: infer code-mode namespace descriptions from specs#22406

Merged
pakrym-oai merged 1 commit into
mainfrom
pakrym/code-mode-namespace-descriptions-from-specs
May 13, 2026
Merged

tools: infer code-mode namespace descriptions from specs#22406
pakrym-oai merged 1 commit into
mainfrom
pakrym/code-mode-namespace-descriptions-from-specs

Conversation

@pakrym-oai
Copy link
Copy Markdown
Collaborator

Why

Code mode already builds the merged nested ToolSpecs that feed the exec prompt. Keeping a separate tool_namespaces map in the planning path duplicated that metadata and left extra wrapper plumbing in spec.rs.

What changed

  • derive code-mode namespace descriptions from the merged ToolSpec::Namespace entries before building the code-mode handlers
  • extract build_code_mode_handlers(...) so the code-mode-specific planning stays in one place
  • remove tool_namespaces from ToolRegistryBuildParams
  • delete the now-unused McpToolPlanInputs wrapper and related test helper plumbing

Testing

  • cargo test -p codex-core spec_plan

@pakrym-oai pakrym-oai marked this pull request as ready for review May 13, 2026 01:26
@pakrym-oai pakrym-oai requested a review from a team as a code owner May 13, 2026 01:26
@pakrym-oai pakrym-oai merged commit 67c8486 into main May 13, 2026
27 checks passed
@pakrym-oai pakrym-oai deleted the pakrym/code-mode-namespace-descriptions-from-specs branch May 13, 2026 03:47
@github-actions github-actions Bot locked and limited conversation to collaborators May 13, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants