recursive-decomposition

Installation
SKILL.md

Recursive Decomposition

Long inputs degrade model quality: details get missed, distant parts get linked by guesswork, reasoning drifts. The RLM paper calls it context rot. Instead of loading everything into the context window, treat the input as an environment you query with tools: size it, narrow it, split it, delegate independent parts to sub-agents, verify on small windows, and merge results programmatically. Based on Recursive Language Models (Zhang, Kraska, Khattab, 2025).

How to use

  • /recursive-decomposition: apply the protocol below to the current task.
  • /recursive-decomposition <path or question>: size that input first, then run the protocol on it.

When it applies

Situation Approach
10+ files, 50k+ tokens, or a multi-hop question across scattered sources Decompose (this skill)
30k to 50k tokens Decompose when completeness matters; otherwise read directly
Under 30k tokens, one file, or a localized answer Read directly

Protocol

Installs
178
GitHub Stars
46
First Seen
Jan 25, 2026
recursive-decomposition — massimodeluisa/recursive-decomposition-skill