Skip to main content

Module bug

Module bug 

Source
Expand description

speccoder bug: the L2 rung. The person’s triad is recorded where the format keeps bugs (its own bug structure first, else its standing bug-fix unit), reproduced by a test-blind author — one test per stated behaviour, red on the untouched code by an assertion — confirmed by the person once, frozen, and fixed as an ordinary task whose verdict also needs the revert rejected. Nothing here is a second pipeline: the stages run inside speccoder run (pipeline::bug).

Re-exports§

pub use keep::keep;
pub use keep::keep_with;

Modules§

candidate
--candidate PATCH|pr:N: someone else’s fix, judged as the attempt — no implementer, no retries. A diff that touches a frozen reproduction, a held-out path or a judge input is refused before it is applied; one that does not apply is refused with the hunks git rejected.
confirm
The one confirmation: bound to the digest of what the person was shown, recorded with who, through what and on what basis, and turned into the fix’s pre-frozen acceptance set. A changed triad lapses it.
handoff
The hand-off of a bug that stopped before a fix, composed by the engine from what the tries recorded — never written by a model. The author’s last words appear only as a labelled claim.
keep
speccoder bug keep <unit>/<task> --reason R: a bug whose reproductions passed on the untouched code on every try (already_satisfied) is kept as a regression test — the reproductions the last try wrote are committed, and the task is accepted as attested, the commit naming the outcome. In a standing unit its task line is ticked; in the format’s own bug structure (bug:<slug>) nothing of the format’s is touched and the commit is the trailer-only task’s evidence.
named
--test PATH::NAME: the person’s own reproduction. It must exist, be collected and fail on the untouched code by an assertion, twice — checked before anything is written. Naming it is the confirmation.
state
What speccoder keeps of a bug: <project state>/bugs/<unit>/<task>/ — the bug (bug.json, the bug payload), its reproductions’ contents until they are confirmed (repro/), and the issue text and candidate diff it was recorded with (extra.json). Nothing here is in the format’s files.
unchanged
The pass-to-pass set, chosen deterministically once the attempt’s diff is known: baseline-green tests in test files that reference a changed source file (per toolchain), plus each Unchanged statement’s test. No model decides what counts as “nearby” (principle IV).

Structs§

Request
What the person asks for.

Functions§

bug
speccoder bug … with the configured model.
bug_with
bug() against state with provider (needed to record in a format’s own bug structure and to run).
confirm
speccoder bug confirm <unit>/<task> --digest D (or --reject): the person’s one decision on the reproductions shown; with run, the fix (or the next try) runs at once.
confirm_with
confirm() against state; provider runs what follows (none: only the decision is recorded).
held_out_warning
What a person confirming bug must know first: no held-out variant could be kept, so the fix cannot be verified.
run
speccoder bug run --task <unit>/<task> or --slug S, with the configured model.
run_bug
Runs the bug’s task (reproduce, or its confirmed fix) and answers with the bug.
run_with
run() against state with provider.
show
The bug named key, as speccoder keeps it.
shown
What a person is shown before confirming key in a terminal.