Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
106 commits
Select commit Hold shift + click to select a range
b37a163
fix(gitlab)!: post triage and prioritize results as new notes
tpouyer Nov 14, 2026
0361d25
fix(triage): answer review on the GitLab notes change
tpouyer Nov 15, 2026
2d5aa6d
fix(triage): carry open and ruled-out causes across re-triage runs
tpouyer Nov 15, 2026
feee97b
fix(triage): answer review on the carried cause lists
tpouyer Nov 16, 2026
48279eb
fix(triage): never trust a carried analysis from a non-triage account
tpouyer Nov 16, 2026
c667ef6
fix(triage): treat newer and Jira-marked comments as untrusted too
tpouyer Nov 16, 2026
9f127ef
fix(triage): trust Jira's own account, and narrow the plus check
tpouyer Nov 16, 2026
261a554
fix(triage): trust GitLab's own account by id, not a username pattern
tpouyer Nov 16, 2026
a1b6e7a
test(triage): keep a run-1 cause through a run that omits it
tpouyer Nov 16, 2026
ade870c
fix(triage): read GitHub comment authors from REST for the trust check
tpouyer Nov 16, 2026
87aae17
fix(triage): count a marked comment only when the triage account wrot…
tpouyer Nov 16, 2026
5101ed9
fix(triage): read GitHub comments with their authors from one listing
tpouyer Nov 16, 2026
1cc14f7
Merge #2037's trust fix into the carried cause lists
tpouyer Nov 16, 2026
fe731bf
fix(triage): fail closed when the account lookup fails
tpouyer Nov 16, 2026
41b8251
Merge #2037's fail-closed account lookup
tpouyer Nov 16, 2026
cf269b5
fix(triage): match the exact triage App and read GitHub comments from…
tpouyer Nov 16, 2026
3e15a1b
Merge #2037's exact triage App check
tpouyer Nov 16, 2026
3123bfa
test(eval): check each case's seeded_comments against its fixture
tpouyer Nov 16, 2026
8fddc96
fix(github-forge): keep the REST field paths in the comment listing
tpouyer Nov 16, 2026
2a3ca03
Merge #2037's REST field-path fix
tpouyer Nov 16, 2026
29a23a6
fix(triage): pick the newest analysis by creation time, not edit time
tpouyer Nov 16, 2026
85ca480
Merge #2037's creation-time ordering
tpouyer Nov 16, 2026
4507d4e
test(eval): leave cases without cause_lists out of its pass rate
tpouyer Nov 16, 2026
0a27289
fix(triage): compare the GitHub App slug with FULLSEND_SLUG
tpouyer Nov 16, 2026
968fe1e
Merge #2037's FULLSEND_SLUG check
tpouyer Nov 16, 2026
b22b9f5
fix(triage): order marked comments by creation time only
tpouyer Nov 16, 2026
0b57d1d
Merge #2037's creation-only ordering
tpouyer Nov 16, 2026
a2003cf
fix(triage): date a comment by its last edit only when the triage App…
tpouyer Nov 16, 2026
49f284c
Merge #2037's editor-aware ordering and App name set
tpouyer Nov 16, 2026
4186ada
fix(triage): trust only App names the triage sandbox has, compare the…
tpouyer Nov 16, 2026
09b6db4
Merge #2037's App name and paging fixes
tpouyer Nov 16, 2026
77c9466
fix(triage): a bot comment someone else last edited is a human comment
tpouyer Nov 16, 2026
a151b24
Merge #2037's rule for bot comments others edited
tpouyer Nov 16, 2026
3d6075f
fix(triage): leave never-edited comments trusted; say what GitLab edi…
tpouyer Nov 16, 2026
8f437f6
Merge #2037's never-edited fix
tpouyer Nov 16, 2026
d97ea7d
fix(triage): spot a foreign edit by its recorded editor on every tracker
tpouyer Nov 16, 2026
572b075
fix(gitlab-forge): name the GraphQL project path <REPO>
tpouyer Nov 16, 2026
7427507
Merge #2037's recorded-editor checks
tpouyer Nov 16, 2026
d09977e
fix(triage): match GitLab notes by their numeric id; page the editor …
tpouyer Nov 16, 2026
1116e95
Merge #2037's GitLab note-id and paging fix
tpouyer Nov 16, 2026
8eba4b4
fix(triage): judge a comment by its last editor; date GitLab notes th…
tpouyer Nov 16, 2026
742e081
Merge #2037's last-editor wording and GitLab dating
tpouyer Nov 16, 2026
863d3da
fix(triage): say how to compare a GitLab editor with the agent's account
tpouyer Nov 16, 2026
825a5ca
Merge #2037's GitLab editor-id comparison
tpouyer Nov 16, 2026
e58a21b
fix(triage): trust a custom App set; say when the identity lookup fails
tpouyer Nov 16, 2026
ce27860
docs(triage): link the issue that exports FULLSEND_APP_SET to triage
tpouyer Nov 16, 2026
afa8c3a
Merge #2037's custom App set and identity-lookup reporting
tpouyer Nov 16, 2026
f6c97fc
fix(triage): do not pass FULLSEND_APP_SET from the harness yet
tpouyer Nov 16, 2026
0103688
Merge #2037's harness revert for FULLSEND_APP_SET
tpouyer Nov 16, 2026
0f05e1c
fix(triage): pass FULLSEND_APP_SET through triage.env; trust the bare…
tpouyer Nov 16, 2026
2248382
Merge #2037's triage.env App set and bare-prefix trust
tpouyer Nov 16, 2026
e161f43
fix(triage): drop the bare App prefix from the trusted names
tpouyer Nov 16, 2026
dc671da
Merge #2037's trusted-name cleanup
tpouyer Nov 16, 2026
b9fa025
fix(triage): read Previous run folds as history, not findings
tpouyer Nov 16, 2026
14bc626
fix(triage): a comment's ruling is a claim, and cause_lists is report…
tpouyer Nov 16, 2026
e36c3b2
fix(triage): revive a cause only on evidence; keep colons in cause names
tpouyer Nov 16, 2026
de5c38b
Merge #2037's Previous run fold rule
tpouyer Nov 16, 2026
ef7f5da
fix(eval): say cause_lists is outside the nightly verdict; keep en da…
tpouyer Nov 16, 2026
5d14be4
fix(triage): keep fold-only causes as unverified; name the job that l…
tpouyer Nov 16, 2026
0b2f9d1
Merge #2037's fold-only causes and APP_SET wording
tpouyer Nov 16, 2026
ed2e20b
docs(triage): name the FULLSEND_APP_SET guard on the fourth trusted name
tpouyer Nov 17, 2026
9d95be9
fix(triage): restore a cause the baseline dropped but its fold still …
tpouyer Nov 17, 2026
16e5585
Merge #2037's FULLSEND_APP_SET guard wording
tpouyer Nov 17, 2026
354e445
docs(triage): a custom App set still matches through the harness slug
tpouyer Nov 17, 2026
e758b91
fix(triage): restore dropped causes from every fold, and say so in th…
tpouyer Nov 17, 2026
25e5d1c
Merge #2037's harness slug wording
tpouyer Nov 17, 2026
e8cea42
fix(triage): restore a dropped fold cause to its own list, and only w…
tpouyer Nov 17, 2026
f495ad9
test(triage): keep FULLSEND_APP_SET in the host file, not the harness
tpouyer Nov 17, 2026
ea2bdc8
Merge #2037's FULLSEND_APP_SET host-file test
tpouyer Nov 17, 2026
c6e6548
fix(triage): label human hypotheses unverified; tighten the APP_SET g…
tpouyer Nov 17, 2026
f465c3a
fix(triage): a fold's ruling needs evidence that holds now
tpouyer Nov 17, 2026
9628b50
Merge #2037's unverified label and APP_SET guard
tpouyer Nov 17, 2026
81b8ef3
test(triage): check the APP_SET host file is wired and expanded
tpouyer Nov 17, 2026
8a3d337
fix(triage): name the fold order, keep the unverified ending, recover…
tpouyer Nov 17, 2026
40765ed
Merge #2037's host-file wiring guard
tpouyer Nov 17, 2026
e6098e0
fix(triage): drop the fold-restore rule; track it in #2043 and #2053
tpouyer Nov 17, 2026
7b942d6
docs(triage): fold copies carry no marker
tpouyer Nov 17, 2026
2142f9f
feat(triage): pick the trusted prior analysis with a script
tpouyer Nov 17, 2026
ebd9394
fix(triage): harden the prior-triage scripts after review
tpouyer Nov 17, 2026
8ac7b83
fix(triage): read the prior triage analysis in the pre-script
tpouyer Nov 17, 2026
41a352e
fix(triage): per-job prior triage file, full Jira paging, earlier res…
tpouyer Nov 17, 2026
1dfe2a8
fix(triage): never fail the pre-script on a write, keep dropped rulings
tpouyer Nov 17, 2026
bb4f943
fix(triage): trust nothing on editor query errors; stale-file clause
tpouyer Nov 17, 2026
c1966a1
docs(triage): fold copies carry no marker, in the rebuild rule too
tpouyer Nov 17, 2026
fcf1107
fix(triage): a rebuilt cause stays unverified until checked
tpouyer Nov 17, 2026
085d85d
feat(triage): pick the trusted prior analysis with a script
tpouyer Nov 17, 2026
3791464
fix(triage): harden the prior-triage scripts after review
tpouyer Nov 17, 2026
e265e1c
fix(triage): read the prior triage analysis in the pre-script
tpouyer Nov 17, 2026
e9dad37
fix(triage): per-job prior triage file, full Jira paging, earlier res…
tpouyer Nov 17, 2026
585c1e6
fix(triage): never fail the pre-script on a write, keep dropped rulings
tpouyer Nov 17, 2026
29b6d74
fix(triage): trust nothing on editor query errors; stale-file clause
tpouyer Nov 17, 2026
502a4af
docs(triage): fold copies carry no marker, in the rebuild rule too
tpouyer Nov 17, 2026
e940bc7
fix(triage): fail closed on a planted prior triage dir, catch read races
tpouyer Nov 17, 2026
97e1476
fix(triage): recheck the prior triage dir around the copy
tpouyer Nov 17, 2026
37e6541
fix(triage): follow X-Next-Page before treating a short page as the last
tpouyer Nov 17, 2026
fb7ec6f
Merge fork/triage-prior-script history after rebasing onto #2044 fcf1107
tpouyer Nov 17, 2026
4575334
fix(triage): no slack in the read-race check
tpouyer Nov 17, 2026
f654393
docs(triage): say where the strict read-race check can misfire
tpouyer Nov 17, 2026
16a5000
docs(triage): fullsend's triage job now exports FULLSEND_APP_SET
tpouyer Nov 17, 2026
0f21a46
Merge #2037's FULLSEND_APP_SET caveat update
tpouyer Nov 17, 2026
bb4b93e
Merge #2044's FULLSEND_APP_SET caveat update
tpouyer Nov 17, 2026
26e11d9
fix(triage): stage text only for trusted records; cite fullsend's ADRs
tpouyer Nov 17, 2026
74161bf
docs(triage): fold text is a claim; cite the sandbox hooks
tpouyer Nov 17, 2026
f2a4496
Merge main into gitlab-doors-append
tpouyer Nov 17, 2026
c23a9fe
Merge #2037 (with main) into triage-carry-state
tpouyer Nov 17, 2026
d658f5a
Merge #2044 (with main) into triage-prior-script
tpouyer Nov 17, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ script-test:
$(call run-timed,bash scripts/labels-test.sh)
$(call run-timed,bash scripts/post-triage-test.sh)
$(call run-timed,bash scripts/pre-triage-test.sh)
$(call run-timed,bash scripts/prior-triage-test.sh)
$(call run-timed,bash scripts/pre-prioritize-test.sh)
$(call run-timed,bash scripts/post-prioritize-test.sh)
$(call run-timed,bash scripts/pre-code-test.sh)
Expand Down Expand Up @@ -121,6 +122,7 @@ script-test:
$(call run-timed,bash eval/scripts/teardown-fixture-test.sh)
$(call run-timed,bash eval/scripts/capture-fixture-test.sh)
$(call run-timed,bash eval/scripts/finding-expectations-test.sh)
$(call run-timed,bash eval/scripts/cause-lists-test.sh)
$(call run-timed,bash eval/scripts/state-and-action-checks-test.sh)
$(call run-timed,bash eval/scripts/aggregate-nightly-test.sh)
$(call run-timed,bash eval/run-functional-test.sh)
Expand Down
52 changes: 43 additions & 9 deletions agents/triage.md

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion behaviour/features/prioritize.feature
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Feature: Prioritize posts the RICE score on the issue
A write actor's "/fs-prioritize" comment on an issue dispatches
prioritize. The dummy agent emits RICE scores chosen so the
post-script's score, round2(R*I*C/E) = round2(2*3*0.5/2), is exactly
1.5. The post-script must post its sticky RICE comment on the issue.
1.5. The post-script must post a RICE comment on the issue.

Scenario: /fs-prioritize posts the RICE score comment
Given the enrolled test repository
Expand Down
4 changes: 2 additions & 2 deletions docs/prioritize.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

Scores an issue using the RICE framework (Reach, Impact, Confidence, Effort) and produces scores with reasoning for project board ranking. Supports GitHub and GitLab forges. A Jira Cloud forge exists in the harness but is **dark**: it is not dispatched, does not change `/fs-prioritize` on GitHub or GitLab, and is used only when `FULLSEND_FORGE=jira`.

On GitHub, scores are written to Projects V2 custom fields and posted as a reasoning comment. On GitLab, scores are posted as a sticky issue comment. GitLab custom fields API integration is deferred — the Issues API silently ignores unknown keys, and the correct Custom Fields API requires Premium/Ultimate with runtime field ID resolution.
On GitHub, scores are written to Projects V2 custom fields and posted as a reasoning comment. On GitLab, scores are posted as an issue comment; each run adds a new comment rather than editing the earlier one. GitLab custom fields API integration is deferred — the Issues API silently ignores unknown keys, and the correct Custom Fields API requires Premium/Ultimate with runtime field ID resolution.

On Jira, when that forge is explicitly selected, the computed RICE score is written to one number custom field named exactly `RICE Score` (located on the `Prioritization` tab). The complete breakdown is in the sticky comment: the Reach, Impact, Confidence, and Effort scores with their reasoning, the RICE formula, and the final score. No separate Reach, Impact, Confidence, or Effort fields are created or written, and Rank, Priority, and other Jira fields are never written. The post-script fails closed if the `RICE Score` field is missing, duplicated, not a custom field, or not a number field.

Expand Down Expand Up @@ -43,7 +43,7 @@ skill data.
The prioritize agent does not apply or consume control labels. It reads the
issue content and produces a score. On GitHub, the project board is updated
directly via Projects V2 custom fields. On GitLab, scores are posted as
a sticky comment on the issue. On Jira (opt-in forge only), the single
a new comment on the issue each run. On Jira (opt-in forge only), the single
`RICE Score` number field is updated and the sticky comment carries
the full breakdown; Rank and Priority are not written.

Expand Down
85 changes: 80 additions & 5 deletions docs/triage.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,18 @@ The harness also declares a CEL `trigger:` for fullsend's harness dispatch: an i
The `/fs-triage` command does not accept arguments — it re-evaluates the issue
using current content, comments, and any prior triage analysis.

Every `sufficient` triage comment carries an **Open causes** list and, once
anything has been refuted, a **Ruled out** list, one line of evidence per
cause, just before the footer the post-script adds. A re-triage starts from
the newest full analysis: it keeps open causes unless it refutes them, and
keeps ruled-out causes out unless new evidence revives them. Only an analysis posted by the triage bot account, and not last edited by
anyone else, is carried this way (on GitLab and Jira, by the account the
tracker credential belongs to); any other marked comment, and the
`Previous run` history fullsend folds into an edited comment, is re-checked
against the evidence instead. A comment saying a cause is wrong, or that a
ruled-out cause is right, moves it only when evidence in the code or the
issue backs it.

## Control labels

These labels are managed by the triage agent based on its assessment of the issue.
Expand Down Expand Up @@ -253,6 +265,66 @@ variable, which the harness sets based on the detected CI platform (`github`,
forward-compatible override when set, but the harness itself only ever sets
`FULLSEND_FORGE`.

Re-running triage posts the result differently per tracker:

- **GitLab:** every run, a retry included, posts the `sufficient` or
`in-progress` result as a new note and never edits an earlier one.
- **GitHub and Jira:** the `sufficient` and `in-progress` results edit the
earlier marked comment until fullsend-ai/fullsend#9399 lands, which is
expected to make them post a new comment each run as well.

A re-run treats an earlier marked comment as its own prior analysis only
when the triage account wrote it and made its last edit; any other marked
comment is read as a human comment, and so is the `Previous run` history
fullsend folds into an edited comment. The pre-script
(`scripts/pre-triage.sh`, with `scripts/lib/prior-triage.lib.sh`) reads every
page of comments on the host, applies these rules, lists the causes an older
analysis or fold names that the newest one dropped, and writes the result to
`${RUNNER_TEMP}/triage-workspace-${CI_JOB_ID}/prior-triage.json` (`CI_JOB_ID`
is empty on GitHub), which the harness copies into the sandbox for the agent.
The file is a snapshot taken before the agent starts. If something
another user made sits at the job's directory and cannot be replaced, the
pre-script fails the run rather than let the harness copy it in. Without `RUNNER_TEMP` there is no file, and
the agent reads the comments itself and trusts none of them. The pre-script
identifies that account per tracker:

- **GitHub:** a `Bot` author whose App is `<owner>-triage`,
`fullsend-ai-triage` or, when `FULLSEND_APP_SET` is not empty,
`${FULLSEND_APP_SET}-triage` (the names the review pre-script trusts for
the review App, with `-triage`). fullsend's route-based `triage` job, which
runs the built-in triage agent, exports `FULLSEND_APP_SET` since
fullsend-ai/fullsend#9575, as the `harness-run` job already did (both in
fullsend's `.github/workflows/reusable-dispatch.yml`). An install on a
fullsend release before that change (v0.56.1 or earlier) whose custom App
set is not named after the repository owner matches none of these names,
so it gets no trusted baseline and the agent rebuilds its lists from the
earlier analyses.
- **GitLab:** the account `GET /api/v4/user` returns for `GITLAB_TOKEN`.
- **Jira:** the account `GET /rest/api/3/myself` returns, which needs the
`read:jira-user` scope (or the granular `read:user:jira`) on
`FULLSEND_JIRA_TOKEN`. Without it, there is no trusted baseline: the
agent rebuilds both lists from every earlier analysis and says so in the
`reasoning` field of the run's result, which is not posted to the issue.

Relation to fullsend's specs (`docs/ADRs` in fullsend-ai/fullsend):

- The GitHub App-name list is an interim naming convention. ADR 0107 does
not accept App names as bot identity. The list is to be replaced by the
mint's registered `bot_role == "triage"` once fullsend-ai/fullsend#9602
exposes that lookup to harness scripts. The GitLab and Jira own-account
match is an exact identity, pending confirmation in #9602.
- Following ADR 0133, the file carries text only for comments the
pre-script trusts. Their `Previous run` folds are included as claims,
since a fold may hold text someone else edited before fullsend folded it.
Other marked comments are listed by id and reason, and the agent reads
them itself with its forge skill. The trusted text is not run through an
input scanner on the host. fullsend's sandbox PostToolUse hooks (Unicode,
secret redaction, context suppression; on by default for every tool) see
it when the agent reads the file, as they see its own comment reads.
- The pre-script is an interim, agents-side subset of ADR 0141's
entity-context snapshot and agent-run receipts. Step 2e moves to those
when they ship.

### Jira setup

Jira triage requires the following env vars, mirroring the shape of the
Expand Down Expand Up @@ -313,11 +385,14 @@ The run stops before any write if `FULLSEND_WORK_ITEM_KEY` does not match
that URL, or if an explicit `FULLSEND_TRACKER` or `ISSUE_URL` points
somewhere else.

- **Retries:** comments are idempotent. Sticky comments (`sufficient`,
`in-progress`) use fixed markers. Other comments use a marker scoped to the
CI run (`GITHUB_RUN_ID` or `CI_PIPELINE_ID`). A re-run of the same workflow
or pipeline edits its earlier comment, while a new triage run still posts a
new one.
- **Retries:** on Jira, comments are idempotent. Sticky comments
(`sufficient`, `in-progress`) each use their own fixed marker, so every
run edits the earlier comment with that marker. Other comments use a
marker scoped to the CI run (`GITHUB_RUN_ID` or `CI_PIPELINE_ID`): a
re-run of the same workflow or pipeline edits its earlier comment, while a
new triage run posts a new one. This is expected to change once
fullsend-ai/fullsend#9399 lands (see [Multi-forge
support](#multi-forge-support)).
- **Write failures:** a failed Jira write fails the step. This covers label
adds and removals, component updates, comments and transitions.
- **Updates that cannot be applied:** these are listed under **Not applied in
Expand Down
6 changes: 6 additions & 0 deletions env/github/triage.env
Original file line number Diff line number Diff line change
@@ -1 +1,7 @@
export ISSUE_URL="${GITHUB_ISSUE_URL}"
# The install's GitHub App prefix, which step 2e of agents/triage.md names
# (scripts/pre-triage.sh reads the same value on the host). Host
# files expand an unset variable to empty, so this is safe where it is
# unset: fullsend's triage and harness-run jobs export it, the triage job
# since fullsend-ai/fullsend#9575, so an older fullsend leaves it empty.
export FULLSEND_APP_SET="${FULLSEND_APP_SET}"
22 changes: 18 additions & 4 deletions eval/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ other judges run and are reported, but don't fail the run:
`triage_quality`)
- live-model behaviour checks: `finding_expectations`, `required_labels`,
`forbidden_labels`, `risk_label_present`, `expected_files`,
`expected_state`, `expected_review_action`
`expected_state`, `expected_review_action`, `cause_lists`
- the `max_turns`/`max_cost` budget judges

Their thresholds stay in each `eval.yaml`; `run-functional.sh` drops
Expand Down Expand Up @@ -146,11 +146,15 @@ eval/scripts/aggregate-nightly.sh eval/review/eval.yaml \

- **Behaviour checks** (`finding_expectations`, `required_labels`,
`forbidden_labels`, `risk_label_present`, `expected_files`,
`expected_state`, `expected_review_action`) with a `min_pass_rate`: a
`expected_state`, `expected_review_action`, `cause_lists`) with a
`min_pass_rate`: a
case fails the check when it is `false` in at least
2 of the given runs. The nightly pass rate is the share of cases that
do not fail, and is compared with `min_pass_rate`. A flake that hits a
different case each night passes; a case that keeps failing does not.
`cause_lists` has no `min_pass_rate` yet: it is scored in each run's
summary but is not part of the nightly verdict until its cases have run
live (fullsend-ai/agents#2043).
- **Quality judges** (`*_quality`) with a `min_mean`: the verdict fails
when the median of 3 non-null per-run means is below `min_mean`. With
fewer than 3, the judge reports "insufficient history" and does not
Expand Down Expand Up @@ -301,15 +305,22 @@ Each case directory under `eval/<agent>/cases/` contains:
- `input.yaml` — fixture definition (forge, fixture type, title, body,
PR files). `${REPO_URL}` in a fixture body expands to the ephemeral GitHub
repository URL. Issue cases may set `labels`, applied before the agent runs
(e.g. `ready-to-code` for a code case). Pull-request cases may add
(e.g. `ready-to-code` for a code case). GitHub issue cases may also set
`comments`, a list of comment bodies posted oldest first before the agent runs (e.g. earlier triage
analyses, marked as the agent recognizes them, for a re-triage case). Pull-request cases may add
`followup_files`, `commit_message` (default `eval: fixture changes`),
and a `prior_review` body/provenance to exercise a re-review. Each PR
file is written ending with exactly one final newline, whatever block
style its `content` uses.
- `annotations.yaml` — expected outcomes (labels, final `state`, review
expectations, and for review cases an optional `review_action` list of
actions allowed in the review-findings marker, which can keep an agent's
approve after a post-review downgrade) and the report-only budgets:
approve after a post-review downgrade), for triage cases an optional
`cause_lists` block checked against the run's own comment (`seeded_comments`,
required: how many `fixture.comments` precede the run, 0 for none; `open`
and `ruled_out`, lists of phrase groups; `forbidden_open`; a case without
the block is not scored by that check), and the
report-only budgets:
`max_cost_usd`, plus `max_turns` where the eval has a `max_turns` judge.
Set `release: true` to include the case in `EVAL_TIER=release` runs (see
[Tiers](#tiers) above).
Expand All @@ -321,6 +332,9 @@ to must exist in its fixture repo (`repo/`, plus the PR's files) or in
the fixture's `labels`. The expected outcome in `annotations.yaml` must
be what a careful engineer would conclude from that repo alone: an agent
that checks the code and finds a gap will rightly answer `needs-info`.
A re-triage case may name things the repo cannot contain inside its seeded
`comments` (for example a cause supported only by an earlier analysis), when
carrying that state forward is what the case grades.
When a case needs code that the shared fixture repo lacks, give the case
its own repo under `eval/<agent>/repos/` rather than changing the shared
one (e.g. triage cases 001 and 003).
Expand Down
4 changes: 3 additions & 1 deletion eval/run-functional-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,8 @@ thresholds:
min_pass_rate: 1.0
expected_review_action:
min_pass_rate: 1.0
cause_lists:
min_pass_rate: 1.0
pr_created:
min_pass_rate: 1.0
new_commit:
Expand Down Expand Up @@ -466,7 +468,7 @@ for tier in full release; do
fi
run_test
SRC_KEYS="$(yq -r '.thresholds | keys | length' "${ROOT}/eval/testagent/eval.yaml")"
if [[ "$SRC_KEYS" == "14" ]]; then
if [[ "$SRC_KEYS" == "15" ]]; then
pass "${tier} tier leaves the checked-in eval.yaml thresholds untouched"
else
fail "${tier} tier leaves the checked-in eval.yaml thresholds untouched (got ${SRC_KEYS} keys)"
Expand Down
6 changes: 3 additions & 3 deletions eval/run-functional.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
# (*_quality), the live-model behaviour checks
# (finding_expectations, required_labels,
# forbidden_labels, risk_label_present, expected_files,
# expected_state, expected_review_action)
# expected_state, expected_review_action, cause_lists)
# and the max_turns/max_cost budget judges still run and
# report, but their thresholds are dropped at runtime.
# If unset, defaults to "release" when running as a
Expand Down Expand Up @@ -210,13 +210,13 @@ yq_expr=".dataset.path = \"${CASES_DIR}\""
# "_quality", e.g. review_quality/triage_quality), the live-model behaviour
# checks (finding_expectations, required_labels, forbidden_labels,
# risk_label_present, expected_files, expected_state,
# expected_review_action) and the max_turns/max_cost budget
# expected_review_action, cause_lists) and the max_turns/max_cost budget
# judges. score.py's detect_regressions() only gates on judges with a
# thresholds: entry, so dropping these leaves them running and reported but
# out of the pass/fail decision. The deterministic contract judges
# (pr_created, new_commit, sandbox_started) keep their thresholds. The
# checked-in eval.yaml keeps every threshold; only the runtime copy drops them.
yq_expr+=' | .thresholds |= with_entries(select(.key | test("^(finding_expectations|required_labels|forbidden_labels|risk_label_present|expected_files|expected_state|expected_review_action|max_turns|max_cost)$|_quality$") | not))'
yq_expr+=' | .thresholds |= with_entries(select(.key | test("^(finding_expectations|required_labels|forbidden_labels|risk_label_present|expected_files|expected_state|expected_review_action|cause_lists|max_turns|max_cost)$|_quality$") | not))'
yq "$yq_expr" "$EVAL_YAML_SRC" > "$EVAL_YAML"
HARNESS_DIR="${AGENT_EVAL_HARNESS_DIR:-${EVAL_DIR}/.agent-eval-harness}"

Expand Down
7 changes: 7 additions & 0 deletions eval/scripts/aggregate-nightly-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,8 @@ thresholds:
min_pass_rate: 1.0
expected_review_action:
min_pass_rate: 1.0
cause_lists:
min_pass_rate: 1.0
EOF

# state_action_summary <name> <expected_state value> <expected_review_action value>
Expand All @@ -184,12 +186,16 @@ judges:
scored_cases: 1
expected_review_action:
scored_cases: 1
cause_lists:
scored_cases: 1
per_case:
001-a:
expected_state:
value: $2
expected_review_action:
value: $3
cause_lists:
value: $2
EOF
echo "$file"
}
Expand All @@ -199,6 +205,7 @@ run_agg "${TMPDIR}/eval-state-action.yaml" \
expect "expected_state false in 2 of 3 runs fails; expected_review_action false once passes" 1 \
'^expected_state .*false in 2\+ runs: 001-a -> FAIL$' \
'^expected_review_action .*nightly pass rate 1.00 over 1 case\(s\) -> PASS$' \
'^cause_lists .*false in 2\+ runs: 001-a -> FAIL$' \
'^NIGHTLY VERDICT: FAIL$'

# --- Quality judges -----------------------------------------------------
Expand Down
6 changes: 3 additions & 3 deletions eval/scripts/aggregate-nightly.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
# score.py summary, newest first, 1 to 3 of them.
#
# Behaviour checks (finding_expectations, required_labels, forbidden_labels,
# risk_label_present, expected_files, expected_state, expected_review_action)
# with a min_pass_rate: a case fails the check when its per_case value is
# risk_label_present, expected_files, expected_state, expected_review_action,
# cause_lists) with a min_pass_rate: a case fails the check when its per_case value is
# false in at least 2 of the given runs.
# The nightly pass rate is the share of cases (scored in at least one run)
# that do not fail; below min_pass_rate is a FAIL.
Expand Down Expand Up @@ -127,7 +127,7 @@ done
REACHED='.per_case // {} | to_entries[]
| select(.key as $k | strenv(NR) | contains("," + $k + ",") | not)'

BEHAVIOUR_CHECKS=(finding_expectations required_labels forbidden_labels risk_label_present expected_files expected_state expected_review_action)
BEHAVIOUR_CHECKS=(finding_expectations required_labels forbidden_labels risk_label_present expected_files expected_state expected_review_action cause_lists)

overall="PASS"
lines=()
Expand Down
Loading
Loading