GPT-5.6 Sol API and credit pricing cut by over 20%Claude Security now scans GitHub repos with Mythos 5Zero Data Retention continues with Private Safety Processing preview for stronger safetyClaude can now send Gmail emails and manage Google Drive filesStrengthen monitoring for high-risk training and pause RL runsApproved defenders can advance advanced vulnerability research with GPT-5.6-CyberCyclone forecasts now provide over a day of extra lead timeTalk while reasoning or using tools without conversation breaksAI delivers new results on 10 long-standing math problems with proofs releasedGPT-5.6 Luna and Terra prices drop 80% and 20%, with faster Sol option addedOpus 5 now available on all paid plans and APISecurely link health records to understand symptom changes and test results in contextRun code inside notes for deeper analysisGPT-Red boosts prompt injection resistance significantlyCut lesson prep time with AIYou can move from conversation to documents fasterRun AI inference in the browser and cut wait timeReview how you use Claude and cut wasteLong tasks can move from draft to presentation more easilyTrack the latest safety rules for bigger modelsGPT-5.6 Sol API and credit pricing cut by over 20%Claude Security now scans GitHub repos with Mythos 5Zero Data Retention continues with Private Safety Processing preview for stronger safetyClaude can now send Gmail emails and manage Google Drive filesStrengthen monitoring for high-risk training and pause RL runsApproved defenders can advance advanced vulnerability research with GPT-5.6-CyberCyclone forecasts now provide over a day of extra lead timeTalk while reasoning or using tools without conversation breaksAI delivers new results on 10 long-standing math problems with proofs releasedGPT-5.6 Luna and Terra prices drop 80% and 20%, with faster Sol option addedOpus 5 now available on all paid plans and APISecurely link health records to understand symptom changes and test results in contextRun code inside notes for deeper analysisGPT-Red boosts prompt injection resistance significantlyCut lesson prep time with AIYou can move from conversation to documents fasterRun AI inference in the browser and cut wait timeReview how you use Claude and cut wasteLong tasks can move from draft to presentation more easilyTrack the latest safety rules for bigger models
Official sources only. Rumors, leaks, and get-rich schemes are excluded.
← Back to glossary
GlossaryAI term

Context Compression

コンテキスト圧縮

Definition

Context compression is the practice of shrinking long inputs into key points or necessary information to save tokens while maintaining accuracy. It is important for balancing quality, latency, and cost.

Passing 10 retrieved chunks directly to an LLM from a RAG pipeline consumes thousands of tokens. Moreover, most of that information may not be directly relevant to the user's question. Context compression is a technique that extracts or summarizes only the truly necessary information from lengthy retrieved documents, passing it efficiently to the LLM.

Why Compression Is Necessary

LLM context windows are limited, and input token counts translate directly to cost. Research has also identified the "Lost in the Middle" problem, where information in the middle of long contexts tends to be overlooked. When too much low-relevance information is included, the response can lose focus. Context compression simultaneously reduces token costs and improves response accuracy.

Extractive and Abstractive Approaches

Context compression has two main approaches. The extractive approach pulls out only the sentences or paragraphs relevant to the question from the search results. LangChain's LLMChainExtractor, for example, uses an LLM for each chunk with the instruction "extract only the parts relevant to this question," removing unnecessary portions.

The abstractive approach summarizes the entire search results into a shorter form. It integrates information spanning multiple chunks and generates a concise summary focused on the question. Because integration and compression happen simultaneously, this approach has the advantage of restructuring fragmented search results into coherent context.

Combining with Filtering

As a pre-compression step, filtering out low-relevance documents is also effective. By using a reranking model to exclude chunks scoring below a threshold and then applying compression to the remaining chunks, the number of LLM calls can also be reduced. A pipeline of reranking, filtering, compression, and generation achieves the optimal balance of accuracy and cost.

Risks and Countermeasures

Context compression comes with caveats. There is a risk of losing important details or numerical values during compression. Additionally, using an LLM for the compression itself incurs extra inference costs. It is therefore important to quantitatively measure the effect of compression and compare response quality with and without compression. Adjusting the degree of compression while monitoring the balance between token savings and response accuracy is the practical approach.

h
hayami

Stay on top of OpenAI, Google & Anthropic updates. An AI digest for business professionals.

Source Policy

We use only official sources. Each article links to the original announcement so you can verify it yourself.

© 2026 hayami. All rights reserved.