Skip to content

feat(speculation): speculator extension contract - #445

Merged
behinddwalls merged 1 commit into
mainfrom
preetam/speculation-speculator
Jul 30, 2026
Merged

feat(speculation): speculator extension contract#445
behinddwalls merged 1 commit into
mainfrom
preetam/speculation-speculator

Conversation

@behinddwalls

@behinddwalls behinddwalls commented Jul 27, 2026

Copy link
Copy Markdown
Collaborator

Add submitqueue/extension/speculation/speculator: the Speculator interface — the one speculation extension the speculate controller calls — with Config, Factory, and mocks. A Speculator decides which paths to build and which running ones to cancel within the queue's build budget; verdicts stay controller-owned, so a swapped-in implementation changes which paths run, never a batch's outcome.

Speculate's doc spells out the contract formally: what batches and pathSets contain, what the returned actions mean (empty result = nothing to change; order carries no meaning), and the error contract — plain unclassified errors for infrastructure failures only, context errors passed through, and an abandoned run retried by the next dirty signal.

Stack

  1. feat(entity): speculation path and run entities #444
  2. @ feat(speculation): speculator extension contract #445
  3. feat(speculation): generator contract and bestfirst impl #446
  4. feat(speculation): allocator contract and sticky impl #450
  5. feat(speculation): standard composed speculator #451

@behinddwalls
behinddwalls marked this pull request as ready for review July 27, 2026 19:00
@behinddwalls
behinddwalls requested review from a team and sbalabanov as code owners July 27, 2026 19:00
@behinddwalls
behinddwalls marked this pull request as draft July 27, 2026 20:45
@behinddwalls
behinddwalls marked this pull request as ready for review July 27, 2026 23:17
@behinddwalls
behinddwalls force-pushed the preetam/speculation-speculator branch from 648e491 to d89bfe4 Compare July 27, 2026 23:18
@behinddwalls
behinddwalls force-pushed the preetam/speculation-speculator branch from d89bfe4 to 648e491 Compare July 28, 2026 19:13
Comment thread submitqueue/extension/speculation/speculator/speculator.go Outdated
@behinddwalls
behinddwalls force-pushed the preetam/speculation-speculator branch from 648e491 to f9397ba Compare July 29, 2026 18:24
@behinddwalls
behinddwalls force-pushed the preetam/speculation-speculator branch from f9397ba to 9698e2a Compare July 29, 2026 22:31
@behinddwalls
behinddwalls force-pushed the preetam/speculation-speculator branch from 9698e2a to d9aaca5 Compare July 29, 2026 22:41
@behinddwalls
behinddwalls added this pull request to the merge queue Jul 29, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to invalid changes in the merge commit Jul 29, 2026
@behinddwalls
behinddwalls added this pull request to the merge queue Jul 29, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to invalid changes in the merge commit Jul 29, 2026
Base automatically changed from preetam/speculation-entities to main July 29, 2026 23:18
Add submitqueue/extension/speculation/speculator: the Speculator interface — the one speculation extension the speculate controller calls — with Config, Factory, and mocks. A Speculator decides which paths to build and which running ones to cancel within the queue's build budget; verdicts stay controller-owned, so a swapped-in implementation changes which paths run, never a batch's outcome.

Speculate's doc spells out the contract formally: what batches and pathSets contain, what the returned actions mean (empty result = nothing to change; order carries no meaning), and the error contract — plain unclassified errors for infrastructure failures only, context errors passed through, and an abandoned run retried by the next dirty signal.
@behinddwalls
behinddwalls force-pushed the preetam/speculation-speculator branch from d9aaca5 to 9dca221 Compare July 29, 2026 23:18
@behinddwalls
behinddwalls added this pull request to the merge queue Jul 30, 2026
Merged via the queue into main with commit 7225967 Jul 30, 2026
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants