Repository navigation
Conversation
|
Extracting parsing for unit tests there seemed overkill, but lmk if you want that :) |
|
Ran a multi-day validation campaign with this build (a browser demo where jev judges 10-15x/s in a game loop) — some field numbers that motivate exposing these knobs:
Happy to share the validation harness (headless browser, URL-parameter driven, per-episode score/latency export) if useful. |
feder-cr
left a comment
There was a problem hiding this comment.
Thanks for the PR and for measuring it. I can't merge it as it is: with this engine the two knobs can only make a request slower.
jev servehas a single model user: oneInferRequest(src/model.cpp) driven by one scheduler thread (src/scheduler.hpp). Calls never run concurrently, so a second stream never gets work of its own; it only takes cores away from the one call that is running. Your table shows exactly that: 40 -> 113 ms and 135 -> 375 ms, and there is no concurrent throughput to win back.- Concurrent clients are handled by the scheduler instead: requests waiting at the same time are read together in one call (
--batch-tokens;batched_requestsin/healthcounts them).
Streams would only pay off with several infer requests, several scheduler workers and the state snapshots shared safely between them, which is a scheduler redesign rather than a flag. If you have a concurrent workload where batching loses, an issue with the numbers is the place to start.
|
Agreed, and your explanation matches the table exactly: with a single I'd also missed that concurrent clients already merge through For the record, our concurrent-latency pain point lives on the llama.cpp lane (PR #43), where two clients serialize ~10x inside that server. If a workload ever shows batching losing on this side, I'll open the issue with numbers first, as you suggest. |
Adds
--hint {latency,throughput}(default latency, the released behavior) and--streams N(default 1) tojev serve/jev decide, wired into the compile config's PERFORMANCE_HINT / NUM_STREAMS, and reported by /health.Bench on a shared 20-core x86-64 box (p50 of 20 sequential runs, short 90-token 1-question request / grouped 235-token 4-question request, ms):
Under a single sequential client the defaults win; streams pay off only under concurrent load (not measured here). Happy to adjust flag naming to match project conventions.