feat(mcp): categorize and group loopover-mcp tools output (#6301) - #6327
feat(mcp): categorize and group loopover-mcp tools output (#6301)#6327nghetienhiep wants to merge 1 commit into
Conversation
…6301) Add a coarse category to every MCP tool on both the local wrapper and the remote server, and group the `loopover-mcp tools` output by it so the ~150-tool surface is navigable instead of a single flat list. - packages/loopover-mcp: each STDIO_TOOL_DESCRIPTORS entry carries a category id, with STDIO_TOOL_CATEGORIES as the single source of truth for order + labels; `tools` prints category headers and `tools --json` adds a categories summary plus a per-tool category. - src/mcp/server.ts: the same ids live in MCP_TOOL_CATEGORIES and ride along as MCP _meta.category via a thin registration wrapper, so tools/list clients see the grouping. Category names follow the repo's own conceptual surfaces (discovery, local branch prep, review/gate prediction, agent automation, maintainer, registry/config utility). Tests assert every registered tool has exactly one known category on both servers and that the CLI output is grouped accordingly. Closes JSONbored#6301
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
|
Warning ⏸️ LoopOver review result - manual review recommendedReview updated: 2026-07-16 02:15:09 UTC
Review summary Nits — 5 non-blocking
Decision drivers
Context & advisory signals — never blocks the verdict
Review context
Contributor next steps
Signal definitions
🧪 Chat with LoopOverAsk LoopOver a question about this PR directly in a comment — grounded only in the same cached, public-safe facts shown above, never a new claim.
Full command reference: https://gittensory.aethereal.dev/docs/loopover-commands 🧪 Experimental — new and may change. 🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by LoopOver, a quiet PR intelligence layer for OSS maintainers.
|
|
LoopOver is closing this pull request on the maintainer's behalf (conflicts with the base branch — resolve and open a fresh PR). This is an automated maintenance action — to pursue this change, please open a new pull request with the issues resolved. Closed PRs may be analyzed later to improve review accuracy, but they are not automatically reopened or re-reviewed. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #6327 +/- ##
=======================================
Coverage 95.60% 95.60%
=======================================
Files 596 596
Lines 47121 47126 +5
Branches 14999 14999
=======================================
+ Hits 45049 45054 +5
Misses 1290 1290
Partials 782 782
Flags with carried forward coverage won't be shown. Click here to find out more.
|
Summary
Adds a coarse
categoryto every MCP tool on both servers and groups theloopover-mcp toolsoutput by it, so a user scanning the full tool surface can find the relevant subset instead of
reading one long flat list (#6301, part of the MCP Platform Wave 1 milestone).
packages/loopover-mcp/bin/loopover-mcp.js): eachSTDIO_TOOL_DESCRIPTORSentry now carries a
categoryid, and a singleSTDIO_TOOL_CATEGORIESlist is the source of truthfor the category order + human labels.
loopover-mcp toolsprints tools under category headers inthat canonical order;
tools --jsongains acategoriessummary ({ id, label, count }) and acategoryfield per tool.src/mcp/server.ts): the same category ids live in an exportedMCP_TOOL_CATEGORIESmap, attached to each tool as MCP_meta.categoryvia a thin registrationwrapper, so
tools/listclients see the same grouping. No tool is added, removed, or renamed.branch & PR prep, review/gate prediction, agent automation, maintainer/repo-owner, and
registry/config utility) rather than an invented taxonomy.
Every registered tool maps to exactly one category; the tests fail loudly if a new tool is ever added
without one, or if the map drifts from the registered set.
Scope
type(scope): short summaryConventional Commit format.CONTRIBUTING.mdand does not reintroduce GitHub Pages, VitePress,site/, orCNAME.Closes #6301).Validation
git diff --checknpm run actionlintnpm run typechecknpm run test:coveragelocally — the tools/list_meta.categorywiring, theMCP_TOOL_CATEGORIESmap, and the registration wrapper insrc/mcp/server.tsare fully covered with no partial branches (verified against the v8 report). New tests:test/unit/mcp-tool-categories.test.tsand an added case intest/unit/mcp-cli-tools.test.ts.npm run build:mcpnpm run test:mcp-packnpm run command-reference:check,npm run docs:drift-check,npm run manifest:drift-checknpm audit --audit-level=moderate(0 vulnerabilities)_meta.categoryparity)If any required check was skipped, explain why:
npm run test:workers/ui:*(ui:lint,ui:typecheck,ui:build,ui:openapi:check): this change touches only the MCP server metadata and the local CLI'stoolsoutput — no worker route, OpenAPI schema, or UI surface changed, so those checks are unaffected.Safety
tools/listnow exposes_meta.category; covered by tests).UI Evidencesection. — n/a, no visible UI/frontend/docs-site change.loopover-mcpREADMEtoolssection now documents the grouped output and the new--jsonshape); no changelog edited.Notes
loopover-mcp tools searchcommand (feat(mcp): addtools search <query>for fuzzy tool discovery #6317): the defaulttoolslistingis now grouped by category, while
tools search <query>keeps its flat ranked results unchanged._meta(the spec-sanctioned place for arbitrarytool metadata), so it rides along in every
tools/listresponse without changing any tool's inputor output schema. The two servers keep their own category maps for now (they live in separate
packages); this can consolidate onto a shared registration point if Spec: should local (@loopover/mcp) and remote (src/mcp/server.ts) MCP tool implementations share a core? #6227's shared-core work lands.
Closes #6301