Expand description
The result contract optimization.result/0.2: outcomes with claims and
evidence, the result journal, and the manifests the runner builds from it
(the guide’s section Results and durable recovery).
Structs§
- Certificate
- A proof of a claim and the verdict of the checker that judged it.
- Evidence
- How much of a claim was verified, and how.
- Objective
Bounds - The objective of the best feasible point and a proven bound on the optimum.
- Outcome
- What a worker reports for one task: why it stopped, what it claims and how
the claim is supported.
Outcome::checkenforces the contract’s rules. - Record
- One committed task in the result journal
results.jsonl. - Refutation
- A claim of the solver that an independent check rejected.
Constants§
- BOUND_
TOLERANCE - Relative tolerance of the objective-bound rules of
Outcome::check: two objective valuesaandbagree, and a dual bound may lie beyond the primal bound, by at mostBOUND_TOLERANCE * max(1, |a|, |b|). Workers with tighter tolerances decide more strictly on their own and keep a rejected value indetails. - CHECKS
- Properties a worker recomputes independently of the solver.
- CLAIMS
- Every claim. A claim states what the worker asserts about the task’s
answer;
evidencestates how much of that was verified. - LEVELS
- Evidence levels, weakest first.
- SCHEMA
- Result manifests written by this build.
- SCHEMAS
- Result manifests
comparereads. A 0.1 manifest is a valid 0.2 manifest without evidence, objective bounds or the claims added in 0.2. - VERDICTS
- Why an independent check refuted the solver’s claim; the solver competitions’ wrong-answer categories.
Functions§
- compare
- Sets result manifests side by side. All must use a schema of
SCHEMAS, the same payload schema and the samespec_digest; manifests of the legacy format go tolegacy::result::compare. The answer lists the arms and warnings and names no winner. - counts
- The work counters of
records, summed per name; an overflow is an error. - manifest
- The result manifest
run.jsonof the attempt indir, built from its journal and its artifacts. Withcompletefalse, the work is not fully accounted for:workis null and onlyknown_work_lower_boundis given. - objectives_
agree - Whether objective values
aandbagree withinBOUND_TOLERANCE. - progress
- The progress of a running attempt: its completed tasks, its known work and its artifact index.
- repair
- Replays the journal of the attempt in
dir, then ends a torn final line: a valid record gets its newline, anything else is removed. An invalid earlier record is an error, and the journal stays unchanged. - replay
- The result journal of the attempt in
dir, ordered bytask_id; empty without a journal. Each record must have a task ID belowtask_countand not seen before, the job’s digest, a finite nonnegative time, safe counter names and an outcome that passesOutcome::check. An incomplete final line is ignored; any other invalid record is an error. - unreadable_
manifest - The manifest of an attempt whose journal cannot be replayed (a corrupt or
invalid record before its final line). No record is trusted, so there are
no results and no work totals;
runner.journal_errorsays why. - worker_
outcome - The status and elapsed time from the worker’s own
run.jsonindir, if it can be trusted: it belongs to this job, its accounting is complete, its status is terminal, and its results and work equal the journal’s. OtherwiseNone. Acompletedmanifest without all tasks, or an invalid elapsed time, is an error.