.outerlayer/judges/. To add one, see Write a judge.
OuterLayer reads the judge files from the pull request’s base branch. A change takes effect when it merges, so a pull request cannot change its own judges. To require a person’s review of such a change, see Require a person’s review of rules changes.
When a factory has a control plane, the judge files come from that repository instead. See Share instructions across repositories.
If OuterLayer cannot read the files, that evaluation has no judges from judge files. If it cannot read the control plane, the Judges tab shows a row that says so.
Whether a flagged verdict blocks the merge is a factory setting, not a file. See The OuterLayer evidence check.
OuterLayer does not read .outerlayer/policy.yaml. A repository that still has the file gets no error. You can delete it.
The verdict
The item page lists the judges on its Judges tab, and the criteria on its Criteria tab. Each one is a row. Together the rows give one verdict:- Pass: no row that counts failed, and none is still waiting.
- Flagged: a row that counts failed.
- Waiting: nothing failed, but a result has not arrived, or a member must decide a result.
required: true. A fail then flags the verdict, and so does a judge with no result. An inconclusive result holds the verdict at waiting. With required: false, the default, the Judges tab shows the judge’s result and the verdict ignores it. See Make a judge required.
A member can overrule one failed result of a judge, with a reason. The verdict then ignores that result. A later result for the judge ends the overrule. See Overrule a failed result.
A person’s review is not a judge, so it never changes the verdict. See Review and merge.
An inconclusive result
A judge answers inconclusive when the evidence cannot decide. See Let a judge answer inconclusive. The result is neither a pass nor a fail:- A required judge. The verdict is waiting. It never passes while the result stands. Approve stays disabled and says that a member must decide the result of the judge. A flagged row still gives a flagged verdict.
- A judge that is not required. The verdict is the same as with no result from the judge. The Judges tab shows the result.
pass, fail and skipped. The dashboard shows them as inconclusive.
A runner releases a build as incomplete while a result is inconclusive. It does the same for any verdict that is not pass.
On GitHub, a pull request gets an evidence comment and a status check named OuterLayer evidence. It also gets one check for each judge and one for the code review. OuterLayer posts them only when Post session summaries on pull requests is on for the repository. See Connect a repository.
The OuterLayer evidence check
TheOuterLayer evidence status check combines the item’s verdict with its review. The factory’s Block the merge when a check fails setting sets what the status check can do:
With the setting on or off, the status check is in progress while a result is pending. The setting applies to every repository of the factory.
To make GitHub block a merge:
- Open Settings → Repositories for the factory. Under Pull request checks, turn on Block the merge when a check fails. You need permission to edit factory settings.
- In GitHub, require the
OuterLayer evidencestatus check in the branch protection rule or ruleset of the base branch.
gh pr checkslists a neutral result asskipping. The status check blocks nothing, but OuterLayer did evaluate the pull request.- A pull request that is on no work item is never evaluated and gets no comment. It always gets a neutral status check titled “Not run through OuterLayer”.
- The title “Evidence check could not run this refresh” means OuterLayer could not read the judge files or the factory’s setting. The result is neutral. A later push tries again.
The checks of each judge and of the code review
Each judge has its own check on the head commit of each pull request of the item. The check is namedOuterLayer judge / <judge id>. The judge id is the name of its file without .md. The built-in criteria judge posts OuterLayer judge / acceptance-criteria. The code review posts OuterLayer code review.
Require one of these checks in GitHub’s branch protection to hold the merge for that judge alone. The OuterLayer evidence check stays the combined verdict. The Block the merge when a check fails setting changes only that check. It does not change the checks of the judges or of the code review.
The conclusion of a judge check shows one of these results:
A
when key that OuterLayer cannot read, such as the list of changed files, never gives skipped. A runner still runs that judge. The check shows the newest result of the judge, or is queued while there is none.
A judge that applies and has no result yet is queued. The check completes when a runner records a result.
A person can push a commit that no runner judges. The check of that commit carries the newest result of the judge. Its title names the commit that result judged, for example “Failed · judged 1a2b3c4”.
The details of a failed check list each failing judge item and link it to the item page. On a private repository, the list also shows each item’s reason. A reason is runner output and can quote code. On any other repository, the reasons stay on the item page.
OuterLayer posts only the checks that changed since the last refresh.
Where judges come from
Every judge that you can add or remove is a file in.outerlayer/judges/. You write each one. outerlayer init writes none.
OuterLayer also adds rows of its own. You cannot remove these:
- A row for each recorded criterion whose declared proof is missing, unless a reviewer accepted it. See Recorded criteria in the verdict.
- A row for each criterion that the criteria judge fails.
- A row for each ask in the item’s issue. See Ask for evidence in an issue.
- A row for a judge file that has an error, and a row for a control plane that OuterLayer cannot read.
code-review or acceptance-criteria. Such a file adds an error row. See The file format.
OuterLayer reads no result of your CI as a judge. The item page shows the pull request’s GitHub checks in their place.
The criteria judge
A runner judges the criteria of every item it builds. No judge file defines the criteria judge. A repository with no.outerlayer/ files has it.
A build or an agent job ends ok. Then a fresh agent on the runner’s host judges each recorded criterion against its tests. The judge is the agent that ran the build, when that agent can judge. Claude Code and Codex can, and Claude Code judges an OpenCode build. A Codex runner needs only an OpenAI API key. A runner that builds with OpenCode also needs a Claude credential. The agent finds those tests itself in the pushed commit. A test needs no comment or title that names the criterion.
A Codex judge runs with Codex’s full tools in the build’s container. It is told to read only, to change no file and to use no network. The runner checks after the run that it changed no file but its answer files, and discards the verdict when it did. The judge is instructed and checked, not sandboxed. See The Codex judge and code review.
The host records one judge item for each criterion. The Criteria tab shows the result. The Judges tab never lists it. The result stays stored under the name acceptance-criteria.
The criteria judge fails a criterion in these cases:
- It does not find the criterion proven.
- It passes the criterion but names no test file for it.
skipped. A judge of the team with for_each: criterion judges every criterion.
An item with no recorded criteria is not judged. The No acceptance criteria are recorded row covers it.
A reviewer can accept a criterion that the criteria judge failed. The row for that criterion then goes until the next commit. See Accept a criterion without proof.
Only a runner judges. An item built in a local session shows no result of the criteria judge. The Criteria tab says that the judge has not run.
The criteria judge always counts: a criterion that it fails flags the verdict. It follows the brief that the CLI ships, which belongs to the outerlayer-build skill. The judge stage lists each reason a judge fails.
To add a judge of your own, see Write a judge.
Recorded criteria in the verdict
An item’s recorded criteria count toward the verdict of its open and merged pull requests. They add these rows:
Each of these rows always counts. In the table,
<id> is the criterion’s id.
A criterion that declares no proof never adds an is unproven row. If your team does not want a proof kind, do not declare it.
If your builds record no criteria, each open pull request is flagged. This is true whether or not the repository has .outerlayer/ files. Record criteria with outerlayer emit criteria.
While a runner or a session holds a claim on the item, these rows read as pending. They flag once the claim ends.
A flagged row has three effects:
- Approve stays disabled on the item page, though the item still reads Ready for review.
- A runner releases the build as incomplete.
- The GitHub status check fails when Block the merge when a check fails is on.
Ask for evidence in an issue
The issue that a work item tracks can add required rows to its pull request. An ask only adds rows. It never makes a judge count less, and it never removes a row.- Put a heading named
Validation requiredin the issue body. The heading can be at any level, in any case. - Write one checklist line under it for each ask. The list ends at the next heading.
An id in an ask uses lowercase letters, digits and hyphens only.
OuterLayer ignores whether a line is ticked. An unknown id or kind adds one flagged row that names the first problem and counts the rest.
Judge items
A judge’s result can carry judge items: one result for each thing the judge judged, such as a criterion or a file. A judge with a failing judge item cannot pass. A result holds at most 500 judge items.
Judge items come from two places:
- The criteria judge records one for each criterion. The Criteria tab shows them.
- A judge of your own records one for each criterion, or one for each part of the change it judged. See Judge each criterion.
outerlayer work status --json. That output names the judges’ results checks, and each result’s judge items items.
When a required judge fails
A required judge that fails a judge item flags the verdict. OuterLayer can send each failed judge item to the agent, so a member does not have to ask for the fix. Open Settings, then Judges under Review. Choose what happens to a required judge’s fail:
Fix rounds is 1, 2 or 3. The default is 2. Each round is one agent job and one run of the judge. The rounds count across heads, from a person’s last action on the pull request. A person’s action starts the count again.
The agent follows these rules:
- It fixes each failed judge item from the judge’s reason. It changes the code or the tests.
- It never passes a judge item. The factory runs the judge again after the job.
- It never rewrites a criterion.
- It hands a criterion that cannot be met as written to a person. It names the wording change in a comment on the general thread, and it changes no test for that criterion.
- The judge is required.
- The fail is at the head of the pull request.
- A runner built the pull request and OuterLayer pushed its head.
outerlayer work status --json. See failedJudgeItems.