Skip to content

Upload each eval run's final reply in the dispatched suite run's artifact after a leak scan #18674

Description

@kyle-sexton

Context

About 65 eval cases fail on main, and their graders and judges cannot be classed or calibrated without the model's final reply, which the dispatched run of .github/workflows/pr-run-plugin-evals.yml keeps only in the --keep-temp traces on the runner and never uploads.

The owner chose option (A) of the "Eval replies in CI artifacts" row in the owner-decisions record, added by melodic-software/architecture#221 (merged: docs/owner-decisions.md#L393 at 4f147729). Option (A) from the row: "keep #18609 held, upload last_message in the existing 3-day artifact on dispatched suite runs after a leak scan, re-run those cases once (about 130 agent runs), then fix graders, judges or skills from the replies". Owner, verbatim: "go w/ recommendations".

This issue covers only the capture. The re-run and the fixes are separate work. Held PR: #18609.

Proposed work

  • Add .github/scripts/plugin-eval/last-messages.mjs: read one results.json, and for each case, arm and run, read the run's kept trace (tracePath) and take its final reply (the result event's text, else the last assistant text, as calibrate-judge.py's trace_reply reads it). Write one JSONL line per run, {case, arm, run, last_message}, to last-messages.jsonl beside results.json.
  • Before it writes the file, run lib/publish-gate.mjs scanLeak (the scanner the scan-upload action already runs over the artifact) on the file's bytes. On a block, write nothing and print one ::warning:: that names only the rule. Never print a reply to the job log.
  • Call it from the DISPATCHED block of the "Summarize the results" step in both the Run Eval and Run Eval Subscription jobs, so only dispatched suite runs capture: a label-started pull request run skips that block, and a compare run starts neither job.
  • Tests for the extraction and the scan gate, plus a workflow test for both call sites.
  • One line in docs/review/evals.md "Reading a result" naming the file and its 3-day retention.

Acceptance criteria

  • A dispatched suite run's eval-browser-<run id>-<attempt> artifact holds <plugin>/last-messages.jsonl, one line per run, when the leak scan blocks nothing.
  • When the scan blocks, the file is absent, the job log carries a ::warning:: naming the rule, and the rest of the artifact still uploads.
  • Label-started pull request runs and compare runs write no replies file.
  • No reply text reaches the job log or the step summary.
  • node --test passes on last-messages.test.mjs and workflow.test.mjs.

Activity

  1. added
    session-owned
    on Nov 24, 2026
  2. added theissue type on Nov 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    session-owned

    Type

    Fields

    No fields configured for Task.

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions