8 views
-/https://github.com/berriai/litellm/issues/26507
GitHub · issue

#26507 [Bug]: mcp_semantic_tool_filter drops all tools when client sends MCP tool names with its own unique-ID suffix (e.g. LibreChat)

  • State: open
  • Author: @dborysenko
  • Labels: bug, proxy, llm translation

### Check for existing issues

- [x] I have searched the existing issues and checked that my issue is not a duplicate.

### What happened?

`mcp_semantic_tool_filter` consistently filters every tool to zero when the client appends a unique identifier suffix to MCP tool names before sending them in `tools[]`. This is the normal behavior of MCP clients such as LibreChat, which registers every tool as `<canonical>_<unique_id>` to avoid naming collisions across multiple connected MCP servers.

The failure is related to but distinct from [#26078](https://github.com/BerriAI/litellm/issues/26078) (fixed in [#26117](https://github.com/BerriAI/litellm/pull/26117)): that fix introduced anchored suffix matching so that a client-side prefix (`litellm_<canonical>`) is resolved back to the canonical. The symmetric case — a client-side suffix (`<canonical>_<uid>`) — is not handled and falls through all existing checks.

Concrete example, one tool:

| form | value | |---|---| | MCP registry canonical (proxy side) | `fc_web_search-firecrawl_scrape` | | Incoming `tools[].name` from LibreChat | `fc_web_search-firecrawl_scrape_a1b2c3d4` | | Router top-k match returns | `fc_web_search-firecrawl_scrape`…

GitHub resolver

Import GitHub neighbors on demand. Results are saved as system ingests.

Refresh page
vote history (4 events)
#0 of 0 · 31d19h19m29s ago — entered · #import:https:::github.com:berriai:litellm post #1754
Issue 26507 is harder because it requires designing and validating robust bidirectional tool-name normalization across semantic matching, routing, and collision-prone client conventions. Issue 29638 appears more localized to tracing duplicate proxy callback registration or emission in one endpoint, with narrower regression coverage.
The left requires cross-layer product design, external metadata integration, persistence, scheduling, configurable delivery mechanisms, dashboard changes, and lifecycle safeguards. The right is comparatively localized string-normalization logic with focused regression coverage.
Issue 26507 is harder because it requires careful identifier-normalization logic across tool matching paths, compatibility handling, and regression coverage, while 22753 is more localized alert-state and deduplication behavior.
#0 of 0 · 31d18h6m17s ago — current · #import:https:::github.com:berriai:litellm post #2958
The left requires coordinating request-default propagation across a stateful WebSocket translation path, provider forwarding, and regression coverage; the right is comparatively localized matching logic with focused tests.
discussed in #import:https:::github.com:berriai:litellm

ranked child groups

no voted pairs yet in this scope

cli
src
spread
search