Repository navigation
Show an Experiment's cost before its first Trial, and ask (#1482) - #1505
Merged
Merged
Conversation
…xperiment (#1482) Addresses the Standards and Spec review of the cost question: the estimate sums a completed Trial's attempts as Arm minutes do, history reads through the Experiment Files seam, a declined new Experiment leaves no Prepared record, and the docs name the release Baseline probe and --yes in the release synopsis.
# Conflicts: # docs/guide.md # site/docs/index.html # site/how-it-works/index.html # src/evals/experiment/options.rs # src/evals/experiment/store.rs
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.
Summary
Before an Experiment runs its first Trial, it now prints what its remaining Trials will cost and, on a terminal, asks before going ahead. There is no cost ceiling in the Bar.
The total
Estimate:line appears only when every suite and Arm has history.scripts/release.shnow passes--yes, so--with-experimentstill asks only its own fail/inconclusive question.docs/guide.md(Experiments section, both synopses), the three hand-written site pages anddocs/code-navigation.mddescribe the question and--yes.site/docs/index.htmlis regenerated.Evidence
cargo test --test experiments cost::→ 5 failed. The Run never showedRun these Trials? [y/N]and ran its Trials straight away.After:
cargo test --test experiments cost::→ 8 passed. These tests drive the CLI through the fake Harnesses, on a pseudo-terminal where it matters:yruns both Trials;--yeson a terminal, and a piped stdin, skip the question2 of 6 Trials remain)estimate 5/10instead of10/20)tests/release/experiments.rsnow expects["experiment", "--release", <commit>, "--json", "--yes"]. Those tests run only on Linux, so CI covers them. On macOS,cargo test --test releasepassed.f17a0605):npm test --prefix sitepassed, andcargo test -- --test-threads=3passed (3162 passed, 0 failed). Under full default parallelism, four timing-bound unit tests in untouched modules failed:github::execution_tests×2,session::private::tests,evals::experiment::execution::tests. That is the host-load casedocs/testing.mddescribes (Experiment tests with 1s Trial timeouts fail under heavy local load on macOS #1472). Each passed when rerun alone.Merge Danger
Door: two-way
A new prompt and flag. Reverting removes them, and saved Experiments are unchanged.
Blast Radius: Experiments
Anyone who runs
thirdshift experimentfrom a terminal in a script without--yesnow gets a question. Piped stdin behaves as before. A declined new Experiment's folder is removed, but only when this same command created it, before any Arm build or Trial.Review
Reviewed with
thirdshift-code-reviewagainstmain. Standards raised 13 findings and Spec raised 5. The review read every changed file exceptsite/docs/index.html, which is generated:npm run docs:checkpassed, and its sourcedocs/guide.mdwas reviewed. The fixes made after the review also changedsrc/evals/experiment/store.rs(the newStored::discard), and the review did not read that hunk.Addressed: Standards 1 (history reads through the
Filesseam), 4 and Spec 1 (every attempt is counted; both tests kept), Standards 5 in part (Description::setup(arm)), 7, 8, 9, 12, 13; Spec 2 (docs now say the release Baseline probe comes first), 3 (a declined fresh Experiment is discarded; test kept), 4 (--release … [--yes]synopsis).Unaddressed findings
Standards
confirmcreates its terminal dependencies; there are no inline tests. Declined. The question's interface is the CLI, andtests/experiments/cost.rsdrives it on a real pseudo-terminal through the fake Harnesses, as the issue asks ("Tests drive the CLI through the fake Harnesses").Planneeds a stored Experiment. AnOutside-style seam would add an abstraction with one caller.historyduplicatesstore::list. Declined.store::list(src/evals/experiment/store.rs) propagates the first unreadable Experiment's error and loads each one throughStored::load, which refreshes legacy Verdicts.historymust skip unreadable Experiments, because one only narrows the estimate (cost.rs,historydoc comment), and must read metadata only (Stored::retained).Armswitches inexecution.rs,store.rsandgrading.rs; aDisplaylabel. Not changed. Those sites are outside this change, andcost.rsnow uses the newDescription::setup(arm).(suite, harness)tuple key. Declined: a private type alias in one module, used in one lookup. A key type would add more than it names.cargo run --quiet -- experiment HEAD 2>/tmp/cost.logfrom an interactive terminal) needs an interactive terminal, so this headless session could not run it.logs::beginis what keeps a declined Experiment out of the Inbox.Spec
Estimate:line, andyesaccepted as well asy. The reviewer judged neither worth undoing. Both are documented indocs/guide.md.Closes #1482
Built with claude 2.1.312 · default model · default effort
Security review outcome
No unaddressed introduced findings.