Context
We implemented the A2A Comment-ID Hand-off Protocol for issues and PRs in #10272 / PR #10287. Ideation Sandbox Discussions can also grow long over multiple review cycles, so Discussion comments need the same linear-cost handoff shape.
Current State (2026-06-03 V-B-A)
manage_discussion_comment already returns commentId, url, and createdAt on create, plus commentId, url, and updatedAt on update. That slice was delivered by #10841 / PR #10891.
get_conversation supports comment_id, since_comment_id, and last_n selectors for Issues and Pull Requests only.
- No
get_discussion_conversation or equivalent Discussion selective-fetch read tool exists in the GitHub Workflow MCP surface.
ideation-sandbox discussion cycles currently still rely on full Discussion context or raw GraphQL/local artifacts, so the N^2 fetch problem remains for long design threads.
Problem
The remaining gap is Discussion-domain selective fetch. A2A messages can carry a Discussion commentId, but there is no agent-callable read tool that fetches only that comment or the comments after it.
Contract Ledger Matrix
| Target Surface |
Source of Authority |
Proposed Behavior |
Fallback / Edge Case |
Docs |
Evidence |
manage_discussion_comment return payload |
#10841 / PR #10891; current DiscussionService.manageDiscussionComment() |
Already returns commentId + URL + timestamp. No new implementation required for this row. |
Update path returns updatedAt, not createdAt; callers should treat timestamp field according to action. |
GitHubWorkflow.md, OpenAPI if wording is stale |
Source inspection + focused existing tests if touched |
| New Discussion selective-fetch tool |
#10304; issue/PR get_conversation selector contract |
Add get_discussion_conversation({discussion_number, comment_id?, since_comment_id?, last_n?}) or an equivalent MCP read surface. Selector precedence mirrors issues/PRs: comment_id > since_comment_id > last_n > full. |
Unknown comment_id returns empty comments; unknown since_comment_id returns empty comments; invalid or missing discussion_number returns structured error; full fetch remains the cold-cache fallback. |
OpenAPI + GitHubWorkflow.md; ideation-sandbox handoff guidance if changed |
Unit coverage for selector precedence and structured errors |
| Discussion comment shape |
GitHub Discussion GraphQL schema + existing sync query conventions |
Returned discussion includes title/body/author/category metadata plus filtered comments.nodes; comment nodes include id, author.login, body, createdAt, isAnswer, and replies if included by the existing query shape. |
Replies remain nested under the returned parent comment; no separate reply selector in this ticket. |
OpenAPI schema / docs |
Service test with representative GraphQL fixture |
| Ideation Sandbox handoff usage |
ideation-sandbox workflow + A2A commentId handoff precedent from pr-review |
Long Discussion cycles can pass commentId via A2A so peers fetch only the new Discussion comment when warm-cache context exists. |
Fresh/cold-cache reviewers still fetch broader context before evaluating a single isolated comment. |
ideation-sandbox docs; optional cross-reference to pr-review warm-vs-cold discipline |
Docs grep + review evidence |
Acceptance Criteria
Related
- #10272 / PR #10287 — issue/PR comment-ID return + selective fetch.
- #10841 / PR #10891 — Discussion commentId return payload.
- #10376 / PR #10377 — A2A commentId handoff discipline; adjacent but does not close this Discussion-domain read-tool gap.
Origin Session ID: 0b29a8fa-c6b0-42e2-ab3b-8015a99db2d8
Context
We implemented the A2A Comment-ID Hand-off Protocol for issues and PRs in #10272 / PR #10287. Ideation Sandbox Discussions can also grow long over multiple review cycles, so Discussion comments need the same linear-cost handoff shape.
Current State (2026-06-03 V-B-A)
manage_discussion_commentalready returnscommentId,url, andcreatedAton create, pluscommentId,url, andupdatedAton update. That slice was delivered by #10841 / PR #10891.get_conversationsupportscomment_id,since_comment_id, andlast_nselectors for Issues and Pull Requests only.get_discussion_conversationor equivalent Discussion selective-fetch read tool exists in the GitHub Workflow MCP surface.ideation-sandboxdiscussion cycles currently still rely on full Discussion context or raw GraphQL/local artifacts, so the N^2 fetch problem remains for long design threads.Problem
The remaining gap is Discussion-domain selective fetch. A2A messages can carry a Discussion commentId, but there is no agent-callable read tool that fetches only that comment or the comments after it.
Contract Ledger Matrix
manage_discussion_commentreturn payloadDiscussionService.manageDiscussionComment()commentId+ URL + timestamp. No new implementation required for this row.updatedAt, notcreatedAt; callers should treat timestamp field according to action.GitHubWorkflow.md, OpenAPI if wording is staleget_conversationselector contractget_discussion_conversation({discussion_number, comment_id?, since_comment_id?, last_n?})or an equivalent MCP read surface. Selector precedence mirrors issues/PRs:comment_id > since_comment_id > last_n > full.comment_idreturns empty comments; unknownsince_comment_idreturns empty comments; invalid or missingdiscussion_numberreturns structured error; full fetch remains the cold-cache fallback.GitHubWorkflow.md;ideation-sandboxhandoff guidance if changedcomments.nodes; comment nodes includeid,author.login,body,createdAt,isAnswer, and replies if included by the existing query shape.ideation-sandboxworkflow + A2A commentId handoff precedent frompr-reviewcommentIdvia A2A so peers fetch only the new Discussion comment when warm-cache context exists.ideation-sandboxdocs; optional cross-reference topr-reviewwarm-vs-cold disciplineAcceptance Criteria
manage_discussion_commentreturnscommentIdand timestamp metadata. Delivered by #10841 / PR #10891; no new code required.comment_id,since_comment_id, andlast_nselectors.get_conversationbehavior.ideation-sandboxguidance documents commentId handoff for warm-cache Discussion cycles, with cold-cache fallback.Related
Origin Session ID: 0b29a8fa-c6b0-42e2-ab3b-8015a99db2d8