auto-research
Skill21 starsChanged 7 months agoMITView on GitHub
Improve any existing Claude Code skill, CLAUDE.md, subagent definition, slash-command, or prompt markdown file by combining web-researched best-practice rewrites with autonomous Karpathy-style binary eval loops. Use when the user wants to "auto-research", "self-improve", "auto-improve", "optimize", "modernize", or "research-improve" any existing SKILL.md, CLAUDE.md, agent file under .claude/agents/, slash-command file under .claude/commands/, or any prompt markdown file. Triggers on phrases like "use auto-research to improve skill X", "auto-improve this CLAUDE.md", "research best practices and rewrite Y", or "self-research and optimize this agent". Researches authoritative sources (Anthropic docs, anthropic.com engineering blog, anthropics/skills GitHub) in parallel sub-agents, proposes a cited rewrite, runs an autonomous binary-assertion eval loop with git commit and reset bookkeeping for testable artifacts, and asks the user to confirm only at the end with a before-and-after score and full source list.
10 other projects use a version of this.
Adopted by
Most recently taken up by
- thistleknot/skillstheir own version, first seen Nov 8, 2026
- dzhng/jevgreptheir own version, first seen Nov 7, 2026
- dzhng/skillstheir own version, first seen Nov 4, 2026
- Buddhilive/buddhi-clitheir own version, first seen Nov 1, 2026
- dzhng/yaptheir own version, first seen Oct 15, 2026
- transitive-bullshit/skillstheir own version, first seen Oct 13, 2026
Used with
Projects with it also use compare-screenshots, marketing-pages and 10 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
transitive-bullshitSkillcompare-screenshots
Compare screenshots against the intended design, distinguishing approved references from historical baselines. Use for iterative implementation matching, before/after visual review, objective image telemetry, or checking a lone capture for flat, empty, or badly framed content.
Also in 5 projects that use this
dzhngSkillmarketing-pages
Best-practice rulebook for a marketing site's pages, organized by page class — campaign landers, product pages, programmatic SEO trees, editorial. Use when writing or updating a landing/marketing page, wiring a campaign lander to an attribution identifier, changing site-wide nav/footer links, touching sitemap/robots/agent-readable surfaces, or auditing a public site's indexing, reachability, and conversion setup.
Also in 4 projects that use this
dzhngSkillclose-spec
When a spec under specs/<feature>/ is done shipping (a write-spec build, or any planned task that produced a spec), archive it to specs/done/ and rewrite it from a build-plan into a durable rationale — the why, the principles, the invariants — pointing back to the real code for the how. Use when implementation has landed and the plan no longer matches what shipped, or the user says a feature/spec is finished. Pairs with [write-spec](../write-spec/SKILL.md) (the plan this closes) and [review](../review/SKILL.md) (run before closing).
Also in 4 projects that use this
LucasMatuszewskiSkillaudit-agents
Audit and maintain agent configuration files (.claude/agents, AGENTS.md, CLAUDE.md, agent-memory). Checks for duplicates, outdated info, naming conflicts, wrong technical facts, and files over 200 lines. Fixes all issues and commits.
Also in 4 projects that use this
isLinXuSkilleval-skills
AI Agent Skill unit testing framework. A framework-agnostic toolkit for discovering, scaffolding, selecting, evaluating, and reporting on AI skills. Use this skill to assess skill quality before production, compare candidate skills on the same benchmark, enforce quality gates in CI/CD, and generate human-readable evaluation reports.
Also in 5 projects that use this
gastonsalgSkillwrite-skills
Creates effective Claude Code skills following official Anthropic guidelines and community best practices. Use when creating or refactoring skills. Focuses on WHAT not HOW, proper structure, and addressing real failure modes.
Also in 5 projects that use this
- +6 more from dzhng
Other versions10 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 10
- dzhng/jevgrep★ 3.2ksame name
- dzhng/skills★ 1.5ksame name
- huytieu/COG-second-brain★ 1.3ksame name
- dzhng/yap★ 112same name
- transitive-bullshit/skills★ 5same name
- christyjacob4/claude-tricks★ 2same name
- Buddhilive/buddhi-cli★ 1same name
- zyphr-labs/bounty-harness★ 1same name
- braincandy-parallel/tamarindos-workflow-kit★ 0same name
- thistleknot/skills★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository22 other files it gives its agents.
- 2d-pixel-assetSkill
- anthropic-skilljar-extractorSkill
- audio-to-midiSkill
- gemini-image-genSkill
- gemini-web-media-analysisSkill
- google-ai-studio-ttsSkill
- hermes-tweetSkill
- link-downloadSkill
- llama-cppSkill
- meta-muse-video-analysisSkill
- midi-synthSkill
- opencodeSkill
- seedanceSkill
- tech-product-landingSkill
- unreal-best-practicesSkill
- unreal-blueprint-codegenSkill
- unreal-gasSkill
- unreal-pcg-pythonSkill
- unreal-thirdpartySkill
- video-downloadSkill
- video-fetch-and-summarizeSkill
- video-summarizerSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
13 rules. 0 are common, 10 are distinctive, and 3 are very specific to this project.
0
Common
Most of the 10 edited versions we read keep these.
10
Distinctive
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 16
Run autonomously between steps 1 and 4.
- Distinctive: line 24
If a path is given, use it.
- Very specific: line 25
If a skill name is given, search .claude/skills/<name>/SKILL.md (project) then ~/.claude/skills/<name>/SKILL.md (user).
- Distinctive: line 26
If "this CLAUDE.md" or similar, use the most-specific one in the current working directory tree (project > user).
- Distinctive: line 57
Read references/research-strategies.md for the per-artifact-type topic checklist and source authority ranking.
- Very specific: line 67
Run WebSearch queries (current year 2026) on the topic.
- Very specific: line 93
Every substantive change must trace to at least one citation in findings.md.
- Distinctive: line 96
Do not silently invent new sections that have no evidence backing.
- Distinctive: line 122
Generic prompt MD: only line-count + heading-structure sanity.
- Distinctive: line 124
If format validation fails, fix the rewrite proposal and re-validate before continuing.
- Distinctive: line 130
Run the loop documented in references/eval-loop.md.
- Distinctive: line 142
If the artifact type is in the skip-eval set (CLAUDE.md, subagent, slash-command, generic-prompt without test inputs), the score is …
- Distinctive: line 164
Do not loop indefinitely — if the user says "iterate" three times in a row without "yes", surface that explicitly and ask whether to abort.
“Common” is measured: kept by at least 6 in 10 of the 10 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Auto-Research
Improve a target prompt artifact (SKILL.md, CLAUDE.md, subagent definition, slash-command, or generic prompt markdown) by:
- Detecting the artifact type and the rules that apply to it
- Researching current authoritative best practices in parallel — every claim cited
- Proposing a rewrite with per-change rationale and source URLs
- Validating the rewrite — for testable artifacts, an autonomous Karpathy-style binary-assertion eval loop with git commit/reset bookkeeping; for non-testable artifacts, deterministic format validation
- Confirming once at the very end with a before/after score table, the diff, and the cited sources — only the user's explicit "yes" causes the final write
Run autonomously between steps 1 and 4. Stop only at step 5.
Phase 0 — Read Inputs and Set Up Workspace
The user will name a target artifact (a path, or a phrase like "my copywriting skill" — resolve it). Resolution rules:
- If a path is given, use it.
- If a skill name is given, search
.claude/skills/<name>/SKILL.md(project) then~/.claude/skills/<name>/SKILL.md(user). - If "this CLAUDE.md" or similar, use the most-specific one in the current working directory tree (project > user).
Then:
- Read the target artifact in full.
- Classify it via references/artifact-types.md: SKILL.md / CLAUDE.md / subagent / slash-command / generic-prompt.
- Set up the workspace — a sibling directory
.auto-research/<target-name>/next to the target. If the target's parent directory is not undergit, rungit initthere so commit/reset bookkeeping works locally. (If the user's project root has its own git repo and the target lives inside it, use the existing repo — do NOT init a sub-repo.) - Capture baseline — copy the original artifact to
.auto-research/<target-name>/iteration-0/baseline.mdand record git rev (git rev-parse HEADif available, else "untracked"). - Create
iterations.tsvwith columns:iter | hypothesis | score_before | score_after | decision | git_rev | timestamp | notes.
The whole workspace structure is documented in references/eval-loop.md. Read that file when about to run the eval loop in Phase 4.
Phase 1 — Extract Research Topics
Read the artifact and produce a list of research topics — concrete questions whose answers would let you rewrite the artifact better. Each topic must be (a) likely to have an authoritative answer on the web in 2026 and (b) directly applicable to a section, claim, or convention in the target.
Examples of well-formed topics:
- "What is the current Anthropic-recommended structure for the SKILL.md
descriptionfield, and what are the current character limits?" - "What are 2026 best practices for CLAUDE.md length and content selection?"
- "What
.claude/agents/*.mdfrontmatter fields are currently supported, and how shouldtoolsbe specified?" - "What does the official skill-creator skill recommend for progressive disclosure between SKILL.md body and reference files?"
- "Which
<tool>frontmatter field has replaced<old-tool>in 2026?" (only ask this if the target uses something that may be deprecated)
Anti-patterns:
- "Is this skill good?" — too vague, not researchable
- "What does Karpathy say about autoresearch?" — not directly applicable to the target rewrite
Read references/research-strategies.md for the per-artifact-type topic checklist and source authority ranking.
Output of this phase: a research_topics list (5–12 topics) saved to .auto-research/<target-name>/research_topics.md.
Phase 2 — Parallel Research
For each topic, spawn a parallel sub-agent (general-purpose, model: sonnet) using the Agent tool. Each sub-agent must:
- Run
WebSearchqueries (current year 2026) on the topic. WebFetchthe most authoritative results — see source authority ranking in references/research-strategies.md.- Return a structured findings block:
### Topic: <topic>
**Verdict:** <1–3 sentence answer>
**Evidence:**
- Quote: "..." — <URL>
- Quote: "..." — <URL>
**Confidence:** high | medium | low
**Implications for rewrite:** <1–2 sentences>Spawn all topic agents in parallel in one message (multiple Agent tool calls in a single response). Wait for all to complete. If any returns "low confidence" or no source, mark that topic as uncertain and either drop it from the rewrite or ask one targeted clarifying research question.
Save aggregated findings to .auto-research/<target-name>/findings.md.
Phase 3 — Propose Rewrite (Draft)
Apply the findings to produce a rewritten artifact at .auto-research/<target-name>/iteration-1/proposal.md.
Rules:
- Every substantive change must trace to at least one citation in
findings.md. - Preserve any project-specific content (German prose, custom workflows, examples) unless a cited best-practice says otherwise.
- Respect format constraints from references/artifact-types.md (line caps, frontmatter rules, etc.).
- Do not silently invent new sections that have no evidence backing.
Then produce a rationale block at .auto-research/<target-name>/iteration-1/rationale.md. Format per change:
### Change: <one-line summary>
**Old:** <quoted excerpt>
**New:** <quoted excerpt>
**Why:** <1–2 sentences>
**Source:** <URL>Phase 4 — Validate / Eval Loop
Decide the validation strategy by artifact type. Look up the rules in references/artifact-types.md — the table there says, per type, whether the autonomous Karpathy eval loop is run or only format validation.
4a. Format validation (always run)
Deterministic checks before any eval loop:
- SKILL.md: frontmatter has
nameanddescription; description ≤ 1024 chars; body ≤ 500 lines; references one level deep only. - CLAUDE.md: total ≤ 200 lines (warn, not fail, if 200–250); no nested imports beyond one level; no Windows backslash paths.
- Subagent (.claude/agents/*.md): valid frontmatter (
name,description, optionaltools,model); description third-person, "use when …" pattern. - Slash-command (.claude/commands/*.md): optional frontmatter; reasonable length (< 200 lines); clear single purpose.
- Generic prompt MD: only line-count + heading-structure sanity.
If format validation fails, fix the rewrite proposal and re-validate before continuing. Do not advance with a malformed proposal.
4b. Autonomous eval loop (only for eligible types)
Eligible types per references/artifact-types.md: SKILL.md (always), generic-prompt with measurable output (if user supplied test inputs).
Run the loop documented in references/eval-loop.md. The reference file owns the full operational manual:
- How to generate
evals.jsonwith binary assertions - The autonomous instruction block ("Be aspy, do not stop, keep looping…")
- Per-iteration: hypothesise → modify → run skill on N test prompts → score → keep (git commit) or revert (git reset) → log
- Iteration cap: 10 by default, hard-stop at 15 (quality typically degrades past that — see eval-loop.md)
- The deterministic scorer is
scripts/score_evals.py
The loop runs autonomously — do not pause to ask the user inside the loop. Push notifications are fine; questions are not.
4c. Skip-eval branch
If the artifact type is in the skip-eval set (CLAUDE.md, subagent, slash-command, generic-prompt without test inputs), the score is "format-validation-only: PASS/FAIL". Do not invent eval scores.
Phase 5 — Final Confirmation Gate (the only stop)
This is the only point at which the skill stops and asks the user. Read references/confirmation-gate.md for the exact report format.
Produce a single confirmation report containing:
- Artifact — path, type, total lines before/after
- Score — eval pass-rate before/after if eval loop ran, otherwise "format-validation only"
- Iterations — table from
iterations.tsv - Sources — every URL cited in
findings.md, deduped - Diff — unified diff between baseline and final proposal (truncated to ~150 lines if huge; full diff in
.auto-research/<target-name>/final.diff)
Then ask exactly one question: "Apply these changes to <path>? (yes / no / iterate-with-feedback)".
- yes → overwrite the target file with the final proposal. The git history in the workspace already has the iteration trail; copy the final commit info into
.auto-research/<target-name>/RESULT.md. - no → leave the target untouched. The workspace stays for inspection.
- iterate-with-feedback → take the user's free-text feedback as a new constraint, return to Phase 3 with the constraint added, run another single iteration, then re-enter Phase 5.
Do not loop indefinitely — if the user says "iterate" three times in a row without "yes", surface that explicitly and ask whether to abort.
Tool & Model Guidance
- Phase 2 (research):
general-purposesub-agents, modelsonnet, run in parallel. - Phase 3 (rewrite): main agent (Opus). One serial pass — synthesis benefits from full context.
- Phase 4 (eval loop): main agent drives the loop; spawn
general-purposesonnet sub-agents to execute the target skill on each test prompt (parallelisable per prompt within an iteration). The scorer is deterministic Python. - Never allow the eval loop to modify the scoring script (
scripts/score_evals.py) orevals.json— those are the locked ground truth, equivalent to Karpathy'sprepare.py.
What This Skill Deliberately Does NOT Do
- It does not create new skills from scratch. Use the
skill-creatorskill for that. This skill is for improving existing artifacts. - It does not run Anthropic's full eval/benchmark/packaging pipeline.
skill-creatoralready does that and is composable with this skill. - It does not silently overwrite the target file. Phase 5 is mandatory.
- It does not rewrite a target whose research topics all came back "low confidence" — surface this and ask whether to proceed without strong evidence.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

