-
-
Notifications
You must be signed in to change notification settings - Fork 89
CLI mirror for loopover_draft_pr_body #6741
Copy link
Copy link
Closed
Labels
gittensor:featureGittensor-scored feature linked to a feature issue — scores a 0.25x multiplier.Gittensor-scored feature linked to a feature issue — scores a 0.25x multiplier.help wantedExtra attention is neededExtra attention is needed
Description
Metadata
Metadata
Assignees
Labels
gittensor:featureGittensor-scored feature linked to a feature issue — scores a 0.25x multiplier.Gittensor-scored feature linked to a feature issue — scores a 0.25x multiplier.help wantedExtra attention is neededExtra attention is needed
Context
The MCP tool
loopover_draft_pr_body(src/mcp/server.ts:2678, viadraftPrBody/analyzeLocalBranchatsrc/mcp/server.ts:4460-4470) callsbuildPublicPrBodyDraft(analysis)(src/services/pr-body-draft.ts:146) on top of aLocalBranchAnalysis. The CLI's existingloopover_prepare_pr_packetstdio tool (loopover-mcp.js:1800-1809) already fetches this same analysis viaanalyzeCurrentBranch/POST /v1/local/branch-analysisbut returns only{ local, prPacket }— no draft-body field.Requirements
buildPublicPrBodyDraftfrom@loopover/engineso the CLI can compute the draft locally from the analysis it already has, matching thelocal-write-tools.tsre-export pattern.registerStdioTool("loopover_draft_pr_body", ...)and a--format markdownoutput option.Deliverables
buildPublicPrBodyDraftexported from@loopover/engineregisterStdioTool("loopover_draft_pr_body", ...)Test Coverage Requirements
99%+ Codecov patch coverage on every changed line and branch in the new route/tool/CLI code, plus a test asserting output parity between the mirrored surfaces for identical input.
Expected Outcome
A contributor can draft a PR body from the CLI before opening the PR, without needing the MCP server.
Links & Resources
Precedent:
registerStdioTool("loopover_prepare_pr_packet", ...)atloopover-mcp.js:1800-1809.