OffloadContextState
public record OffloadContextState(Map<String, List<Msg>> offloadContext) implements State
源码Source
io/agentscope/core/memory/autocontext/OffloadContextState.java:35承载卸载上下文状态数据的记录类型。位于 io.agentscope.core.memory.autocontext 包,实现 State。核心成员包括 offloadContext。
State record for persisting AutoContextMemory's offload context.
When messages are compressed with offload hints (e.g., "Use context_offload_tool to reload full content with uuid: xxx"), the original full content is stored in the offloadContext map. This state record wraps that map for session persistence.
Without persisting this state, after loading a session, the agent cannot reload offloaded content because the UUIDs reference non-existent data.
记录组件摘要Record Component Summary
| 组件Component | 类型Type | 说明Description |
|---|---|---|
offloadContext | Map<String, List<Msg>> | 执行卸载上下文相关操作。 map from UUID to the original messages that were offloaded |
记录组件详情Record Component Detail
offloadContext
Map<String, List<Msg>> offloadContext执行卸载上下文相关操作。
map from UUID to the original messages that were offloaded
源码Source
io/agentscope/core/memory/autocontext/OffloadContextState.java:35