What you’ll accomplish: Install Magpie, configure your environment, and run your first end-to-end pipeline from task to pull request.
Prerequisites
Before you begin, ensure you have the following tools installed:Rust 1.75+
Rust 1.75+
Claude CLI
Claude CLI
Required for both Tier 1 (text generation) and Tier 2 (Goose agent). See Claude Code docs for setup.After installation, verify:
Git and GitHub CLI
Git and GitHub CLI
Git is required for branch operations. The GitHub CLI (Authenticate with GitHub:
gh) handles PR creation.Install Git: git-scm.com/downloadsInstall GitHub CLI:Install Magpie
Build the project
First build takes 4-5 minutes due to Goose transitive dependencies (candle, llama-cpp, tree-sitter). Subsequent builds are much faster.
target/release/magpie-cli.Run your first task
Let’s test Magpie with a simple agent prompt before running the full pipeline.Run a single prompt
Configure for full pipeline
To run the complete pipeline (task → code → CI → PR), configure these environment variables:Create a
.env file in your working directory, and Magpie will automatically load it at startup via dotenvy::dotenv().Run the full pipeline
Now trigger an end-to-end autonomous coding task:What happens next
Task classification
Magpie analyzes your task description and classifies it:
- Simple: docs, typos, renames → single agent call
- Standard: features, refactors → TDD blueprint (plan → tests → implement)
- BugFix: bug fixes → diagnostic blueprint (investigate → regression test → fix)
Blueprint execution
The agent executes the TDD blueprint steps:You’ll see streaming output as the agent:
- Scans the repository structure
- Plans the implementation
- Writes test cases first (red phase)
- Implements the feature to pass tests (green phase)
- Runs
cargo testandcargo clippy
CI loop
After coding completes, Magpie runs your configured test and lint commands. If CI fails, the fix blueprint gives the agent the error output and attempts repairs (up to
MAGPIE_MAX_CI_ROUNDS).Enable tracing (optional)
To debug agent behavior, enable JSONL tracing:.magpie/traces/magpie-trace-YYYY-MM-DD.jsonl with detailed logs of every agent call:
Next steps
Chat adapters
Set up Discord or Teams to trigger tasks from chat messages
Blueprint engine
Learn how deterministic and agent steps combine in blueprints
Configuration
Explore all environment variables and options
Sandbox options
Run tasks in Daytona sandboxes for isolated execution
Common issues
Error: claude: command not found
Error: claude: command not found
The Claude CLI is not installed or not in your PATH. Follow the Claude Code setup guide.
Error: gh: command not found
Error: gh: command not found
Install the GitHub CLI:Then authenticate:
gh auth loginBuild fails with candle/llama-cpp errors
Build fails with candle/llama-cpp errors
Ensure you’re using Rust 1.75+ and have a C++ compiler installed:
Agent doesn't make file changes
Agent doesn't make file changes
Verify the agent has write permissions to
MAGPIE_REPO_DIR. The agent uses Goose’s file tools, which operate relative to the working directory set in the session.