fix: refine highlighted tool parameter descriptions
Summary
Clarifies agent-facing parameter descriptions across existing GitHub MCP tools and tightens a few schemas with concise enums/examples where they prevent incorrect usage.
Why
Schema linting in #2425 found missing or insufficient parameter descriptions across many tools, causing agents to guess formats for values like Markdown bodies, search queries, branch refs, and file paths. This improves schema guidance while keeping descriptions short to avoid unnecessary token usage.
Fixes #2425
Why some highlighted params were not updated
Some highlighted parameters were intentionally left unchanged after review. The goal was not to describe every string parameter exhaustively, but to add guidance where agents were likely to misuse a value.
Parameters were left as-is when the existing name and description already gave enough context, such as common GitHub identifiers (owner, repo, issue_number, pullNumber) or standard pagination/sorting fields. Others were unchanged where extra wording would mostly repeat the parameter name without reducing ambiguity, increasing schema token usage without improving tool use.
Search and filter parameters were only expanded when the accepted syntax or format was easy to misuse. For example, GitHub search query fields were clarified because agents need to know they accept GitHub search syntax, while simple filters with enums or obvious values did not need additional text.
In short, unchanged highlighted params were reviewed and judged either self-explanatory, already constrained by enum/type, or not worth the token cost of extra description.
What changed
- Added concise descriptions for ambiguous issue, pull request, repository, gist, Actions, code scanning, Copilot, discussion, project, and search parameters.
- Added schema constraints where appropriate, including
search_code.sortandsub_issue_write.methodenums. - Clarified GitHub-specific formats such as
user:branchforlist_pull_requests.head, repository-relative file paths, and full Git refs for code scanning filters. - Regenerated tool snapshots and generated docs.
MCP impact
-
[ ] No tool or API changes
-
[x] Tool schema or behavior changed
Existing tool schemas changed through parameter descriptions and enum metadata only; tool behavior is unchanged.
-
[ ] New tool added
Prompts tested (tool changes only)
- Variety of different prompts covering affected tools.
Security / limits
- [x] No security or limits impact
- [ ] Auth / permissions considered
- [ ] Data exposure, filtering, or token/size limits considered
Tool renaming
- [ ] I am renaming tools as part of this PR (e.g. a part of a consolidation effort)
- [ ] I have added the new tool aliases in
deprecated_tool_aliases.go
- [ ] I have added the new tool aliases in
- [x] I am not renaming tools as part of this PR
Lint & tests
- [x] Linted locally with
./script/lint - [x] Tested locally with
./script/test
Docs
- [ ] Not needed
- [x] Updated (README / docs / examples)