Research Topic
You are the engineering-manager. Investigate a topic and produce a reusable reference document that agents can consult during future work.
When to Use
- •An agent encounters an unfamiliar API, framework, or pattern
- •A skill needs companion documentation that doesn't exist yet
- •The team needs a decision-support reference (comparison, lookup table, runbook)
- •A recurring question keeps coming up across sessions
Step 1: Scope the Research
- •Parse
$ARGUMENTSto identify the topic - •Determine the research type:
- •API/SDK reference — document endpoints, methods, configuration
- •Pattern library — collect examples of a coding pattern
- •Decision guide — compare options with trade-offs
- •Troubleshooting runbook — symptoms, causes, fixes
- •Integration guide — how to connect two systems
- •Check if a reference already exists:
bash
find .claude/skills/ -name "*reference*" -o -name "*$TOPIC*" 2>/dev/null
- •If existing reference found → offer to update it instead of creating a new one
Step 2: Gather Information
Use multiple sources, prioritizing reliability:
- •Codebase exploration — Grep/Glob for existing usage patterns
- •Official documentation — WebFetch from official docs sites
- •Web search — WebSearch for recent articles, guides, Stack Overflow answers
- •Existing skills — Read related skills for established patterns
For each source consulted, record:
- •URL or file path
- •Key finding (1-2 sentences)
- •Reliability assessment (official docs > blog posts > forum answers)
Step 3: Write the Reference Document
Use the template structure from .claude/skills/_templates/reference.md.template.
Create the file at .claude/skills/<skill-name>/reference.md if it supports an existing skill, or .claude/skills/<topic>/reference.md for standalone references.
The reference must include:
- •Overview — what this reference covers, which skills/agents use it
- •Core content — organized into logical sections with tables and code blocks
- •Quick Reference — condensed lookup table for fast agent access
- •Troubleshooting — common issues and fixes (if applicable)
- •Sources — URLs and file paths consulted during research
Quality Criteria
- •Each section is self-contained (agents can read one section without the whole doc)
- •Tables preferred over prose for structured data
- •Code examples are copy-pasteable
- •No speculation — only documented, verified information
- •Dated so agents know when to re-research
Step 4: Register the Reference
- •If the reference supports an existing skill, add it to that skill's directory
- •If it's a standalone reference, link it from the relevant agent definition(s):
- •Read the agent
.mdfile - •Add to the agent's reference/context section
- •Read the agent
- •Commit the reference:
bash
git add .claude/skills/<path>/reference.md git commit --no-gpg-sign -m "research: Add <topic> reference document"
Step 5: Summary
code
Research complete: <topic> - Reference: .claude/skills/<path>/reference.md - Sections: N - Sources: N consulted - Used by: <skill or agent list>
Inputs
| Parameter | Required | Type | Description |
|---|---|---|---|
$ARGUMENTS | Yes | string | Topic or question to research |
Outputs
| Output | Type | Description |
|---|---|---|
| Reference doc | .md file | Structured reference at .claude/skills/<path>/reference.md |
| Git commit | commit | Reference committed to current branch |
Error Handling
| Error | Action |
|---|---|
| Topic too broad | Ask user to narrow scope |
| No reliable sources found | Report findings gap, suggest manual research |
| Existing reference covers topic | Offer to update instead of duplicate |