Uploaded October 2026 | Updated November 2026, 2 days ago
The longer an agent runs, the more instructions and tool results pile into its context window, and the worse its reasoning tends to get. That's context rot. This video walks through two context engineering techniques the Deep Agents harness ships out of the box: offloading, which keeps large tool results and long messages out of context while saving them to a virtual file system, and summarization, which compacts the conversation once token usage crosses a threshold (85% by default).
You'll see where the 20,000 token offloading threshold kicks in, why token usage can overshoot 85% before summarization runs, how the keep cutoff decides what stays verbatim, and how the two techniques work together over a long run.
Deep Agents is LangChain's open source agent harness for long-running tasks, with offloading, summarization, skills, subagents, and long-term memory built in.
Chapters:
0:00 What is context rot
0:29 An agent is a model plus a harness
1:14 Two ways to manage context
1:33 How offloading works for tool results
2:12 Offloading long human messages
2:37 How summarization works
3:10 Why token usage overshoots the threshold
3:45 The summarization loop
4:13 Offloading vs summarization
4:34 Skills, subagents, and long-term memory
Resources:
→ Introduction to Deep Agents (free LangChain Academy course): academy.langchain.com/courses/foundation-introduction-to-deepagents
→ Context Management for Deep Agents (blog): langchain.com/blog/context-management-for-deepagents
→ Context Engineering Starts with Retrieval (blog): langchain.com/blog/context-engineering-starts-with-retrieval
→ Context engineering in Deep Agents (docs): docs.langchain.com/oss/python/deepagents/context-engineering
→ Agent Memory 101: Context Engineering (live workshop): events.langchain.com/register/agent-memory-101-context-engineering
→ Agent Memory 102: Context Retrieval & Storage (live workshop): events.langchain.com/register/agent-memory-102-context-retrieval-storage
The longer an agent runs, the more instructions and tool results pile into its context window, and the worse its reasoning tends to get. That's context rot. This video walks through two context engineering techniques the Deep Agents harness ships out of the box: offloading, which keeps large tool results and long messages out of context while saving them to a virtual file system, and summarization, which compacts the conversation once token usage crosses a threshold (85% by default).
You'll see where the 20,000 token offloading threshold kicks in, why token usage can overshoot 85% before summarization runs, how the keep cutoff decides what stays verbatim, and how the two techniques work together over a long run.
Deep Agents is LangChain's open source agent harness for long-running tasks, with offloading, summarization, skills, subagents, and long-term memory built in.
Chapters:
0:00 What is context rot
0:29 An agent is a model plus a harness
1:14 Two ways to manage context
1:33 How offloading works for tool results
2:12 Offloading long human messages
2:37 How summarization works
3:10 Why token usage overshoots the threshold
3:45 The summarization loop
4:13 Offloading vs summarization
4:34 Skills, subagents, and long-term memory
Resources:
→ Introduction to Deep Agents (free LangChain Academy course): academy.langchain.com/courses/foundation-introduction-to-deepagents
→ Context Management for Deep Agents (blog): langchain.com/blog/context-management-for-deepagents
→ Context Engineering Starts with Retrieval (blog): langchain.com/blog/context-engineering-starts-with-retrieval
→ Context engineering in Deep Agents (docs): docs.langchain.com/oss/python/deepagents/context-engineering
→ Agent Memory 101: Context Engineering (live workshop): events.langchain.com/register/agent-memory-101-context-engineering
→ Agent Memory 102: Context Retrieval & Storage (live workshop): events.langchain.com/register/agent-memory-102-context-retrieval-storage










