Repository navigation
Conversation
Each request is now read by two assessors, Claude and GPT, each in a Tessl environment with a signing key of its own and no access to issues. An assessor hands in a signed vote on a branch; the Assessment workflow checks the signatures against the public keys in scripts/assessors.json and applies a decision only when both agree, in main's own words. Votes that differ, or a vote that never comes, send the request to a maintainer. The builders start on the label GitHub Actions' bot adds, so no agent can start a build. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
The cases that were meant to show a malformed vote is refused failed on their signature first, so they showed nothing about the checks. Each is now signed by the listed assessor, and the checks lose the branches no test could tell apart. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…argument ADR 0082 and the request spec describe the two assessors, their signed votes and the workflow that applies them. The vote command takes the issue's number as its argument: a run's inputs are not in its environment. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
There was a problem hiding this comment.
Tessl Reviewer
Advisory findings (6 should fix, 2 advisory)
This repository runs Tessl Reviewer in advisory mode, so the review doesn't block merging.
The change separates assessment from issue-writing and verifies signed votes, but several correctness and recovery gaps remain. Votes can certify text neither model assessed or combine decisions about different replies; settlement can close newer requests, discard valid votes after transient failures, and leave decisions permanently incomplete. Timeout handling also mishandles edited and answered requests.
| Severity | Should fix | Advisory |
|---|---|---|
| Major | 6 | 1 |
| Minor | 0 | 1 |
Should fix (6)
- Major · Should fix · Accepting an older request closes the author's newer requests
scripts/assessment-settle.ts:138 - Major · Should fix · Casting can sign an old decision against newly edited request text
scripts/assessment-cast.ts:61 - Major · Should fix · Votes about different author replies are indistinguishable
scripts/assessment-vote.ts:59 - Major · Should fix · Obsolete votes start the timeout for a newly edited request
scripts/assessment-settle.ts:125 - Major · Should fix · Transient issue-read failures delete signed votes
scripts/assessment-apply.ts:100 - Major · Should fix · Answered needs-info requests have no fallback when neither assessor votes
scripts/assessment-settle.ts:125
Advisory (2)
- Major · Advisory · Pre-existing · Terminal labels prevent retries from completing partial decisions
scripts/assessment-settle.ts:111 - Minor · Advisory in Standard mode · Invalid branches can displace all authenticated votes from the read limit
scripts/assessment-apply.ts:112
Reviews are incremental. The first review shows every valid finding. A later round checks the latest changes and earlier findings, and adds a fresh finding when it still applies. It never repeats one you refuted or declined. Ask for a full review to inspect the whole change and show earlier findings again.
Mention @tessl-reviewer to run another review.
| const stale = has('needs-info') ? ['needs-info'] : []; | ||
| if (vote.verdict === 'accept') { | ||
| // The latest request wins: the author's older open ones close as superseded. | ||
| for (const older of calls.openRequests(issue.author, LABEL[kind])) { |
There was a problem hiding this comment.
Major · Should fix · Accepting an older request closes the author's newer requests
In scripts/assessment-settle.ts:138–144, openRequests returns all open same-author requests of the same kind, but the loop excludes only the current number. Accepting #5 therefore closes #6 as superseded, even if #6 is awaiting assessment or already being built. The lowest-first settlement sweep makes this reachable when both requests have votes ready; later settlement discards #6's votes because it is closed. Supersession must preserve requests newer than the accepted issue, as the documented latest-request-wins rule requires.
Craft · Correctness And Data Integrity · Maintainability And Code Quality · Markdown · Plugin Content · Scale And Resilience · Security And Privacy
There was a problem hiding this comment.
Addressed in the current revision. assessment-settle.ts now skips every request numbered greater than or equal to the accepted request, so supersession applies only to older requests.
| const vote = { | ||
| issue: issue.number, | ||
| assessor, | ||
| request: fingerprint(issue.title, issue.body ?? ''), |
There was a problem hiding this comment.
Major · Should fix · Casting can sign an old decision against newly edited request text
The assessor decides before invoking assessment-cast.ts, but lines 96–103 fetch the issue again and ballot fingerprints that fresh fetch rather than the text used for the decision. If both models assessed version A and the author replaces it with B before casting, both accept decisions are signed with B's fingerprint. Settlement then accepts B even though neither model assessed it. Edit-triggered runs do not prevent those earlier votes from settling first. The signed request identity must remain bound to the snapshot actually assessed rather than silently certifying its replacement.
Craft · Correctness And Data Integrity · Maintainability And Code Quality · Plugin Content · Scale And Resilience · Security And Privacy
There was a problem hiding this comment.
Fixed in 62c6d1d. An assessor now reads a request with scripts/assessment-read.ts, which prints the fingerprint of exactly what it showed, and votes with that fingerprint. assessment-cast.ts signs that fingerprint, never a fresh one, and refuses when the request no longer reads that way. The skill tells the assessor to read again and judge what it says now.
There was a problem hiding this comment.
Addressed in the current revision. assessment-read.ts supplies the snapshot fingerprint. ballot requires the supplied fingerprint to match the current request and signs that supplied value, rather than silently substituting a freshly fetched fingerprint.
| ]); | ||
|
|
||
| /** A request's fingerprint: its title and body, as GitHub gives them. */ | ||
| export function fingerprint(title: string, body: string): string { |
There was a problem hiding this comment.
Major · Should fix · Votes about different author replies are indistinguishable
fingerprint in scripts/assessment-vote.ts:59–62 includes only title and body, although the assessment skill explicitly judges the newest author reply and the factory's proposal on needs-info requests. One model can accept an earlier choice and the other a later, different choice while both votes carry the same request identity. Settlement treats those votes as agreement and authorizes a build without agreement on the effective request. Old signed needs-info votes also remain replayable after cleanup because needs-info is not terminal. Vote applicability must distinguish the assessed proposal, relevant answer, and question round; the ADR's replay guarantee currently exceeds what the code enforces.
Craft · Correctness And Data Integrity · Maintainability And Code Quality · Markdown · Plugin Content · Scale And Resilience · Security And Privacy
There was a problem hiding this comment.
Fixed in 62c6d1d. The fingerprint now covers the title, the body and the request's thread: the author's comments and the factory's own replies, told apart by numeric id. A vote on one reply of the author's is no vote on a later one, and every reply the factory posts changes the fingerprint, so a needs-info vote can't be handed in again for a later round.
There was a problem hiding this comment.
Addressed in the current revision. requestFingerprint includes the author's comments and authenticated factory replies, including comment identities. A later reply or factory question changes applicability.
| if (!issue || issue.isPull || issue.state !== 'open') return dropped(); | ||
| const kind = kindOf(issue.labels); | ||
| const has = (label: string) => issue.labels.includes(label); | ||
| if (!kind || SETTLED.some(has)) return dropped(); |
There was a problem hiding this comment.
Major · Advisory · Pre-existing · Terminal labels prevent retries from completing partial decisions
Settlement writes a terminal label before the remaining effects, but scripts/assessment-settle.ts:111 treats that label as proof of completion. If adding declined succeeds and the comment fails, the issue remains open; the next run deletes its votes without commenting or closing it. An acceptance interrupted after tessl similarly loses its announcement and explicit progress/deploy handoff. Failures inside started are additionally swallowed before votes are deleted. Recovery must distinguish a recorded decision from completion of its required effects without handing the request over twice. The base skill already had the label-first ordering and terminal-label stop rule; the workflow carries that recovery defect forward.
Pre-existing: this is in code the change does not modify, so it is not blocking.
Craft · Correctness And Data Integrity · Maintainability And Code Quality · Scale And Resilience
There was a problem hiding this comment.
Partly taken in 62c6d1d: a write that fails, including the progress comment and the deploy, now ends the run red, which is the signal to a maintainer. I've kept the label as the first write and as the mark of a settled request. Finishing a half-applied decision on a later run would need a record of which writes happened, and replying before the label would repeat the reply on every retry. ADR 0082 records this as a known limit.
There was a problem hiding this comment.
Not repeated: declined in the conversation. The terminal-label early return still prevents retries from completing later effects. In reply inline:4778428487, jedi4ever explicitly retained label-first settlement and declined automatic completion, accepting a failed workflow as the maintainer signal. Current error handling now makes those write failures fail the run, and ADR 0082 documents the remaining limit.
| if (outcome.state === 'waiting') { | ||
| // The clock starts at the first vote, or with none at the request's opening. A request its | ||
| // author has yet to answer has no clock: it waits for them. | ||
| const since = votes.at(0)?.at ?? (has('needs-info') ? now.toISOString() : issue.createdAt); |
There was a problem hiding this comment.
Major · Should fix · Obsolete votes start the timeout for a newly edited request
Consensus rejects votes for an old fingerprint, but scripts/assessment-settle.ts:125 still takes the timeout origin from the oldest signature-valid vote regardless of fingerprint. With a 21-minute-old vote for version A and a fresh assessment of version B still pending, the next settlement immediately applies needs-human. That terminal label prevents the fresh votes from completing assessment. With no votes, an old createdAt can likewise expire a recently edited request. The deadline must belong to the current assessment rather than an obsolete request version.
Craft · Correctness And Data Integrity · Maintainability And Code Quality · Security And Privacy
There was a problem hiding this comment.
Fixed in 62c6d1d. Only votes on the request as it reads now are counted, for the clock as for the consensus, and with none the clock starts at the issue's last change, not its opening. Cases are in scripts/assessment-settle-clock.test.ts.
There was a problem hiding this comment.
Addressed in the current revision. currentVotes filters by issue and current request fingerprint before computing the clock. With no current votes, settlement uses updatedAt rather than creation time; the clock tests exercise obsolete-vote and recent-change behavior.
| votes: (issue) => | ||
| refsOf(`assess/${String(issue)}/`) | ||
| .slice(-MOST_VOTES) | ||
| .flatMap(({ sha }): CastVote[] => { |
There was a problem hiding this comment.
Minor · Advisory in Standard mode · Invalid branches can displace all authenticated votes from the read limit
scripts/assessment-apply.ts:110–118 slices the ref list to ten entries before reading or authenticating votes. An assessor with branch-push access can create ten matching, lexically later refs with missing or invalid vote files, excluding both genuine votes from consideration. Those invalid refs remain until settlement, so an otherwise agreed request can reach needs-human based on an apparent absence of votes. This does not forge acceptance, but it creates unnecessary manual intervention without compromising the peer's signing key. Invalid entries must not displace the authenticated votes needed for consensus.
Security And Privacy
There was a problem hiding this comment.
Declining this one. Anything that can push a vote's branch can also delete one, so capping what the workflow reads gives a flood no more than deletion already does: the request goes to a maintainer, and nothing is accepted. Reading every branch would trade that for an unbounded number of API calls. ADR 0082 notes it.
There was a problem hiding this comment.
Not repeated: declined in the conversation. The slice before authentication remains. In reply inline:4778428717, jedi4ever expressly declined changing it because branch pushers can already delete votes and an unbounded read would increase API exposure. ADR 0082 records this bounded-read trade-off.
| try { | ||
| return requestIssue(JSON.parse(gh(`${repo}/issues/${String(number)}`)) as ApiIssue); | ||
| } catch { | ||
| return undefined; |
There was a problem hiding this comment.
Major · Should fix · Transient issue-read failures delete signed votes
The issue adapter in scripts/assessment-apply.ts:96–101 returns undefined for every exception, including a transient GitHub 5xx, rate limit, or connection failure. settle interprets undefined as a nonexistent issue and calls dropVotes, deleting its signed vote branches. The scheduled retry cannot reconstruct those decisions: an agreed request can instead time out to a maintainer, and a needs-info request can disappear from the unanswered sweep entirely. An unavailable issue read must preserve votes and remain retryable rather than enter missing-issue cleanup.
Scale And Resilience
There was a problem hiding this comment.
Fixed in 62c6d1d. Only a 404 from GitHub counts as an issue that isn't there. Any other failure throws, the votes are kept, and the run ends red, so the next run settles it.
There was a problem hiding this comment.
Addressed in the current revision. The issue adapter now returns undefined only for a classified HTTP 404 and rethrows other failures. Those failures leave settlement before cleanup and are caught by the outer loop, which marks the run unsuccessful.
| if (outcome.state === 'waiting') { | ||
| // The clock starts at the first vote, or with none at the request's opening. A request its | ||
| // author has yet to answer has no clock: it waits for them. | ||
| const since = votes.at(0)?.at ?? (has('needs-info') ? now.toISOString() : issue.createdAt); |
There was a problem hiding this comment.
Major · Should fix · Answered needs-info requests have no fallback when neither assessor votes
requestsToSettle in scripts/assessment-apply.ts:44–49 excludes every needs-info issue from the no-vote sweep, without distinguishing an unanswered question from an author answer awaiting assessment. If both runs triggered by an answer fail before pushing a vote, scheduled settlement never revisits the request. Even direct settlement would reset its no-vote clock to now because needs-info remains present. The author can therefore wait indefinitely without the documented maintainer handoff. Waiting for the author and waiting for assessments of an answer must have distinct timeout behavior.
Markdown · Scale And Resilience
There was a problem hiding this comment.
Fixed in 62c6d1d. A question the factory asks records the fingerprint it was asked about. A request waiting on its author has no clock; once the author replies or edits, it has the same twenty minutes as any request, and the sweep now looks at needs-info requests too.
There was a problem hiding this comment.
Addressed in the current revision. requestsToSettle now includes needs-info requests without votes. For questions emitted by this implementation, answered distinguishes author silence from replies or edits, and answered requests use updatedAt for the no-vote deadline.
From review: a vote was signed against whatever the issue read when the vote was cast, and its fingerprint covered only the title and body, so a request could change under a decision, and votes on different replies of the author's looked alike. An assessor now reads a request through one command that prints its fingerprint, covering the author's comments and the factory's replies, and votes with it. Also from review: accepting a request closes only the author's older ones; votes on how a request read no longer start its clock; an answered question with no vote reaches a maintainer; a failed read of an issue keeps its votes; and a write that fails ends the run red. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
There was a problem hiding this comment.
Tessl Reviewer
Advisory findings (2 should fix)
This repository runs Tessl Reviewer in advisory mode, so the review doesn't block merging.
2 findings require changes before approval.
| Severity | Should fix | Advisory |
|---|---|---|
| Major | 2 | 0 |
Should fix (2)
- Major · Should fix · Author comments invalidate votes without starting replacement assessments
scripts/assessment-request.ts:65 - Major · Should fix · The assessor's permitted reads exclude facts required for its decision
plugins/north-pole/skills/assess-booth-request/SKILL.md:18
Earlier findings: 6 addressed · 2 declined
About this review
These findings are AI-generated and not authoritative. Check each one against the code before acting on it. See the guidance on working with this review.
Mention @tessl-reviewer to run another review.
| export function requestIssue(issue: ApiIssue, comments: readonly ApiComment[]): RequestIssue { | ||
| const thread = comments.flatMap(({ id, body, user }): ThreadEntry[] => { | ||
| const text = body ?? ''; | ||
| if (user?.id === issue.user.id) return [{ id, by: 'author', body: text }]; |
There was a problem hiding this comment.
Major · Should fix · Author comments invalidate votes without starting replacement assessments
The reply-thread fingerprint repair makes every author comment change the request identity, including comments on requests not labelled needs-info. However, tessl.json starts comment-triggered assessments only for needs-info issues. If an author adds a clarification after one assessor votes on a fresh request, that vote becomes stale without a replacement run being started. Even if the other assessor reads and votes on the clarification, consensus cannot complete and the scheduled workflow eventually applies needs-human. Fingerprint-changing author updates need a corresponding reassessment path; restoring fingerprints that ignore relevant replies would lose the snapshot-consensus guarantee.
Correctness And Data Integrity
There was a problem hiding this comment.
Fixed in 0b61ec5, by making the two rules agree. A request is its title and body until the factory asks something; from the factory's first reply on, its replies and the author's comments count. That is exactly when tessl.json starts an assessment for a comment (needs-info), so a comment on a request nobody has asked about no longer changes the fingerprint, and the read command doesn't show it to an assessor either.
There was a problem hiding this comment.
Addressed in the current revision. requestIssue() now excludes author comments before the first factory reply from both the fingerprint and briefing. Subsequent author replies remain included while needs-info comment events start both assessors. This implements the boundary described by jedi4ever in inline:4778615935 for commit 0b61ec5 without weakening snapshot agreement on the proposals and answers covered by P3.
| remove labels, and close. You never change code, push, open a pull request, run | ||
| the project, or reach any address the issue mentions. | ||
| may build it. You **only** read the issue and this repository, with the one | ||
| command in **Read the request**, and hand in your vote with the one command |
There was a problem hiding this comment.
Major · Should fix · The assessor's permitted reads exclude facts required for its decision
The skill permits reading only through assessment-read.ts and explicitly prohibits running anything else. That command returns the request, not repository contents or other issues. Yet Gather the facts still requires checking the booth on main, disabled.json, AGENTS.md, and potentially another accepted booth request for level eligibility. An assessor following the new restriction cannot establish these prerequisites: for example, it cannot distinguish a level author with an accepted booth being built from one who has not unlocked a level. The allowed evidence gathering must support the required eligibility and kill-switch checks while retaining the prohibition on issue writes.
Plugin Content
There was a problem hiding this comment.
Fixed in 0b61ec5. The skill now says an assessor reads the issue only through the read command, and may also read the repository's files and list the author's open accepted booth requests by number alone (gh issue list ... --json number), which is what the level check needs.
There was a problem hiding this comment.
Addressed in the current revision. The opening restriction now expressly permits repository-file reads and the accepted-booth-request list used by Gather the facts. The level eligibility check names a number-only gh issue list operation. These reads support the booth-presence, kill-switch and house-rule checks without granting permission to write issues.
|
Preview: https://ainativedev.github.io/Carnival-Factory/previews/pr-369/ (built from 62c6d1d). It updates on every push. Once this pull request closes, its links take you to the live map. |
From review: an author's comment on a request nobody had asked about made its votes stale, with nothing to read it again. A request is its title and body until the factory asks something; from then on the factory's replies and the author's comments count, which is also when a comment starts a new assessment. The skill now says what an assessor may read besides the issue: the repository's files, and the author's accepted booth requests by number. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
There was a problem hiding this comment.
Tessl Reviewer
No advisory concerns
This repository runs Tessl Reviewer in advisory mode, so the review doesn't block merging.
The current code binds signed votes to the request snapshot shown to each assessor, includes relevant question-and-answer history, and preserves votes across transient issue-read failures. Supersession and timeout handling address the earlier correctness concerns. No additional defect is established by the supplied candidates: their compatibility and ADR-history claims assume an earlier deployed version that the PR history does not support. Partial-write recovery and bounded vote reads remain explicitly accepted limitations.
Earlier findings: 8 addressed · 2 declined
About this review
These findings are AI-generated and not authoritative. Check each one against the code before acting on it. See the guidance on working with this review.
Mention @tessl-reviewer to run another review.

What changed
A booth or level request is now assessed by two models that must agree, and a workflow, not an agent, writes the answer on the issue (ADR 0082).
assess-booth-request(Claude Opus 5.5) and the newassess-booth-request-openai(GPT-6.2 Sol) run the same skill on the same events.pull-requestsaccess, so it can't label, comment on or close an issue. It reads the request withnode scripts/assessment-read.ts <issue>and hands in a small signed vote withnode scripts/assessment-cast.ts <issue> <fingerprint>, on a branchassess/<issue>/<assessor>-<time>.scripts/assessors.json. A vote carries the issue, the assessor, the fingerprint of the request it read, and the time, all under the signature..github/workflows/assessment.ymlrunsmain's ownscripts/assessment-apply.ts. When both verdicts match it applies the labels, closes older requests and replies in fixed words. When they differ, or a vote is missing after twenty minutes, it addsneeds-humanand says a maintainer will look.implement-boothandimplement-levelstart when GitHub Actions' bot addstessl. The Tessl App adding it starts nothing. A maintainer addingtesslto a booth request still does.What a requester sees
The same three answers as before, now from
github-actions[bot], plus a fourth: "The factory's assessments didn't agree on it, so a maintainer will take a look."Trials, out of band, on a throwaway issue
Both assessors ran from this branch on #368, in their own environments, and the applier ran in dry-run on their real votes.
needs-human: the assessments differneeds-human: the assessments differtessland reply that it's being builtscripts/assessors.json.After the review's fixes, a fourth trial on the new read-then-vote flow: both models read #368 through the read command, voted with the same fingerprint, and agreed on decline, because the thread by then held a comment saying the issue was only a trial. The applier would post that decline and close the issue.
#368 is closed. Its eight vote branches (
assess/368/…) are still there; this workflow deletes them on its first run after merging.Checks
npm run check: 3729 tests pass.smoke/nudge.spec.ts, which this change doesn't touch; Let frames in flight finish before the nudge test jumps the clock #370 fixes that test.actionlintandtessl loop validatepass.To know before merging
carnival-assessor-claudeandcarnival-assessor-openai, already exist and hold their keys.🤖 Generated with Claude Code