docs(s08): clarify reactive_compact aggressive wording refers to trigger, not compression

The original phrasing "more aggressive than compact_history" was
ambiguous: the code shows reactive_compact is actually more
conservative in compression (keeps ~5 recent messages vs replacing
everything with a summary).  The real difference is the trigger
mechanism — reactive_compact is an emergency response to a 413
error, not a proactive threshold-based trigger.

Clarify in all three README languages that the aggressiveness is
about the trigger, not the compression strategy.

Closes #467
This commit is contained in:
root
2026-07-28 22:17:25 +08:00
parent 581241cdc7
commit b6eb5c0f3b
3 changed files with 3 additions and 3 deletions

View File

@@ -136,7 +136,7 @@ def compact_history(messages):
有时候 API 还是返回 `prompt_too_long`413上下文增长速度快于压缩触发速度时。
这时触发 **reactive_compact**:比 compact_history 更激进,从尾部回退,但仍要避免留下孤立 `tool_result`
这时触发 **reactive_compact**触发方式比 compact_history 更激进API 报错后的应急手段),但压缩策略更温和,保留最近约 5 条原始消息,只总结较早历史。同样避免留下孤立 `tool_result`
```python
def reactive_compact(messages):