feat(backend): every generation call carries a session name
The release audit swept every agent.run and raw chat call: the two streaming orchestrate paths never carried a binding (they predate the v2.6.0 pinning), and the biographer and housekeeper ran bare. Through the wrapper a session-less call takes idle slots only and 503s once four sessions are resident — so the streaming paths join tatlock-orchestrate, and the experts share tatlock-experts at rank 35: between the librarian and the phases, the two least-used consumers trade the spare slot by rank instead of anyone hitting an empty pool. Rank mutation shown to fail its test. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -121,11 +121,12 @@ class TestPhaseBinding:
|
||||
monkeypatch.setattr(model_selector, "_local_flavor", "boilerroom")
|
||||
ranks = {
|
||||
phase: model_selector.phase_extra_body(phase)["eviction_order"]
|
||||
for phase in ("steward", "orchestrate", "synthesize", "librarian")
|
||||
for phase in ("steward", "orchestrate", "synthesize", "experts", "librarian")
|
||||
}
|
||||
assert ranks["steward"] == ranks["orchestrate"] == ranks["synthesize"] == 40
|
||||
assert ranks["experts"] == 35
|
||||
assert ranks["librarian"] == 30
|
||||
assert ranks["librarian"] < ranks["steward"]
|
||||
assert ranks["librarian"] < ranks["experts"] < ranks["steward"]
|
||||
assert ranks["librarian"] > 20 # webber's rank stays below
|
||||
|
||||
def test_wrapper_session_names_are_stable(self, local_first, monkeypatch):
|
||||
@@ -134,12 +135,13 @@ class TestPhaseBinding:
|
||||
monkeypatch.setattr(model_selector, "_local_flavor", "boilerroom")
|
||||
names = {
|
||||
phase: model_selector.phase_extra_body(phase)["session"]
|
||||
for phase in ("steward", "orchestrate", "synthesize", "librarian")
|
||||
for phase in ("steward", "orchestrate", "synthesize", "experts", "librarian")
|
||||
}
|
||||
assert names == {
|
||||
"steward": "tatlock-steward",
|
||||
"orchestrate": "tatlock-orchestrate",
|
||||
"synthesize": "tatlock-synthesize",
|
||||
"experts": "tatlock-experts",
|
||||
"librarian": "librarian",
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user