- Status: accepted 2026-12-01, by Alessandro Prandini, the way recommended
(§5): (a), with the value in
Case.expect. Proposed the same day by the session that wrote it, at his request (P-1746). Three rulings of the construction are noted where they land, dated: §2 point 2, §2 point 3 and §5. Built in two pull requests: the core first, then thesuite.tomlform and the docs - Shipped: 1.5.0
- Date: 2026-12-01
- Opens: under the recommended way, one key per check and one field on
EvaluatorInputs. NoSCHEMA_VERSIONand noOUTPUT_VERSIONmove; no assertion identity and noconfig_hashof a suite that loads today moves (§2, point 5). Under the other two, less (§3, §4) - Amends: nothing yet. Accepted as recommended, it would note the sentence in
docs/api.mdthat says the assertions apply "to every case", beside it - Assumes: ADR 0002 and
fixed decision 9 (a case's data is payload, the verdict travels);
ADR 0003 §4 (a
prompt's digest does not travel) and
ADR 0022 §6, as corrected 2026-09-26 (an
assertion_iddigests a rubric, a needle, a pattern, unsalted, and a rubric comes from the same small space as a prompt); ADR 0027 §1 (which checks a case is asked is the driver's dispatch, read back bychecks_asked); ADR 0034 §4 (a projected document carries tokens, never a case's words); ADR 0065 §2 (config_hashcovers the checks and never the cases) - Touches: nothing in
CLAUDE.md's fixed section. Decision 1 holds under each way: a check stays a pure function ofEvaluatorInputs, callable on its own. Decision 9 holds: the value a case declares is the case's data and does not cross - Number: 0069. Swept on 2026-12-01 across
origin/main(a33b2496), every branch on the remote, every worktree of this repository and the open pull requests (two, Dependabot's). The highest number taken anywhere is 0068 - Owed: the three lines on digline.dev that every new record needs
Context¶
What happened. On a hand-written multi-turn agent in Python with a suite
of its own, each case expected something of its own: this answer must
contain one phrase, that one must not contain another, and on this sentence
the agent asks for clarification instead of answering. A digline check holds for
every case it is asked: docs/api.md says the assertions "apply to
every case: each one states something that must hold for all of them", and
Contains has one needle, NotContains one, LlmRubric one rubric. A
suite with twenty expectations would be twenty checks, each failing on the
nineteen cases it was not written for.
What a suite can do today, read at a33b2496:
- Which checks a case is asked is the driver's dispatch, read back by
checks_asked(src/digline/run/suite.py:1678): a suspended case nothing, a calibration case its one check, a reviewed answer the check it names and those on its steps, every other case every declared check. There is no way to ask a hand-written case one check and not another. - What a check receives is
EvaluatorInputs(src/digline/core/types.py:1075), built by the driver (src/digline/run/driver.py:710): the output, the input, the case'sexpectedandcontext, the cost, the latency, andmetadataholding{"case": Case.metadata, "response": Response.metadata}.Case.varsdoes not reach a check. So the "check of your own that readsCase.vars" that is the answer today cannot be written: a check of one's own readsinputs.metadata["case"], which isCase.metadata, and the expectation has to be put there. - A per-case value already exists once:
Equalscompares againstCase.expected. It is the precedent for a check that reads the case, and the limit of it: one value, the whole expected output, and onlyEqualsreads it. - What a check is identified by is its type and every declared field,
defaults included (
dataclass_identity,src/digline/core/assertions.py:150), so aneedleor arubricchanged in the suite is a new identity, and a comparison says so (AssertionBase.identity). A field added toContainsmoves the identity of everyContainsalready declared, even left at its default, unless the rule says otherwise (§4).
Decision¶
1. What every way has to answer¶
Five questions, the same for each way below:
- Identity and
config_hash. The name of the key a check reads is the check's declaration and enters both. The value is the case's data and enters neither: it lives with the case, whichconfig_hashnever covers (ADR 0065 §2). - What a changed value looks like. Because the value is in neither, a
case whose expectation was rewritten between two runs pairs its verdicts
as if nothing had moved. Today a rewritten
needleis a new identity. So each way says how a moved value is seen. - A case that declares no value for a check that reads one.
- The report, the projection and the MCP server.
- Compatibility and cost.
2. (a) Checks read a value from the case, by a key's name¶
Contains(needle_from="must")
NotContains(needle_from="must_not")
LlmRubric(rubric_from="criterion", judge=judge, threshold=0.7, tolerance=0.05)
Each check that has one text to look for or to judge against gains a second
way to get it: needle_from beside needle, rubric_from beside rubric,
exactly one of the two declared. The key names a value the case declares.
Where the value lives. The brief named vars, as vars.must. Proposed
here instead: a field of its own, Case.expect, a mapping of names to text,
read as expect.must. Case.vars are the target's inputs: a prompt template
renders them by name, an HttpTarget maps them into the request body, and a
target written in Python receives the case. An expectation kept among them is
one template edit away from being sent to the model it judges. Case.expect
reaches the checks and nothing else, through one new field on
EvaluatorInputs, expect. vars. stays possible as a path, and is the
alternative this paragraph does not take.
- Identity and
config_hash:needle_from="must"enters both, as the string"must". The value does not. - A moved value: the verdict records, in its metadata, a digest of the
value it read,
expect_digest, so a comparison of two full runs says the case's expectation changed for that check and case, as it says a flip. Noted 2026-12-01, by Alessandro Prandini's ruling: the digest is recorded from the first pull request, and the sentence incomparethat reads it arrives with the second. Closed 2026-12-02, with the second pull request:compareanddiffread the two documents'expect_digestfor each case and check and say the case's expectation changed, on the row and in the sentence, in English and in Italian, and in--jsonasexpectation_changedon a row andexpectations_changedandexpectations_unreadbeside the counts, keys added underOUTPUT_VERSION6. No exit code moves. Where one side read expectations and the other is redacted, the comparison says it cannot tell; where neither read any, it says nothing. The digest is of case data and is payload: absent from a redacted document and from a projection, so a projected comparison cannot say it, and says that it cannot. A short needle's digest can be guessed from a list of words, the reason ADR 0022 §6 gives for a rubric's, which is why it does not cross. - No value declared: the case is not asked that check. It is read in
checks_asked, beside the other branches, soidle_checks, the state of a suite and the plan already say it: asked of 12 cases, not of 8, which declare nomust. Not anerror, which would read as the harness failing, and not a pass, which would be vacuous (fixed decision 3). Noted 2026-12-01, by Alessandro Prandini's ruling: this holds of an ordinary case. A calibration case and a reviewed answer name the check they are asked, or ask every judged one, so one that would meet a check reading a key it does not declare is refused when the suite is assembled, by the case's name, rather than left unasked: a band or a person's yes with nothing to hold says nothing. - The report shows the verdict under the check's own name,
contains, and its reason, which already quotes the needle, as payload. The projection has nothing new to tokenise: the value is in no field that crosses, andneedle_from's key is part of the identity, which is already a digest. The MCP server returns facts, and the facts carry no needle and no rubric today; nothing changes, beside the count of cases not asked. - Compatibility: a minor. A suite that loads today loads the same.
No identity moves, by one rule added to
dataclass_identity: a field a class declares as omitted whileNoneis left out of the payload while it isNone, so aContainswithoutneedle_fromdigests exactly as it does today.tests/test_check_kind.py's pinned identities hold it. Cost: two pull requests. The first, the core:Case.expect, the field onEvaluatorInputs, the rule indataclass_identity,needle_fromonContainsandNotContains,affix_fromonAffix,rubric_fromonLlmRubric, the branch inchecks_askedand the driver, the digest. The second: thesuite.tomlkeys, the cases file'sexpect, the docs.
3. (b) A check that wraps: PerCase¶
PerCase(Contains, needle="expect.must")
PerCase(
LlmRubric, rubric="expect.criterion", judge=judge, threshold=0.7, tolerance=0.05
)
One new check that builds the inner check for each case, with the named parameter read from the case. No existing check changes.
- Identity and
config_hash:PerCase's, over the inner check's type, its other parameters, and the key's name, with the per-case value left out the wayRepeatedleaves out what it must (nested). No existing identity moves, without a rule indataclass_identity. - A moved value: the same digest as (a), the same limit.
- No value declared: the same, read in
checks_asked. - The report shows a check named
per_case, and its row says which check it wraps. Everything that names a check by name meets a second name for the same thing: an aggregate'sover="contains"does not find it, a calibration band (ADR 0067) is held toper_case, and a reviewed answer that namescontainsdoes not reach it. Projection and MCP as (a). - Compatibility: a minor, one new public name. Cost: one pull
request for the check, one for the
suite.tomlform, whose table has to carry an inner check's parameters inside another's.
4. (c) Nothing new: the check of one's own, documented¶
The expectation goes in Case.metadata, which reaches every check today as
inputs.metadata["case"], and the suite writes a check that reads it. The
docs page that says the assertions apply to every case says, beside it, how.
- Identity and
config_hash: the check's own fields, as for any check. - A moved value: unseen. Nothing records which value a verdict read unless the check's author writes it.
- No value declared: whatever the author writes; most will pass, which is the vacuous green fixed decision 3 names.
- The report shows a foreign verdict. The projection treats its metadata as foreign: keys as tokens, values withheld (ADR 0034 §17). MCP: nothing.
- Compatibility: nothing moves. Cost: one docs pull request. And a
suite.tomlcannot do it at all: a check of one's own is an object in asuite.py.
5. Recommended: (a)¶
(a), with the value in Case.expect. Three reasons, in the order they
weigh:
- A case not asked is a fact the product already says. Under (a) and
(b) a case with no expectation for a check is a branch of
checks_asked, so the plan,idle_checks, the state of a suite andwherealready count it. Under (c) it is whatever each author wrote, and the likeliest is a pass. - The check keeps its name. Under (b) every place that names a check,
over=, a calibration band, a reviewed answer's check, meetsper_casewhere the person wrotecontains, and each would learn the wrapper or be wrong about it. Under (a) aContainsthat reads its needle from the case is stillcontainseverywhere. - A moved expectation is said. (a) and (b) record the digest; (c) records nothing, so a case rewritten between two runs compares as if it had not moved.
Noted 2026-12-01, by Alessandro Prandini's ruling. Still contains
everywhere was true of the name and not yet of the count: an aggregate over
the check, over="contains", read a case never asked it as suspended,
because build_matrix reads an absent verdict that way, and its reason would
have said 8 suspended of cases nobody set aside. A case not asked the check
is counted apart, as not_asked on the case's outcome and
not_asked_excluded on the matrix: written in the aggregate verdict's
metadata only where it is not zero, as reviewed_excluded is, so no
document written before moves; said as N not asked in the reason; and
named in the report, in English and in Italian.
What (a) costs that (b) does not is the rule in dataclass_identity, a
change to how every identity is derived, held by the pinned identities. It is
one sentence of rule and one test, and the alternative, a wrapper with a
second name, is paid for in every reader of a check's name.
The expectation outside vars is recommended for its own reason and can
be decided apart: (a) works with vars. as its path, and an expectation in
the target's inputs is the risk §2 names.
Consequences¶
Under the recommendation, a hand-written case says what it expects of each check by name, a check that reads a name the case does not declare is not asked of it and says so, and a comparison of two full runs says when a case's expectation moved. Nothing in a projection or an MCP answer carries an expectation.
Not decided here¶
- Which other checks gain a
_fromform beyondContains,NotContains,AffixandLlmRubric:Regex's pattern is the next, and a pattern read from data is a pattern nobody reviewed with the suite. - Whether
expect_digestshould cross a projection keyed, as ADR 0022 §6 weighed for a rubric and refused. - A case that names a check to be asked, the other direction of the same question.