-
Notifications
You must be signed in to change notification settings - Fork 292
Description
I am using rust-mcp-server, and in my setup I have a registry hosted locally. However, cargo info only works with crates.io, and it fails in the current setup because the LLM doesn’t add this parameter. If I were able to change it somewhere in the middle, it would help fix the issue.
I have requested this feature on the Rust MCP repo:
Vaiz/rust-mcp-server#82
Disclaimer : AI content Starts here:
Description
Currently, MetaMCP allows for great orchestration of multiple MCP servers through Namespaces. However, when a tool is exposed through a namespace, it always requires the full set of arguments defined by the upstream server.
I would like to propose a system that allows users to set default values for specific tool inputs at the Namespace level.
The Problem
In many cases, an MCP tool has parameters that stay the same for a specific project or workflow. For example:
- A
filesystemtool might always need to point to a specific/project/docsdirectory for one namespace, but a/logsdirectory for another. - A
searchtool might always need a specificsite:example.comfilter or a specificregionset for a particular team's namespace.
Right now, the LLM/User has to provide these values every single time, which increases token usage and the chance of errors.
Proposed Solution
Add a configuration option within the Namespace settings (either in the UI or the provision.yaml) to "bind" or "override" tool parameters.
Key features of this proposal:
- Namespace-Level Defaults: Allow users to define a JSON object of default values for a specific tool within a namespace.
- Input Masking: If a default is set, provide an option to "hide" that parameter from the LLM, effectively turning it into a constant for that specific endpoint.
- Variable Injection: (Optional) Support environment variables (e.g.,
${USER_ID}) in these default settings.
Example Configuration (Conceptual)
In the Namespace settings, it could look like this:
{
"namespace": "documentation-helper",
"servers": [
{
"name": "local-files",
"tool_overrides": {
"read_file": {
"defaults": {
"base_path": "/home/user/docs/project-v1"
},
"hidden_params": ["base_path"]
}
}
}
]
}
Why this is useful
- Security: You can restrict a tool to only work on a specific folder or resource by hardcoding the input.
- Efficiency: Reduces the amount of context/instructions needed for the LLM.
- Personalization: Allows different "Namespaces" to act as specialized agents with pre-configured settings.
Thank you for the amazing work on MetaMCP! I believe this would significantly improve the developer experience for complex agentic workflows.