docs(mcp): describe every MCP tool and parameter - #37
Merged
Conversation
MCP clients showed 'No description' for most tools and for every parameter: 20/30 tools had no docstring, and none documented their params. FastMCP derives the tool description from the docstring and each PARAMETER description from Annotated[type, Field(description=...)] (a Google-style Args: section does not work), so wrap every parameter accordingly and give the 20 undocumented tools a one-line docstring. Verified via the live FastMCP server: 30/30 tools now have a description and 0 parameters are missing one; every _call action name and default value is unchanged from before (confirmed by an AST diff), and tools still execute correctly through the MCP dispatcher (cfg_status/cfg_whoami). Full suite 158 passed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
MCP clients (and one-click deeplink tooltips) showed 'No description' for most tools and for every parameter — 20/30 tools had no docstring, and none documented their params (see the reported screenshots for
cfg_branch_diff/cfg_pr_merge).Fix
FastMCP derives the tool description from the docstring and each parameter description only from
Annotated[type, Field(description=...)](a Google-styleArgs:section does not work — verified). So:Annotated[..., Field(description=...)].config_file/env/author/record/message/dry_run/allow_secret) use consistent shared descriptions.Verification (e2e)
_callaction name and every default value is unchanged. Tools still execute correctly through the MCP dispatcher (cfg_status→ 50 rows/5 drift,cfg_whoami→ dev/mongo).Authored with parallel Sonnet agents (6 groups of ~5 tools), reconciled and verified centrally.