From 6496c8e813a155674339dbd05109902b3e0a6028 Mon Sep 17 00:00:00 2001 From: Branimir Georgiev <66906831+braboj@users.noreply.github.com> Date: Sun, 1 Nov 2026 17:23:25 +0200 Subject: [PATCH] docs(decisions): move chapter 9's log into decision records Each topic of the decision log becomes a record under docs/decisions/, with the decision as it holds today and a History table keeping every dated row of the log. Chapter 9 now groups the records, and links that pointed into the log point at the record that settles them. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01DpT5xPFWEQr1bipxbbKBRF --- .../architecture/01-introduction-and-goals.md | 2 +- docs/architecture/06-runtime-view.md | 6 +- .../architecture/09-architecture-decisions.md | 156 +++++++++--------- docs/decisions/001-the-app-under-test.md | 50 ++++++ docs/decisions/002-the-arms.md | 49 ++++++ docs/decisions/003-k-blocks-and-escalation.md | 64 +++++++ docs/decisions/004-the-builder-models.md | 41 +++++ docs/decisions/005-the-judge.md | 57 +++++++ docs/decisions/006-the-hidden-suite.md | 37 +++++ docs/decisions/007-the-baseline.md | 50 ++++++ .../008-the-brief-and-the-build-prompt.md | 68 ++++++++ docs/decisions/009-the-change-task.md | 48 ++++++ docs/decisions/010-trial-bounds.md | 31 ++++ docs/decisions/011-html-validity-and-size.md | 50 ++++++ .../012-security-and-data-protection.md | 62 +++++++ .../013-what-the-report-opens-with.md | 38 +++++ docs/decisions/014-no-human-holdout.md | 35 ++++ docs/decisions/015-contrasts-and-verdicts.md | 36 ++++ ...016-anchors-control-fixture-and-repeats.md | 52 ++++++ docs/decisions/017-a-rounds-registration.md | 38 +++++ docs/decisions/018-the-security-probes.md | 55 ++++++ .../019-archive-before-the-report.md | 42 +++++ docs/decisions/020-trial-isolation.md | 67 ++++++++ docs/decisions/TEMPLATE.md | 68 ++++++++ docs/journeys/check/archive-and-report.md | 2 +- docs/journeys/prepare/generate-the-arms.md | 2 +- docs/journeys/read/re-read-an-old-round.md | 4 +- docs/journeys/run/run-a-round.md | 2 +- 28 files changed, 1126 insertions(+), 86 deletions(-) create mode 100644 docs/decisions/001-the-app-under-test.md create mode 100644 docs/decisions/002-the-arms.md create mode 100644 docs/decisions/003-k-blocks-and-escalation.md create mode 100644 docs/decisions/004-the-builder-models.md create mode 100644 docs/decisions/005-the-judge.md create mode 100644 docs/decisions/006-the-hidden-suite.md create mode 100644 docs/decisions/007-the-baseline.md create mode 100644 docs/decisions/008-the-brief-and-the-build-prompt.md create mode 100644 docs/decisions/009-the-change-task.md create mode 100644 docs/decisions/010-trial-bounds.md create mode 100644 docs/decisions/011-html-validity-and-size.md create mode 100644 docs/decisions/012-security-and-data-protection.md create mode 100644 docs/decisions/013-what-the-report-opens-with.md create mode 100644 docs/decisions/014-no-human-holdout.md create mode 100644 docs/decisions/015-contrasts-and-verdicts.md create mode 100644 docs/decisions/016-anchors-control-fixture-and-repeats.md create mode 100644 docs/decisions/017-a-rounds-registration.md create mode 100644 docs/decisions/018-the-security-probes.md create mode 100644 docs/decisions/019-archive-before-the-report.md create mode 100644 docs/decisions/020-trial-isolation.md create mode 100644 docs/decisions/TEMPLATE.md diff --git a/docs/architecture/01-introduction-and-goals.md b/docs/architecture/01-introduction-and-goals.md index 3ddb7ac..df03324 100644 --- a/docs/architecture/01-introduction-and-goals.md +++ b/docs/architecture/01-introduction-and-goals.md @@ -47,7 +47,7 @@ What it is not: | 06 | Judge | Scores each trial blind, three times, on an anchored rubric, and checks every quoted line | [ch. 8.6.6](08-crosscutting-concepts.md), [ch. 8.6.7](08-crosscutting-concepts.md) | | 07 | Check the judge | Builds damaged and improved trees that a working judge must tell apart | [ch. 8.6.7](08-crosscutting-concepts.md) | | 08 | Report | Pairs trials, computes intervals and verdicts, owes or refuses the escalation, and prints the report | section 1.4, [ch. 8.7](08-crosscutting-concepts.md) | -| 09 | Archive | Copies a round's raw data to a private store, restores it and checks the figures match | Ch. 9 | +| 09 | Archive | Copies a round's raw data to a private store, restores it and checks the figures match | [ADR-019](../decisions/019-archive-before-the-report.md) | | 10 | Reuse | Copies an earlier round's trials into a new run root, with their readings | [ch. 4.2](04-solution-strategy.md) | ## 1.2 Quality goals diff --git a/docs/architecture/06-runtime-view.md b/docs/architecture/06-runtime-view.md index 2966f04..e601600 100644 --- a/docs/architecture/06-runtime-view.md +++ b/docs/architecture/06-runtime-view.md @@ -206,10 +206,10 @@ restoring it, then the report. | 1 | The context file, the vendored templates and every condition marker are removed. A bundle that still names its arm is not judged | [ch. 8.6.6](08-crosscutting-concepts.md) | | 2-3 | The rubric is a JSON Schema, so a score is read by machine. Each primary row has anchors at 1, 3 and 5 in this domain's terms | [ch. 8.6.6](08-crosscutting-concepts.md) | | 4 | Every quoted line is looked up in its bundle. A judge that never opened the code still returns plausible numbers | [ch. 8.6.7](08-crosscutting-concepts.md) | -| 5 | Run records, tarballs without their environments, transcripts and every reading go to a fresh directory of `braboj/tariff-runs` | Ch. 9 | -| 6-7 | The archive is restored into a temporary root and the report's table, contrasts, withdrawals, escalation, reach scan and lost trials are computed from both. Any difference fails | Ch. 9 | +| 5 | Run records, tarballs without their environments, transcripts and every reading go to a fresh directory of `braboj/tariff-runs` | [ADR-019](../decisions/019-archive-before-the-report.md) | +| 6-7 | The archive is restored into a temporary root and the report's table, contrasts, withdrawals, escalation, reach scan and lost trials are computed from both. Any difference fails | [ADR-019](../decisions/019-archive-before-the-report.md) | | 8 | K paired differences per contrast, a 10,000-resample bootstrap interval at a recorded seed, the registered verdict rule, and whether the one escalation to K = 5 is owed | [ch. 8.1](08-crosscutting-concepts.md) | -| 9 | Without the stamp, or once any reading changed since it was written, the report refuses to write under `docs/audits/` | Ch. 9 | +| 9 | Without the stamp, or once any reading changed since it was written, the report refuses to write under `docs/audits/` | [ADR-019](../decisions/019-archive-before-the-report.md) | | 10 | The finding table first, then the record behind every cell | [ch. 8.7.3](08-crosscutting-concepts.md) | ### 6.4.1 Judging notes diff --git a/docs/architecture/09-architecture-decisions.md b/docs/architecture/09-architecture-decisions.md index 753fd0d..2014c1b 100644 --- a/docs/architecture/09-architecture-decisions.md +++ b/docs/architecture/09-architecture-decisions.md @@ -1,79 +1,81 @@ # 9. Architecture decisions -Every decision the benchmark has taken, dated, with its reason. The log is -append-only: a later row supersedes an earlier one, and no row is edited -for meaning. - -An issue number refers to `solid-ai-dev/solid-ai-templates`, where the -benchmark lived until the split. A dash marks a decision taken in this -repository. A chapter reference points to where that rule now lives. A row -that mentions the design means the document these chapters replaced. - -## 9.1 Decision log - -| Date | Decision | Why | Issue | -|---|---|---|---| -| 2026-09-12 | The app is `tariff`, chosen over `logsift`, `flowkit`, `ledger` and `convert` | Natural object model, two extension axes, sharp decimal tests | #1712 | -| 2026-09-12 | The hand-written arm runs | Only it separates the templates from having any file | #1705 | -| 2026-09-12 | K = 3, one bounded escalation to 5 | The smallest set an interval can be computed on; the bound stops sampling to significance | #1705 | -| 2026-09-12 | Generator `claude-sonnet-5` at effort `high`; judge `gpt-6-astra` through `codex exec`, effort set explicitly | What a typical adopter runs; a stronger model's ceiling would hide the effect; a different vendor judges | #1711 | -| 2026-09-12 | The hidden suite lives in the private `braboj/tariff-hidden-suite` | This repository is public, so a suite here is one search away from a future trial | #1705 | -| 2026-09-12 | Flask stays | Server-rendered Jinja with HTMX is its home ground | #1705 | -| 2026-09-12 | The baseline runs against `v2.90.0`, before the v3.0 split moves any template | [ch. 4.2](04-solution-strategy.md)'s comparison needs a baseline older than the move | #1705 | -| 2026-09-12 | The hidden suite is written and validated before any trial | Written afterwards, it would be shaped by the first outputs ([ch. 10.6](10-quality-requirements.md)) | #1714, #1715 | -| 2026-09-12 | The brief names the two extension axes | An adopter would; [ch. 5.5.4](05-building-block-view.md) states what that costs | #1713 | -| 2026-09-12 | The change task adds a spend threshold and a capped rate, replacing a first draft of buy-one-get-one and a reduced rate | Both first-draft items were already expressible by configuration, so every arm would score zero churn | #1717 | -| 2026-09-12 | Trials are bounded by `--max-budget-usd` and a timeout | The installed CLI (2.1.153) has no `--max-turns` | #1710 | -| 2026-09-15 | HTML validity sets aside errors on `hx-*` attributes | The spec requires HTMX; otherwise the metric counts how much HTMX a trial uses | — | -| 2026-09-15 | The escalation reads the effect in either direction, on any contrast; a row with no interval triggers nothing | An escalation owed only to a favourable effect would lean toward "better" | — | -| 2026-09-16 | Security and data protection become primary dimensions from round 3 | Owner decision after reading round 1's report | #1767 | -| 2026-09-16 | Round 1 is read for security with checks declared after the run | Its fixed security checks passed on every trial and separated nothing | #1766 | -| 2026-09-17 | The report opens with a 1–10 score per contrast, replacing "no single headline number" | Asked for after reading round 1 | #1786 | -| 2026-09-17 | The finding table opens the report | Asked for after reading the score table | #1789, #1791, #1796, #1798 | -| 2026-09-17 | Round 1's change-task pass rate is withdrawn | Its grader built the new rule and rate through names the prompt never gave | #1772 | -| 2026-09-17 | No human holdout | Scoring many implementations by hand cannot be sustained, and a person in the loop breaks [ch. 4.3](04-solution-strategy.md) | #1774 | -| 2026-09-17 | Round 2 holds length fixed and adds the hybrid model | Owner's reading of round 1: the generated file is too long to add quality, and a short one can¹ | #1795 | -| 2026-09-18 | The score table stays only for contrasts between two files | Beside the finding table it repeated itself | #1820 | -| 2026-09-18 | A contrast crossing rounds gets no verdict | Round 2's `full` read Worse because `none` moved between rounds, not the file | #1826 | -| 2026-09-19 | The primaries are anchored and checked by the control fixture | Unanchored, `design` and `maintainability` scored 3 on all 24 trials of rounds 1–2 | #1827, #1829, #1830 | -| 2026-09-19 | Each tree is judged three times | Six judgings of one unchanged tree disagreed ([ch. 10.6](10-quality-requirements.md)) | #1830 | -| 2026-09-19 | A second judge, Claude, reads the control fixture only | A second vendor's reading of the same trees; never averaged with the rounds' judge | #1831 | -| 2026-09-24 | Round 3 starts anew with all five arms and reuses no trial | The spec gained sign-in and customers, and the judge changed | #1767 | -| 2026-09-24 | Eight contrasts, adding `short − full` | Does length matter | #1767 | -| 2026-09-24 | The brief and the change prompt live in files of their own | The design's restructure would have broken the code that read them by heading | #1843 | -| 2026-09-24 | The change prompt states the API, the form fields and the rules its acceptance modules check; the UI is graded by HTTP cases from round 3 | A grader driving names the prompt never gave grades guessing; the UI was asked for but never graded | #1767 | -| 2026-09-24 | The brief names customers as personal data under the GDPR and one signing-in administrator; `hand` gains two generic lines (OWASP ASVS level 1, GDPR) | An adopter storing customers would say so. `hand`'s lines stay generic: lines mirroring the probes would hand it the answer key | #1767 | -| 2026-09-24 | Security and data protection: an anchored judge row and a probe pass rate each, all primary; probe margins mean no probe lost | A judge row alone is an opinion; the probes are deterministic. Security regressions get no tolerance | #1767 | -| 2026-09-24 | The control's application for the security and data-protection rows is one uncounted calibration trial on the extended spec | The first application has no sign-in or customers; the reference implementation is a worked answer and stays private | #1767 | -| 2026-09-25 | A probe the trial keeps from running is lost, not missing | Missing would drop it from the rate, so a trial would score higher for not signing in | #1767 | -| 2026-09-25 | The security and data-protection rows' 3 describes the common defences and nothing more; their 5 asks for an explicitly configured deployment and one declaration of what is personal | Anchored first at a level the calibration application already met, both rows fell on damage and could not rise | #1767 | -| 2026-09-25 | Design's 1 names the damage to layering, and dispatch on concrete classes with the layers kept apart is a 3 | Under `claude-opus-5-5` the base and the damaged tree both scored 2, each judged on that dispatch | #1767 | -| 2026-09-25 | The rounds' judge is `claude-opus-5-5`; `gpt-6-astra` reads a sample as a cross-check | gpt-6-astra's plan allows about thirty judgings a week and a round needs three times as many; Opus 5.5 runs on capacity the owner already pays for | #1767 | -| 2026-09-26 | `short`'s instruction asks the model to measure every line against the width before answering | On the round-3 brief two generations in a row were refused, with 1 and then 9 lines over 88 characters; retrying until one passed would select the tersest sample, and dropping the width lets a line carry a paragraph | #1767 | -| 2026-09-27 | The SQL probe counts a statement only where an interpolated value cannot be traced to the module's constants | SQLite binds values only, so a table name, a PRAGMA value or a migration script has to be interpolated; round 3's 23 hits were all such, and every user value was bound | #1882 | -| 2026-10-15 | A round is archived to the private `braboj/tariff-runs`, verified by restoring it and recomputing the report's figures, before the report is written under `docs/audits/` | Round 3's run root and scoring area were deleted with nothing kept, so none of its readings can be re-run, re-judged or cross-checked | #1904 | -| 2026-10-15 | Round 3's K = 5 escalation is recorded as unrunnable, and its report stays at K = 3 | The escalation adds blocks 4 and 5 to round 3's root, which no longer exists; re-running the whole round would not reproduce the three blocks its report read | #1767 | -| 2026-10-15 | Round 4 is judged by `claude-opus-5-5` alone, without the cross-check | The owner keeps `gpt-6-astra`'s weekly plan free; round 4's thirty build trials would take all of it. The same-vendor caveat round 3 carried stands for round 4 | #1903 | -| 2026-10-15 | The security probes read a client as signed in by what it is shown beside an anonymous client, not by `GET /` answering 200 | The thin specification lets the dashboard be public, and a public dashboard read a CSRF-checked sign-in as forged: 100 % fell to 90.91 %, past round 4's 9-point threshold | #1876 | -| 2026-10-15 | A trial is both fenced and excluded: its file tools are denied every path it may not reach, and a trial whose transcript still reaches one, through the shell, is voided and re-run once; a second reach loses it without stopping the run | A deny rule matches a shell command's prefix, not its paths, so the shell cannot be fenced; a trial that read the hidden suite measures the suite, so counting it was never an option, and deciding after its scores were seen would be | #1907 | -| 2026-10-15 | The cross-check reads whole blocks, reports agreement per judge row, and withholds a verdict only where the two judges read opposite directions | A shared vendor could favour the templates' style in every arm; opposite signs is the disagreement a verdict cannot survive, and a missed confirmation is what the interval already weighs | #1903 | -| 2026-10-16 | A trial may not stop processes by name: the commands are denied, one that ran voids the trial, and a trial whose harness died under it is voided before the next run re-runs it `--from` that trial | Round 4's thin run ended after one trial when an agent stopped its dev server with `Get-Process -Name python \| Stop-Process`, which stopped the harness too; a probe showed a deny rule's glob matches anywhere in a command, chained ones included, and lets a stop by PID through | #1928 | -| 2026-10-27 | Round 5 is judged by `gpt-6-astra` through `codex exec` at effort `high` alone, three times per trial, with no cross-check | The owner's OpenAI plan is raised to cover a round's judgings. With a judge from another vendor than every round-5 builder, the same-vendor concern the cross-check answered is gone, and a second judge could only withhold verdicts | — | -| 2026-10-27 | Each round names its builder models in its registration, and none comes from the vendor of the rounds' judge | The models are a knob a round sets, not a fixed list. A builder from the judge's vendor would bring back the self-preference the cross-check once answered, which no longer runs | — | -| 2026-10-27 | Round 5 runs block A alone, at K = 15 with no escalation, each block starting one arm later; adherence is held within 8 pp, and H2 reads the mean over pairs of trials. Blocks B and C wait for a later round | The report's rules, run on round 3's per-trial noise, decide almost nothing at K = 3: H1 is supported in 29 % of rounds when true, and a chance "worse" turns up in 36 %. At K = 15 those are 73 % and 12 %. On round 4's noise, B and C would contradict block A by chance at any affordable K | — | -| 2026-10-28 | A template change runs the baseline and the candidate head to head in the candidate's round, with one contrast, `candidate − baseline`, and no `none` arm; round 3 stays a reference without a verdict | A contrast pairing trials from different rounds gets no verdict, so round 3 as the baseline could decide nothing. Two arms answer "is the trim free" at the least cost | — | -| 2026-10-28 | From round 5, size reads app code's lines and files against a band of 20 %, smallest change 40 %; test lines are reported without a verdict; docs and configuration leave size; committed generated files count as artifacts nobody asked for | A better solution is often a little bigger, with tests and layering. Round 4's source lines missed templates, and its file count was mostly docs, templates and committed bytecode | — | -| 2026-10-29 | A round registers its spec by content, and the harness and the report each refuse a trial built from other content | Each trial recorded the spec's hash but nothing compared it, so an edit during a two-day run would have mixed two specs in one round unseen | — | -| 2026-10-29 | The prompt tells every arm the spec is the approved plan and nobody will answer, and the report refuses a build trial on another prompt. Round 5 stays as registered and runs again as round 5b | Round 5's first start: `inline-1` stopped after its plan, waiting for an approval no headless trial gets. A registration is fixed once a trial has run, so the change is a registration of its own | — | -| 2026-10-29 | Each trial's workspace sits in a pen of its own in the run root; the pen is the trial's, and a voided trial takes its whole pen. Round 5b stays as registered and runs again as round 5c | A virtualenv the agent put beside its workspace, out of the repository, read as a reach and voided two of the first four trials of rounds 5 and 5b, though neither read another trial | — | - -¹ This agrees with Anthropic's guidance on context engineering, which asks for the -smallest set of high-signal tokens: [Effective context engineering for AI -agents](https://www.anthropic.com/engineering/effective-context-engineering-for-ai-agents). - -## 9.2 Decisions about the templates - -The decisions about the templates themselves, such as ADR-052 (hybrid is -the delivery floor) and ADR-058 (task procedures load on demand), live in -`solid-ai-templates` under `docs/decisions/`. A round's hypotheses name the -record they decide. +The decisions the benchmark has taken, grouped by the part of the benchmark each +one shapes. A record under [`docs/decisions/`](../decisions/) holds one topic: +the decision as it holds today, its context and its reasons, and a History +table with every dated change to it, the superseded ones included. Each row +here gives a record's decision in one line. + +- Status "Accepted" means the decision holds. "Superseded" means a later record + replaced it, and both name each other in `supersedes` and `superseded_by`. +- A change to a topic adds a row to its record's History and updates its + decision; a new topic gets a record of its own, from + [`TEMPLATE.md`](../decisions/TEMPLATE.md). +- An issue `solid-ai-templates#N` is in `solid-ai-dev/solid-ai-templates`, + where the benchmark lived until the split; `#N` is in this repository. +- Each record sits in one group. The rows run in record order. + +## 9.1 The app, the arms and their inputs + +What every trial builds, which context files it builds with, and what it is +told. + +| Record | Decision | Status | +| ------ | -------- | ------ | +| [ADR-001](../decisions/001-the-app-under-test.md) | The app every trial builds is `tariff`, a small invoicing app on Flask, rendered on the server with Jinja and HTMX | Accepted | +| [ADR-002](../decisions/002-the-arms.md) | The arms have included a hand-written file and a `short` file at the same length, and `short`'s instruction asks the model to measure every line against the width | Accepted | +| [ADR-004](../decisions/004-the-builder-models.md) | Each round names its builder models in its registration, and none comes from the vendor of the rounds' judge | Accepted | +| [ADR-007](../decisions/007-the-baseline.md) | The baseline runs against `v2.90.0`, and a template change runs baseline and candidate head to head in one round | Accepted | +| [ADR-008](../decisions/008-the-brief-and-the-build-prompt.md) | The brief names the extension axes and the personal data, and the prompt tells every arm the spec is the approved plan and nobody will answer | Accepted | + +## 9.2 What a trial is measured on + +The tests, tasks, metrics and probes that score a trial without a judge. + +| Record | Decision | Status | +| ------ | -------- | ------ | +| [ADR-006](../decisions/006-the-hidden-suite.md) | The hidden suite lives in a private repository and is written and validated before any trial | Accepted | +| [ADR-009](../decisions/009-the-change-task.md) | The change task adds a spend threshold and a capped rate, and its prompt states everything its grader checks | Accepted | +| [ADR-011](../decisions/011-html-validity-and-size.md) | HTML validity sets aside `hx-*` errors, and size reads app code against a band of 20 % | Accepted | +| [ADR-012](../decisions/012-security-and-data-protection.md) | Security and data protection are primary, each read by an anchored judge row and a probe pass rate | Accepted | +| [ADR-018](../decisions/018-the-security-probes.md) | A probe the trial keeps from running is lost, SQL counts only untraced values, and sign-in is read beside an anonymous client | Accepted | + +## 9.3 The judge + +Which model judges, how its rows are anchored, and who else may score. + +| Record | Decision | Status | +| ------ | -------- | ------ | +| [ADR-005](../decisions/005-the-judge.md) | The rounds' judge is `gpt-6-astra` through `codex exec` at effort `high`, alone, three times per trial | Accepted | +| [ADR-014](../decisions/014-no-human-holdout.md) | No implementation is scored by a person | Accepted | +| [ADR-016](../decisions/016-anchors-control-fixture-and-repeats.md) | The primary rows are anchored and checked by the control fixture, and each tree is judged three times | Accepted | + +## 9.4 Blocks, contrasts and the report + +How many blocks a round runs, when a contrast gets a verdict, and what the +report shows first. + +| Record | Decision | Status | +| ------ | -------- | ------ | +| [ADR-003](../decisions/003-k-blocks-and-escalation.md) | A round fixes K before its first trial, 15 from round 5 with no escalation; a round at K = 3 escalates at most to 5 | Accepted | +| [ADR-013](../decisions/013-what-the-report-opens-with.md) | The report opens with the finding table, and keeps the score table only for contrasts between two files | Accepted | +| [ADR-015](../decisions/015-contrasts-and-verdicts.md) | A contrast gets a verdict only when both its arms run in the same round | Accepted | + +## 9.5 Running and keeping a round + +How a trial is bounded and fenced, how a round is registered, and how it is +kept. + +| Record | Decision | Status | +| ------ | -------- | ------ | +| [ADR-010](../decisions/010-trial-bounds.md) | Trials are bounded by `--max-budget-usd` and a timeout | Accepted | +| [ADR-017](../decisions/017-a-rounds-registration.md) | A round registers its spec by content, and the harness and the report refuse a trial built from other content | Accepted | +| [ADR-019](../decisions/019-archive-before-the-report.md) | A round is archived to `braboj/tariff-runs` and verified by restoring it before its report is written | Accepted | +| [ADR-020](../decisions/020-trial-isolation.md) | A trial is fenced by deny rules and excluded by its transcript, in a pen of its own; a reach voids it | Accepted | + +## 9.6 Decisions about the templates + +The decisions about the templates themselves, such as ADR-052 (hybrid is the +delivery floor) and ADR-058 (task procedures load on demand), live in +`solid-ai-templates` under `docs/decisions/`, numbered in that repository's own +series. A round's hypotheses name the record they decide. diff --git a/docs/decisions/001-the-app-under-test.md b/docs/decisions/001-the-app-under-test.md new file mode 100644 index 0000000..2c338ce --- /dev/null +++ b/docs/decisions/001-the-app-under-test.md @@ -0,0 +1,50 @@ +--- +id: "001" +status: Accepted +date: 2026-09-12 +category: design +supersedes: [] +superseded_by: [] +--- + +# ADR-001: The app under test + +## Context + +Every trial builds the same app from the same spec, then extends it in a change +task, so the app decides what the benchmark can see. It needs an object model a +design can get right or wrong, room to extend, and tests that tell a correct +answer from a near one. + +## Decision + +The app every trial builds is `tariff`, a small invoicing app on Flask, +rendered on the server with Jinja and HTMX. + +## Rationale + +- `tariff` has a natural object model, two extension axes and sharp decimal + tests. +- Server-rendered Jinja with HTMX is Flask's home ground. + +## Alternatives considered + +The apps `tariff` was weighed against. The decision named `tariff`'s +strengths, not a reason against each of the others: + +| # | Alternative | Outcome | +| - | ----------- | ------- | +| A | `tariff` | Chosen | +| B | `logsift` | Not chosen as the app under test | +| C | `flowkit` | Not chosen as the app under test | +| D | `ledger` | Not chosen as the app under test | +| E | `convert` | Not chosen as the app under test | + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-12 | The app is `tariff`, chosen over `logsift`, `flowkit`, `ledger` and `convert` | Natural object model, two extension axes, sharp decimal tests | solid-ai-templates#1712 | +| 2026-09-12 | Flask stays | Server-rendered Jinja with HTMX is its home ground | solid-ai-templates#1705 | diff --git a/docs/decisions/002-the-arms.md b/docs/decisions/002-the-arms.md new file mode 100644 index 0000000..b29a166 --- /dev/null +++ b/docs/decisions/002-the-arms.md @@ -0,0 +1,49 @@ +--- +id: "002" +status: Accepted +date: 2026-09-12 +category: design +supersedes: [] +superseded_by: [] +--- + +# ADR-002: The arms + +## Context + +An arm is one setting of the context-file knob. Comparing a generated file with +the bare agent alone cannot tell the templates' effect from the effect of +having any file at all. Round 1's reading added a second question: whether the +generated file is too long to add quality. + +## Decision + +Beside the bare agent and the generated file, the arms have included a +hand-written file and, from round 2, a `short` generated file held to the same +length and the hybrid model, and `short`'s instruction asks the model to +measure every line against the width before answering. + +## Rationale + +- Only the hand-written arm separates the templates from having any file. +- The owner read round 1 as saying the generated file is too long to add + quality and that a short one can, so length is held fixed and the + hybrid model added. +- Refusing a `short` generation over the width and retrying until one passes + would select the tersest sample, and dropping the width lets a line carry a + paragraph; asking the model to measure every line does neither. + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-12 | The hand-written arm runs | Only it separates the templates from having any file | solid-ai-templates#1705 | +| 2026-09-17 | Round 2 holds length fixed and adds the hybrid model | Owner's reading of round 1: the generated file is too long to add quality, and a short one can[^context] | solid-ai-templates#1795 | +| 2026-09-26 | `short`'s instruction asks the model to measure every line against the width before answering | On the round-3 brief two generations in a row were refused, with 1 and then 9 lines over 88 characters; retrying until one passed would select the tersest sample, and dropping the width lets a line carry a paragraph | solid-ai-templates#1767 | + +[^context]: This agrees with Anthropic's guidance on context engineering, which + asks for the smallest set of high-signal tokens: [Effective context + engineering for AI + agents](https://www.anthropic.com/engineering/effective-context-engineering-for-ai-agents). diff --git a/docs/decisions/003-k-blocks-and-escalation.md b/docs/decisions/003-k-blocks-and-escalation.md new file mode 100644 index 0000000..377b9ac --- /dev/null +++ b/docs/decisions/003-k-blocks-and-escalation.md @@ -0,0 +1,64 @@ +--- +id: "003" +status: Accepted +date: 2026-09-12 +category: measurement +supersedes: [] +superseded_by: [] +--- + +# ADR-003: K, blocks and escalation + +## Context + +K is the number of blocks a round runs, so the number of trials per arm. Each +block runs every arm once, and a contrast's interval is computed on its K +paired differences. Too few blocks and the interval decides nothing; adding +blocks until an effect turns significant is sampling to significance. + +## Decision + +A round fixes K before its first trial, at K = 15 with no escalation from +round 5, while a round registered at K = 3 escalates at most once, to K = 5, on +an effect in either direction. + +## Rationale + +- Three is the smallest set an interval can be computed on, and the bound on + escalation stops sampling to significance. +- An escalation owed only to a favourable effect would lean toward "better". +- Run on round 3's per-trial noise, the report's rules decide almost nothing at + K = 3: H1 is supported in 29 % of rounds when true, and a chance "worse" + turns up in 36 %. At K = 15 those are 73 % and 12 %. +- On round 4's noise, blocks B and C would contradict block A by chance at any + affordable K, so round 5 runs block A alone. + +## Design + +The rules a round's K follows: + +| # | Rule | In practice | +| - | ---- | ----------- | +| 1 | K is registered | Fixed by the round's registration before its first trial | +| 2 | Escalation | Only a round registered at K = 3: one step to K = 5, owed by an effect in either direction on any contrast; a row with no interval triggers nothing | +| 3 | Block order | Each block starts one arm later than the last | +| 4 | One lettered block | Round 5 runs block A alone; blocks B and C wait for a later round | + +## Consequences + +What the history of this decision left behind: + +| Consequence | Effect | +| ----------- | ------ | +| Round 3 stays at K = 3 | Its K = 5 escalation is recorded as unrunnable, since its run root no longer exists | + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-12 | K = 3, one bounded escalation to 5 | The smallest set an interval can be computed on; the bound stops sampling to significance | solid-ai-templates#1705 | +| 2026-09-15 | The escalation reads the effect in either direction, on any contrast; a row with no interval triggers nothing | An escalation owed only to a favourable effect would lean toward "better" | — | +| 2026-10-15 | Round 3's K = 5 escalation is recorded as unrunnable, and its report stays at K = 3 | The escalation adds blocks 4 and 5 to round 3's root, which no longer exists; re-running the whole round would not reproduce the three blocks its report read | solid-ai-templates#1767 | +| 2026-10-27 | Round 5 runs block A alone, at K = 15 with no escalation, each block starting one arm later; adherence is held within 8 pp, and H2 reads the mean over pairs of trials. Blocks B and C wait for a later round | The report's rules, run on round 3's per-trial noise, decide almost nothing at K = 3: H1 is supported in 29 % of rounds when true, and a chance "worse" turns up in 36 %. At K = 15 those are 73 % and 12 %. On round 4's noise, B and C would contradict block A by chance at any affordable K | — | diff --git a/docs/decisions/004-the-builder-models.md b/docs/decisions/004-the-builder-models.md new file mode 100644 index 0000000..c47cef8 --- /dev/null +++ b/docs/decisions/004-the-builder-models.md @@ -0,0 +1,41 @@ +--- +id: "004" +status: Accepted +date: 2026-09-12 +category: design +supersedes: [] +superseded_by: [] +--- + +# ADR-004: The builder models + +## Context + +The model a trial's agent runs on sets the ceiling every arm works under. A +model far stronger than an adopter's would leave the context file little to +add, and a model from the judge's vendor could be favoured by that judge. + +## Decision + +Each round names its builder models in its registration, and none comes from +the vendor of the rounds' judge. + +## Rationale + +- The first choice was what a typical adopter runs, `claude-sonnet-5` at effort + `high`, since a stronger model's ceiling would hide the effect. +- The models are a knob a round sets, not a fixed list. +- A builder from the judge's vendor would bring back the self-preference the + cross-check once answered, and the cross-check no longer runs + ([ADR-005](005-the-judge.md)). + +## History + +Every change to this decision, oldest first. The 2026-09-12 row is the builder +half of that day's decision on models; its judge half is in +[ADR-005](005-the-judge.md): + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-12 | Generator `claude-sonnet-5` at effort `high` | What a typical adopter runs; a stronger model's ceiling would hide the effect | solid-ai-templates#1711 | +| 2026-10-27 | Each round names its builder models in its registration, and none comes from the vendor of the rounds' judge | The models are a knob a round sets, not a fixed list. A builder from the judge's vendor would bring back the self-preference the cross-check once answered, which no longer runs | — | diff --git a/docs/decisions/005-the-judge.md b/docs/decisions/005-the-judge.md new file mode 100644 index 0000000..7d3a346 --- /dev/null +++ b/docs/decisions/005-the-judge.md @@ -0,0 +1,57 @@ +--- +id: "005" +status: Accepted +date: 2026-09-12 +category: judge +supersedes: [] +superseded_by: [] +--- + +# ADR-005: The judge + +## Context + +A judge model scores each blind bundle on the rubric's rows. Its vendor +matters: a judge sharing a vendor with the builder could favour the templates' +style in every arm. Its plan matters too: a round needs three judgings per +trial, and a plan that allows fewer cannot judge a round. + +## Decision + +The rounds' judge is `gpt-6-astra` through `codex exec` at effort `high`, +alone, three times per trial, with no cross-check. + +## Rationale + +- A judge from another vendor than the builder answers the self-preference + concern; with a judge from another vendor than every round-5 builder + ([ADR-004](004-the-builder-models.md)), that concern is gone. +- The owner's OpenAI plan is raised to cover a round's judgings, which in + rounds 3 and 4 it could not. +- A second judge could only withhold verdicts. + +## Design + +The cross-check that ran in round 3 and is dropped from round 5, kept for +reading the rounds that used it: + +| # | Rule | In practice | +| - | ---- | ----------- | +| 1 | Never averaged | A second judge's scores are never averaged with the rounds' judge | +| 2 | Whole blocks | The cross-check reads whole blocks and reports agreement per judge row | +| 3 | Opposite directions | It withholds a verdict only where the two judges read opposite directions | + +## History + +Every change to this decision, oldest first. The 2026-09-12 row is the judge +half of that day's decision on models; its builder half is in +[ADR-004](004-the-builder-models.md): + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-12 | Judge `gpt-6-astra` through `codex exec`, effort set explicitly | A different vendor judges | solid-ai-templates#1711 | +| 2026-09-19 | A second judge, Claude, reads the control fixture only | A second vendor's reading of the same trees; never averaged with the rounds' judge | solid-ai-templates#1831 | +| 2026-09-25 | The rounds' judge is `claude-opus-5-5`; `gpt-6-astra` reads a sample as a cross-check | gpt-6-astra's plan allows about thirty judgings a week and a round needs three times as many; Opus 5.5 runs on capacity the owner already pays for | solid-ai-templates#1767 | +| 2026-10-15 | Round 4 is judged by `claude-opus-5-5` alone, without the cross-check | The owner keeps `gpt-6-astra`'s weekly plan free; round 4's thirty build trials would take all of it. The same-vendor caveat round 3 carried stands for round 4 | solid-ai-templates#1903 | +| 2026-10-15 | The cross-check reads whole blocks, reports agreement per judge row, and withholds a verdict only where the two judges read opposite directions | A shared vendor could favour the templates' style in every arm; opposite signs is the disagreement a verdict cannot survive, and a missed confirmation is what the interval already weighs | solid-ai-templates#1903 | +| 2026-10-27 | Round 5 is judged by `gpt-6-astra` through `codex exec` at effort `high` alone, three times per trial, with no cross-check | The owner's OpenAI plan is raised to cover a round's judgings. With a judge from another vendor than every round-5 builder, the same-vendor concern the cross-check answered is gone, and a second judge could only withhold verdicts | — | diff --git a/docs/decisions/006-the-hidden-suite.md b/docs/decisions/006-the-hidden-suite.md new file mode 100644 index 0000000..c542697 --- /dev/null +++ b/docs/decisions/006-the-hidden-suite.md @@ -0,0 +1,37 @@ +--- +id: "006" +status: Accepted +date: 2026-09-12 +category: measurement +supersedes: [] +superseded_by: [] +--- + +# ADR-006: The hidden suite + +## Context + +The hidden suite is the set of acceptance tests every trial is graded by. A +trial that could find the suite would measure the suite, and a suite shaped by +the trials it grades would grade what they happened to build. + +## Decision + +The hidden suite lives in the private `braboj/tariff-hidden-suite` and is +written and validated before any trial. + +## Rationale + +- This repository is public, so a suite here is one search away from a future + trial. +- Written afterwards, the suite would be shaped by the first outputs + ([ch. 10.6](../architecture/10-quality-requirements.md)). + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-12 | The hidden suite lives in the private `braboj/tariff-hidden-suite` | This repository is public, so a suite here is one search away from a future trial | solid-ai-templates#1705 | +| 2026-09-12 | The hidden suite is written and validated before any trial | Written afterwards, it would be shaped by the first outputs ([ch. 10.6](../architecture/10-quality-requirements.md)) | solid-ai-templates#1714, solid-ai-templates#1715 | diff --git a/docs/decisions/007-the-baseline.md b/docs/decisions/007-the-baseline.md new file mode 100644 index 0000000..37aae5b --- /dev/null +++ b/docs/decisions/007-the-baseline.md @@ -0,0 +1,50 @@ +--- +id: "007" +status: Accepted +date: 2026-09-12 +category: design +supersedes: [] +superseded_by: [] +--- + +# ADR-007: The baseline + +## Context + +The benchmark compares a release of the templates with what came before it. The +v3.0 split moves templates, so a baseline taken after it could not show what +the move changed. A later question is how a template change is measured at all, +once a contrast pairing trials from different rounds gets no verdict +([ADR-015](015-contrasts-and-verdicts.md)). + +## Decision + +The baseline runs against the templates at `v2.90.0`, before the v3.0 split, +and a template change runs the baseline and the candidate head to head in the +candidate's round, with one contrast, `candidate − baseline`, and no `none` +arm. + +## Rationale + +- [ch. 4.2](../architecture/04-solution-strategy.md)'s comparison needs a + baseline older than the move. +- A contrast pairing trials from different rounds gets no verdict, so round 3 + as the baseline could decide nothing. +- Two arms answer "is the trim free" at the least cost. + +## Consequences + +What the head-to-head rule changes for earlier rounds: + +| Consequence | Effect | +| ----------- | ------ | +| Round 3 is a reference | It stays a reference without a verdict | + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-12 | The baseline runs against `v2.90.0`, before the v3.0 split moves any template | [ch. 4.2](../architecture/04-solution-strategy.md)'s comparison needs a baseline older than the move | solid-ai-templates#1705 | +| 2026-10-28 | A template change runs the baseline and the candidate head to head in the candidate's round, with one contrast, `candidate − baseline`, and no `none` arm; round 3 stays a reference without a verdict | A contrast pairing trials from different rounds gets no verdict, so round 3 as the baseline could decide nothing. Two arms answer "is the trim free" at the least cost | — | diff --git a/docs/decisions/008-the-brief-and-the-build-prompt.md b/docs/decisions/008-the-brief-and-the-build-prompt.md new file mode 100644 index 0000000..640d020 --- /dev/null +++ b/docs/decisions/008-the-brief-and-the-build-prompt.md @@ -0,0 +1,68 @@ +--- +id: "008" +status: Accepted +date: 2026-09-12 +category: design +supersedes: [] +superseded_by: [] +--- + +# ADR-008: The brief and the build prompt + +## Context + +The brief is what an adopter would type to the generator, and the build prompt +is what every arm's agent is told with the spec. Both shape what a trial +builds, so each says what an adopter would say and nothing the hidden suite +checks. A headless trial gets no answer to any question it asks. + +## Decision + +The brief and the prompts live in files of their own; the brief names the two +extension axes, customers as personal data under the GDPR and one signing-in +administrator, and the build prompt tells every arm the spec is the approved +plan and nobody will answer. + +## Rationale + +- An adopter would name the extension axes; + [ch. 5.5.4](../architecture/05-building-block-view.md) states what that + costs. +- An adopter storing customers would say so. +- `hand`'s two added lines stay generic: lines mirroring the probes would hand + it the answer key. +- The design's restructure would have broken the code that read the brief and + the change prompt by heading. +- A trial waiting for an approval no headless trial gets stops after its plan, + as `inline-1` did in round 5's first start. + +## Design + +The rules the brief and the prompt follow: + +| # | Rule | In practice | +| - | ---- | ----------- | +| 1 | Files of their own | The brief and the change prompt are read from their own files, not by heading | +| 2 | Extension axes | The brief names the app's two extension axes | +| 3 | Personal data | The brief names customers as personal data under the GDPR, and one administrator who signs in | +| 4 | `hand`'s lines | `hand` carries two generic lines, OWASP ASVS level 1 and the GDPR, and nothing that mirrors a probe | +| 5 | No one answers | The prompt tells every arm the spec is the approved plan and nobody will answer; the report refuses a build trial on another prompt | + +## Consequences + +What the prompt change did to the round it arrived in: + +| Consequence | Effect | +| ----------- | ------ | +| Round 5b | A registration is fixed once a trial has run, so round 5 stays as registered and runs again as round 5b | + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-12 | The brief names the two extension axes | An adopter would; [ch. 5.5.4](../architecture/05-building-block-view.md) states what that costs | solid-ai-templates#1713 | +| 2026-09-24 | The brief and the change prompt live in files of their own | The design's restructure would have broken the code that read them by heading | solid-ai-templates#1843 | +| 2026-09-24 | The brief names customers as personal data under the GDPR and one signing-in administrator; `hand` gains two generic lines (OWASP ASVS level 1, GDPR) | An adopter storing customers would say so. `hand`'s lines stay generic: lines mirroring the probes would hand it the answer key | solid-ai-templates#1767 | +| 2026-10-29 | The prompt tells every arm the spec is the approved plan and nobody will answer, and the report refuses a build trial on another prompt. Round 5 stays as registered and runs again as round 5b | Round 5's first start: `inline-1` stopped after its plan, waiting for an approval no headless trial gets. A registration is fixed once a trial has run, so the change is a registration of its own | — | diff --git a/docs/decisions/009-the-change-task.md b/docs/decisions/009-the-change-task.md new file mode 100644 index 0000000..0b86f72 --- /dev/null +++ b/docs/decisions/009-the-change-task.md @@ -0,0 +1,48 @@ +--- +id: "009" +status: Accepted +date: 2026-09-12 +category: measurement +supersedes: [] +superseded_by: [] +--- + +# ADR-009: The change task + +## Context + +The change task is a second session that extends a copy of a frozen build. Its +churn shows how well the first build was laid out for change, so the task has +to need code, not configuration, and its grader has to check what the prompt +asked for and nothing it did not. + +## Decision + +The change task adds a spend threshold and a capped rate, and its prompt states +the API, the form fields and the rules its acceptance modules check, with the +UI graded by HTTP cases from round 3. + +## Rationale + +- Buy-one-get-one and a reduced rate, the first draft's items, were already + expressible by configuration, so every arm would score zero churn. +- A grader driving names the prompt never gave grades guessing. +- The UI was asked for but never graded. + +## Consequences + +What the grading rule withdrew: + +| Consequence | Effect | +| ----------- | ------ | +| Round 1's pass rate | Its change-task pass rate is withdrawn: its grader built the new rule and rate through names the prompt never gave | + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-12 | The change task adds a spend threshold and a capped rate, replacing a first draft of buy-one-get-one and a reduced rate | Both first-draft items were already expressible by configuration, so every arm would score zero churn | solid-ai-templates#1717 | +| 2026-09-17 | Round 1's change-task pass rate is withdrawn | Its grader built the new rule and rate through names the prompt never gave | solid-ai-templates#1772 | +| 2026-09-24 | The change prompt states the API, the form fields and the rules its acceptance modules check; the UI is graded by HTTP cases from round 3 | A grader driving names the prompt never gave grades guessing; the UI was asked for but never graded | solid-ai-templates#1767 | diff --git a/docs/decisions/010-trial-bounds.md b/docs/decisions/010-trial-bounds.md new file mode 100644 index 0000000..35ab15d --- /dev/null +++ b/docs/decisions/010-trial-bounds.md @@ -0,0 +1,31 @@ +--- +id: "010" +status: Accepted +date: 2026-09-12 +category: process +supersedes: [] +superseded_by: [] +--- + +# ADR-010: Trial bounds + +## Context + +A trial is one headless agent session, and nothing stops it but a limit the +harness sets. The installed CLI decides which limits are available. + +## Decision + +Trials are bounded by `--max-budget-usd` and a timeout. + +## Rationale + +- The installed CLI (2.1.153) has no `--max-turns`. + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-12 | Trials are bounded by `--max-budget-usd` and a timeout | The installed CLI (2.1.153) has no `--max-turns` | solid-ai-templates#1710 | diff --git a/docs/decisions/011-html-validity-and-size.md b/docs/decisions/011-html-validity-and-size.md new file mode 100644 index 0000000..0064935 --- /dev/null +++ b/docs/decisions/011-html-validity-and-size.md @@ -0,0 +1,50 @@ +--- +id: "011" +status: Accepted +date: 2026-09-15 +category: measurement +supersedes: [] +superseded_by: [] +--- + +# ADR-011: HTML validity and size + +## Context + +HTML validity and size are measured on every trial without a judge. Each has to +count what the arm chose, not what the spec required or what a better solution +naturally adds. + +## Decision + +HTML validity sets aside errors on `hx-*` attributes, and from round 5 size +reads app code's lines and files against a band of 20 %, with test lines +reported without a verdict. + +## Rationale + +- The spec requires HTMX; otherwise the validity metric counts how much HTMX a + trial uses. +- A better solution is often a little bigger, with tests and layering. +- Round 4's source lines missed templates, and its file count was mostly docs, + templates and committed bytecode. + +## Design + +The rules size follows from round 5: + +| # | Rule | In practice | +| - | ---- | ----------- | +| 1 | App code | Size reads app code's lines and files against a band of 20 %; the smallest change that matters is 40 % | +| 2 | Tests | Test lines are reported without a verdict | +| 3 | Left out | Docs and configuration leave size | +| 4 | Artifacts | Committed generated files count as artifacts nobody asked for | + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-15 | HTML validity sets aside errors on `hx-*` attributes | The spec requires HTMX; otherwise the metric counts how much HTMX a trial uses | — | +| 2026-10-28 | From round 5, size reads app code's lines and files against a band of 20 %, smallest change 40 %; test lines are reported without a verdict; docs and configuration leave size; committed generated files count as artifacts nobody asked for | A better solution is often a little bigger, with tests and layering. Round 4's source lines missed templates, and its file count was mostly docs, templates and committed bytecode | — | diff --git a/docs/decisions/012-security-and-data-protection.md b/docs/decisions/012-security-and-data-protection.md new file mode 100644 index 0000000..3830324 --- /dev/null +++ b/docs/decisions/012-security-and-data-protection.md @@ -0,0 +1,62 @@ +--- +id: "012" +status: Accepted +date: 2026-09-16 +category: measurement +supersedes: [] +superseded_by: [] +--- + +# ADR-012: Security and data protection + +## Context + +Round 1 measured security with fixed checks that every trial passed, so they +separated nothing. A judge row alone is an opinion, and the control fixture's +first application has no sign-in and no customers to calibrate such a row on. + +## Decision + +Security and data protection are primary dimensions from round 3, each read by +an anchored judge row and a probe pass rate, and their probe margins let no +probe be lost. + +## Rationale + +- An owner decision after reading round 1's report. +- A judge row alone is an opinion; the probes are deterministic. +- Security regressions get no tolerance. +- Anchored first at a level the calibration application already met, both rows + fell on damage and could not rise, so their 3 and their 5 were moved. + +## Design + +The rules the two dimensions follow: + +| # | Rule | In practice | +| - | ---- | ----------- | +| 1 | Four primaries | An anchored judge row and a probe pass rate for each of security and data protection | +| 2 | No probe lost | The probe margins mean no probe lost | +| 3 | The 3 | Each row's 3 describes the common defences and nothing more | +| 4 | The 5 | Each row's 5 asks for an explicitly configured deployment and one declaration of what is personal | +| 5 | Calibration | The control's application for these rows is one uncounted calibration trial on the extended spec; the reference implementation is a worked answer and stays private | + +## Consequences + +What the change did to the round before it: + +| Consequence | Effect | +| ----------- | ------ | +| Round 1 | Read for security with checks declared after the run | + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-16 | Security and data protection become primary dimensions from round 3 | Owner decision after reading round 1's report | solid-ai-templates#1767 | +| 2026-09-16 | Round 1 is read for security with checks declared after the run | Its fixed security checks passed on every trial and separated nothing | solid-ai-templates#1766 | +| 2026-09-24 | Security and data protection: an anchored judge row and a probe pass rate each, all primary; probe margins mean no probe lost | A judge row alone is an opinion; the probes are deterministic. Security regressions get no tolerance | solid-ai-templates#1767 | +| 2026-09-24 | The control's application for the security and data-protection rows is one uncounted calibration trial on the extended spec | The first application has no sign-in or customers; the reference implementation is a worked answer and stays private | solid-ai-templates#1767 | +| 2026-09-25 | The security and data-protection rows' 3 describes the common defences and nothing more; their 5 asks for an explicitly configured deployment and one declaration of what is personal | Anchored first at a level the calibration application already met, both rows fell on damage and could not rise | solid-ai-templates#1767 | diff --git a/docs/decisions/013-what-the-report-opens-with.md b/docs/decisions/013-what-the-report-opens-with.md new file mode 100644 index 0000000..a6c13e7 --- /dev/null +++ b/docs/decisions/013-what-the-report-opens-with.md @@ -0,0 +1,38 @@ +--- +id: "013" +status: Accepted +date: 2026-09-17 +category: report +supersedes: [] +superseded_by: [] +--- + +# ADR-013: What the report opens with + +## Context + +A round's report first had no single headline number. Reading round 1's report, +the owner asked for a score per contrast, and reading the score table, for the +findings first. + +## Decision + +The report opens with the finding table, and keeps the 1–10 score table only +for contrasts between two files. + +## Rationale + +- A 1–10 score per contrast was asked for after reading round 1. +- The finding table was asked for after reading the score table. +- Beside the finding table, the score table repeated itself for every contrast + but those between two files. + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-17 | The report opens with a 1–10 score per contrast, replacing "no single headline number" | Asked for after reading round 1 | solid-ai-templates#1786 | +| 2026-09-17 | The finding table opens the report | Asked for after reading the score table | solid-ai-templates#1789, solid-ai-templates#1791, solid-ai-templates#1796, solid-ai-templates#1798 | +| 2026-09-18 | The score table stays only for contrasts between two files | Beside the finding table it repeated itself | solid-ai-templates#1820 | diff --git a/docs/decisions/014-no-human-holdout.md b/docs/decisions/014-no-human-holdout.md new file mode 100644 index 0000000..8aef99e --- /dev/null +++ b/docs/decisions/014-no-human-holdout.md @@ -0,0 +1,35 @@ +--- +id: "014" +status: Accepted +date: 2026-09-17 +category: judge +supersedes: [] +superseded_by: [] +--- + +# ADR-014: No human holdout + +## Context + +A human holdout would score a share of the implementations by hand, as a check +on the judge. Every round produces many implementations, and the benchmark runs +with no person in the loop +([ch. 4.3](../architecture/04-solution-strategy.md)). + +## Decision + +No implementation is scored by a person: there is no human holdout. + +## Rationale + +- Scoring many implementations by hand cannot be sustained. +- A person in the loop breaks + [ch. 4.3](../architecture/04-solution-strategy.md). + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-17 | No human holdout | Scoring many implementations by hand cannot be sustained, and a person in the loop breaks [ch. 4.3](../architecture/04-solution-strategy.md) | solid-ai-templates#1774 | diff --git a/docs/decisions/015-contrasts-and-verdicts.md b/docs/decisions/015-contrasts-and-verdicts.md new file mode 100644 index 0000000..19b3a31 --- /dev/null +++ b/docs/decisions/015-contrasts-and-verdicts.md @@ -0,0 +1,36 @@ +--- +id: "015" +status: Accepted +date: 2026-09-18 +category: report +supersedes: [] +superseded_by: [] +--- + +# ADR-015: Contrasts and verdicts + +## Context + +A contrast compares two arms within each block, so its differences are paired. +A contrast whose two arms come from different rounds is not paired that way: +anything that moved between the rounds moves its reading too. + +## Decision + +A contrast gets a verdict only when both its arms run in the same round, and +round 3 read eight contrasts, adding `short − full`. + +## Rationale + +- Round 2's `full` read Worse because `none` moved between rounds, not the + file. +- `short − full` asks whether length matters. + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-18 | A contrast crossing rounds gets no verdict | Round 2's `full` read Worse because `none` moved between rounds, not the file | solid-ai-templates#1826 | +| 2026-09-24 | Eight contrasts, adding `short − full` | Does length matter | solid-ai-templates#1767 | diff --git a/docs/decisions/016-anchors-control-fixture-and-repeats.md b/docs/decisions/016-anchors-control-fixture-and-repeats.md new file mode 100644 index 0000000..a2e6ac3 --- /dev/null +++ b/docs/decisions/016-anchors-control-fixture-and-repeats.md @@ -0,0 +1,52 @@ +--- +id: "016" +status: Accepted +date: 2026-09-19 +category: judge +supersedes: [] +superseded_by: [] +--- + +# ADR-016: Anchors, the control fixture and repeated judgings + +## Context + +The judge scores each tree 1 to 5 per rubric row. In rounds 1 and 2 its rows +had no anchors. A row that cannot fall on a damaged tree, or a score that +changes when the same tree is judged again, cannot carry a verdict. + +## Decision + +The primary judge rows are anchored and checked by the control fixture, and +each tree is judged three times. + +## Rationale + +- Unanchored, `design` and `maintainability` scored 3 on all 24 trials of + rounds 1–2. +- Six judgings of one unchanged tree disagreed + ([ch. 10.6](../architecture/10-quality-requirements.md)). +- Under `claude-opus-5-5` the base and the damaged tree both scored 2 on + design, each judged on dispatch on concrete classes, so design's anchors were + moved. + +## Design + +The rules the anchors and the repeats follow: + +| # | Rule | In practice | +| - | ---- | ----------- | +| 1 | Anchored primaries | Each primary row is anchored, and the control fixture checks it | +| 2 | Three judgings | Each tree is judged three times | +| 3 | Design's 1 | Names the damage to layering | +| 4 | Design's 3 | Dispatch on concrete classes with the layers kept apart | + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-19 | The primaries are anchored and checked by the control fixture | Unanchored, `design` and `maintainability` scored 3 on all 24 trials of rounds 1–2 | solid-ai-templates#1827, solid-ai-templates#1829, solid-ai-templates#1830 | +| 2026-09-19 | Each tree is judged three times | Six judgings of one unchanged tree disagreed ([ch. 10.6](../architecture/10-quality-requirements.md)) | solid-ai-templates#1830 | +| 2026-09-25 | Design's 1 names the damage to layering, and dispatch on concrete classes with the layers kept apart is a 3 | Under `claude-opus-5-5` the base and the damaged tree both scored 2, each judged on that dispatch | solid-ai-templates#1767 | diff --git a/docs/decisions/017-a-rounds-registration.md b/docs/decisions/017-a-rounds-registration.md new file mode 100644 index 0000000..5a88862 --- /dev/null +++ b/docs/decisions/017-a-rounds-registration.md @@ -0,0 +1,38 @@ +--- +id: "017" +status: Accepted +date: 2026-09-24 +category: process +supersedes: [] +superseded_by: [] +--- + +# ADR-017: A round's registration + +## Context + +A round runs under one set of rules. When the spec or the judge changes, an +earlier round's trials were built or scored under other rules. A round can also +run for days, and an edit to the spec during it would leave its trials built +from two specs. + +## Decision + +A round registers its spec by content, with the harness and the report each +refusing a trial built from other content, and round 3, whose spec and judge +changed, started anew and reused no trial. + +## Rationale + +- Round 3's spec gained sign-in and customers, and its judge changed. +- Each trial recorded the spec's hash but nothing compared it, so an edit + during a two-day run would have mixed two specs in one round unseen. + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-24 | Round 3 starts anew with all five arms and reuses no trial | The spec gained sign-in and customers, and the judge changed | solid-ai-templates#1767 | +| 2026-10-29 | A round registers its spec by content, and the harness and the report each refuse a trial built from other content | Each trial recorded the spec's hash but nothing compared it, so an edit during a two-day run would have mixed two specs in one round unseen | — | diff --git a/docs/decisions/018-the-security-probes.md b/docs/decisions/018-the-security-probes.md new file mode 100644 index 0000000..ec015b6 --- /dev/null +++ b/docs/decisions/018-the-security-probes.md @@ -0,0 +1,55 @@ +--- +id: "018" +status: Accepted +date: 2026-09-25 +category: measurement +supersedes: [] +superseded_by: [] +--- + +# ADR-018: The security probes + +## Context + +The security and data-protection probes are deterministic checks run against +each trial's app ([ADR-012](012-security-and-data-protection.md)). A probe +reads a trial's failure only if it can tell the trial's choice from its own +assumptions about the app: whether it could sign in, what SQL had to be +interpolated, and what a signed-in client sees. + +## Decision + +A probe the trial keeps from running is lost, the SQL probe counts a statement +only where an interpolated value cannot be traced to the module's constants, +and a client reads as signed in by what it is shown beside an anonymous client. + +## Rationale + +- Counted as missing, a probe would drop out of the rate, so a trial would + score higher for not signing in. +- SQLite binds values only, so a table name, a PRAGMA value or a migration + script has to be interpolated; round 3's 23 hits were all such, and every + user value was bound. +- The thin specification lets the dashboard be public, and a public dashboard + read a CSRF-checked sign-in as forged: 100 % fell to 90.91 %, past round 4's + 9-point threshold. + +## Design + +The rules the probes follow: + +| # | Rule | In practice | +| - | ---- | ----------- | +| 1 | Lost, not missing | A probe the trial keeps from running fails; it never drops out of the rate | +| 2 | Traced SQL | A statement counts only where an interpolated value cannot be traced to the module's constants | +| 3 | Signed in | A client reads as signed in by what it is shown beside an anonymous client, not by `GET /` answering 200 | + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-09-25 | A probe the trial keeps from running is lost, not missing | Missing would drop it from the rate, so a trial would score higher for not signing in | solid-ai-templates#1767 | +| 2026-09-27 | The SQL probe counts a statement only where an interpolated value cannot be traced to the module's constants | SQLite binds values only, so a table name, a PRAGMA value or a migration script has to be interpolated; round 3's 23 hits were all such, and every user value was bound | solid-ai-templates#1882 | +| 2026-10-15 | The security probes read a client as signed in by what it is shown beside an anonymous client, not by `GET /` answering 200 | The thin specification lets the dashboard be public, and a public dashboard read a CSRF-checked sign-in as forged: 100 % fell to 90.91 %, past round 4's 9-point threshold | solid-ai-templates#1876 | diff --git a/docs/decisions/019-archive-before-the-report.md b/docs/decisions/019-archive-before-the-report.md new file mode 100644 index 0000000..39f5c15 --- /dev/null +++ b/docs/decisions/019-archive-before-the-report.md @@ -0,0 +1,42 @@ +--- +id: "019" +status: Accepted +date: 2026-10-15 +category: process +supersedes: [] +superseded_by: [] +--- + +# ADR-019: Archive before the report + +## Context + +A round's run root and scoring area live outside this repository, and nothing +kept a copy of them. Round 3's were deleted with nothing kept. + +## Decision + +A round is archived to the private `braboj/tariff-runs`, verified by restoring +it and recomputing the report's figures, before the report is written under +`docs/audits/`. + +## Rationale + +- With round 3's run root and scoring area gone, none of its readings can be + re-run, re-judged or cross-checked. + +## Consequences + +What round 3's loss left behind: + +| Consequence | Effect | +| ----------- | ------ | +| Round 3's escalation | Recorded as unrunnable ([ADR-003](003-k-blocks-and-escalation.md)) | + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-10-15 | A round is archived to the private `braboj/tariff-runs`, verified by restoring it and recomputing the report's figures, before the report is written under `docs/audits/` | Round 3's run root and scoring area were deleted with nothing kept, so none of its readings can be re-run, re-judged or cross-checked | solid-ai-templates#1904 | diff --git a/docs/decisions/020-trial-isolation.md b/docs/decisions/020-trial-isolation.md new file mode 100644 index 0000000..ca4d965 --- /dev/null +++ b/docs/decisions/020-trial-isolation.md @@ -0,0 +1,67 @@ +--- +id: "020" +status: Accepted +date: 2026-10-15 +category: isolation +supersedes: [] +superseded_by: [] +--- + +# ADR-020: Trial isolation + +## Context + +A trial runs an agent with a shell on the operator's machine, beside this +repository, the hidden suite, the scoring area and other trials. A trial that +read the hidden suite measures the suite. A trial can also harm the run itself: +in round 4's thin run an agent stopped its dev server with +`Get-Process -Name python | Stop-Process`, which stopped the harness too. + +## Decision + +A trial is fenced by deny rules and excluded by a scan of its transcript: a +trial that reaches past its own pen is voided and re-run once, a second reach +loses it without stopping the run, and a trial that stops processes by name is +voided. + +## Rationale + +- A deny rule matches a shell command's prefix, not its paths, so the shell + cannot be fenced. +- A trial that read the hidden suite measures the suite, so counting it was + never an option. +- A probe showed a deny rule's glob matches anywhere in a command, chained ones + included, and lets a stop by PID through. +- A virtualenv the agent put beside its workspace, out of the repository, read + as a reach and voided two of the first four trials of rounds 5 and 5b, + though neither read another trial. + +## Design + +The rules a trial runs under: + +| # | Rule | In practice | +| - | ---- | ----------- | +| 1 | Fenced | The trial's file tools are denied every path it may not reach | +| 2 | Excluded | A trial whose transcript still reaches such a path, through the shell, is voided and re-run once; a second reach loses it without stopping the run | +| 3 | No stop by name | The commands that stop processes by name are denied, and one that ran voids the trial | +| 4 | A dead harness | A trial whose harness died under it is voided before the next run re-runs it `--from` that trial | +| 5 | The pen | Each trial's workspace sits in a pen of its own in the run root; the pen is the trial's, and a voided trial takes its whole pen | + +## Consequences + +What the pen did to the round it arrived in: + +| Consequence | Effect | +| ----------- | ------ | +| Round 5c | Round 5b stays as registered and runs again as round 5c | + +## History + +Every change to this decision, oldest first: + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| 2026-10-15 | A trial is both fenced and excluded: its file tools are denied every path it may not reach, and a trial whose transcript still reaches one, through the shell, is voided and re-run once; a second reach loses it without stopping the run | A deny rule matches a shell command's prefix, not its paths, so the shell cannot be fenced; a trial that read the hidden suite measures the suite, so counting it was never an option, and deciding after its scores were seen would be | solid-ai-templates#1907 | +| 2026-10-16 | A trial may not stop processes by name: the commands are denied, one that ran voids the trial, and a trial whose harness died under it is voided before the next run re-runs it `--from` that trial | Round 4's thin run ended after one trial when an agent stopped its dev server with `Get-Process -Name python \| Stop-Process`, which stopped the harness too; a probe showed a deny rule's glob matches anywhere in a command, chained ones included, and lets a stop by PID through | solid-ai-templates#1928 | +| 2026-10-29 | Each trial's workspace sits in a pen of its own in the run root; the pen is the trial's, and a voided trial takes its whole pen. Round 5b stays as registered and runs again as round 5c | A virtualenv the agent put beside its workspace, out of the repository, read as a reach and voided two of the first four trials of rounds 5 and 5b, though neither read another trial | — | diff --git a/docs/decisions/TEMPLATE.md b/docs/decisions/TEMPLATE.md new file mode 100644 index 0000000..f29bf28 --- /dev/null +++ b/docs/decisions/TEMPLATE.md @@ -0,0 +1,68 @@ +--- +id: "NNN" +status: Proposed +date: YYYY-MM-DD +category: design +supersedes: [] +superseded_by: [] +--- + +# ADR-NNN: Title in sentence case + + + +## Context + +Why the decision was needed: what a round showed, or what the benchmark has to +answer. + +## Decision + +What holds today, in one sentence. + +## Rationale + +Why, in two to four bullets, each tied to something named in the context. + +## Design + +The rules that make the decision concrete, where it has several: + +| # | Rule | In practice | +| - | ---- | ----------- | +| 1 | A short name | What the rule requires | + +## Alternatives considered + +Only the options the decision actually weighed: + +| # | Alternative | Outcome | +| - | ----------- | ------- | +| A | What the option is | Chosen | +| B | What the option is | Why not | + +## Consequences + +What the decision changes elsewhere: + +| Consequence | Effect | +| ----------- | ------ | +| | | + +## History + +Every change to this decision, oldest first. An issue `solid-ai-templates#N` +is in `solid-ai-dev/solid-ai-templates`, where the benchmark lived until the +split; `#N` is in this repository; a dash means none. + +| Date | Change | Why | Issue | +| ---- | ------ | --- | ----- | +| YYYY-MM-DD | What was decided | Why | — | diff --git a/docs/journeys/check/archive-and-report.md b/docs/journeys/check/archive-and-report.md index f68042a..e83b356 100644 --- a/docs/journeys/check/archive-and-report.md +++ b/docs/journeys/check/archive-and-report.md @@ -39,6 +39,6 @@ py tests/efficacy/report.py --root --templates | # | Finding | Status | | - | ------- | ------ | -| 1 | Round 3's run root and scoring area were deleted with nothing kept, so none of its readings can be re-run. Rounds are now archived before they are reported | Settled in [chapter 9](../../architecture/09-architecture-decisions.md), 2026-10-15 | +| 1 | Round 3's run root and scoring area were deleted with nothing kept, so none of its readings can be re-run. Rounds are now archived before they are reported | Settled in [ADR-019](../../decisions/019-archive-before-the-report.md), 2026-10-15 | | 2 | A file over 50 MB is refused, because a push would be | Settled in [ch. 6.4.2](../../architecture/06-runtime-view.md) | | 3 | The report lands in another repository, so this one holds no results | Settled: [the rounds index](../../rounds/README.md#reports) links every report | diff --git a/docs/journeys/prepare/generate-the-arms.md b/docs/journeys/prepare/generate-the-arms.md index 2e5fd11..10e844f 100644 --- a/docs/journeys/prepare/generate-the-arms.md +++ b/docs/journeys/prepare/generate-the-arms.md @@ -39,6 +39,6 @@ py tests/efficacy/generate_arm.py --arm inline --root | # | Finding | Status | | - | ------- | ------ | -| 1 | Retrying a refused generation until one passes would select the tersest sample. The instruction instead asks the model to measure every line before answering | Settled in [chapter 9](../../architecture/09-architecture-decisions.md), 2026-09-26 | +| 1 | Retrying a refused generation until one passes would select the tersest sample. The instruction instead asks the model to measure every line before answering | Settled in [ADR-002](../../decisions/002-the-arms.md), 2026-09-26 | | 2 | The prompt scan is broad and the output scan narrow: a spec-only token in the prompt means the wiring is wrong, and only data nobody could derive counts as an output leak | Settled in [ch. 5.5.4](../../architecture/05-building-block-view.md) | | 3 | Round 5's `reference` and `skills` arms are made by other means: fixed text, and `resolve_chain.py --emit` | Open in [round 5's registration, 13.4](../../rounds/round-5.md) | diff --git a/docs/journeys/read/re-read-an-old-round.md b/docs/journeys/read/re-read-an-old-round.md index fe9f70b..3047198 100644 --- a/docs/journeys/read/re-read-an-old-round.md +++ b/docs/journeys/read/re-read-an-old-round.md @@ -40,5 +40,5 @@ py tests/efficacy/report.py --root --cross-check | # | Finding | Status | | - | ------- | ------ | | 1 | The report refuses a cross-check root that holds no judging of the round's trials, since an empty one would print as agreement | Settled in [ch. 6.4](../../architecture/06-runtime-view.md) | -| 2 | Round 4 ran without the cross-check to keep the other vendor's plan free | Settled in [chapter 9](../../architecture/09-architecture-decisions.md), 2026-10-15 | -| 3 | Round 3's raw data was lost, so it cannot be re-read | Settled in [chapter 9](../../architecture/09-architecture-decisions.md), 2026-10-15 | +| 2 | Round 4 ran without the cross-check to keep the other vendor's plan free | Settled in [ADR-005](../../decisions/005-the-judge.md), 2026-10-15 | +| 3 | Round 3's raw data was lost, so it cannot be re-read | Settled in [ADR-019](../../decisions/019-archive-before-the-report.md), 2026-10-15 | diff --git a/docs/journeys/run/run-a-round.md b/docs/journeys/run/run-a-round.md index 723b054..44135bc 100644 --- a/docs/journeys/run/run-a-round.md +++ b/docs/journeys/run/run-a-round.md @@ -48,6 +48,6 @@ py tests/efficacy/score.py --root | # | Finding | Status | | - | ------- | ------ | | 1 | Each trial records the templates source's remote, ref and commit, and vendoring reads that ref with `git archive`, so the templates clone's HEAD may move during a run | Settled in [ch. 6.1.2](../../architecture/06-runtime-view.md) | -| 2 | A stray process-stop command in a trial once stopped the harness itself. Such commands are now denied, and a trial whose harness died is voided by the next run | Settled in [chapter 9](../../architecture/09-architecture-decisions.md), 2026-10-16 | +| 2 | A stray process-stop command in a trial once stopped the harness itself. Such commands are now denied, and a trial whose harness died is voided by the next run | Settled in [ADR-020](../../decisions/020-trial-isolation.md), 2026-10-16 | | 3 | A full disk ends a trial with `No space left on device`, and that trial is not a result | Settled in [ch. 7.2](../../architecture/07-deployment-view.md) | | 4 | A trial that prints its result but does not exit is ended two minutes later | Settled in chapter 6.1 |