ResearchClaw is an autonomous research pipeline that takes a research topic and produces a complete academic paper through 23 automated stages. This file defines how AI agents should bootstrap and interact with the system.
You are an AI research assistant operating ResearchClaw. Your job is to:
- Understand the user's research interest — clarify the topic, scope, and constraints
- Configure the pipeline — set up
config.yamlwith appropriate LLM settings and experiment mode - Execute the pipeline — run the 23-stage pipeline via CLI or Python API
- Monitor and intervene — handle gate stages (5, 9, 20), review intermediate outputs
- Deliver results — present the final paper, charts, and experiment data to the user
# Install
pip install -e .
# Configure (copy and edit)
cp config.researchclaw.example.yaml config.yaml
# Set llm.base_url, llm.api_key, experiment.mode
# Run
researchclaw run --topic "Your topic" --auto-approve| Phase | Stages | Description |
|---|---|---|
| A: Research Scoping | 1-2 | Define topic, decompose into sub-problems |
| B: Literature Discovery | 3-6 | Search strategy, collect papers, screen [GATE@5], extract knowledge |
| C: Knowledge Synthesis | 7-8 | Cluster topics, generate hypotheses |
| D: Experiment Design | 9-11 | Design experiments [GATE@9], generate code, plan resources |
| E: Experiment Execution | 12-13 | Run experiments, iterative refinement |
| F: Analysis & Decision | 14-15 | Analyze results, decide proceed/pivot/iterate |
| G: Paper Writing | 16-19 | Outline, draft, peer review, revision |
| H: Finalization | 20-23 | Quality gate [GATE@20], archive, export with charts, citation verification |
Three stages require approval (use --auto-approve for fully autonomous mode):
- Stage 5 (Literature Screen): Validates collected literature quality
- Stage 9 (Experiment Design): Validates experiment protocol before code generation
- Stage 20 (Quality Gate): Validates overall paper quality before export
simulated: LLM generates synthetic results (fast, no code execution)sandbox: Execute generated code locally (requires Python environment)ssh_remote: Execute on remote GPU server (requires SSH configuration)
| File | Purpose |
|---|---|
config.yaml |
Pipeline configuration (LLM, experiment mode, etc.) |
config.researchclaw.example.yaml |
Configuration template |
researchclaw/cli.py |
CLI entry point |
researchclaw/pipeline/executor.py |
Stage execution logic |
researchclaw/pipeline/runner.py |
Pipeline orchestration |
researchclaw/experiment/validator.py |
Code validation (AST, security, imports) |
researchclaw/experiment/visualize.py |
Chart generation |
| Situation | Action |
|---|---|
| User provides a clear topic | Run full pipeline with --auto-approve |
| User wants to review stages | Run without --auto-approve, pause at gates |
| Pipeline fails at a stage | Check error, fix config or retry from that stage with --from-stage |
| User wants iteration | Use execute_iterative_pipeline() with max_iterations |
| Experiment code fails | Validator auto-retries up to 3 times; if still failing, switch to simulated mode |
ResearchClaw works with:
- Claude Code: Load via
.claude/skills/researchclaw/SKILL.md - OpenClaw: Read this
AGENTS.md+README.mdfor bootstrapping - OpenCode: Compatible skill format in
.claude/skills/ - Standalone: Direct CLI or Python API usage