Researcher v2.0 (USACF Research Generator)
Voice-to-research engineering for Claude Code. Transform rough questions into executable USACF swarm configurations.
Changelog
| Version |
Changes |
| v2.0 |
Full USACF integration: algorithm selection, claude-flow commands, adversarial review, fact-checking, memory namespaces |
| v1.0 |
Initial version based on Reprompter v4.1 |
Purpose
Turn your rough research questions into complete, executable multi-agent research prompts using the USACF framework.
The Problem:
- Research questions are often vague and unstructured
- Manual setup of research swarms is tedious
- Missing adversarial review leads to blind spots
- No systematic algorithm selection
The Solution:
Smart interview → USACF super-prompt with all phases, agents, and commands.
Process (4 steps)
Step 1: Receive raw input
Accept the user's rough research question (dictated, typed messily, or incomplete).
Trigger words: research, investigate, deep dive, analyze, research this
Step 2: Complexity detection
Auto-detect complexity to select algorithm:
- Simple (< 20 words, single topic) → CoT, 1-3 agents
- Medium (branching, comparison) → ToT, 4-8 agents
- Complex (comprehensive, multi-domain) → GoT, 9-15 agents
Step 3: Smart interview (gather user input)
Gather:
- Research Title - Name for this research
- Subject - What we're researching
- Subject Type - Product / Software / Business / Process / Organization
- Research Type - Competitive / Gap / Technical / Due Diligence / Market
- Objectives - What to find out (1-20, one per line)
- Constraints - Focus areas, limitations (optional)
- Depth - CoT / ToT / GoT
- Output - Brief / Full Report / Action Plan / Raw
Step 4: Generate USACF super-prompt + score
Generate complete executable configuration with:
- Initialization commands
- All phase agents (Discovery, Analysis, Adversarial, Synthesis)
- Memory operations
- Final report generator
- Quality score comparison
CRITICAL: MUST GENERATE COMPLETE SUPER-PROMPT
After interview completes, you MUST immediately:
- Select algorithm (CoT/ToT/GoT) based on complexity
- Generate full USACF super-prompt with ALL phases
- Include claude-flow commands for every operation
- Add adversarial review agents (red-team, fact-checker)
- Show quality score (before/after comparison)
- Offer to execute or copy
WRONG: Generate simple prompt without agents
RIGHT: Generate full USACF config with all phases, agents, memory ops
Algorithm selection matrix
| Complexity |
Algorithm |
Topology |
Agents |
When to Use |
| Simple |
Chain-of-Thought (CoT) |
Star |
1-3 |
"What is X?" Single topic |
| Medium |
Tree-of-Thought (ToT) |
Hierarchical |
4-8 |
"Compare X vs Y" Branching |
| Complex |
Graph-of-Thought (GoT) |
Mesh/Hive |
9-15+ |
"Comprehensive analysis" |
Complexity Indicators:
- Simple: Single topic, factual question, < 20 words
- Medium: "compare", "vs", "evaluate", "options"
- Complex: "comprehensive", "gaps and opportunities", multiple domains
USACF phases (all required for complex research)
Phase 0: Initialization
npx claude-flow@alpha init --force
npx claude-flow@alpha swarm init --topology {topology} --max-agents {N}
npx claude-flow@alpha memory store "session/config" '{...}' --namespace search
Phase 0.5: Meta-analysis
- Step-back prompting (principles, criteria)
- Self-ask decomposition (15-20 questions)
- Research planning (ReWOO)
Phase 1: Discovery (Parallel)
- component-identifier
- hierarchy-analyzer
- interface-mapper
- flow-tracer
Phase 2: Analysis (Parallel)
- 6 gap hunters (quality, performance, security, structural, capability, UX)
- 4 risk analysts (FMEA, edge cases, vulnerabilities, reliability)
Phase 2.5: Adversarial review (critical)
- red-team-reviewer: Challenge ALL findings
- fact-checker: RAG verification with web_search
- coordinator: Integrate feedback, update confidence
Phase 3: Synthesis (Parallel)
- quick-win-generator (0-3 months)
- strategic-generator (3-12 months)
- transformational-generator (12-36 months)
- pareto-optimizer (multi-objective portfolios)
Phase 4: Final report
- Ultra-brief (3 sentences)
- Executive summary
- Top 10 findings with confidence
- Recommended actions by horizon
- Limitations & uncertainties
Memory namespace convention
All agents store to namespaced memory:
# Session
session/config # Research configuration
# Meta
meta/principles # Core principles
meta/questions # Decomposed questions
meta/research-plan # Planned tasks
# Discovery
discovery/components # Identified components
discovery/hierarchy # Structural map
discovery/interfaces # APIs/contracts
discovery/flows # Data/control flows
# Gaps
gaps/quality # Quality gaps
gaps/performance # Performance gaps
gaps/security # Security gaps
# Risks
risks/fmea # Failure mode analysis
risks/edge-cases # Edge cases
risks/vulnerabilities # Security vulnerabilities
# Adversarial
adversarial/critiques # Red team challenges
adversarial/fact-check # Verified claims
# Opportunities
opportunities/quick-wins # 0-3 month wins
opportunities/strategic # 3-12 month plays
opportunities/transformational # 12-36 month bets
opportunities/pareto-recommendation # Optimal portfolio
# Output
output/final-report # Comprehensive report
Quality scoring
Always show before/after metrics:
| Dimension |
Before |
After |
Change |
| Clarity |
X/10 |
X/10 |
+X% |
| Algorithm Selection |
0/10 |
10/10 |
+∞ |
| Agent Design |
0/10 |
9/10 |
+∞ |
| Memory Ops |
0/10 |
10/10 |
+∞ |
| Adversarial |
0/10 |
9/10 |
+∞ |
| Fact Checking |
0/10 |
8/10 |
+∞ |
| Overall |
X/10 |
9+/10 |
+2000%+ |
Example
Before (rough input):
"look into what solana is doing with AI and how we compare"
After (USACF super-prompt):
# USACF Research: Solana AI Competitive Analysis
## Configuration
- Algorithm: ToT (medium complexity - comparison)
- Topology: Hierarchical
- Agents: 8
- Output: Executive Brief
## Phase 0: Initialization
[claude-flow init commands]
## Phase 1: Discovery
[4 parallel agents with memory stores]
## Phase 2: Analysis
[Gap hunters + risk analysts]
## Phase 2.5: Adversarial
[Red team + fact checker]
## Phase 3: Synthesis
[Opportunity generators + pareto optimizer]
## Phase 4: Report
[Final report generator]
Quality: 1.2/10 → 9.3/10 (+675%)
Tips for best results
- Be specific about competitors - Name them in the input
- Mention constraints early - "focus on Q1", "executive-level"
- State objectives - Even rough ones help
- Say "expand" - For full interview on simple queries
- Say "quick" - To skip interview for simple research
Comparison: Reprompter vs Researcher
| Aspect |
Reprompter |
Researcher |
| Trigger |
"reprompt" |
"research" / "researcher" |
| Purpose |
General prompts |
Research prompts |
| Output |
Structured prompt |
USACF swarm config |
| Agents |
None |
8-15 parallel agents |
| Memory |
No |
Full namespace system |
| Adversarial |
No |
Red team + fact checker |
| Algorithm |
No |
CoT/ToT/GoT selection |
1---2name: research-reprompter3description: Transform rough research questions into executable USACF research prompts. Use when user says "research", "research this", "investigate", "deep dive", "researcher", or pastes a research topic. Generates complete multi-agent swarm configuration with algorithm selection, claude-flow commands, and adversarial review.4---56# Researcher v2.0 (USACF Research Generator)78> **Voice-to-research engineering for Claude Code. Transform rough questions into executable USACF swarm configurations.**910## Changelog1112| Version | Changes |13|---------|---------|14| **v2.0** | Full USACF integration: algorithm selection, claude-flow commands, adversarial review, fact-checking, memory namespaces |15| v1.0 | Initial version based on Reprompter v4.1 |1617## Purpose1819Turn your rough research questions into complete, executable multi-agent research prompts using the USACF framework.2021**The Problem:**22- Research questions are often vague and unstructured23- Manual setup of research swarms is tedious24- Missing adversarial review leads to blind spots25- No systematic algorithm selection2627**The Solution:**28Smart interview → USACF super-prompt with all phases, agents, and commands.2930---3132## Process (4 steps)3334### Step 1: Receive raw input35Accept the user's rough research question (dictated, typed messily, or incomplete).3637**Trigger words:** `research`, `investigate`, `deep dive`, `analyze`, `research this`3839### Step 2: Complexity detection40**Auto-detect complexity to select algorithm:**41- Simple (< 20 words, single topic) → CoT, 1-3 agents42- Medium (branching, comparison) → ToT, 4-8 agents43- Complex (comprehensive, multi-domain) → GoT, 9-15 agents4445### Step 3: Smart interview (gather user input)46Gather:471. **Research Title** - Name for this research482. **Subject** - What we're researching493. **Subject Type** - Product / Software / Business / Process / Organization504. **Research Type** - Competitive / Gap / Technical / Due Diligence / Market515. **Objectives** - What to find out (1-20, one per line)526. **Constraints** - Focus areas, limitations (optional)537. **Depth** - CoT / ToT / GoT548. **Output** - Brief / Full Report / Action Plan / Raw5556### Step 4: Generate USACF super-prompt + score57Generate complete executable configuration with:58- Initialization commands59- All phase agents (Discovery, Analysis, Adversarial, Synthesis)60- Memory operations61- Final report generator62- Quality score comparison6364---6566## CRITICAL: MUST GENERATE COMPLETE SUPER-PROMPT6768**After interview completes, you MUST immediately:**69701. **Select algorithm** (CoT/ToT/GoT) based on complexity712. **Generate full USACF super-prompt** with ALL phases723. **Include claude-flow commands** for every operation734. **Add adversarial review agents** (red-team, fact-checker)745. **Show quality score** (before/after comparison)756. **Offer to execute or copy**7677```text78WRONG: Generate simple prompt without agents79RIGHT: Generate full USACF config with all phases, agents, memory ops80```8182---8384## Algorithm selection matrix8586| Complexity | Algorithm | Topology | Agents | When to Use |87|------------|-----------|----------|--------|-------------|88| Simple | Chain-of-Thought (CoT) | Star | 1-3 | "What is X?" Single topic |89| Medium | Tree-of-Thought (ToT) | Hierarchical | 4-8 | "Compare X vs Y" Branching |90| Complex | Graph-of-Thought (GoT) | Mesh/Hive | 9-15+ | "Comprehensive analysis" |9192**Complexity Indicators:**93- Simple: Single topic, factual question, < 20 words94- Medium: "compare", "vs", "evaluate", "options"95- Complex: "comprehensive", "gaps and opportunities", multiple domains9697---9899## USACF phases (all required for complex research)100101### Phase 0: Initialization102```bash103npx claude-flow@alpha init --force104npx claude-flow@alpha swarm init --topology {topology} --max-agents {N}105npx claude-flow@alpha memory store "session/config" '{...}' --namespace search106```107108### Phase 0.5: Meta-analysis109- Step-back prompting (principles, criteria)110- Self-ask decomposition (15-20 questions)111- Research planning (ReWOO)112113### Phase 1: Discovery (Parallel)114- component-identifier115- hierarchy-analyzer116- interface-mapper117- flow-tracer118119### Phase 2: Analysis (Parallel)120- 6 gap hunters (quality, performance, security, structural, capability, UX)121- 4 risk analysts (FMEA, edge cases, vulnerabilities, reliability)122123### Phase 2.5: Adversarial review (critical)124- **red-team-reviewer**: Challenge ALL findings125- **fact-checker**: RAG verification with web_search126- **coordinator**: Integrate feedback, update confidence127128### Phase 3: Synthesis (Parallel)129- quick-win-generator (0-3 months)130- strategic-generator (3-12 months)131- transformational-generator (12-36 months)132- pareto-optimizer (multi-objective portfolios)133134### Phase 4: Final report135- Ultra-brief (3 sentences)136- Executive summary137- Top 10 findings with confidence138- Recommended actions by horizon139- Limitations & uncertainties140141---142143## Memory namespace convention144145All agents store to namespaced memory:146147```bash148# Session149session/config # Research configuration150151# Meta152meta/principles # Core principles153meta/questions # Decomposed questions154meta/research-plan # Planned tasks155156# Discovery157discovery/components # Identified components158discovery/hierarchy # Structural map159discovery/interfaces # APIs/contracts160discovery/flows # Data/control flows161162# Gaps163gaps/quality # Quality gaps164gaps/performance # Performance gaps165gaps/security # Security gaps166167# Risks168risks/fmea # Failure mode analysis169risks/edge-cases # Edge cases170risks/vulnerabilities # Security vulnerabilities171172# Adversarial173adversarial/critiques # Red team challenges174adversarial/fact-check # Verified claims175176# Opportunities177opportunities/quick-wins # 0-3 month wins178opportunities/strategic # 3-12 month plays179opportunities/transformational # 12-36 month bets180opportunities/pareto-recommendation # Optimal portfolio181182# Output183output/final-report # Comprehensive report184```185186---187188## Quality scoring189190**Always show before/after metrics:**191192| Dimension | Before | After | Change |193|-----------|--------|-------|--------|194| Clarity | X/10 | X/10 | +X% |195| Algorithm Selection | 0/10 | 10/10 | +∞ |196| Agent Design | 0/10 | 9/10 | +∞ |197| Memory Ops | 0/10 | 10/10 | +∞ |198| Adversarial | 0/10 | 9/10 | +∞ |199| Fact Checking | 0/10 | 8/10 | +∞ |200| **Overall** | **X/10** | **9+/10** | **+2000%+** |201202---203204## Example205206**Before (rough input):**207> "look into what solana is doing with AI and how we compare"208209**After (USACF super-prompt):**210211```markdown212# USACF Research: Solana AI Competitive Analysis213214## Configuration215- Algorithm: ToT (medium complexity - comparison)216- Topology: Hierarchical217- Agents: 8218- Output: Executive Brief219220## Phase 0: Initialization221[claude-flow init commands]222223## Phase 1: Discovery224[4 parallel agents with memory stores]225226## Phase 2: Analysis227[Gap hunters + risk analysts]228229## Phase 2.5: Adversarial230[Red team + fact checker]231232## Phase 3: Synthesis233[Opportunity generators + pareto optimizer]234235## Phase 4: Report236[Final report generator]237238Quality: 1.2/10 → 9.3/10 (+675%)239```240241---242243## Tips for best results244245- **Be specific about competitors** - Name them in the input246- **Mention constraints early** - "focus on Q1", "executive-level"247- **State objectives** - Even rough ones help248- **Say "expand"** - For full interview on simple queries249- **Say "quick"** - To skip interview for simple research250251---252253## Comparison: Reprompter vs Researcher254255| Aspect | Reprompter | Researcher |256|--------|------------|------------|257| **Trigger** | "reprompt" | "research" / "researcher" |258| **Purpose** | General prompts | Research prompts |259| **Output** | Structured prompt | USACF swarm config |260| **Agents** | None | 8-15 parallel agents |261| **Memory** | No | Full namespace system |262| **Adversarial** | No | Red team + fact checker |263| **Algorithm** | No | CoT/ToT/GoT selection |