Skip to content

Commit 4ce970b

Browse files
authored
Update meta-mcp guide (#194)
* Add more context to the meta-mcp guide Signed-off-by: Dan Barr <[email protected]> Co-authored-by: Dan Barr <[email protected]>
1 parent aa253e0 commit 4ce970b

File tree

1 file changed

+75
-27
lines changed

1 file changed

+75
-27
lines changed

docs/toolhive/guides-mcp/meta-mcp.mdx

Lines changed: 75 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,13 @@ multiple MCP servers. It provides tool discovery, unified access to multiple MCP
1616
servers through a single endpoint, and intelligent routing of requests to
1717
appropriate MCP tools.
1818

19+
:::info[Status]
20+
21+
The meta-mcp server is currently experimental. If you try it out, please share
22+
your feedback on the [Stacklok Discord community](https://discord.gg/stacklok).
23+
24+
:::
25+
1926
Key features include:
2027

2128
- **Tool discovery**: Uses hybrid search (semantic + keyword) to find the right
@@ -27,37 +34,73 @@ Key features include:
2734
- **Intelligent routing**: Automatically routes requests to the appropriate MCP
2835
server based on tool requirements
2936

37+
This approach helps you avoid problems associated with context overload and tool
38+
confusion by narrowing down the toolset to only those relevant for a given task.
39+
It also simplifies client configurations by providing a single access point to
40+
multiple MCP servers.
41+
42+
The meta-mcp workflow:
43+
44+
1. Your AI client sends the request to meta-mcp
45+
2. Meta-mcp uses hybrid search (semantic + keyword) to find relevant tools
46+
across all connected MCP servers
47+
3. Meta-mcp server returns the short list of matching tools to the client
48+
4. Client selects one tool from the short list and uses meta-mcp to call that
49+
tool
50+
5. Results are returned from meta-mcp to the client
51+
3052
## Metadata
3153

3254
<MCPMetadata name='meta-mcp' />
3355

3456
## Usage
3557

36-
<Tabs groupId='mode' queryString='mode'>
58+
The meta-mcp server is specifically designed to work with
59+
[ToolHive groups](../guides-cli/group-management.md). The recommended setup is
60+
to run meta-mcp in its own dedicated group (e.g., "meta") and have other MCP
61+
servers in a separate group (e.g., "default"). This keeps client configurations
62+
clean and allows meta-mcp to discover and route to tools across all connected
63+
MCP servers.
64+
65+
Clients using meta-mcp should be configured to connect only to the meta group.
66+
The meta-mcp server discovers and routes requests to tools in the default group.
67+
68+
```mermaid
69+
flowchart TB
70+
subgraph meta["ToolHive group: meta"]
71+
direction TB
72+
metamcp["meta-mcp server"]
73+
end
74+
subgraph def["ToolHive group: default"]
75+
direction TB
76+
mcp1["mcp1"]
77+
mcp2["mcp2"]
78+
mcp3["mcp3"]
79+
end
80+
81+
client(["Client"]) <-- connects --> meta
82+
metamcp <-. discovers/routes .-> def
83+
client x-. 🚫 .-x def
84+
```
3785

86+
<Tabs groupId='mode' queryString='mode'>
3887
<TabItem value='ui' label='UI'>
3988

4089
The meta-mcp server uses ToolHive groups to function. While you need the
4190
ToolHive UI to run meta-mcp, it doesn't support group management yet, so you'll
4291
need to use the CLI for setup.
4392

4493
</TabItem>
45-
4694
<TabItem value='cli' label='CLI' default>
4795

4896
:::info[Prerequisites]
4997

5098
You need both the ToolHive CLI and UI to use the meta-mcp server because it
5199
depends on the UI's API server for tool discovery and management.
52100

53-
- ToolHive UI (version >= 0.6.0) must be running for setup
101+
- ToolHive UI (version >= 0.6.0) must be running during setup and operation
54102
- ToolHive CLI (version >= 0.3.1)
55103

56-
The meta-mcp server should run in a
57-
[dedicated group](../guides-cli/group-management.md) to keep client
58-
configurations clean. Other MCP servers that you want to access through meta-mcp
59-
should be in a separate group.
60-
61104
:::
62105

63106
**Step 1: Create a dedicated group and run meta-mcp**
@@ -80,12 +123,23 @@ thv client setup
80123
thv client list-registered
81124
```
82125

126+
:::note
127+
128+
If your client was previously registered with the default group, unregister it.
129+
For example, to unregister Cursor:
130+
131+
```bash
132+
thv client remove cursor --group default
133+
```
134+
135+
:::
136+
83137
**Step 3: Add MCP servers to the default group**
84138

85139
```bash
86140
# Add MCP servers that you want to access through meta-mcp
87141
thv run github
88-
thv run filesystem
142+
thv run fetch
89143
thv run time
90144

91145
# Verify the configuration - meta-mcp should be in 'meta' group, others in 'default'
@@ -97,29 +151,23 @@ thv list
97151

98152
## Sample prompts
99153

100-
Once meta-mcp is configured and running, you can use it with natural language
101-
prompts. The server automatically discovers and routes to appropriate tools:
102-
103-
**Direct task examples:**
154+
Once meta-mcp is configured and running, you can use the same prompts you would
155+
normally use with individual MCP servers. The meta-mcp server automatically
156+
discovers and routes to appropriate tools.
104157

105-
- "Get the details of GitHub issue 1911 from stacklok/toolhive repo"
106-
- "List recent PRs from stacklok/toolhive repo"
158+
Using the example MCP servers above, here are some sample prompts:
107159

108-
**The meta-mcp workflow:**
109-
110-
1. Your AI client sends the request to meta-mcp
111-
2. Meta-mcp uses hybrid search (semantic + keyword) to find relevant tools
112-
across all connected MCP servers
113-
3. Meta-mcp server returns the short list of matching tools to the client
114-
4. Client selects one tool from the short list and uses meta-mcp to call that
115-
tool
116-
5. Results are returned from meta-mcp to the client
160+
- "Get the details of GitHub issue 1911 from the stacklok/toolhive repo"
161+
- "List recent PRs from the stacklok/toolhive repo"
162+
- "Fetch the latest news articles about AI"
163+
- "What is the current time in Tokyo?"
117164

118165
## Available tools
119166

120-
The meta-mcp server provides two main tools:
167+
The meta-mcp server provides two tools of its own for tool discovery and
168+
execution.
121169

122-
### find_tool
170+
### `find_tool`
123171

124172
Discovers available tools that match your requirements using hybrid search
125173
(semantic + keyword).
@@ -131,7 +179,7 @@ Discovers available tools that match your requirements using hybrid search
131179
- `tool_keywords`: Space-separated keywords of the task or capability needed
132180
(e.g., "list issues github", "SQL query postgres")
133181

134-
### call_tool
182+
### `call_tool`
135183

136184
Executes a specific tool with provided parameters after discovery.
137185

0 commit comments

Comments
 (0)