← Back to feed
Threat Actors & CampaignsEmerging1 sourceJul 2, 2026 · 13:00via SentinelLabs

Context Engineering | Compaction & Agent Memory for Automated Malware Analysis

Brief

Executive Summary

  • Compaction is a context-management pattern used across agent systems to compress prior context into a denser working state for long-running tasks.
  • SentinelLABS evaluated OpenAI’s native Responses API implementation against our automated malware analysis evaluation harness to measure real-world impact on task quality and cost.
  • Compaction reduced input tokens by ~86% with no measurable change to the aggregate evaluation score.
  • Our analysis found that compaction can significantly reduce the cost and noise of long-running security workflows without sacrificing task quality.

OpenAI introduced native compaction in a March 2026 engineering post describing extensions to the Responses API. However, the underlying idea is not unique to OpenAI. Anthropic, Google, and other agent frameworks such as LangChain all expose or document related approaches under different names.

Read more on SentinelLabs