Install
openclaw skills install open-source-contributorAutonomous GitHub contribution agent using the Architect-Builder pattern. Buck (main agent) handles all git/network I/O; subagents handle focused cognitive work only. Scouts issues, implements fixes, and submits PRs. Supports three difficulty levels. Triggers on: open source, github, contribution, PR, pull request, issue fix, OSS, contributor.
openclaw skills install open-source-contributorAutonomous GitHub contribution agent using the Architect-Builder pattern. The main agent handles all git operations and I/O; subagents handle only focused cognitive work.
Store your GitHub token securely (e.g., ~/.openclaw/.github_token). Never log or print token values. The agent should read it silently from disk.
Maintain a list of repos you've already contributed to (to avoid duplicate PRs). Store in your config file.
THE CORE RULE: Subagents do NOT clone repos, push code, or make GitHub API calls. The main agent does all I/O.
Subagents timed out when trying to do full git workflows (clone large repos + modify files + push + create PR). Root causes:
The fix: The main agent owns all I/O and git operations. Subagents only do focused cognitive work on pre-staged content.
┌─────────────────────────────────────────────────────┐
│ MAIN AGENT — The Architect & Builder │
│ │
│ 1. Research: Find issues via GitHub API │
│ 2. Stage: Clone repo, identify files, read context │
│ 3. Delegate: Send focused edit task to subagent │
│ 4. Apply: Review subagent output, apply changes │
│ 5. Push: Commit, push, create PR via GitHub API │
│ │
│ Uses: exec, GitHub API, git CLI — all I/O tools │
└─────────────────────────────────────────────────────┘
│
│ Focused task + file contents (pasted inline)
▼
┌─────────────────────────────────────────────────────┐
│ SUBAGENT — The Specialist │
│ │
│ Receives: Specific files + the issue + instructions │
│ Returns: Exact code changes (diff/patch/new content)│
│ Does NOT: Clone repos, push code, create PRs │
│ Does NOT: Make GitHub API calls │
│ Does NOT: Browse the web │
│ │
│ Timeout: 600s max (focused work only) │
└─────────────────────────────────────────────────────┘
| Criteria | Requirement |
|---|---|
| Labels | good first issue, help wanted, bug |
| Stars | 500+ |
| Issue age | 3-30 days |
| Comments | < 10 |
| Scope | Single file, < 30 lines changed |
Typical fixes: UI text corrections, missing error handling, simple config fixes, accessibility improvements, missing validation.
| Criteria | Requirement |
|---|---|
| Labels | bug, feature, performance, enhancement |
| Stars | 1,000+ |
| Issue age | 7-60 days |
| Comments | < 5 |
| Scope | Multi-file, 30-150 lines changed |
Typical fixes: Dependency bumps with tests, missing API parameters, edge case fixes, missing method implementations, performance improvements.
| Criteria | Requirement |
|---|---|
| Labels | bug, feature, performance, enhancement, design |
| Stars | 2,000+ |
| Issue age | 7-90 days |
| Comments | < 8 |
| Scope | Multi-module, 100-500+ lines changed |
Typical fixes: Race conditions, memory leaks, API redesigns, query optimization, plugin systems, cross-platform fixes.
Optional: Spawn a Council of LLMs to evaluate approach before implementing.
The main agent searches GitHub for suitable issues:
The main agent does ALL the I/O work directly (no subagent):
git clone --depth 1fix/<issue-number>-<short-description>CONTRIBUTING.md and relevant source filesSpawn a specialist subagent with:
runTimeoutSeconds: 600 (10 min max — focused work only)lightContext: trueThe subagent task MUST include:
The subagent does NOT:
The main agent takes the subagent's output and:
For Level 3 fixes that are security-sensitive or architecturally complex, spawn a Council of LLMs BEFORE Phase 3. Use 3 different models as Strategos, Analyticos, and Creativos with distinct analytical perspectives. If consensus is "don't implement" → skip, move to next candidate.
For simple fixes (Level 1, some Level 2), skip cloning entirely and use the GitHub API directly:
GET /repos/{owner}/{repo}/contents/{path}PUT /repos/{owner}/{repo}/contents/{path}POST /repos/{owner}/{repo}/pullsThis eliminates clone time entirely and completes in 2-5 minutes.
Use API-first when:
Use clone when:
Store your settings in a config file (e.g., contrib-scout/config.json):
{
"difficulty_level": 2,
"github_token_path": "~/.openclaw/.github_token",
"max_contributions_per_night": 1,
"languages": ["python", "javascript", "typescript", "go", "rust"],
"excluded_repos": ["your-org/your-repo"]
}
For Level 3 Council review, configure your preferred models in ~/.openclaw/council-config.json:
{
"council_models": [
"your-first-model-here",
"your-second-model-here",
"your-third-model-here"
],
"default_timeout": 900,
"max_tokens": 8192
}
Example (using Ollama cloud models):
{
"council_models": [
"ollama/kimi-k2.6:cloud",
"ollama/deepseek-v4-pro:cloud",
"ollama/gemma4:31b-cloud"
]
}
Choose models with different strengths — one strategic, one analytical, one creative. The more diverse, the better the council output.
runTimeoutSeconds above 600 for subagents — if they need more, the task is too broadlightContext: true on all subagent spawns| Symptom | Cause | Fix |
|---|---|---|
| Subagent times out | Task too broad (clone + edit + push) | Use Architect-Builder pattern: main agent does I/O |
| Shallow code changes | Vague subagent prompt | Paste full file contents + specific instructions |
| Lint failures after subagent edit | Subagent didn't know lint rules | Include lint config in the prompt or run lint before subagent |
| PR rejected by maintainer | Low-quality contribution | Follow CONTRIBUTING.md, write meaningful fixes only |
| Context overflow in subagent | Too much data pasted inline | Summarize to <1500 words, paste only relevant files |
contrib-scout/
├── repos/ # Cloned repositories (cleaned up after each run)
├── logs/ # Activity + audit trail (JSONL)
├── config.json # Difficulty level + settings
└── nightly-report.json # Daily summary