| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Add `assign_copilot_to_issue_with_intent` in a new non-default toolset `copilot_issue_intents`. The tool uses GraphQL's object-form `assignees: [AssigneeUpdateInput!]` so intent metadata (rationale, confidence, is_suggestion) is attached to the Copilot entry only, while existing assignees are preserved. - Reuses the existing Copilot actor lookup, target-repository resolution, base_ref, custom_instructions, GraphQL-Features header, and direct-assignment PR polling behavior. - `is_suggestion: true` records a pending Copilot assignment intent, returns a suggestion-shaped result, and does not launch Copilot or poll for a linked PR. - `rationale` is capped at 280 characters (schema + runtime); `confidence` is validated against `LOW`/`MEDIUM`/`HIGH`. - Toolset is non-default so its inputs do not add schema bloat to the default tool surface; available via `copilot_issue_intents`, `all`, or explicit tool selection. Includes unit tests for direct assignment (with existing assignees and with base_ref/custom_instructions), the suggestion path, invalid rationale length, invalid confidence, and Copilot-not-available; a generated toolsnap; regenerated docs; and an e2e test for the suggestion path. Refs: github/plan-track-agentic-toolkit#683
There was a problem hiding this comment.
Adds an opt-in tool for assigning or suggesting Copilot on issues with intent metadata.
Changes:
| File | Description |
|---|---|
| README.md | Documents the toolset and tool. |
| pkg/github/tools.go | Registers the opt-in toolset and tool. |
| pkg/github/copilot.go | Implements intent-aware assignment behavior. |
| pkg/github/copilot_test.go | Tests schema, validation, and assignment paths. |
| pkg/github/__toolsnaps__/assign_copilot_to_issue_with_intent.snap | Captures the tool schema. |
| e2e/e2e_test.go | Tests suggested assignment end to end. |
| docs/remote-server.md | Documents remote toolset access. |
Sorry, something went wrong.
| "readOnlyHint": false, | ||
| "title": "Assign Copilot to issue with intent" | ||
| }, | ||
| "description": "Assign Copilot to a specific issue with intent metadata attached to the assignment. When is_suggestion is true, a pending Copilot assignment intent is recorded rather than launching the agent; otherwise Copilot is directly assigned and begins work.\n\nThis tool can help with the following outcomes:\n- a Pull Request created with source code changes to resolve the issue (direct assignment)\n- a pending Copilot assignment suggestion is recorded on the issue for later approval (is_suggestion=true)\n\n\nMore information can be found at:\n- https://docs.github.com/en/copilot/using-github-copilot/using-copilot-coding-agent-to-work-on-tasks/about-assigning-tasks-to-copilot\n", |
There was a problem hiding this comment.
should we trim this description a bit? it's too verbose and repeats information, imo which adds to the schema bloat
Sorry, something went wrong.
There was a problem hiding this comment.
Maybe we can have an identical description to the assign_copilot_to_issue tool, and just add to it "prefer this tool over assign_copilot_to_issue when available"?
Sorry, something went wrong.
There was a problem hiding this comment.
Done — trimmed the description to mirror assign_copilot_to_issue with an appended "Prefer this tool over assign_copilot_to_issue when available" note. Removed the verbose is_suggestion narrative from the schema in bf2defd.
Sorry, something went wrong.
There was a problem hiding this comment.
Went with exactly this — description now matches assign_copilot_to_issue plus the preference note. See bf2defd.
Sorry, something went wrong.
| Description: "If true, records a pending Copilot assignment intent rather than launching the agent. Approval later supplies the launch context; base_ref and custom_instructions are ignored in this case.", | ||
| }, | ||
| }, | ||
| Required: []string{"owner", "repo", "issue_number"}, |
There was a problem hiding this comment.
should we require the intent fields?
Sorry, something went wrong.
There was a problem hiding this comment.
Done — rationale, confidence, and is_suggestion are now required in both the schema and at runtime. Added missing-field tests. is_suggestion is always sent explicitly on the Copilot AssigneeUpdateInput entry now. See bf2defd.
Sorry, something went wrong.
Per review feedback on #2909: - Trim the tool description to mirror assign_copilot_to_issue and add "Prefer this tool over assign_copilot_to_issue when available", removing the verbose is_suggestion narrative from the schema. - Make rationale, confidence, and is_suggestion required inputs (schema and runtime). is_suggestion is now always sent explicitly on the Copilot AssigneeUpdateInput entry. - Update unit tests to supply the newly-required fields and cover the missing-rationale and missing-confidence rejection paths. - Regenerate toolsnap and README.
Per @RossTarrant review feedback on #2909: - Reject requests where `is_suggestion` is omitted from the raw args before decoding. `mapstructure.WeakDecode` defaults missing bools to false, which would silently launch Copilot instead of recording a suggestion. Presence-check the raw map so callers make the choice explicit. - Skip the copilot-swe-agent actor when copying existing assignees so we don't send its actorId twice (once without metadata and once with intent metadata) when Copilot is already assigned. - Update the stale about-assigning-tasks-to-copilot reference to the redirect target (about-cloud-agent). Applied to the const message, both tool descriptions, and the e2e/unit-test literals that assert on that message. New unit tests cover the missing-is_suggestion rejection and the copilot-dedup behavior. Regenerated toolsnaps.
There was a problem hiding this comment.
Looks good, thanks for the updates!
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Adds assign_copilot_to_issue_with_intent in a new non-default toolset copilot_issue_intents. The tool uses GraphQL's object-form assignees: [AssigneeUpdateInput!] so intent metadata (rationale, confidence, is_suggestion) is attached to the Copilot entry only, while existing assignees are preserved.
Refs: github/plan-track-agentic-toolkit#683
Design
Behavior
Toolset
New non-default copilot_issue_intents toolset — available via X-MCP-Tools/--toolsets copilot_issue_intents, all, or explicit tool selection. It is intentionally kept out of the default configuration so its inputs do not add schema bloat to the default tool surface, matching the guidance in the source issue.
Acceptance criteria
Testing