refactor(agent): let runner own context compaction (#5568)

* refactor(agent): consolidate accepted history under pressure

* fix(agent): align provider and session compaction

* refactor(agent): simplify runner context compaction

* refactor(agent): remove background token consolidation

* fix(agent): keep injected transcript messages distinct

* refactor(agent): unify native compaction summaries

* fix(agent): preserve native compaction boundary

* fix(agent): unify context compaction paths

* fix(agent): preserve exact compaction request boundaries
This commit is contained in:
chengyongru
2026-09-02 18:05:54 +08:00
committed by GitHub
parent da96c5c6eb
commit d81aa5a4ab
44 changed files with 1914 additions and 1666 deletions
+9
View File
@@ -13,3 +13,12 @@ def test_gateway_restart_mode_accepts_camel_alias():
def test_gateway_restart_mode_rejects_unknown_value():
with pytest.raises(ValueError):
GatewayConfig(restart_mode="service")
def test_heartbeat_ignores_removed_retention_limit():
config = Config.model_validate(
{"gateway": {"heartbeat": {"keepRecentMessages": 8}}}
)
heartbeat = config.model_dump(by_alias=True)["gateway"]["heartbeat"]
assert "keepRecentMessages" not in heartbeat