Loading...
Loading...
Spawn a single autonomous AI agent with a specific task, personality, and CLI backend (Claude, Gemini, OpenCode, Copilot). Agent accepts task from docs/todo/pending/, selects personality based on task type, and works autonomously with CLI tools. Integrates with docs-first workflow via task signals and progress tracking.
npx skill4agent add opendndapps/ogt-skills ogt-agent-spawndocs/todo/pending/ogt-agent-spawn \
--task "implement-user-auth" \
--personality engineer \
--backend claudeogt-agent-spawn \
--task "fuzzy-search" \
--personality engineer \
--backend gemini \
--priority high \
--estimated-hours 4 \
--context "docs/todo/pending/fuzzy-search/context.md"# Task 1: Research (Researcher on Gemini - fast)
ogt-agent-spawn --task "eval-orm-libraries" --personality researcher --backend gemini
# Task 2: Code Review (Architect on Claude - deep)
ogt-agent-spawn --task "review-auth-flow" --personality architect --backend claude
# Task 3: Implementation (Engineer on OpenCode - templates)
ogt-agent-spawn --task "implement-orm-models" --personality engineer --backend opencodeflowchart TD
A["Spawn Agent"] --> B["Load Task<br/>docs/todo/pending/{task}/"]
B --> C["Set Personality<br/>Read personality briefing"]
C --> D["Select CLI Backend<br/>Claude/Gemini/OpenCode/Copilot"]
D --> E["Create .assigned_to Signal"]
E --> F["Move to in_progress/"]
F --> G["Agent Works<br/>Updates progress.md"]
G --> H{Task Complete?}
H -->|Blocked| I["Move to blocked/<br/>Add .blocked_reason"]
H -->|Done| J["Create implementation.md"]
I --> X["Return Status"]
J --> K["Update Task<br/>Add .ready_for_review"]
K --> L["Move to review/"]
L --> X
style A fill:#fef3c7
style F fill:#dbeafe
style L fill:#e0e7ff
style I fill:#fee2e2
style X fill:#e0e7ffYou are a Software Architect personality. Your role:
1. **Think Holistically** - Consider system design, scalability, maintainability
2. **Question Assumptions** - Ask "why" before implementing
3. **Provide Rationale** - Explain design decisions
4. **Document Trade-offs** - Show alternatives considered
5. **Plan for Growth** - Consider future requirements
When reviewing code or design:
- Assess architectural fitness
- Identify risks and bottlenecks
- Suggest refactoring opportunities
- Document your reasoning
Communication: Formal, thorough, rationale-driven
Output: Design documents, architecture decisions, code review feedbackYou are an Engineer personality. Your role:
1. **Ship Working Code** - Focus on completeness and correctness
2. **Think Pragmatically** - Balance perfection with done
3. **Test as You Go** - Verify each piece works
4. **Handle Edge Cases** - Don't leave TODOs
5. **Document Implementation** - Log what you did
When implementing:
- Write passing tests first
- Complete all acceptance criteria
- Handle error cases
- Clean up before shipping
Communication: Clear, direct, action-oriented
Output: Working code, test results, implementation notesYou are a Researcher personality. Your role:
1. **Be Thorough** - Leave no stone unturned
2. **Document Findings** - Show your work
3. **Explore Alternatives** - Compare options
4. **Explain Assumptions** - Make reasoning visible
5. **Provide Context** - Help others understand
When researching:
- Compare multiple solutions
- Test assumptions
- Document pros/cons
- Provide clear conclusions
Communication: Detailed, evidence-based, exploratory
Output: Research reports, recommendations, comparative analysisYou are a Tester personality. Your role:
1. **Think Like a User** - Anticipate edge cases
2. **Verify Everything** - Don't trust "it works"
3. **Document Findings** - Log all issues clearly
4. **Test Systematically** - Cover happy and sad paths
5. **Validate Criteria** - Check every acceptance criterion
When testing:
- Read acceptance criteria first
- Test happy path, error cases, edge cases
- Verify TypeScript compilation
- Run test suites
- Document any failures
Communication: Clear, detailed, evidence-focused
Output: Test results, issue logs, verification reportsYou are an Educator personality. Your role:
1. **Explain Clearly** - Assume less knowledge
2. **Provide Examples** - Show concrete cases
3. **Anticipate Questions** - Address confusion proactively
4. **Structure Logically** - Make it easy to follow
5. **Link to Resources** - Help others learn more
When writing documentation:
- Use clear, simple language
- Provide before/after examples
- Include troubleshooting
- Add quick start sections
- Link to deeper resources
Communication: Clear, example-rich, accessible
Output: Documentation, guides, tutorials, examples| Backend | Best For | Speed | Cost | Context |
|---|---|---|---|---|
| Claude | Complex reasoning, code review, architecture | Medium | Reasonable | 200K tokens |
| Gemini | Fast generation, bulk work, research | Fast | Very cheap | 1M tokens |
| OpenCode | Template-based generation, rapid prototyping | Very fast | Low | Unlimited |
| Copilot | Repository-aware work, git integration | Fast | Reasonable | Repo-aware |
# Load from docs/todo/pending/{task_slug}/task.md
cat docs/todo/pending/fuzzy-search/task.md# Task: {Title}
## Summary
{What needs doing}
## Objectives
- Objective 1
- Objective 2
## Acceptance Criteria
- [ ] Criterion 1
- [ ] Criterion 2| Signal | When | Action |
|---|---|---|
| On spawn | Touch to claim task |
| On start | Write ISO timestamp |
| If blocked | Create .blocked signal |
| If blocked | Write reason content |
| When done | Create empty signal |
| If code PR | Write PR URL |
progress.md# Progress: {Task Name}
## Session 1: Initial Setup
- Started at 2026-02-06T20:15:00Z
- Completed objective 1: xyz
- Found blocking issue: abc
## Blocking Issue
Blocked on {reason}
Depends on: docs/todo/pending/{other-task}
## Current Status
Working on: objective 2
Time spent: 1.5 hoursogt-agent-spawn \
--task "implement-fuzzy-search" \
--personality engineer \
--backend geminidocs/todo/pending/implement-fuzzy-search/.assigned_to_geminiprogress.md.blocked_reason.ready_for_reviewreview/ogt-agent-spawn \
--task "review-auth-flow" \
--personality architect \
--backend claudedocs/todo/pending/review-auth-flow/done/ogt-agent-spawn \
--task "write-api-docs" \
--personality educator \
--backend geminidocs/todo/pending/write-api-docs/done/{
"task": "implement-fuzzy-search",
"personality": "engineer",
"backend": "gemini",
"status": "done",
"started_at": "2026-02-06T20:15:00Z",
"completed_at": "2026-02-06T21:30:00Z",
"time_spent_hours": 1.25,
"acceptance_criteria_met": ["criterion1", "criterion2"],
"blocked_by": null,
"implementation": {
"files_created": ["src/SearchService.ts"],
"files_modified": ["src/services/index.ts"],
"pr_link": "https://github.com/org/repo/pull/123"
},
"notes": "Completed all criteria. Tests passing. Ready for review."
}--priorityprogress.md.blockedreview/# Check progress file
cat docs/todo/in_progress/{task}/progress.md
# Check blocking reason
cat docs/todo/in_progress/{task}/.blocked_reason
# Re-spawn after resolving
ogt-agent-spawn --task {task_name} --backend {same-backend}# Verify task structure
ls docs/todo/pending/{task}/
# Should have: task.md, context.md, .priority, .version
# Check for .assigned_to signals blocking it
ls -la docs/todo/in_progress/{task}/# Increase timeout
ogt-agent-spawn --task {task} --timeout 600
# Switch backends if one is slow
ogt-agent-spawn --task {task} --backend gemini # faster