Repository navigation
Reuse ready batch proposals after short concurrent bursts - #1570
Closed
jonathan308 wants to merge 4 commits into
Closed
jonathan308 wants to merge 4 commits into
jonathan308 wants to merge 4 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This branch was successfully deployed
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.
A short concurrent burst can drain before automatic batch planning finishes. The host previously discarded the valid proposal, leaving GPT-OSS serial through repeated bursts despite four successful capacity proposals. This draft retains the metadata-only result for at most 30 seconds and consumes it once on renewed queue pressure in the same serving generation.
Generation, expiry and live pressure are checked again immediately before reuse. Idle requests never reload workers. Teardown clears the proposal; original request deadlines, response ownership, cleanup-before-load, fresh post-release memory quotes, exact promised width and rollback remain intact. The existing plain-pipeline batch planner tries independently priced widths 8, 4 and 2 in descending order once pressure exists.
This is a separate child of #1569. It repairs the existing lifecycle; it does not establish tensor-parallel batching or restore omitted media capabilities. Final acceptance requires tensor parallel for every included model with all supported capabilities retained.
Before
flowchart TD A["Concurrent burst"] --> B["Read-only batch planning"] B --> C{"Queue still waiting?"} C -->|No| D["Discard valid proposal"] D --> E["Next burst remains serial"] classDef default fill:#e8f0fe,stroke:#174ea6,color:#102a43; classDef failure fill:#fde2e2,stroke:#9b1c1c,color:#571111; class D,E failure;After
flowchart TD A["Completed proposal after burst drains"] --> B["Retain bounded metadata only"] B --> C{"Fresh queued pressure, same generation, unexpired?"} C -->|Yes| D["Consume once and drain original workers"] D --> E["Fresh exact-width memory check and load"] C -->|No| F["Keep serving without idle reload"] classDef default fill:#e8f0fe,stroke:#174ea6,color:#102a43; classDef guard fill:#fff4ce,stroke:#8a6100,color:#332500; classDef success fill:#d7f0df,stroke:#176b39,color:#103b23; class C,E guard; class D,F success;Validation: full actual ProviderCore module and object compilation; 29 real host/loopback/queue tests; 1,108 pure placement checks; canonical documentation, impact and changelog checks all pass. Regression tests reproduce the drained first burst, reuse without another planner call, expiry/replanning, disconnect, empty queue, stop during planning, teardown, generation and capacity guards. Independent review found and fixed the scheduled-task expiry race, then verified the final source and test receipts with no unresolved finding.
The focused host suites are
DistributedLocalServerBatchReplacementTests,DistributedLocalServerTestsandDistributedRequestQueueTests. Recorded compilation/tests used pinned isolated actual-source closures; native sessions in host tests are deliberately model-free. Patch SHA-256:1bd5279946f44cdc006ec1cd96a93d53e3445170970167e9262c3b965b31c5bd; independent review SHA-256:8dd8563e62efccc2560654dd313880d5b5771f913c63a91cfa1f0eae11da171a.The original installed GPT-OSS automatic test remains failed and immutable: both endpoint passes were 36/0/2, but neither activated native batching. Fresh installed hardware validation for this repair is pending. This draft does not relax memory admission or numerical tolerances, count phase-split results, or claim universal TP/capability qualification.
Need help on this PR? Tag
@codesmith-botwith what you need.