[MCP] Prefix MCP tools names with mcp__ (#5309)

This should make it more clear that specific tools come from MCP
servers.

#4806 requested that we add the server name but we already do that.

Fixes #4806
This commit is contained in:
Gabriel Peal
2025-10-19 17:41:55 -07:00
committed by GitHub
parent 2d9ee9dbe9
commit 0170860ef2
4 changed files with 13 additions and 12 deletions

View File

@@ -1001,7 +1001,7 @@ pub(crate) fn new_mcp_tools_output(
}
for (server, cfg) in config.mcp_servers.iter() {
let prefix = format!("{server}__");
let prefix = format!("mcp__{server}__");
let mut names: Vec<String> = tools
.keys()
.filter(|k| k.starts_with(&prefix))