See also: Open Research Workspace — a variant of this template designed for public/open-source research (adds export commands, publishing integrations, and public-audience formatting).
A template for conducting iterative AI-assisted research using Claude Code as the execution engine.
This repository is a structured research workspace — not a traditional codebase. It uses a folder-based pattern where:
- Context folders hold background information and compacted history
- Prompt folders manage the research queue
- Output folders capture and aggregate findings
- A compaction loop feeds previous findings back as context for deeper investigation
The filesystem acts as both the workflow engine and the knowledge base. No databases, no vector stores, no complex tooling — just folders, markdown files, and Claude Code.
Click Use this template on GitHub, or fork and clone.
Edit context/from-human/research-brief.md with your research topic, scope, and any background information.
Create a prompt in prompts/run/initial/ describing what you want to investigate. See prompts/run/initial/example-initial-prompt.md for the format.
Open the repo in Claude Code and tell it to run the prompt:
Run the prompt in prompts/run/initial/
Review the output in outputs/individual/, write follow-up prompts in prompts/run/subsequent/, and keep going. When context grows large, ask Claude to compact.
├── CLAUDE.md # System instructions for Claude Code
├── context/
│ ├── from-human/ # Your background info and notes
│ ├── from-history/ # Compacted findings from prior iterations
│ └── from-internet/ # Saved web sources and references
├── prompts/
│ ├── drafting/ # Prompts under development
│ ├── queue/ # Ready to run (ordered)
│ └── run/
│ ├── initial/ # First-pass research prompts
│ └── subsequent/ # Follow-up prompts
├── outputs/
│ ├── individual/ # Per-prompt research outputs
│ ├── aggregated/
│ │ ├── markdown/ # Combined research documents
│ │ └── pdf/ # PDF exports
│ └── final/ # Polished deliverables
├── slash-commands/ # Custom Claude Code slash commands
└── notes/ # Working notes and methodology
┌─────────────┐
│ Context │◄──────────────────────┐
│ (from-human │ │
│ from-history│ │
│ from-internet) │
└──────┬──────┘ │
│ │
▼ │
┌─────────────┐ │
│ Prompt │ │
│ (queue/run) │ │
└──────┬──────┘ │
│ │
▼ │
┌─────────────┐ ┌────────────┐ │
│ Claude │─────►│ Output │ │
│ Code │ │ (individual) │
└─────────────┘ └──────┬─────┘ │
│ │
┌───────┴───────┐ │
│ Compaction │──┘
│ (summarise │
│ → history) │
└───────┬───────┘
│
▼
┌────────────┐
│ Aggregation│
│ (combined │
│ markdown/ │
│ pdf) │
└────────────┘
| Command | Purpose |
|---|---|
/run-prompt |
Execute the next prompt in the queue |
/compact |
Summarise outputs into compacted history |
/aggregate |
Combine individual outputs into a single document |
/status |
Show research progress (prompts run, outputs generated, queue length) |
- Use this repo as a GitHub template
- Replace
context/from-human/research-brief.mdwith your topic - Clear the example prompts and outputs
- Start researching
- Filesystem as workflow engine: Folder structure defines the process
- Markdown-native: Everything is plain text, version-controlled, portable
- Compaction over RAG: Summarise and feed back rather than vectorise
- Iterative deepening: Each round builds on compacted findings from the last
- No infrastructure required: Just Claude Code and a git repo
MIT
For more Claude Code projects, visit my Claude Code Projects Index.