{
  "id": "recursive-language-model",
  "code": "PTL-0213",
  "term": "Recursive Language Model",
  "aliases": [
    "RLM",
    "RLMs",
    "recursive LM"
  ],
  "category": "test-time",
  "definition": "A recursive language model (RLM) is an inference strategy in which a long prompt is kept outside the model's context window as an external resource that the model inspects programmatically, splitting the task into parts and calling itself recursively on them.",
  "description": "RLMs address inputs far longer than a context window without first compressing or summarizing them. The model works in a code environment where the prompt is stored as data, reads only the parts it needs, and delegates sub-problems to recursive calls whose results it combines. The authors report handling inputs about two orders of magnitude beyond the context window and outperforming compaction and common agent scaffolds on long-context tasks at comparable cost. The approach treats long-context handling as a form of test-time compute rather than a property of the model.",
  "example": null,
  "broader": [
    "test-time-compute-scaling"
  ],
  "narrower": [],
  "related": [
    "context-window",
    "context-compaction",
    "context-rot",
    "lost-in-the-middle",
    "code-execution-tool"
  ],
  "introduced": 2025,
  "added": "2026-10-14",
  "sources": [
    {
      "title": "Recursive Language Models",
      "authors": "Zhang et al.",
      "year": 2025,
      "url": "https://arxiv.org/abs/2512.24601"
    }
  ],
  "url": "https://protologue.com/t/recursive-language-model/",
  "citation": "Protologue. (2026). Recursive Language Model. In Protologue: A Taxonomy of Prompting and LLM Techniques (v1.4.0, PTL-0213). https://protologue.com/t/recursive-language-model/"
}