Conversation
41 tasks
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.
Summary
0–10to the OpenAI-compatible Chat Completions API.Motivation
InfiniLM currently admits waiting requests in FIFO order. Mixed online workloads need a bounded way to reduce queueing latency for latency-sensitive requests without disrupting in-flight Decode batches.
Priority affects Prefill admission only. Aging raises the effective priority of waiting requests to prevent starvation, and requests deferred by KV-cache pressure remain queued.
Closes #570.
Type of Change
feat— new feature / new modelfix— bug fixperf— performance improvement (no behavioral change)refactor— code restructuring without behavior changetest— adding or fixing tests onlydocs— documentation onlybuild/ci— build system or CI configurationchore— tooling, formatting, or other non-code changesTest Results of Involved Models on Supported Platforms (Please attach screenshots)
The MetaX validation used PR commit
6683db7and completed 14 reports, 320 paired FIFO/Priority runs, and 20,480 requests with no failures. The benchmark was executed headlessly; the measurements and server logs were archived outside this PR, so no UI screenshot is attached.Benchmark / Performance Impact
This feature redistributes admission waiting time; it is not intended to increase aggregate throughput.
NVIDIA smoke benchmark
Configuration: RTX 4090 D, FP16, DeepSeek-R1-Distill-Qwen-1.5B, concurrency 16,
max_batch_size=1, input/output lengths 128/32, 25% high-priority traffic, and two repetitions with 64 requests per cache mode.MetaX C500 paired benchmark
Configuration: C500 25% sGPU with 16 GiB memory, MACA 3.1.0.14, DeepSeek-R1-Distill-Qwen-1.5B,
max_batch_size=1, Prefix Cache disabled, and EOS ignored. FIFO uses priorities0/0; Priority uses10/0. Each scenario contains 64 requests and five paired repetitions with alternating FIFO/Priority execution order. Confidence intervals use per-run paired percentage differences and a Student-t 95% CI (df=4).The shared baseline uses concurrency 32, 25% high-priority traffic, input/output lengths 128/32, and a 5-second aging interval. Values below are means from the baseline repeated across the concurrency, priority-ratio, input-length, output-length, and aging scans.
Across the complete MetaX matrix:
The broader paired NVIDIA and MetaX suites contain 40,960 successful requests. On the shared baseline, Static high-priority TTFT p95 falls by 73.1% on MetaX versus 74.6% on RTX 4090 D; Paged falls by 53.0% versus 52.6%.
Absolute device performance is not compared because the MetaX run used a 25% C500 slice and a different software stack. The Paged 512-token input case lies on the KV-capacity boundary and is excluded as a standalone conclusion. MetaX used InfiniCore build-compatibility patches in the remote test copy; those patches are not part of this InfiniLM PR. The MetaX client reproduced the NVIDIA workload and statistical method but was not the same source file. Streaming responses lacked usage metadata, so absolute output-token throughput uses non-empty content chunks; relative paired comparisons remain consistent.
Notes for Reviewers
Please focus on:
Queue selection is
O(n log n)over the current waiting snapshot. Priority redistributes waiting time rather than removing it, so normal-priority latency can increase under mixed-priority traffic. The implementation is independent of the protocol refactor in #554.CI / ChatOps
Local Ruff formatting/checks and the focused 14-test scheduling regression passed. NVIDIA and MetaX service-level validation is summarized above.
The upstream CI run and Ruff run currently report
action_requiredwith no jobs executed. Maintainer approval or/retestis still required.Checklist
Title, Branch, and Commits
feat(nvidia): …,fix(cuda/gemm): …).<type>/xxx-yyyy-zzzzwhere<type>matches the PR title's Conventional Commits type and words are joined with hyphens (seeCONTRIBUTING.md§Branches).CONTRIBUTING.md§Pull Requests).InfiniLM-v0.2.9c; it is cleanly based on that release branch rather than currentmain.fixup!/squash!/wipcommits remain.Scope and Design
CONTRIBUTING.md§Code/General).printf/std::cout/print(...)left behind, orTODOwithout an owner and issue link.General Code Hygiene (applies to all languages)
CONTRIBUTING.md§Code/General).CONTRIBUTING.md§Code/General).the \seqlens_k` tensor) (CONTRIBUTING.md` §Code/General).CONTRIBUTING.md§Code/General).CONTRIBUTING.md§Code/General; §Python).C++ Specific (if C++ files changed)
csrc/models/llama_legacy/.Python Specific (if Python files changed)
CONTRIBUTING.md§Python).CONTRIBUTING.md§Python).scripts/format.py.python/infinilm/auto_config.py.Testing
examples/test_infer.pywas not run; equivalent model execution was exercised through the service path on NVIDIA and MetaX.examples/bench.pywas not run; performance was measured with the paired HTTP service benchmark described above.test/bench/test_benchmark.pywas not run because this change does not alter model numerics; focused scheduler tests and service output controls were used.python/infinilm/server/inference_server.pyand the paired performance harness on NVIDIA and MetaX.Build, CI, and Tooling
action_required; maintainer approval or/retestis required.Documentation
README.mdwas updated for the new API field and configuration.Security and Safety