feat(runtime): Chronos-Bolt in forecasts, each series chosen once by the coordinator #668
Labels
Clear labels
accessibility
all-platforms
area:agents
area:ai
area:chain
area:ci
area:client
area:daemon
area:p2p
area:project
area:protocol
area:runtime
area:storage
bug
chore
community
dependencies
discussion
discussion/Announcements
discussion/General
discussion/Ideas
discussion/Q&A
discussion/Show and tell
discussion/answered
documentation
duplicate
enhancement
good first issue
help wanted
i18n
infra
invalid
needs:decision
needs:hardware
paired
question
research
security
status:in-review
test
testing
tracking
wontfix
Barrier affecting people with disabilities
Run every platform's packaging and checks on this pull request, not only the three main ones
MCP server, skill, and thinking on the pool
Planner and model providers
Blockchain, SISY, verification
Continuous integration and build workflows
Desktop and web clients
sisyphusd coordinator, worker, scheduler
libp2p hosts, relays, discovery, connections between nodes
Project planning, roadmap, and governance
Protobuf schemas and RPC contracts
Workload execution and environments
Content-addressed storage, IPFS, Kubo, Cluster, S3, names, pinning
Something isn't working
Repository health, templates, Discussions, contributor experience
Updates to actions, Go modules or npm packages
Migrated from GitHub Discussions
GitHub Discussions category: Announcements
GitHub Discussions category: General
GitHub Discussions category: Ideas
GitHub Discussions category: Q&A
GitHub Discussions category: Show and tell
Q&A discussion with an accepted answer
Improvements or additions to documentation
This issue or pull request already exists
New feature or request
Good for newcomers
Extra attention is needed
Translations and right-to-left layouts
Build, CI, releases
This doesn't seem right
Waits on a decision from both owners
Waits on a machine we do not have yet
Built together by both maintainers, with co-authored commits
Further information is requested
Needs investigation or a design decision
Sealing, keys, access control, tokens, the security model
Built and in an open pull request; closes when it merges
Tests, test harnesses and the rehearsal
Roadmap and meta issues
This will not be worked on
type
Feature
A request, idea, or new functionality (GitHub issue type)
type
Task
A specific piece of work (GitHub issue type)
Milestone
No items
No Milestone
Real workloads
Projects
Clear projects
No projects
Sisyphus roadmap
Done
No Assignees
rvnminers-A-and-N
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: Sisyphus/Sisyphus#668
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Part of #665. Builds on #667.
forecastscan now try the Chronos-Bolt kinds for each of many series, asforecastdoes for one:chronos-tiny,chronos-mini,chronos-smallandchronos-base. They are opt-in, need a node that runs containers, and go only to workers that offer the same pinned image (theforecast-chronos:<hash>label from #667).Who chooses each series' forecast
With Chronos-Bolt, a task no longer decides each series' forecast. For each series it returns:
Aggregatethen decides, from the result taken. The backtests are the best candidate of each kind written in Go, plus every Chronos-Bolt candidate.decideuses nothing else from the Go kinds: it takes the best candidate, or the median of the best of each of the best kinds. A test checks that the kept candidates choose exactly as all of them would.Two honest workers' Chronos-Bolt scores can differ in their last digits, and so can which candidate looks best. Choosing once, from one result, keeps that from becoming a disagreement between workers.
Lior, this differs from what we agreed on #665. There,
Comparere-derived the choice from each worker's scores. Deciding inAggregategives the same guarantee and is simpler: there is no choice forCompareto check, only numbers within a tolerance. It is also howforecastalready works. Are you happy with this?Comparing
forecastsnowVariesandCompares, series by series:forecast.compareCandidatesis shared withforecast.Since #669 (Lior's review items)
compareCandidates(xs, ys, seriesSize)measures every Chronos-Bolt field against max(size, largest |forecast|). The size must match exactly, along with every other field of the series apart from its candidates.forecaststoo.forecasts'Splitnow uses the samecannotRunChronosasforecast. A test caught that it still checked only for containers.Offers, the form and the runners already shared it throughf.forecast().TestManySeriesAreComparedEachAgainstItsOwnSizecovers:Executewrites each series' size;Other changes
outcomeOrderis factored out ofdecide, so thatkeptCandidatesranks a kind's candidates the same way.Registry.Offerslists a label once. Before,forecastandforecastsboth offered the image, so it was listed twice.Tests
forecastjob of it alone would, checked step by step.Aggregate. A series whose candidates all failed is counted as failed.dockerengine default, which the realimages test covers.Docs
docs/forecast-benchmark.mdexplains the coordinator's choice.forecastandforecastswith a Chronos-Bolt candidate are checked within a tolerance.I’m happy with the coordinator-side choice in
Aggregate. Given that candidate scores are compared within tolerance, choosing once from the accepted result avoids a second worker-specific choice at a near-tie boundary. I’ve updated my earlier note on #665 accordingly; the key invariant is that the chosen output comes from the same candidate-score payload that passed comparison, while the no-Chronos path stays byte-for-byte unchanged.Two review items remain before I’d consider this complete: (1) please verify Chronos is not advertised/selected when the owner’s memory confinement cap is below its 4 GiB requirement (the current capability appears gated by container availability, not that cap); and (2)
compareChronosshould use a scale appropriate to each compared field—using forecast-output magnitude to set the tolerance for scores/residuals can make valid cross-hardware differences fail for near-zero forecasts or large residuals. Could you add focused regression cases for both?/cc @rvnminers-A-and-N
Holding this until #669 lands. #669 fixes the two points Lior raised on #667. Afterwards I'll rebase this PR and make
forecastsgive each series' size too, so its Chronos-Bolt candidates are compared against their own series.Thanks for confirming the Aggregate choice. Both review items are fixed in #669, which is on
devforforecast:cannotRunChronosgatesOffers, the form choices and the runners on the owner's memory ceiling as well as on containers, with tests for nodes limited to 4095 and 512 MB.compareChronosmeasures every field against max(series size, largest |forecast|). There are regression tests for a near-zero forecast with large residuals and for a size that differs between outputs.Once #669 lands I'll rebase this PR.
forecastsgets the same gate for free, since it uses the sameForecastrunners. I'll also add a size for each series, so every series' Chronos-Bolt candidates are compared against their own series, with the same regression cases per series.Rebased onto
34aba6f(#669) as3f0c03e. Both of your #668 review items are now covered forforecaststoo:forecasts'Splitnow usescannotRunChronos. The new test caught it still checking only for containers.Offers, the form and the runners already shared the gate.TestManySeriesAreComparedEachAgainstItsOwnSizeis the regression case for both. I've updated the PR description to match.Reviewed the rebased change against the two follow-ups from #667.
forecastsnow uses the same memory-confinement gate asforecast, carries each series’ input-derived scale with its candidate backtests, compares candidates per series, and leaves the coordinator to choose once from the accepted result. The registry now wires container capability and confinement intoForecasts; regression coverage exercises multi-series choice, per-series scales and the low-memory path. The docs describe the new behavior. I found no remaining review blocker. The CI is still running, so please merge only after every required check is green./cc @rvnminers-A-and-N
The rebased #668 is now green: all 34 checks passed, including coverage, real-image tests, desktop E2E and packaging. My approval is in; it is ready for your squash merge.
/cc @rvnminers-A-and-N
@excho0 Thanks for the review. Squash-merged as
c32b53f; integration is synced and the R620 worker is on it. Next up is #670, the firstdev/batch of #633.