code-sweep — Claude Code skill: what it does, how to install
code-sweep audits research code folders against paper figures, tables, and raw data before paper submission. It flags inconsistencies and proposes confirmed fixes one by one.
no license ★ 165 updated 2026-08-21
npx skills add aspi6246/Claude-Code-Skills-for-Academics --skill code-sweep -a claude-codeWhat code-sweep does
The skill verifies alignment across .Rmd analysis scripts, generated assets, and TeX manuscripts. It inspects YAML metadata headers, verifies that referenced input and output paths exist, and traces \includegraphics and \input calls inside Paper/main.tex to confirm that active scripts account for every figure. Discrepancies are tagged as either MUST-FIX or SUGGESTED.
Execution safety is tested by purling active scripts with knitr and running a 120-second dry run on downsampled data. It also monitors deterministic execution, requiring an explicit set.seed() whenever random sampling functions appear in code.
Without a Code/ directory present the skill halts immediately, and full registry reconciliation relies on build_registry.R provided by script-registry.
What it helps with
- detect missing source scripts for figures cited in TeX files
- dry-run R markdown analysis scripts to catch runtime errors
- locate unseeded random variables across analytical pipelines
- reconcile missing input datasets and outdated generated outputs
Example prompts for the agent
- /code-sweep
- /code-sweep --no-dryrun
- run a code sweep before paper submission
How to install code-sweep
1Skills CLI (Vercel)
npx skills add aspi6246/Claude-Code-Skills-for-Academics --skill code-sweep -a claude-code2Manually: put the files in place
~/.claude/skills/code-sweep/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/code-sweep/
1Skills CLI (Vercel)
npx skills add aspi6246/Claude-Code-Skills-for-Academics --skill code-sweep -a codex2Manually: put the files in place
.agents/skills/code-sweep/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add aspi6246/Claude-Code-Skills-for-Academics --skill code-sweep -a cursor2Manually: put the files in place
.cursor/skills/code-sweep/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install aspi6246/Claude-Code-Skills-for-Academics code-sweep2Manually: put the files in place
.github/skills/code-sweep/SKILL.md1Skills CLI (Vercel)
npx skills add aspi6246/Claude-Code-Skills-for-Academics --skill code-sweep -a gemini-cli2Platform CLI
gemini skills install https://github.com/aspi6246/Claude-Code-Skills-for-Academics --path code-sweepManually: put the files in place
.devin/skills/code-sweep/SKILL.mdThe legacy .windsurf/skills/ path still works
Claude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about code-sweep
How to install code-sweep in Claude Code?
Run npx skills add aspi6246/Claude-Code-Skills-for-Academics --skill code-sweep -a claude-code in your terminal.
What does code-sweep do?
It performs an automated milestone audit of empirical research code, finding drift across scripts, metadata registries, generated figures, and TeX drafts.
What is the relationship between code-sweep and script-registry?
The skill extends script-registry by reusing its YAML schema, directory rules, and the build_registry.R builder while adding status flags and seed verification.