Latent Context Compilation: Distilling Long Context into Compact Portable Memory
Not on the map. Why?
Abstract (arXiv)
Efficient long-context LLM deployment is stalled by a dichotomy between amortized compression, which struggles with out-of-distribution generalization, and Test-Time Training, which incurs prohibitive synthetic data costs and requires modifying model weights, creating stateful parameters that complicate concurrent serving. We propose Latent Context Compilation, a framework that fundamentally shifts context processing from adaptation to compilation. By utilizing a disposable LoRA module as a compiler, we distill long contexts into compact buffer tokens -- stateless, portable memory artifacts that are plug-and-play compatible with frozen base models. Crucially, we introduce a self-aligned optimization strategy that eliminates the need for synthetic context-relevant QA pairs. By regularizing context reconstruction task with context-agnostic random queries, we force compressed tokens to reside within the model's existing instruction-following manifold. Experiments with Llama-3.1-8B demonstrate that Latent Context Compilation preserves fine-grained details and reasoning capabilities where prior methods falter, effectively decoupling memory density from model parameters even at a 16x compression ratio.
Key facts. Cited by 13 papers in the map (data through 14 Oct 2026). Builds on 27 of its 32 references that are in the map. First posted on arXiv 31 Jan 2026.
Builds on
27 of 32 references.
References · 27
- 2024The Llama 3 Herd of Modelscited by 14,715
- 2023GPQA: A Graduate-Level Google-Proof Q&A Benchmarkcited by 2,879
- 2018Know What You Don't Know: Unanswerable Questions for SQuADcited by 1,554
- 2018Don't Give Me the Details, Just the Summary! Topic-Aware Convolutional Neural Networks for Extreme Summarizationcited by 1,317
- 2024SnapKV: LLM Knows What You are Looking for Before Generationcited by 880
- 2023H2O: Heavy-Hitter Oracle for Efficient Generative Inference of Large Language Modelscited by 832
- 2018CoQA: A Conversational Question Answering Challengecited by 683
- 2023Learning to Compress Prompts with Gist Tokenscited by 390
- 2023Adapting Language Models to Compress Contextscited by 356
- 2023RECOMP: Improving Retrieval-Augmented LMs with Compression and Selective Augmentationcited by 256
- 2023In-context Autoencoder for Context Compression in a Large Language Modelcited by 199
- 2023Compressing Context to Enhance Inference Efficiency of Large Language Modelscited by 189
15 more
- 2021BookSum: A Collection of Datasets for Long-form Narrative Summarizationcited by 184
- 2024Long Context Compression with Activation Beaconcited by 104
- 2022Prompt Compression and Contrastive Conditioning for Controllability and Toxicity Reduction in Language Modelscited by 97
- 2023Test-Time Training on Nearest Neighbors for Large Language Modelscited by 88
- 2024Test-Time Model Adaptation with Only Forward Passescited by 74
- 2025Expected Attention: KV Cache Compression by Estimating Attention from Future Queries Distributioncited by 74
- 2025ChunkKV: Semantic-Preserving KV Cache Compression for Efficient Long-Context LLM Inferencecited by 60
- 2025Test-Time Learning for Large Language Modelscited by 50
- 2024500xCompressor: Generalized Prompt Compression for Large Language Modelscited by 47
- 2023Compressed Context Memory For Online Language Model Interactioncited by 43
- 2024With Greater Text Comes Greater Necessity: Inference-Time Training Helps Long Text Generationcited by 37
- 2024A Silver Bullet or a Compromise for Full Attention? A Comprehensive Study of Gist Token-based Context Compressioncited by 17
- 2025InfiniteICL: Breaking the Limit of Context Window Size via Long Short-term Memory Transformationcited by 17
- 2025Context Cascade Compression: Exploring the Upper Limits of Text Compressioncited by 17
- 2024StreamAdapter: Efficient Test Time Adaptation from Contextual Streamscited by 6
Built on by
Citing papers per year: 2026: 13.
13 papers.
Sort:
By area:
- 2026Context Distillation as Latent Memory Managementcited by 6
- 2026RestoreKV: Recovering Full-Cache Behavior Under Aggressive Query-Agnostic KV Cache Evictioncited by 3
- 2026A Survey on Self-Improving Test-Time Intelligence: Feedback-Driven Adapting, Learning, and Scaling at Inferencecited by 3
- 2026Context Compaction Theorycited by 2
- 2026Cartridges++: KV Cache Compression without Off-Context Derailmentcited by 2
- 2026Large Language Models Do Not Always Need Readable Languagecited by 1
- 2026Program-as-Weights: A Programming Paradigm for Fuzzy Functionscited by 1
- 2026One Token per Multimodal Evidence: Latent Memory for Resource-Constrained QAcited by 0
- 2026Compact-Memory LLM Agents via Online Max-Member Clustering and Atom-Aware Packingcited by 0
- 2026Machine-Interpretable Information: Compiling Documents into Searchable and Readable Protocol Statescited by 0
- 2026MemFold: Learning Compact Soft Memory for Long-Context Personalization via On-Policy Optimizationcited by 0
- 2026When Can Prefixes Compile LoRA? Exact Resource-Capped Tests for Frozen Attentioncited by 0
- 2026Compile the Table: Query-Calibrated Operator Compression for Tabular In-Context Learning8 Oct 2026
- 2026When Can Prefixes Compile LoRA? Exact Resource-Capped Tests for Frozen Attention29 Sep 2026
- 2026MemFold: Learning Compact Soft Memory for Long-Context Personalization via On-Policy Optimization29 Sep 2026
- 2026Cartridges++: KV Cache Compression without Off-Context Derailment28 Sep 2026
- 2026Machine-Interpretable Information: Compiling Documents into Searchable and Readable Protocol States20 Sep 2026
- 2026Compact-Memory LLM Agents via Online Max-Member Clustering and Atom-Aware Packing4 Sep 2026
- 2026A Survey on Self-Improving Test-Time Intelligence: Feedback-Driven Adapting, Learning, and Scaling at Inference1 Sep 2026
- 2026Context Compaction Theory2 Aug 2026
- 2026RestoreKV: Recovering Full-Cache Behavior Under Aggressive Query-Agnostic KV Cache Eviction2 Aug 2026
- 2026Program-as-Weights: A Programming Paradigm for Fuzzy Functions2 Jul 2026
- 2026Large Language Models Do Not Always Need Readable Language18 Jun 2026
- 2026One Token per Multimodal Evidence: Latent Memory for Resource-Constrained QA9 Jun 2026
1 more
- 2026Context Distillation as Latent Memory Management27 May 2026
- 2026Context Distillation as Latent Memory Managementcited by 6
- 2026A Survey on Self-Improving Test-Time Intelligence: Feedback-Driven Adapting, Learning, and Scaling at Inferencecited by 3
- 2026Context Compaction Theorycited by 2
- 2026Large Language Models Do Not Always Need Readable Languagecited by 1
- 2026Program-as-Weights: A Programming Paradigm for Fuzzy Functionscited by 1
- 2026Machine-Interpretable Information: Compiling Documents into Searchable and Readable Protocol Statescited by 0
- 2026MemFold: Learning Compact Soft Memory for Long-Context Personalization via On-Policy Optimizationcited by 0
- 2026When Can Prefixes Compile LoRA? Exact Resource-Capped Tests for Frozen Attentioncited by 0
- 2026Compile the Table: Query-Calibrated Operator Compression for Tabular In-Context Learningcited by 0
- 2026Compile the Table: Query-Calibrated Operator Compression for Tabular In-Context Learning8 Oct 2026
- 2026When Can Prefixes Compile LoRA? Exact Resource-Capped Tests for Frozen Attention29 Sep 2026
- 2026MemFold: Learning Compact Soft Memory for Long-Context Personalization via On-Policy Optimization29 Sep 2026
- 2026Machine-Interpretable Information: Compiling Documents into Searchable and Readable Protocol States20 Sep 2026
- 2026A Survey on Self-Improving Test-Time Intelligence: Feedback-Driven Adapting, Learning, and Scaling at Inference1 Sep 2026
- 2026Context Compaction Theory2 Aug 2026
- 2026Program-as-Weights: A Programming Paradigm for Fuzzy Functions2 Jul 2026
- 2026Large Language Models Do Not Always Need Readable Language18 Jun 2026
- 2026Context Distillation as Latent Memory Management27 May 2026
Similar, not cited
Close in wording, no citation either way
- 2024Enhancing and Accelerating Large Language Models via Instruction-Aware Contextual Compression
- 2026PReM: Learning What to Preserve and When to Refresh for Context Compression
- 2026LongAttnComp: Cross-Family Context Compression for Long-Context Reasoning
- 2025PERK: Long-Context Reasoning as Test-Time Learning
- 2025Let's (not) just put things in Context: Test-Time Training for Long-Context LLMs
- 2025ContextPilot: Fast Long-Context Inference via Context Reuse
- 2025Scaling Instruction-Tuned LLMs to Million-Token Contexts via Hierarchical Synthetic Data Generation
- 2026GradMem: Learning to Write Context into Memory with Test-Time Gradient Descent