9 views
-/https://github.com/berriai/litellm/issues/28766
GitHub · issue

#28766 [Bug]: Semantic MCP Tool Filtering emits invalid OpenAI tool schema

  • State: open
  • Author: @junkman690
  • 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?

Semantic MCP tool filtering appears to reconstruct filtered tools incorrectly, causing invalid OpenAI tool payloads to be sent to the backend model.

Tested with latest llama.cpp as provider

### Steps to Reproduce

1. Add MCP tools 2. Test in webui playground without semantic search to ensure they work 3. Enable semantic search 4. Test in webui playground

### Relevant log output

```shell 2026-05-25 15:01:07 - LiteLLM - INFO - mcp_server_manager.py:3060 - reload_servers_from_database() - Found 4 MCP servers in database 15:01:07 - LiteLLM Proxy:INFO: proxy_server.py:6372 - Loading 0 search tool(s) from database into router 2026-05-25 15:01:07 - LiteLLM Proxy - INFO - proxy_server.py:6372 - _init_search_tools_in_db() - Loading 0 search tool(s) from database into router 15:01:07 - LiteLLM Proxy:INFO: tool_registry_writer.py:329 - ToolPolicyRegistry: synced 41 tool policies and 0 object permissions from DB 2026-05-25 15:01:07 - LiteLLM Proxy - INFO - tool_registry_writer.py:329 - sync_tool_policy_from_db() - ToolPolicyRegistry: synced 41 tool pol…

GitHub resolver

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

Refresh page
vote history (2 events)
#0 of 0 · 31d18h59m17s ago — entered · #import:https:::github.com:berriai:litellm post #1975
Semantic filtering spans MCP integration, tool selection, schema reconstruction, and provider-compatible translation, requiring broader investigation and regression coverage. The other issue appears more localized to request-parameter filtering and provider adapter behavior.
#0 of 0 · 31d17h38m27s ago — current · #import:https:::github.com:berriai:litellm post #3330
The left item spans new proxy capabilities across multiple tool ecosystems, requiring configuration modeling, precedence/enforcement rules, persistence or distribution mechanisms, compatibility testing, and security-sensitive administration behavior. The right item is more likely a contained defect in an existing MCP transformation path, with focused reproduction, schema correction, and regression tests.
discussed in #import:https:::github.com:berriai:litellm

ranked child groups

no voted pairs yet in this scope

cli
src
spread
search