Autonomy Planning Agent is an intelligent GitHub planning system that enables human-AI collaboration through a structured Generate-Verify loop. This guide will help you get started with Autonomy and use it effectively in your development workflow.
- Python 3.8 or newer
- GitHub account with repository access
- (Optional) Slack workspace for notifications
# Install via pip
pip install autonomy
# Or install with development dependencies
pip install autonomy[dev]# Check if autonomy is installed
autonomy --version
# Test the CLI
autonomy --help# Authenticate with GitHub
autonomy auth login
# Or use a personal access token
export GITHUB_TOKEN="your_token_here"# Initialize Autonomy for your repository
autonomy init --repo your-org/your-repo
# This will:
# - Set up GitHub Projects v2 board
# - Create necessary fields (Priority, Pinned, Sprint, Track)
# - Configure workflow settings# Get your next task
autonomy next
# Update a task status
autonomy update 123 --done --notes "Completed feature X"
# Check project status
autonomy status# GitHub authentication
export GITHUB_TOKEN="your_github_token"
# Slack integration (optional)
export SLACK_BOT_TOKEN="your_slack_bot_token"
export SLACK_SIGNING_SECRET="your_slack_signing_secret"
# Autonomy configuration
export AUTONOMY_LOG_LEVEL="INFO"
export AUTONOMY_WORKSPACE_PATH="/path/to/your/project"Create autonomy.json in your project root:
{
"github": {
"owner": "your-org",
"repo": "your-repo",
"token": "your_token"
},
"workflow": {
"autonomy_level": "supervised",
"max_file_lines": 300,
"max_function_lines": 40,
"test_coverage_target": 0.75
},
"slack": {
"enabled": true,
"channel": "#autonomy-daily"
}
}# Get next priority task
autonomy next
# Get next task for specific assignee
autonomy next --me
# List all tasks
autonomy list
# Update task status
autonomy update 123 --done --notes "Completed implementation"
# Pin/unpin tasks
autonomy pin 123
autonomy unpin 123# Initialize GitHub Projects board
autonomy board init
# Rank items by priority
autonomy board rank
# Reorder items
autonomy board reorder# Sync issue hierarchy with GitHub Tasklists
autonomy hierarchy-sync --verbose# Run backlog doctor to clean up issues
autonomy doctor run
# Schedule nightly backlog maintenance
autonomy doctor nightlyDaily metrics include weekly active users (WAU), approval rates, time-to-task statistics and other workflow insights.
# View daily metrics
autonomy metrics daily
# Monitor weekly active users and approval rate
autonomy metrics daily --repos owner/repo
# Export metrics
autonomy metrics export --format json
# View audit log
autonomy audit logAutonomy uses specialized AI agents for different phases:
- PM Agent: Requirements analysis and planning
- SDE Agent: Implementation and development
- QA Agent: Testing and quality assurance
# Process issue through PM phase
autonomy process 123 --phase pm
# Process issue through full workflow
autonomy process 123 --phase all# Install Slack app
autonomy auth slack install
# Test Slack integration
autonomy slack test
# Send notification
autonomy slack notify --message "Daily digest ready"# View memory entries
autonomy memory list
# Learn from override
autonomy memory learn --issue 123 --reason "Priority changed"
# Export memory
autonomy memory exportUseful templates are provided in the examples/ directory:
agent.yml— sample planning agent configurationboard_cache.json— cached board field IDs
Copy these files and adapt them to match your repository.
# Check token scopes
autonomy auth scopes
# Re-authenticate
autonomy auth login --force# Reinitialize board
autonomy board init --force
# Check board status
autonomy board status# Run a dry-run sync to identify problems
autonomy hierarchy-sync --dry-run
# Force sync if items are out of order
autonomy hierarchy-sync --force# Check performance metrics
autonomy metrics performance
# Clear cache
autonomy cache clear# Undo the last operation
autonomy undo --last
# Undo specific hash with custom window
autonomy undo abcd1234 --commit-window 3
# Create a shadow PR for recent changes
autonomy audit shadow-pr --limit 3# Enable debug logging
export AUTONOMY_LOG_LEVEL="DEBUG"
autonomy next --debug# View all commands
autonomy --help
# Get help for specific command
autonomy next --help
# Check version and dependencies
autonomy version- Use meaningful issue titles that clearly describe the task
- Add detailed descriptions with acceptance criteria
- Use labels consistently for categorization
- Set appropriate priorities (P0-P3)
- Start with supervised mode until you're comfortable
- Review AI agent outputs before accepting
- Use pin/unpin for important tasks that shouldn't be reordered
- Regularly run backlog doctor to maintain hygiene
- Communicate workflow changes to team members
- Use Slack notifications for transparency
- Review metrics regularly to optimize workflow
- Provide feedback to improve AI agent performance
- Documentation: GitHub README
- Issues: GitHub Issues
- Discussions: GitHub Discussions
For more advanced usage and development information, see the Technical Documentation.