atomic-decomposition — Claude Code skill: math to code
Splits a research idea into atomic concepts, then finds the math formula in papers and the matching code for each one.
npx skills add lingzhi227/agent-research-skills --skill atomic-decomposition -a claude-codeWhat atomic-decomposition does
The skill takes an idea, method or paper and breaks it into single-concept atoms. Each atom needs a mathematical foundation, a code implementation and a traceable reference to a specific paper. From there it runs two searches per concept: papers for the exact LaTeX formula, codebases for the implementation.
Every concept becomes a knowledge entry holding the definition, formula, code, reference papers, repositories, assumptions and links to other parts of the method. The entries merge into one knowledge base, and the skill checks both directions: each formula has code, each code module traces back to a formal definition. Gaps surface as formulas without implementations or code without theory.
The workflow reads ~/.claude/skills/atomic-decomposition/references/decomposition-prompts.md; without that file the decomposition steps do not run. Input is a single argument, $0 — the idea, paper or method description. The author's rule is to break down further when atomicity is unclear rather than merge concepts, so a long paper produces a long breakdown. It sits between research-planning and idea-generation upstream and experiment-code, algorithm-design downstream.
What it helps with
- break a method description into separate concepts
- pull the exact formula from a paper and its code
- check that every formula has an implementation
- trace each code module back to its source paper
- assemble a knowledge base for a complex system
Example prompts for the agent
- decompose this paper into atomic concepts with formulas and code
- find the LaTeX formula and a repo implementation for each concept in my method
- check my knowledge base for formulas that have no code
How to install atomic-decomposition
1Skills CLI (Vercel)
npx skills add lingzhi227/agent-research-skills --skill atomic-decomposition -a claude-code2Manually: put the files in place
~/.claude/skills/atomic-decomposition/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/atomic-decomposition/
1Skills CLI (Vercel)
npx skills add lingzhi227/agent-research-skills --skill atomic-decomposition -a codex2Manually: put the files in place
.agents/skills/atomic-decomposition/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add lingzhi227/agent-research-skills --skill atomic-decomposition -a cursor2Manually: put the files in place
.cursor/skills/atomic-decomposition/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install lingzhi227/agent-research-skills atomic-decomposition2Manually: put the files in place
.github/skills/atomic-decomposition/SKILL.md1Skills CLI (Vercel)
npx skills add lingzhi227/agent-research-skills --skill atomic-decomposition -a gemini-cli2Platform CLI
gemini skills install https://github.com/lingzhi227/agent-research-skills --path skills/atomic-decompositionManually: put the files in place
.devin/skills/atomic-decomposition/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add lingzhi227/agent-research-skills --skill atomic-decomposition -a opencodeClaude.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 atomic-decomposition
How do I install atomic-decomposition in Claude?
Run npx skills add lingzhi227/agent-research-skills --skill atomic-decomposition -a claude-code. The skill lands at ~/.claude/skills/atomic-decomposition/SKILL.md.
What does atomic-decomposition do?
It decomposes a research idea into atomic concepts, finds the math formula in papers and the code implementation for each, then compiles them into a knowledge base with a completeness check.
What does the skill need to run?
The file ~/.claude/skills/atomic-decomposition/references/decomposition-prompts.md with the prompts and workflow. You pass an idea, paper or method description as input.