Repository navigation
mcp-slim: Zero-dependency MCP stdio proxy for Haystack MCPToolset (-50% to -98% schema tokens & SecretGuard) #13705
Replies: 2 comments
|
the lazy BM25 search for token reduction is genuinely useful, that's the main win for anyone hitting context limits with large tool schemas in haystack pipelines. on SecretGuard: post-hoc regex redaction is better than nothing, but by the time it fires the secret already landed in the tool output and potentially in logs or traces. the cleaner fix is upstream, keeping raw keys out of the pipeline entirely so the agent only ever holds a short-lived reference, not the actual credential. i work on 1Claw which takes that approach via an HSM-backed vault (docs.1claw.co?utm_source=github&utm_medium=comment&utm_campaign=growth), but any vault pattern addresses the root cause better than reactive scrubbing. |
|
@redbotster Completely agree on keeping raw credentials out of the agent loop via short-lived vault references whenever the agent is authenticating to an external service. Where |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Hi everyone,
For anyone using
MCPToolset/MCPToolin Haystack agent pipelines, we built mcp-slim, a zero-dependency Python 3.10+ stdio proxy that wraps any stdio MCP server (StdioServerInfo(command="mcp-slim", args=["run", "--", ...])).Key Benefits with
MCPToolsettools/listschema tokens by ~50% (or-98.7%with--lazyBM25 search) while inlining$defs/$refpointers and flattening rootanyOf/oneOf.--allow-toolsand--deny-toolson bothtools/listandtools/callat the stdio boundary.-43%+tokens), flattensEmbeddedResourcetext blocks, and redacts leaked API keys / URL query secrets viaSecretGuard.Repository: https://github.com/SalyyS1/mcp-slim
If you find
mcp-slimuseful with Haystack'sMCPToolset, a star on SalyyS1/mcp-slim is greatly appreciated!All reactions