fix: shorten MCP server name to prevent tool name length errors (#360)

* fix: shorten MCP server name to prevent tool name length errors (#358)

Root cause: Claude Code prefixes MCP tool names with
`mcp__plugin_{plugin-name}_{server-name}__` which was 43 chars
for `mcp__plugin_claude-mem_claude-mem-search__`. Combined with
`progressive_description` (22 chars) this exceeded the 64 char limit.

Changes:
- Shortened MCP server name from 'claude-mem-search' to 'mem-search'
  (saves 8 chars, new prefix is 35 chars)
- Renamed `progressive_description` tool to `help` (saves 18 chars)
- Updated SKILL.md to reference new `help` tool name
- Updated internal Server constructor name for consistency

All tool names now safely under 64 char limit:
- Longest is now `get_batch_observations` at 56 chars total
- `help` is only 39 chars total

Fixes #358

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>

* refactor: rename get_batch_observations to get_observations

The plural form naturally implies multiple items can be fetched,
following WordPress conventions. Simpler and clearer naming.

Also saves 6 additional characters for MCP tool name length.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>

* docs: update all references to renamed MCP tools

Updated documentation and code comments to reflect:
- progressive_description → help
- get_batch_observations → get_observations

Files updated:
- docs/public/usage/claude-desktop.mdx
- docs/public/architecture/worker-service.mdx
- src/services/worker/FormattingService.ts

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
Alex Newman
2025-12-16 22:06:24 -05:00
committed by GitHub
parent da30aedb28
commit 660c523ba4
10 changed files with 26 additions and 26 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
{
"mcpServers": {
"claude-mem-search": {
"mem-search": {
"type": "stdio",
"command": "${CLAUDE_PLUGIN_ROOT}/scripts/mcp-server.cjs"
}
File diff suppressed because one or more lines are too long
+1 -1
View File
@@ -1157,7 +1157,7 @@ No previous sessions found for project "${r}".`}]};let i=[];i.push("# Recent Ses
\u{1F4A1} Search Strategy:
1. Search with index to see titles, dates, IDs
2. Use timeline to get context around interesting results
3. Batch fetch full details: get_batch_observations(ids=[...])
3. Batch fetch full details: get_observations(ids=[...])
Tips:
\u2022 Filter by type: obs_type="bugfix,feature"
Binary file not shown.
+9 -9
View File
@@ -86,13 +86,13 @@ For each relevant ID, fetch full details using MCP tools:
**Fetch multiple observations (ALWAYS use for 2+ IDs):**
```
get_batch_observations(ids=[11131, 10942, 10855])
get_observations(ids=[11131, 10942, 10855])
```
**With ordering and limit:**
```
get_batch_observations(
get_observations(
ids=[11131, 10942, 10855],
orderBy="date_desc",
limit=10,
@@ -126,7 +126,7 @@ get_prompt(id=5421)
**Batch optimization:**
- **ALWAYS use `get_batch_observations` for 2+ observations**
- **ALWAYS use `get_observations` for 2+ observations**
- 10-100x more efficient than individual fetches
- Single HTTP request vs N requests
- Returns all results in one response
@@ -175,13 +175,13 @@ search(query="database migration", limit=20, project="my-project")
**Get detailed instructions:**
Use the `progressive_description` tool to load full instructions on-demand:
Use the `help` tool to load full instructions on-demand:
```
progressive_description(topic="workflow") # Get 4-step workflow
progressive_description(topic="search_params") # Get parameters reference
progressive_description(topic="examples") # Get usage examples
progressive_description(topic="all") # Get complete guide
help(topic="workflow") # Get 4-step workflow
help(topic="search_params") # Get parameters reference
help(topic="examples") # Get usage examples
help(topic="all") # Get complete guide
```
## Why This Workflow?
@@ -210,5 +210,5 @@ progressive_description(topic="all") # Get complete guide
**Remember:**
- ALWAYS get timeline context to understand what was happening
- ALWAYS use `get_batch_observations` when fetching 2+ observations
- ALWAYS use `get_observations` when fetching 2+ observations
- The workflow is optimized: search → timeline → batch fetch = 10-100x faster