Skip to content

core: limit search_tool_bm25 to Apps and clarify discovery guidance - #11669

Merged
apanasenko-oai merged 2 commits into
mainfrom
codex/apps-search-tool-apps-only-guidance
Feb 13, 2026
Merged

apanasenko-oai merged 2 commits into
mainfrom
codex/apps-search-tool-apps-only-guidance

Conversation

@apanasenko-oai

Copy link
Copy Markdown
Contributor

Summary

  • Limit search_tool_bm25 indexing to codex_apps tools only, so non-Apps MCP servers are no longer discoverable through this search path.
  • Move search-tool discovery guidance into the search_tool_bm25 tool description (via template include) instead of injecting it as a separate developer message.
  • Update Apps discovery guidance wording to clarify when to use search_tool_bm25 for Apps-backed systems (for example Slack, Google Drive, Jira, Notion) and when to call tools directly.
  • Remove dead core helper code (filter_codex_apps_mcp_tools and codex_apps_connector_id) that is no longer used after the tool-selection refactor.
  • Update core search-tool tests to assert codex-apps-only behavior and to validate guidance from the tool description.

Validation

  • ✅ just fmt
  • ✅ cargo test -p codex-core search_tool
  • ⚠️ cargo test -p codex-core was attempted, but the run repeatedly stalled on tools::js_repl::tests::js_repl_can_attach_image_via_view_image_tool.

Tickets

  • None

@apanasenko-oai
apanasenko-oai marked this pull request as ready for review February 13, 2026 01:14
@apanasenko-oai
apanasenko-oai force-pushed the codex/apps-search-tool-apps-only-guidance branch from a47b28f to 1b176ff Compare February 13, 2026 01:16
- When the user asks to search/lookup/query any external system (logs, tickets, metrics, Slack, etc.), you must call `search_tool_bm25` first before running any shell command or repo search.
- Only use shell commands if (a) MCP tools for that system are not available or not sufficient, and (b) the user explicitly wants a local file/CLI search.
- If unsure which system/tool applies, ask a clarifying question after checking MCP tools.
- Use `search_tool_bm25` when the user asks to work with an Apps-backed external system (for example Slack, Google Drive, Jira, Notion) and the exact tool name is not already known.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can still be vague to the model, should we explicitly add the name and description of the installed and enabled apps here?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

make sense, let's inject enabled app names.

@apanasenko-oai
apanasenko-oai force-pushed the codex/apps-search-tool-apps-only-guidance branch 3 times, most recently from 97cfeb7 to cf2c644 Compare February 13, 2026 05:49
@apanasenko-oai
apanasenko-oai force-pushed the codex/apps-search-tool-apps-only-guidance branch from cf2c644 to 1099a5e Compare February 13, 2026 17:20
@apanasenko-oai
apanasenko-oai merged commit 38c442c into main Feb 13, 2026
33 checks passed
@apanasenko-oai
apanasenko-oai deleted the codex/apps-search-tool-apps-only-guidance branch February 13, 2026 17:32
@github-actions github-actions Bot locked and limited conversation to collaborators Feb 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.

3 participants