Skip to content

feat(runs): add the run-to-fix skill, from a finished run to checked fixes and a compared rerun - #244

Open
opPO333 wants to merge 14 commits into
ThinkFlowLab:mainfrom
opPO333:feat/run-to-fix-skill
Open

opPO333 wants to merge 14 commits into
ThinkFlowLab:mainfrom
opPO333:feat/run-to-fix-skill

Conversation

@opPO333

@opPO333 opPO333 commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

Closes #241

What

  • /run-analysis ends at what to fix. Nothing took a finished run to a checked fix.
  • /run-to-fix does, in rounds of five stages: read, classify, check, select, compare.
  • A round stops twice for a person: which fixes to keep, and what runs next at what price. The skill writes each
    paid command to a file and a person starts it.
  • scripts/loop.py keeps the records in a loop folder outside git. One adapter file holds what belongs to one agent.
  • A task with an accepted flag is out of every stage. A trial labelled environment or evaluator is out of the
    groups. nullius.runs.failure_analysis reads both.
  • read --fixed-copy keeps the tasks a /fix-flawed-tasks copy fixed.
  • A task unsolved on the run and the baseline is a suspect for /find-flawed-tasks.
  • No text sends the reader to a task's verifier or expected answer.

Verified

  • Skill tests: 213 pass, 236 s. CI does not run them:
    cd .agents/skills/run-to-fix/tests && python3 -m unittest
  • Backend suite 3915. Docs check: 0 findings.
  • On real Harbor and standard jobs, before the flags work: read, classify, compare matched a count by hand.
  • Not checked: a real run with flags; a real fixed copy; stages 3 and 4 on the standard path.

Risk

Agents

  • Claude Code, Opus 5.5
  • Claude Code, Fable 5.2

@opPO333

opPO333 commented Nov 19, 2026

Copy link
Copy Markdown
Contributor Author

/judge

@github-actions

This comment has been minimized.

@opPO333

opPO333 commented Nov 19, 2026

Copy link
Copy Markdown
Contributor Author

/judge

@github-actions

This comment has been minimized.

@opPO333

opPO333 commented Nov 20, 2026

Copy link
Copy Markdown
Contributor Author

/judge

@github-actions

This comment has been minimized.

@opPO333
opPO333 marked this pull request as ready for review November 20, 2026 22:03
aitianshi added a commit that referenced this pull request Nov 25, 2026
… judge's tests and docs rows (#418)

Closes #417

## What

- AGENTS.md: 4,041 to 1,293 words. `check_docs.py` no longer asks for
modules.
- A page and its command change together; one look for pages (`ui.md`).
- Skills move to `.agents/skills`; `.claude/skills` links there.
- Issue forms, template, `file-issue` skill: under 150 words, an
example, P0 to P3. Draft pull requests.
- Judge: no tests or docs rows; short descriptions, no risk and "Nothing
visible changes." pass; code read before tests.
- Versions: Official or Experiment (#420).
- Outdated text fixed: README, CONTRIBUTING, packaging, `running.md`,
`launch.json`.

## Verified

- Three reviews: no blocker.
- #416's body, rewritten: 128 to 173 words; before, 532.
- Routes 708, backend 3044.

## Risk

- 8 open pull requests conflict on AGENTS.md: take this version. #412
and #244 move their skill.
- A pull deletes ignored files under `.claude/skills`.
- Windows without symlinks: `.claude/skills` is a file.
- Undo: revert.
@github-actions github-actions Bot added the merge conflict Conflicts with its base: merge or rebase it label Nov 25, 2026
The skill as pull request ThinkFlowLab#244 holds it at 7de82f9, placed in the skill library with its link and its row in AGENTS.md. No file of the skill is changed.
read loads the run's failure-analysis.json through nullius.runs.failure_analysis and records what the round leaves out in round-NN/left-out.json. A task with an accepted flag that covers one of its trials is out of the groups, the targets, guards and canaries of select, the trials of decide --stop 2 and the pairs of compare, on every run. A trial labelled environment or evaluator is out of the groups of classify and the causes built on them. trials.csv keeps every trial with a left_out column; groups.json counts the left-out trials and tasks by reason. A round read before this change is refused.
read takes --fixed-copy, the folder /fix-flawed-tasks wrote, which the person states the run used. A flagged task with a record in its APPLIED.json whose label is not no-fix stays in the search; one with only no-fix records, or none, stays out. Names are matched as nullius flags names a task. A folder without APPLIED.json, or a copy that names no task of the run, is refused. The record keeps the folder and the SHA-256 of its MANIFEST.json.
…e baseline

A suspect is a task unsolved on the run and on the baseline and not left out. groups.json lists the suspects, each with whether a pending flag exists, and the warning fails_on_baseline counts and names a group's suspects from one task up. Its text and the docs send suspects to /find-flawed-tasks on the run and the baseline, and say that a suspect with no accepted flag stays in the search for an agent cause.
…answer

The skill no longer tells its reader to open a task's verifier or expected answer: a task the benchmark may have wrong goes to /find-flawed-tasks. It gains the rule the neighbouring skills carry, "The answers stay here": a fix changes how the agent works on any task and never holds a value, name or text that one task's check expects.
A cause's layer is model, agent, environment or evaluator: the labels Nullius gives a failed trial, in SKILL.md and the cause example of references/files.md. No script, test or asset holds the earlier words.
left-out.json keeps the SHA-256 of the fixed copy's MANIFEST.json file and the hash field inside it, the copy's total hash that /fix-flawed-tasks reports. A manifest that is not JSON or holds no hash stops read with its path. The Limits of SKILL.md say where --fixed-copy applies: a dataset with one folder per task, each named as nullius flags shows the task.
… path

read --fixed-copy stopped with a traceback when the copy's APPLIED.json was not JSON or could not be read. It now stops with the file's path and the error, as it does for MANIFEST.json.
… check

check counted the trials of flagged tasks in its replay table, false successes, touched and changed trials, which decision-1.md shows the person. It now counts only the trials outside the flagged tasks; the replay still labels every recorded trial.
A job of the standard names a task by its unit with / turned into -, so units x/y and x-y share the task name x-y. Every stage of run-to-fix counts by task name, and a flag on one of them left both out. read now refuses such a run and names the task and its units. A Harbor job whose datasets share a task name is still read. The test fixture can give a unit that differs from the task name.
"The answers stay here" now covers the test of stage 3 and what it records. Where the skill sends its reader to the investigation guide of run-analysis, it says that a trial's verifier output serves to group and understand failures, and that what it shows of the expected outcome goes into no test and no fix.
cross_check compared run-analysis with its own copy of the pair count, while compare used pairs_of. pairs_of now lives beside cross_check, which calls it, so the count compare reports is the one checked against run-analysis.
run_names refused a task whose trials give two unit ids. Both callers pass the trials of the round's run, and read refuses such a run first, so the check could not run.
…tasks

kept_recorded of check counted every trial the replay names, beside a table that leaves the flagged tasks out, and decision-1.md printed both side by side. It now counts the same trials as the table. The checks.json row of references/files.md says which trials the replay's counts cover.
@opPO333
opPO333 force-pushed the feat/run-to-fix-skill branch from 7de82f9 to 88071e5 Compare December 5, 2026 02:34
@github-actions github-actions Bot added needs review Tests pass, no conflict, no verdict on its latest commit and removed merge conflict Conflicts with its base: merge or rebase it labels Dec 5, 2026
@opPO333

opPO333 commented Dec 5, 2026

Copy link
Copy Markdown
Contributor Author

/judge

@github-actions

github-actions Bot commented Dec 5, 2026

Copy link
Copy Markdown

🟡 PR judge · 4 of 5 yes · #244 ↔ #241

Merge risk 🟢 MINOR the judge's reading of the diff
Depth 🟡 MEDIUM the deepest path is .agents/skill-library/evaluation/run-to-fix/SKILL.md
Question Verdict
Changes do what the issue asks · 10 of 12 criteria ⚠️ partly
Issue and pull request describe the same change ✅ yes
Description matches the diff ✅ yes
Diff stays in scope ✅ yes
Risk named in the description ✅ yes
Before and after shown –
Acceptance criteria, 10 of 12 met
# Criterion Verdict
1 .agents/skill-library/evaluation/run-to-fix/ holds SKILL.md, the reference pages, the scripts and their tests, with… ✅ met (cut)
2 The scripts import the Python standard library and nullius.runs of the checkout they are in, and their tests pass wit… ✅ met (cut)
3 A test builds the same trials as a job of a Harbor recipe and as a job of the standard and gets the same classes for bo… ⚠️ partial (cut)
4 No script names an agent, and a test runs read, classify and compare for a made-up agent whose adapter has no command a… ✅ met (cut)
5 A test proves that a command named as paid is written to a file and not started, for a check and for a trial run. ✅ met (cut)
6 Every budget is an argument with no default value. ✅ met (cut)
7 A test proves that the agent's checkout is unchanged after a check and that no worktree is left. ✅ met (cut)
8 A test gives the verdict noise when the exact test on the won and lost tasks gives p of 0.05 or more, and improved or r… ✅ met (cut)
9 read refuses a loop folder that git would list as untracked. ✅ met (cut)
10 The Verified section of the pull request records one round on recorded runs of a real agent, and one round on a job of … ⚠️ partial (cut)
11 A task with an accepted flag is in no stage, and a trial labelled environment or evaluator is in no group. A test s… ✅ met (cut)
12 No text of the skill sends its reader to a task's verifier or expected answer. ✅ met (cut)
Checks the script runs itself, 4 of 4 pass
No machine attribution trailer in the commits or the description ✓
New code under app/, docs/, .github/, .agents/ or .claude/ ✓
No Flask import under the backend package ✓
No key-shaped string in the diff ✓

some of the diff was cut before the judge read it

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs review Tests pass, no conflict, no verdict on its latest commit

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Skills: take a finished run from its failures to checked fixes and a compared rerun

1 participant