@@ -106,6 +106,41 @@ tools:
106106
107107For the complete list of supported tools and custom tools, please refer to [here](./Tools.md)
108108
109+ ## Memory Compression Configuration
110+
111+ > Optional, for context management in long conversations
112+
113+ ` ` ` yaml
114+ memory :
115+ # Context Compressor: token detection + tool output pruning + LLM summary
116+ context_compressor :
117+ context_limit : 128000 # Model context window size
118+ prune_protect : 40000 # Token threshold to protect recent tool outputs
119+ prune_minimum : 20000 # Minimum pruning amount
120+ reserved_buffer : 20000 # Reserved buffer
121+ enable_summary : true # Enable LLM summary
122+ summary_prompt : | # Custom summary prompt (optional)
123+ Summarize this conversation...
124+
125+ # Refine Condenser: structured compression preserving execution trace
126+ refine_condenser :
127+ threshold : 60000 # Character threshold to trigger compression
128+ system : ... # Custom compression prompt (optional)
129+
130+ # Code Condenser: generate code index files
131+ code_condenser :
132+ system : ... # Custom index generation prompt (optional)
133+ code_wrapper : ['```', '```'] # Code block markers
134+ ` ` `
135+
136+ Supported compressor types:
137+
138+ | Type | Use Case | Compression Method |
139+ |------|----------|-------------------|
140+ | ` context_compressor` | General long conversations | Token detection + Tool pruning + LLM summary |
141+ | `refine_condenser` | Preserve execution trace | Structured message compression (1:6 ratio) |
142+ | `code_condenser` | Code generation tasks | Generate code index JSON |
143+
109144# # Others
110145
111146> Optional, configure as needed
0 commit comments