Repository navigation
[Docs] Mixed traffic: keep batch_after at 4 (1 costs 1.9 s per conversation) - #17
Merged
Merged
Conversation
…as dead
Two card windows, same build, differing only in --conv-route-batch-after.
1 wins 0.52 s across the first six single-shot requests of a burst
(0.17 / 0.18 / 0.13 on the second, third and fourth, then nothing)
1 loses 1.88 s on the conversation turn that follows it
(C2 2.465 s against 0.587 s: served cache-off, the first turn parks
nothing, so the second re-reads its whole context)
break-even is ~21 single-shot requests per conversation re-open
So the ranked item closes the other way round: 4 stands, and 1 is only
right for a pure single-shot queue.
Getting there also found a dead setting. Both configs produced identical
results on all eleven steps until the flag was passed by hand: the server
read --conv-route-batch-after and ignored the config's
conv_route_batch_after, while the launcher writes the key and passes no
flag. Every deployment ran 4 whatever the config said. The fix and its
test are in PR #16, unmerged on purpose: serve/ has to stay
byte-identical on this branch.
Also renumbers the method rules to section 8.
This was referenced Nov 14, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem and result
The ranked list's first item was "ship
conv-route-batch-after1–2", on a single-shot measurement of −21 % median TTFT.The missing half was what a smaller run length costs a conversation. Ran it: one traffic shape — a repeated 3k prompt,
a two-turn conversation, six unique single-shot prompts, then the conversation's next turn and the repeat — against two
card windows that differ only in
--conv-route-batch-after.1 buys 0.52 s across six single-shot requests and costs 1.88 s on the next conversation turn. Break-even is ~21
single-shots per conversation re-open. 4 stands; 1 is only right for a pure one-shot queue.
Finding it also exposed a dead setting:
conv_route_batch_afterin the config was ignored by the server (it read onlythe flag, and the launcher passes no flag), so both arms were byte-identical until the flag was passed by hand. Fixed in
PR #16.
Related discussion
serve/must stay byte-identical hereApproach
strata-mixed-probe.pyruns R1 (3k prompt), C1/C2 (two turns), S1–S6 (uniquesingle-shots), C3 (third turn), R2 (the 3k prompt again); a step that jumps from ~0.3 s to seconds is a re-prefill.
arms — the flag is what the server reads. Re-ran with
SRV_ARGS='--conv-route-batch-after 1'; the inert runs arekept beside the good ones.
4"; the closed table records both numbers; the method rules renumber to section 8.
Validation
Passed:
are equal (0.328 against 0.327) in both arms — the flip happens either way by the fifth request; C2 flips from 0.587
to 2.465; C3 and R2 behave the same in both arms.
C2at 2.465 s matches the 2026-11-09 arm's 2.472 s, on a different day, a differentwindow and a fresh engine start. Those older artifacts are shipped under
mixed/2026-11-09/.:8095 http=200, engine 0.1.58, checked after each.Failed:
byte-identical, which no real setting difference would produce. Fixed the sweep (server flag), and filed the setting
itself as PR serve: honour conv_route_batch_after from the config, not only the flag #16.
Not run:
requests, not seconds.
Limits
requests; the conversation cost is one number from one turn, though it reproduces a week-old measurement to 7 ms.
which strengthens the conclusion rather than weakening it.