From 7a2eae67116f6190725e3838fb8b5a97d5c7200f Mon Sep 17 00:00:00 2001 From: 0xGosu <0xGosu@gmail.com> Date: Sat, 16 Aug 2025 16:33:56 +0800 Subject: [PATCH] Change role from "system" to "user" in prompt messages for `AssignCodingAgentPrompt` and `IssueToFixWorkflowPrompt`. Role "system" is not allowed by Claude Code in MCP provided prompt (allowed only role "user" and "assistant") --- pkg/github/issues.go | 2 +- pkg/github/workflow_prompts.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/github/issues.go b/pkg/github/issues.go index 80fe22f9d..89375ae90 100644 --- a/pkg/github/issues.go +++ b/pkg/github/issues.go @@ -1552,7 +1552,7 @@ func AssignCodingAgentPrompt(t translations.TranslationHelperFunc) (tool mcp.Pro messages := []mcp.PromptMessage{ { - Role: "system", + Role: "user", Content: mcp.NewTextContent("You are a personal assistant for GitHub the Copilot GitHub Coding Agent. Your task is to help the user assign tasks to the Coding Agent based on their open GitHub issues. You can use `assign_copilot_to_issue` tool to assign the Coding Agent to issues that are suitable for autonomous work, and `search_issues` tool to find issues that match the user's criteria. You can also use `list_issues` to get a list of issues in the repository."), }, { diff --git a/pkg/github/workflow_prompts.go b/pkg/github/workflow_prompts.go index 8a9545a42..42b6d51c8 100644 --- a/pkg/github/workflow_prompts.go +++ b/pkg/github/workflow_prompts.go @@ -37,7 +37,7 @@ func IssueToFixWorkflowPrompt(t translations.TranslationHelperFunc) (tool mcp.Pr messages := []mcp.PromptMessage{ { - Role: "system", + Role: "user", Content: mcp.NewTextContent("You are a development workflow assistant helping to create GitHub issues and generate corresponding pull requests to fix them. You should: 1) Create a well-structured issue with clear problem description, 2) Assign it to Copilot coding agent to generate a solution, and 3) Monitor the PR creation process."), }, {
Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.
Alternative Proxies: