Exit 10

Run timeline

The study, phase by phase, from the first Flagsmith smoke test to the second experiment. Read from PROGRESS.md when this site was built. A phase counts as done only when its gate passes.

Phases

Each sign is one phase. The signal shows its state; the evidence is what passed the gate.

  1. Done

    Phase 1: Access: Flagsmith project + CLI login, LLM key, budget cap, VM approval, GitHub repo

    Gate evidence

    Flagsmith project fork-in-the-bill (id 56673, free plan) reachable through the Admin API; Haiku call succeeded ($0.000004, through harness/budget.py); BUDGET_USD_TOTAL=100 in .env; AWS VM approved; public repo created. CLI v2 needs a master API key or flagsmith login (rejects legacy user tokens)

  2. Done

    Phase 2: Flagsmith smoke test

    Gate evidence

    Managed warehouse enabled on Production, first event received 2026-11-26T18:52Z. Smoke flag fib_smoke (306164) with keyed variant treat, metric 720 (occurrence), experiment 713 started (running). 11 identities exposed, both variants served, conversions sent. Results API returned exposures and conversions per variant at 19:59Z (treat 4, control 4; saved in analysis/flagsmith/smoke/). The 3 identities tracked before the flush fix have no exposure, which confirms DECISIONS.md D9

  3. Done

    Phase 3: Task pools selected and validated

    Gate evidence

    exp1 and exp1b: 145 valid of 220 (tasks/validation_report.json); rollout 13 of 20; exp2 and exp2b validated as experiment 2 ran, 146 tasks run (D20, D26); exp3 validated as it ran, 125 of 183 tasks run

  4. Done

    Phase 4: Harness, runner, telemetry, ledger, cost; unit and replay tests; dry run 2 tasks per arm

    Gate evidence

    CI green; dry run runs/dryrun5-* (2 tasks per arm, forced policies, identical caps): control $0.147 + $0.083, both solved; lanes_v1 $0.053 solved + $0.033 unsolved; ledgers verify. Earlier dry runs found the dirty-work-tree patch bug (D15) and that the agent never delegated (D16-D18)

  5. Done

    Phase 5: Pilot

    Gate evidence

    runs/pilot-*, 9 tasks per arm, forced policies: control 5/9 solved at $0.114 mean, lanes_v1 4/9 at $0.072; ledgers verify (Merkle 4ab5f604…, d1f87905…). Report prereg/pilot-report.md, power analysis/out/power.json. One harness bug found and fixed (malformed tool arguments crashed the task)

  6. Done

    Phase 6: Prereg exp1, create and start experiment

    Gate evidence

    prereg/experiment-1.md sha256 44d715bd… in prereg/HASHES.txt, tag prereg-exp1 (annotated; signing key not available). Flagsmith experiment 822 created with the prereg hypothesis verbatim, started 2026-11-26T23:02:34Z; env snapshot 000-start shows the experiment segment at lanes_v1 50% (runs/exp1/env/)

  7. Done

    Phase 7: Main run

    Gate evidence

    runs/exp1: 145 analysed tasks, finished 11:54Z on 2026-11-27; ledger and assignments verify (make verify)

  8. Done

    Phase 8: Decision, End Experiment, same-flag rollout, fresh batch

    Gate evidence

    Decision in analysis/results.md; experiment 822 ended 12:05Z with lanes_v1 rolled out (D25); runs/rollout, 13 tasks

  9. Done

    Phase 9: Exp2 and exp3 prereg and run

    Gate evidence

    prereg/experiment-2.md, tag prereg-exp2; experiment 1423 ran 12:56Z to 20:58Z on 2026-11-27, 146 tasks; decided by the registered rule (keep lanes_v1) and ended in Flagsmith by analysis/decide.py (D30). prereg/experiment-3.md, tag prereg-exp3; experiment 1774 ran 19:26Z on 2026-11-28 to 00:51Z on 2026-11-29, 125 tasks; the rule shipped lanes_v1 again and analysis/decide.py ended it at 04:25Z (D31)

  10. Done

    Phase 10: Analysis, Merkle root, consistency gate

    Gate evidence

    analysis/out/numbers.json, analysis/results.md, secondary analyses (D29); check_consistency passes in CI

  11. Done

    Phase 11: Self-hosted portability demo, kit, board polish

    Gate evidence

    selfhost/README.md; the starter published as the template repository flagsmith-experiment-starter, whose e2e workflow boots it on a clean GitHub runner; npm packages forkbill 0.2.0 and forkbill-mcp 0.2.1 (approver read from the GitHub login); a Claude Code plugin (plugins/flagsmith-experiments) with the server and the skill; the read-only flagsmith-decision GitHub Action; e2e workflows for the approval example and the skill; board live at forkbill.prashantthakur.dev

  12. In progress

    Phase 12: README, video, rules check, submit

    Gate evidence

    README, paper and deck published (releases v0.1.0 to v1.0.0, signed provenance); the film (4:19, subtitles burned in) is on YouTube and linked from the README, SUBMISSION.md and the site; the person-approved rollout re-recorded with forkbill-mcp 0.2.1; outside-reader reviews acted on; experiment 4 (bigger fixes) registered as prereg-exp4 and running; submission by the owner

Milestones

Timed to the second, each read from a file or a tag in the repository when this site was built.

  1. Experiment 1 registeredtag prereg-exp1
  2. Experiment 1: first worker startedruns/exp1/meta.json
  3. Experiment 1: worker finishedruns/exp1/ledger.jsonl, the end snapshot
  4. Rollout batch: first worker startedruns/rollout/meta.json
  5. Release v0.1.0 publishedtag v0.1.0
  6. Rollout batch: worker finishedruns/rollout/ledger.jsonl, the end snapshot
  7. Experiment 2 registeredtag prereg-exp2
  8. Experiment 2: first worker startedruns/exp2/meta.json
  9. Release v0.2.0 publishedtag v0.2.0
  10. Release v0.3.0 publishedtag v0.3.0
  11. Experiment 2: worker finishedruns/exp2/ledger.jsonl, the end snapshot
  12. Experiment 2 decided by the registered rule and ended in Flagsmith by code: control staysruns/exp2/ledger.jsonl, the decision_applied record · Decision D30
  13. Experiment 3 registeredtag prereg-exp3
  14. Experiment 3: first worker startedruns/exp3/meta.json
  15. Release v0.4.0 publishedtag v0.4.0
  16. Experiment 3: worker finishedruns/exp3/ledger.jsonl, the end snapshot
  17. Experiment 3 decided by the registered rule and ended in Flagsmith by code: lanes_v1 shipsruns/exp3/ledger.jsonl, the decision_applied record · Decision D30
  18. Release v1.0.0 publishedtag v1.0.0

Flag history

Every change Flagsmith reported for this environment's flags, through a signed webhook. Who made a change is never stored, and flag values only as hashes.

readingReading what Flagsmith has reported, from the board's API.

The webhook was connected after experiment 2 ended, because nothing about the flag is touched while an experiment runs. For the runs themselves, the state of agent_routing is in each run's ledger, as hashed environment snapshots taken at the start, every 15 minutes and at the end.

Log

Dated notes from the run, oldest first.

  1. 2026-11-27Read Flagsmith experimentation, CLI, statistics and self-hosting docs; Python SDK 6.7 source checked for get_experiment_flag, track_event, flush_events, close, EventProcessorConfig. Model ids, prices and cutoffs pinned in harness/pricing.json (pricing page checked 2026-11-27). Dataset dates counted (see DECISIONS.md D1).
  2. 2026-11-27Smoke test found that SDK 6.7 drops the oldest buffered event with max_buffer_items=1; the runner now flushes after every event (DECISIONS.md D9). Metric enums confirmed from the API: aggregation count/sum/mean/occurrence, direction up/down/informational.
  3. 2026-11-27Flagsmith CLI v2 authenticated with a master API key; flagsmith project list shows fork-in-the-bill (phase 1 gate). flagsmith/setup.sh lanes_v1 created agent_routing (306193, value = control policy) with keyed variant lanes_v1 (37431), routing_kill (306194, off), and metrics task_cost 737, task_solved 738, task_turns 739, task_seconds 740. The SDK serves the control policy, it parses, and lanes_v1 differs from it only in delegate.model.
  4. 2026-11-27Kit verified on self-hosted Flagsmith 2.295.2 (selfhost/README.md, "Verified run"): 120 identities, 538 events stored with none lost, results returned. Accepted literals: expected_direction increase/decrease/not_increase/not_decrease; rollouts must list every variant.
  5. 2026-11-27Pools reselected with the final stratum (DECISIONS.md D10): pilot 12, exp1 140, rollout 20, exp2 100. Runner VM up (spot m7i.4xlarge, 1.5 TB gp3, AWS budget alarm $60); Docker Hub allows 100 anonymous pulls per hour from it. Validation running on the VM.
  6. 2026-11-27Pilot pool validation finished: 9 of 12 valid once a target test passing before the gold patch no longer disqualifies a task (upstream rule).
  7. 2026-11-27Pilot done; m = 20 points and N = the whole valid fresh pool (DECISIONS.md D19). Experiment 1 registered, created (822) and started; main run started with environment snapshots every 15 minutes (D21).
  8. 2026-11-27Validator VM filled its disk at 23:36Z (task images were not removed); restarted 03:56Z with --prune-images. Main VM unaffected.
  9. 2026-11-27Assignment check: all exp1 arms recomputed offline with Flagsmith's flag-engine 11.1.2 from runs/exp1/env/000-start.json match the arms served (72 of 72 at the time of the check; integrity/verify_assignment.py, run in CI for committed runs). Flags described in Terraform (infra/flagsmith/); make flags-drift reports no drift against the live project (6 resources). Kit verified in four evaluation modes and through OpenFeature on self-hosted Flagsmith (selfhost/README.md). Board receives signed Flagsmith webhooks; runner/health.py reports infra-only health of the routing flag.
  10. 2026-11-27Experiment 1 finished at 11:54Z (145 analysed tasks, ledger and assignments verified). Decision by the registered rule: ship lanes_v1. Experiment 822 ended at 12:05Z with lanes_v1 rolled out; the 13 valid rollout tasks ran on the same flag (D25). Paper, deck and release v0.1.0 published.
  11. 2026-11-27Experiment 2 registered (tag prereg-exp2, 12:53Z), created (1423) and started at 12:56Z on the pools exp2 and exp2b (D26, D27).
  12. 2026-11-28Experiment 2 analysed: lanes_v2 cut mean cost per task but solved fewer tasks, so cost per solved task rose; the registered rule kept lanes_v1. Applied in Flagsmith by analysis/decide.py at 18:59Z (D30).
  13. 2026-11-28Flagsmith environment webhook connected to the board (first delivery: fib_smoke switched off); smoke-test experiment ended and fib_smoke archived; agent_routing's description now records both experiments' registrations and decisions; new flag site_notice drives the site's notice sign.
  14. 2026-11-28Experiment 3 (replication of experiment 1 on 183 unused tasks) registered (tag prereg-exp3, 19:25Z), created (1774) and started at 19:26Z, with the flag's environment value set back to the control policy as registered.
  15. 2026-11-29Experiment 3 finished at 00:51Z (121 analysed tasks, ledger and assignments verified). Decision by the registered rule: ship lanes_v1, the same as experiment 1, so the replication succeeded. Applied in Flagsmith by analysis/decide.py at 04:25Z; fresh identities receive lanes_v1, and the policy is again the flag's own value (D31). Pooled exp1 + exp3 estimates added as secondary (replication in numbers.json).
Part 2

Design decisions

Every choice made while building and running the experiments, with the reason. Quoted in full from DECISIONS.md.

Task pools: fresh tier for experiment 1, newest pre-cutoff tier for the rest

All three candidate models (Claude Opus 5.5, Sonnet 5.5, Haiku 5.5) have a June 2026 training-data cutoff (models overview, checked 2026-11-27). Counted on 2026-11-27 from the Hugging Face parquet exports:

SourceCreated ≥ 2026-07-01Created 2026-03-01 to 2026-06-30
SWE-bench-Live/MultiLang (c, cpp, go, js, rust, java, ts, cs)231423
SWE-bench-Live/SWE-bench-Live (Python, full)0 (latest is 2025-04)0
nebius/SWE-rebench-leaderboard 2026_030110
nebius/SWE-rebench-V20 (latest is 2025-10)0

The fresh tier can't fill three disjoint pools of several hundred tasks each. So:

  • Experiment 1 (the headline) uses every task in the fresh tier that passes validation. Every task in the headline result was created after every model's training cutoff.
  • Pilot, experiment 2 and the rollout batch draw from the newest pre-cutoff tier. This is disclosed in the README limits section, and created_month is recorded as a trait.
  • N per arm comes from analysis/power.py on pilot data, bounded by the fresh pool size. If that falls below the original target of 250 per arm, the prereg states the smallest solve-rate drop the experiment can detect, rather than claiming more than it can.

Contamination doesn't bias the arm comparison much, since both arms use the same main-lane model, but it does inflate absolute solve rates. That's why the fresh tier carries the headline.

Back to the index

No `temperature`; arms share effort and thinking settings instead

The Messages API rejects temperature, top_p and top_k on every model, and Opus 5.5 can't turn thinking off. The clean-A/B control is therefore: identical output_config.effort per lane, adaptive thinking (the model default, never configured differently per arm), identical prompts, tools, tool order, caps and harness code. RoutingPolicy.clean_ab_diff checks that the two flag values differ only in delegate.model, and flagsmith/setup.sh refuses to create a variant that differs in anything else.

Back to the index

No server-side refusal fallback

The API offers a fallback that re-runs a refused request on another model inside the same call. That would silently change which model did the work in one arm, so it's off. A refusal ends the task as agent_error. Agent errors are never excluded, so refusals count against the arm that produced them.

Back to the index

The delegate has its own short tool loop

At first the delegate answered only from files preloaded into its prompt. Grunt work that's worth delegating (finding call sites, running a test suite, reading a build log) needs a shell, so the delegate gets read-only use of bash in the same container, up to 12 turns, and still returns the {summary, findings[], confidence} JSON. The main lane never sees the delegate's transcript. The setup is identical in both arms.

Back to the index

Kill switch tasks carry no exposure

routing_kill is read with get_identity_flags (no exposure). When it's on, a task runs the control policy, sends no exposure and no events, and is logged to the ledger as kill_switch. That keeps the experiment's data free of tasks the runner forced into one arm.

Back to the index

Global spend cap by reservation

harness/budget.py reserves each call's worst-case cost before the call, using an atomic Lua script in Redis or a file lock locally, and settles it to the real cost afterwards. A reservation that would exceed the cap is refused, so a crash or bug can only make the cap stricter, never looser.

Back to the index

Per-task cap checked before each call

The per-task dollar cap is checked before every model call in both lanes. A task can therefore end slightly above the cap by at most one call's cost, and the same rule applies in both arms. The full real spend is reported as task_cost.

Back to the index

$100 total model budget: Sonnet 5.5 as the frontier model, smaller and easier pools

The whole study has a hard $100 cap on model spend (BUDGET_USD_TOTAL=100), with per-phase allowances (BUDGET_USD_PILOT, BUDGET_USD_EXP1, ...) enforced inside it by harness/budget.py. Opus 5.5 everywhere would cost too much per task to clear Flagsmith's floor of 50 identities per arm in two experiments. So:

  • Model pair: Claude Sonnet 5.5 ($2 in / $10 out per MTok) as the frontier lane, Claude Haiku 5.5 ($0.10 / $0.50) as the small lane, a 20x price gap. Still a frontier-vs-small comparison, at a price that fits.
  • Caps: 40 turns, $0.60 and 20 minutes per task, identical in both arms.
  • Difficulty stratum: pools are restricted, before any run, to tasks whose gold patch touches one or two files and at most 40 changed lines. This raises the solve rate a mid-tier model can reach under a tight cap, which the original plan called for as the fallback if solve rates were near zero. The filter is recorded in tasks/pools/manifest.json and in the prereg, and the README states the result applies to this stratum.
  • Power: with roughly 70 tasks per arm, a guardrail margin of 5 points can't be verified. The analysis fixtures suggest that needs about 800 per arm. The prereg sets m from the pilot and power simulation, and states the detectable drop plainly.
Back to the index

Flush after every exposure and event

Flagsmith's docs recommend EventProcessorConfig(max_buffer_items=1) for short-lived processes. In the Python SDK 6.7, a full buffer drops its oldest event when another is tracked before the first has been sent. The smoke test on 2026-11-27 logged "Event buffer was full: dropped the 2 oldest events" when an exposure and a conversion were tracked back to back. The runner keeps max_buffer_items=1 and calls flush_events() after the exposure and after each conversion event. A rerun with eight identities had no drops and served both variants. The worker calls close() on exit.

Back to the index

Final difficulty stratum: at most 3 files and 60 changed lines, C++ included

With the first stratum (at most 2 files, 40 lines, no C++), only 92 fresh tasks qualified, which is 46 per arm and below Flagsmith's floor of 50 identities per arm before validation drops any. The final stratum allows the gold patch to touch at most 3 files and 60 changed lines, keeps problem statements under 12,000 characters, and includes C++ (the runner VM has 64 GB of RAM). Selected with seed 20261127 from the pinned dataset revision recorded in tasks/pools/manifest.json:

PoolTasksTier
pilot12created 2026-03-01 to 2026-06-30
exp1140created on or after 2026-07-01 (every fresh task in the stratum)
rollout20created 2026-03-01 to 2026-06-30
exp2100created 2026-03-01 to 2026-06-30
reserve74SWE-rebench 2026_03, Python

Pool files are stored as gzip with a fixed timestamp, so the same seed produces byte-identical files.

Back to the index

Grading runs with network access; the agent's container does not

The agent works in a container with networking disabled. Grading happens afterwards, in a fresh container built from the same image, with networking on, as the official SWE-bench-Live harness does: many rebuild steps download dependencies, and some PASS_TO_PASS tests (for example c-ares' DNS tests) make live lookups. Because grading starts from a clean container after the agent has finished, network access during grading can't help the agent.

Back to the index

How Flagsmith computes the verdict, and how our replication differs

Read from Flagsmith's open-source api/experimentation/stats.py and results_query.py, then checked against a Cloud response. For each metric and variant the warehouse returns n, sum and sum_squares over exposed identities. It counts only events at or after an identity's first exposure. Inference is a normal approximation to the relative lift (delta method). chance_to_win is the normal probability that the lift is above zero, flipped for metrics whose direction is down. The 95% interval is lift ± 1.96 standard errors. The SRM p-value is a chi-square test.

Our replication deliberately uses different methods: a percentile bootstrap for mean cost, and Beta(1,1) posteriors for solve rate. Agreement between the two is therefore evidence that the result isn't an artefact of one statistical method. analysis/pull_results.py parses the documented shape, and numbers.json reports both results side by side.

Back to the index

Runner VM: on-demand r7i.2xlarge

The first runner was a spot m7i.4xlarge. AWS reclaimed it about 15 minutes into validation and the in-progress work was lost. An on-demand 16-vCPU replacement exceeded the account's 16-vCPU on-demand quota, half of which other instances already use. The runner is now an on-demand r7i.2xlarge (8 vCPU, 64 GB, about $0.53 an hour in us-east-1, estimated) with a 1.5 TB gp3 volume, so validated images stay cached for the runs. Results are copied off the VM every 5 minutes.

Back to the index

New files the agent creates are part of its patch

The SWE-bench-Live README collects a prediction with git diff HEAD, which leaves out untracked files. A fix that adds a source file would then be graded without it. The runner runs git add -N . first, which marks new files without staging their content and respects .gitignore, so they appear in the diff. This applies identically to both arms. Validation uses the dataset's gold patches and is unaffected.

Back to the index

The agent's patch is measured from the container's starting state

The SWE-bench-Live images ship with a dirty work tree: test reports and other files left by the image build, and sometimes edited tracked files. Collecting the agent's patch with git diff HEAD swept these in. In the dry run that produced a 27 MB patch that failed to apply at grading. When a task container starts, the runner commits its state as a local baseline and records which files were untracked build output. The agent's patch is its diff against that baseline, including files it created. Build-output files are left out even when the agent's test runs rewrite them. Grading starts a fresh container from the same image, which is in the same starting state, so the patch applies cleanly. Covered by tests/integration/test_baseline_diff.py.

Back to the index

Delegation is the expected way to do grunt work

In the dry run the main lane never called delegate in four tasks. The two arms differ only in the delegate lane's model, so without delegation they would be identical. The shared main-lane prompt now states that the main lane's context is the expensive resource. It tells the agent to delegate surveys, long reads and test runs, starting with a survey of the code the issue touches, and to use bash itself only for small, targeted checks. Both arms get the same prompt. The pilot measures the delegate share of tokens and cost before the prereg is fixed.

Back to the index

The main lane sees short tool output; long output goes through the delegate

The stronger prompt (D16) still produced no delegation: the main lane read files and ran builds with its own bash. The harness now enforces the two-lane design in both arms. The main lane's bash returns only the first and last 1 KB of output, and its tool description says so. The delegate's bash returns up to 16 KB. Short checks still work in the main lane. Reading long files, searching widely and digesting test or build output are delegated, which is the grunt work the experiment routes to a cheaper model.

Back to the index

Planner and worker: the main lane has no shell

Even with its shell output cut to 1 KB (D17), the main lane still delegated nothing. It switched to tighter sed -n and grep | head commands. Two identical arms would measure nothing. The harness now uses the orchestrator/worker split that many coding agents use, identically in both arms:

  • Main lane (planner). Tools are view_file (up to 150 numbered lines of one file), edit_file, delegate and submit. It decides what to change and writes the change.
  • Delegate lane (worker). Has bash (16 KB of output) in the same container. All searching, surveying, building and test running goes through it, and it returns JSON findings.

The experiment's question is unchanged: whether the worker can be a small model without the planner solving fewer tasks. D17's main-lane bash cap no longer applies, because the main lane has no bash.

Back to the index

The guardrail margin is 20 points, because the fresh pool is small

N was meant to come from the power analysis, but it is capped by supply: every task in the fresh tier (created after the models' cutoff, inside the stratum) is already in the exp1 pool, and about 62% of them validate. That gives about 43 tasks per arm. With those numbers, analysis/power.py on the pilot shows:

  • the cost question is well powered: 95% power at the pilot's 37% cut;
  • the solve-rate guardrail is not: only a drop of about 25 points is detectable.

A 5-point margin would fail almost every time, even for an arm that is truly as good as control, so the experiment would decide nothing. The prereg uses m = 20 points, which an equal arm passes 77% of the time at this N. It also states plainly that smaller solve-rate losses cannot be ruled out. Adding older tasks would raise N but bring back the contamination risk that D1 avoids.

Back to the index

Tasks are enqueued as they pass validation

Validating a task means building it and running its tests with the gold patch. That takes from one minute to an hour, and a full pool takes many hours across two machines. The runner's --valid-report mode enqueues each task once any validation report marks it valid, and it keeps polling until every pool task has a verdict. This is sound because validation never involves a model or an arm, so the order in which tasks enter the queue tells us nothing about either arm. Every enqueue batch is written to the ledger.

Back to the index

Environment snapshots

integrity/snapshot_env.py saves the Flagsmith environment document at the start of the run, every 15 minutes during it, and at the end. It removes the organisation and project names first, and it writes each snapshot's SHA-256 and a summary of the routing flags to the run's ledger. If the flag or the split changed mid-run, the snapshots would show it.

Back to the index

Experiment 1 grows by amendment to clear Flagsmith's 50-per-variant floor

Flagsmith reports no inference for a metric until each variant has 50 identities (RESULTS_MIN_IDENTITIES_PER_VARIANT in the Flagsmith API source). The fresh pool would give about 43 per arm, so the decision rule's Flagsmith condition could never pass. prereg/experiment-1-amendment-1.md adds the next 80 pre-cutoff tasks from the same seeded order. It was written after three tasks had finished, and before any result per arm had been seen. The fresh tier is still reported on its own. Experiment 2 is sized from the start to clear the floor.

Back to the index

Flags as code are read-only during an experiment

infra/flagsmith/ describes the flags, the lanes_v1 variant, the environment defaults and the experiment's segment override as Terraform, but it is only ever planned, never applied. An apply in the middle of a run would publish new feature-state versions on the flag the experiment is splitting, and could reset parts the provider cannot express (the variant key and the per-segment weights) that the CLI scripts set. So the scripts in flagsmith/ stay the only writers, and make flags-drift runs a read-only plan that must report no changes. Each check can be appended to the run's ledger as a config record with the plan's hash, so the ledger shows that the flag configuration matched the committed code during the run.

Back to the index

The live board shows running totals per arm

The board at https://forkbill.prashantthakur.dev went live at 05:55Z on 2026-11-27, with exp1 89 tasks in. From then on it shows each arm's tasks, solves and spend as the run goes, so the operator sees interim figures too. This can't move the result: the decision rule, the margin, the pools and the stopping rule (every task in both pools done, excluded or invalid) are fixed in the registration, and there is no early stop. The verdict section stays empty until the analysis script runs at the end.

Back to the index

Ending experiment 1 and making the winner the flag's own value

Experiment 822 was ended through the API at 12:05Z on 2026-11-27 with rollout_decision=variant and rollout_variant set to the lanes_v1 option (POST .../experiments/822/complete/). Flagsmith applies that by setting the variant's weight to 100% on the environment default and removing the experiment's segment override, so the flag served the lanes_v1 policy to every identity through a variant weight. The rollout batch ran in that state.

Before experiment 2 was created, the environment value of agent_routing was set to the lanes_v1 policy itself and both variant weights to 0 (flagsmith flag update agent_routing --value ... --weight lanes_v1=0,lanes_v2=0). Every identity got the same policy before and after; the change makes the rolled-out winner the flag's own value, which is what experiment 2's control arm is. No experiment was running at the time. flagsmith/create_experiment.sh now checks the template's control value against the environment value instead of the project default, because after a rollout the two differ.

Back to the index

Experiment 2's pool reaches back before March 2026

The 100-task exp2 pool would have given about 30 valid tasks per arm, below the 50 identities per variant Flagsmith needs before it shows a verdict (D22). exp2b adds 110 tasks: the 58 pre-cutoff tasks left after exp1b, then 52 tasks created before 2026-03-01, drawn in a separately seeded order from the same stratum. Older tasks are more likely to have been seen in training. Assignment is random, so that affects both arms alike, and created_month is reported per arm. The pool was fixed in prereg/experiment-2.md before the first task ran.

Back to the index

A three-task dry run of `lanes_v2` before registration

The draft-review path had never run end to end, so lanes_v2 ran on 3 pilot tasks outside any experiment (runs/dryrun-lanes_v2) before experiment 2 was registered. All three ran to grading and none was solved. The registration was written with that known; the tasks are in no experiment pool and enter no analysis.

Back to the index

Environment snapshots keep the client-side environment key

Each snapshot under runs/<exp>/env/ is the Flagsmith environment document, and it contains the environment's client-side key in api_key. Flagsmith treats that key as public: it is the one a browser uses to evaluate flags. It is also an input to the bucketing hash, so integrity/verify_assignment.py cannot re-derive an arm without it. It therefore stays in the published snapshots, and .gitleaks.toml allows exactly that field in exactly those files. Server-side keys (prefix ser.), the admin API key and every other credential stay in .env and CI secrets only.

Anyone holding a client-side key can send identities and events to the environment, as with any public web app. If that happened during a run, Flagsmith's exposure counts and means would stop matching our own ledger; the agreement check in analysis/results.md (our mean cost against Flagsmith's, per arm) is there to show it.

Back to the index

Secondary analyses added after experiment 1 ended

Four analyses were added on 2026-11-27, after experiment 1 had ended, been decided and been rolled out. None of them is in a registration. They are secondary robustness readings: the registered decision for experiment 1 was made by the rule in prereg/experiment-1.md and stands whatever they show, and the same holds for experiment 2, which was registered before they were written. Each runs for exp2 too once runs/exp2 is committed. Their figures go into analysis/out/numbers.json under <exp>.secondary, frontier and integrity.proofs, and from there into the documents through markers.

When they were written, experiment 1's final readout was already public, by-tier figures included. The running totals had also been on the board during the run, so the order in which results came in was not unknown to the project; that is why the always-valid test takes its only tuning constant from the pilot and not from experiment 1. One count disagrees with an earlier entry: D24 says the board went public at 05:55Z with 89 tasks in, but the exp1 ledger has 94 task_done records before 05:55Z. The always-valid analysis takes the time from D24 and the count from the ledger.

  1. Always-valid p-values (analysis/always_valid.py). The board showed running totals while experiment 1 ran (D24), so the question is what someone watching it could have concluded at any point. The mixture sequential probability ratio test of Johari et al. (2017), with a normal mixing distribution, is replayed in the order tasks finished, for the difference in mean cost per task and for the difference in solve rate. The mixing scale tau was fixed from the pilot runs alone, in code and in this entry, before the experiment 1 trajectory was computed: tau is the absolute difference between the pilot's two arms (lanes_v1 minus control) in mean cost and in solve rate. Nothing is evaluated until each arm has 10 analysed tasks, because the test plugs in a running variance estimate; on simulated null data with skewed costs, starting at two tasks per arm crossed the 0.05 line well over 5% of the time, and starting at ten keeps it under 5% (tests/unit/test_always_valid.py checks this). Experiment 2 uses the same pilot tau.
  2. Cost against solve rate for every arm (analysis/frontier.py), following Kapoor et al. (2024): the pilot arms, both arms of experiment 1, the rollout batch and the experiment 2 arms when they exist, each with bootstrap intervals, and the arms no other arm beats on both axes marked. Dry runs are left out: they have two or three tasks each and ran on a harness that changed between them (D16 to D18). The batches use different task pools, so a comparison across batches describes them and tests nothing.
  3. Merkle inclusion proofs (integrity/merkle.py, integrity/prove.py). Any one task_done record can be shown to be under the published root with a short audit path, as in Certificate Transparency. The tree rule is the one already published (raw leaves, an odd node paired with itself), which is not RFC 6962's rule; the root does not change.
  4. A specification curve (analysis/multiverse.py), after Gelman and Loken (2013). The two decision quantities, the change in cost per solved task and the guardrail posterior P(Δsolve > −m), are recomputed for every combination of five choices an analyst could reasonably have made differently: task set (all, fresh tier, pre-cutoff tier), which attempt of a repeated identity is kept (last, first), the cost statistic (mean, median, 10% trimmed mean), the solve-rate prior (Beta(1,1), Beta(0.5,0.5)) and cost outliers (as recorded, winsorised at the pooled 99th percentile). The by-tier section had already shown that the guardrail falls below its bar on the fresh tier alone, so the curve was expected to fail there, and it is reported either way.
Back to the index

The registered rule, not a person, ends the experiment

Experiment 1 was ended by hand with the CLI after reading the decision (D25). For experiment 2 the same step is code: analysis/decide.py reads the decision analysis.analyse computed from Flagsmith's verdict and the registered thresholds, refuses to act if the registration file no longer has the hash the analysis was computed against or if the Flagsmith experiment is not running, sends End Experiment with the rollout decision the rule chose, reads the experiment back and appends a decision_applied record (with the Flagsmith response and the hash of numbers.json) to the run's hash-chained ledger. Experiment 1423 was ended this way at 18:59Z on 2026-11-28 with control as the rollout decision. A dry run without --apply shows exactly what would be sent.

Experiment 2's worker finished at 20:58Z on 2026-11-27; the result was pulled, analysed and applied the next evening. The flag served the lanes_v1 policy throughout that gap, because the experiment's split only ever routed identities the runner sent, and no task ran after the pool was exhausted.

Back to the index

Experiment 3 decided and rolled out by the same script; the winner made the flag's value again

Experiment 3 (Flagsmith experiment 1774, registered as prereg-exp3) finished its pool at 00:51Z on 2026-11-29. The run was copied home, its ledger and every assignment were verified, Flagsmith's results were pulled and saved raw, and analysis.analyse computed the registered decision: ship lanes_v1, the same answer as experiment 1, so the replication succeeded by the registration's own definition. uv run python -m analysis.decide --exp exp3 showed the request it would send, and --apply ended the experiment at 04:25Z with rollout_decision=variant and the lanes_v1 option, then appended the decision_applied record to runs/exp3/ledger.jsonl. Three fresh identities evaluated on the Edge API afterwards all received lanes_v1. The record's numbers_sha256 is the hash of analysis/out/numbers.json as decide.py read it. That file is not in git: make analyse was run again right after the apply so that the integrity counts include the new ledger record, and every regenerated file has a new generated_at. The fields the decision used (ship, rule_met, Flagsmith's chance, the registration's hash) are written into the ledger record itself and equal the committed file's.

Flagsmith carries out a variant rollout by setting that variant's weight to 100% on the environment default (D25), so the environment-level value, which the site's routing badge reads, still said control. As after experiment 1 (D25), the lanes_v1 policy was then made the flag's own value with both variant weights at 0 (flagsmith flag update agent_routing --value <flagsmith/policies/lanes_v1.json> --weight lanes_v1=0,lanes_v2=0). Every identity receives the same policy before and after; only the environment-level reading changes. No experiment was running.

The registration announced pooled estimates across experiments 1 and 3, labelled secondary. They are computed in analysis/analyse.py (replication in numbers.json) by putting both experiments' tasks into one sample per arm, and drawn in analysis/charts/replication.png. The two pools differ in task age, so the pooled figures summarise the evidence and decide nothing.

Back to the index

The routing-only snapshot hash

The environment snapshots taken through a run were first compared by hashing each whole document, and one distinct hash was read as "the flag and the split never changed". The document also holds flags that have nothing to do with assignment. During experiment 3 the site_notice text was edited at 19:58Z on 2026-11-28 (ledger record 45 is the first snapshot that shows it), so that run has two distinct whole-document hashes. analysis/analyse.py now also hashes only what decides a task's arm: the environment value, enabled state and variant weights of agent_routing and routing_kill, and every segment override of those two flags with the segment's rules (routing_config_digest). Every committed run has exactly one routing hash across all its snapshots (integrity.by_experiment.<run>.routing_config_distinct_hashes), including experiment 3. The site shows both counts. The whole-document count is kept as it was, because a change to any flag is still worth seeing.

Back to the index

What Flagsmith costs per task, measured after the study

A reader weighing Flagsmith as the assignment layer will ask what it costs a task. That was not measured during the runs, so after experiment 3 ended analysis/flag_latency.py timed it from one client against the study's own environment: environment flags over the Edge API, one identity with its traits through the Python SDK (the runner's call), and local evaluation with Flagsmith's flag-engine after one environment-document fetch, with a check that local and remote evaluation give the same answer. analysis/analyse.py sets the newest measurement against the committed tasks' own duration and cost (flagsmith_overhead in numbers.json). It is labelled as measured after the study from one client, it is not part of any registered analysis, and it changes no decision. The benchmark identities (latency-bench:*) exist in the environment because Flagsmith creates an identity on first read; they sent no events.

Back to the index

A real agent ran the skill after the judge pass

An outside review on 29 November marked Track 04 down because its demo was a script and its token baseline was written by us. So a real agent was run on the same job: skills/flagsmith-preregistered-rollout/agent-run/agent.py gives Claude Sonnet 5.5 (effort medium, prompt caching on) SKILL.md as its system prompt and one allowlisted bash tool, against a fresh self-hosted Flagsmith, in an application repository built like the demo's, with the demo's flag, variant, metrics, hypothesis and thresholds. The harness answered as the operator, exactly as the demo's operator did: yes to each plan id the skill printed, --by "demo operator" and the environment name Demo typed; it played the same simulated traffic after the start and made the stand-in code change when the agent asked. Every API call's usage was recorded and priced with harness/pricing.json, with the global cap enforced through harness/budget.py (set to $76.65, the $100 cap less the study's spend, because the runner's ledger went with the VM) and a per-run cap of $5. The first attempt stopped on a harness bug after step 8 and is kept with its cost from the ledger (its per-call usage was lost, and the harness now writes it as it goes). The second completed all nine steps. The figures are in numbers.json as skill_agent_run; nothing in the skill was changed between the runs.

Back to the index

Experiment 4 asks experiment 1's question on bigger fixes

Experiment 4 (prereg/experiment-4.md, tag prereg-exp4, Flagsmith experiment 2859) runs experiment 1's arms, metrics, margin and rule on 200 tasks the registered stratum left out for size: a gold patch of 4 to 6 files, or 61 to 250 changed lines, disjoint from every earlier pool (tasks/select_tasks.py --exp4-large). As for experiment 3 (D31), the flag's own value was set back to the all-Sonnet control policy with both variant weights at 0 before the experiment was created, at 10:53Z on 2026-11-29; no experiment was running. The run uses a spot runner (r7i.2xlarge) and the validator VM, and a spend cap of $14 for the phase (BUDGET_USD_EXP4), which the registration names as a stopping condition. This work lives on the branch exp4-bigger-bugs and is not merged into main until the hackathon's judging has ended.

Back to the index