feat: add GitHub Copilot support to Ralph agent#80
Open
Jeff-Tian wants to merge 4 commits intosnarktank:mainfrom
Open
feat: add GitHub Copilot support to Ralph agent#80Jeff-Tian wants to merge 4 commits intosnarktank:mainfrom
Jeff-Tian wants to merge 4 commits intosnarktank:mainfrom
Conversation
Greptile OverviewGreptile SummaryThis PR adds GitHub Copilot as a third supported “AI coding tool” alongside Amp and Claude Code. Changes include documentation updates (README.md, AGENTS.md) to describe installing/using Copilot and a new Main concern: the Copilot execution path in Confidence Score: 2/5
Important Files Changed
Sequence DiagramsequenceDiagram
participant User
participant Ralph as ralph.sh
participant Prompt as prompt.md/COPILOT.md
participant Amp
participant Claude
participant CopilotCLI as Copilot CLI
User->>Ralph: ./ralph.sh --tool {amp|claude|copilot} [max_iterations]
Ralph->>Ralph: Parse args, validate tool
loop Iterations 1..MAX
alt TOOL=amp
Ralph->>Prompt: Read prompt.md
Ralph->>Amp: amp --dangerously-allow-all
Amp-->>Ralph: stdout/stderr
else TOOL=claude
Ralph->>Prompt: Read CLAUDE.md
Ralph->>Claude: claude --dangerously-skip-permissions --print
Claude-->>Ralph: stdout/stderr
else TOOL=copilot
Ralph->>Prompt: Read prompt.md (current implementation)
Ralph->>CopilotCLI: copilot -i "PROMPT_CONTENT" --yolo --no-ask-user
CopilotCLI-->>Ralph: stdout/stderr
end
Ralph->>Ralph: If output contains <promise>COMPLETE</promise> then exit 0
end
Ralph-->>User: Exit 1 if max iterations reached
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Thanks for the great repo! 👍 I’ve made some changes and successfully used it. Hope the change can also benefit others.
—
This pull request adds support for GitHub Copilot as a third AI coding tool in the Ralph agent workflow, alongside Amp and Claude Code. The changes update documentation, scripts, and instructions to reflect Copilot integration, and introduce a new prompt template specifically for Copilot. The most important changes are grouped below:
Copilot Integration:
copilottool in theralph.shscript, allowing users to run Ralph iterations using GitHub Copilot by specifying--tool copilot. The script now validates the new option and handles Copilot-specific prompt formatting. [1] [2] [3]COPILOT.mdfile containing detailed instructions and prompt template for Copilot-driven iterations, mirroring the structure of existing Amp and Claude Code prompts.Documentation Updates:
README.mdandAGENTS.mdto reference GitHub Copilot throughout, including installation instructions, usage examples, and file explanations. This ensures users know how to set up and run Ralph with Copilot. [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11]These changes make Ralph more flexible by supporting a wider range of AI coding tools and providing clear instructions for using Copilot in autonomous agent workflows.