You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Agents share the operator's GitHub identity, so their reviews cannot gate a merge #791
Four wrapper agents produced four PRs and genuinely good review reasoning — one caught a real ReDoS (polynomial regex on attacker-controlled message text). All four merged with zero GitHub reviews, and nothing stopped that.
Two separate reasons, and fixing only the first does not help:
1. main requires zero approving reviews. So gh pr review --request-changes is advisory. An agent can say "not ready" and the merge button still works.
2. Turning required-reviews on would deadlock, not gate. Every agent acts as the operator's single GitHub identity. They author as lilyshen0722 and would review as lilyshen0722; GitHub blocks self-approval. Requiring one approval would make agent-authored PRs unmergeable by agents — the pipeline stops rather than gains a gate.
So: the agents cannot be held to the process humans are held to, because they are not distinguishable principals.
Options
approach
gates?
cost
advisory — agent requests changes, human honours it
the human is the reviewer again — defeats the purpose
Recommended first step, cheap and reversible: give one agent (the reviewer) its own GitHub principal and enable required reviews on main. That is the minimum that makes an agent review load-bearing, and it tests the operational cost of per-agent credentials on exactly one agent before committing to N.
Already mitigated in part:#789 added a bundled-skill rule that review output belongs on the PR via gh pr review, not in pod chat. That fixes agents reviewing into the void. It does not make the review binding — this issue is the binding half.
Strategic context in ADR-018 (agent identity), where this is one of three costs of (agentName, instanceId) and the only one that bites in an external system.
Confirmed empirically, and not by me predicting it.
sprint-review tried to approve #792 and hit the wall — and notably reported it as "Tried it just now rather than telling you from memory", which is the discipline this sprint has been failing at repeatedly.
Reproduced directly:
$ gh pr view 792 --json author
author: lilyshen0722
$ gh pr review 792 --approve
failed to create review: GraphQL: Review Can not approve your own pull request (addPullRequestReview)
pod-architect authored #792. sprint-review reviewed it. GitHub sees one person, so the approval is refused as self-approval.
This moves the issue from predicted to demonstrated: the agents are already producing review work that GitHub structurally will not accept. They are not failing to review — they reviewed well, twice, and the second pass caught fixes to its own earlier findings. The platform simply has nowhere to put the verdict.
That also sharpens the recommended first step. Giving one agent its own GitHub principal is not a nice-to-have for future gating — it is the minimum for the review work already happening to count for anything. sprint-review is the obvious candidate, since it is the only one whose entire job is producing verdicts it currently cannot record.
Strategic framing in ADR-018 (#790) unchanged; this is the concrete instance.
Second instance, wider than the first: the operator seat is undifferentiated too.
This issue scoped the problem to agents sharing one GitHub identity, so their reviews cannot be attributed or gated. The same defect just appeared inside the pod itself, and the cost was provenance rather than permissions.
What happened. The assistant orchestrating the sprint posts to the pod under the operator's account. On #798 it proposed a fix (parse the cursor to a Date at the route so the service signature becomes before?: Date). A reviewing agent, tracing who authored that argument, credited it to pod-architect — which correctly replied "I have no record of the analysis you're crediting me with."
Verified from the message log: the proposal is message 52204, authored under the operator account.
Why it matters beyond etiquette. A design decision now traces to a seat that did not make it. When someone later asks why the cursor is a Date, the trail points at an agent that cannot defend reasoning it never had — and the agent that can is invisible. That is exactly the provenance property the memory work (#632) treats as a kernel primitive, failing in our own operating practice.
It also collapses two different kinds of message into one voice. Operator instructions ("take #795 next", "do not build a subscription system") and assistant analysis ("here is my read of the taint path") arrive from the same identity, so an agent cannot tell a directive from an argument. A directive should be followed; an argument should be checked. Today they are indistinguishable, which is a bad property in a pod whose entire discipline is verify rather than accept.
Widens the recommendation. The first step was: give one agent (the reviewer) its own GitHub principal. Add: give the orchestrating assistant its own pod identity, separate from the operator's. Cheap — it is an attach, not an account — and it makes instruction-vs-analysis legible without any platform change.
The general form, now demonstrated twice in one day: indistinguishable principals break attribution before they break authorization, and attribution failures are quieter.
I maintain Tenuo, and I opened #4190 on the broader idea. This issue is the sharpest version of it, so a concrete proposal here.
There's a middle path between advisory reviews and N machine users: each agent gets its own key, delegated by its owner. The reviewing agent signs its verdict bound to the PR's head SHA. One GitHub App verifies the chain (reviewer key differs from the author's, both delegated for this repo, not expired) and reports a required status check. Branch protection requires that check instead of an approving review.
What it gets you: an agent review that blocks a merge, one App to manage instead of an account per agent, and a review record anyone can verify later. What it doesn't: GitHub still shows one human as the author, so the native "approved by" badge stays a human's. The signed tokens follow an IETF draft (AAT), so the format isn't specific to us.
If you'd like to see it, I can build it against your #792 case on a fork and link it here.
Yes, please build it against #792 on a fork and link it here. One update since August: agents now commit and merge as a separate machine account instead of an operator's, but they all share that one account, so the self-approval wall is still there. A per-agent key that gates through a required check is exactly the missing piece.
Each agent has its own key, generated where it runs. GitHub still sees one account; the keys are what tell agents apart.
The instance issues the author agent a Tenuo warrant: it may merge to this repo only with a signed approval from one of the listed reviewer agents. Its own key is never listed.
The reviewer signs one exact merge: repo, PR, head SHA. A new push needs a new approval.
A required check verifies the warrant and approvals with only the instance's public key, and the broker's merge tool can run the same check (with proof of possession) before it merges.
tenuo-ai/demo-day, .github/tenuo: the required check.
Walkthrough on tenuo-ai/demo-day#1, with every comment posted from one GitHub account: no approval fails, pod-architect approving itself fails, sprint-review's approval passes, a new push fails until sprint-review approves the new SHA, then it merges.
Two things we'd like your take on:
Where the required check comes from in production. The prototype runs it as a GitHub Action, and branch protection can only pin that to "GitHub Actions", which also covers workflows a PR branch adds itself. Fine for trying it, but the real gate should come from something a PR can't produce: a small dedicated verifier App, one of your existing Apps (simplest, though the check is then only as independent as the server), or an org ruleset pinning the workflow from a protected repo. Which fits how you run things?
Do agents merge only through the broker's merge tool, or also with gh pr merge? If it's only the broker, its check is the gate and branch protection is a backstop.
Next would be keys generated by the seat, issuing the warrant when the owner grants the GitHub connection, and the merge tool requiring the check. Not wired into the CLI or broker yet.
Merge queue version is working, tested on tenuo-ai/demo-day without an App: a repo ruleset requires a merge queue and tenuo/agent-review, and a local harness runs the verifier and posts a commit status in place of the App.
How it works: before enqueueing, the author agent sends the instance a presented merge_pr call (warrant, fresh proof of possession, reviewer approvals). The instance runs Tenuo's verify(), records the authorized commit, and reports the check on the PR head. On merge_group it passes only if every PR in the group is authorized at its queued head.
Add PostgreSQL message route tests #6: never approved, enqueue refused. With a fake passing status on its head it got into the queue, the group commit failed, and GitHub dropped it.
Code: tenuo-ai/commonly, branch tenuo/signed-agent-review, packages/tenuo-review. src/verifier.js is what your App would call: requestMerge() for the agent's request, onPullRequest() and onMergeGroup() for the webhooks. bin/verifier-app.js wraps it as a small App server, and bin/verifier-local.js is the no-App harness used here. Over to you for trying it behind your own App.
The four changes from your review of bff8e4f are in b23e392 on tenuo/signed-agent-review, with a test for each:
PRs no agent opened pass. The verifier takes the agent account(s) in TENUO_REVIEW_AGENT_LOGINS. A PR opened by any other account passes, on its head and in a merge group, titled "not opened by an agent". commonly-agent and commonly-agent[bot] count as the same account. With the list empty, every PR still needs a review.
Records expire. A record is good until the earliest approval it rests on expires, and reviewers' approvals are now cut to the warrant's expiry when signed. After that, both the head check and the merge-group check fail with "authorization expired, ask again".
Queue lookup errors fail the group. Anything that goes wrong while checking a merge group reports a failure on the group commit, so the queue drops it at once.
Approvers named from keys. Check titles use the instance's own key-to-name map (TENUO_REVIEW_REVIEWERS=name=keyhex,...), never the name a reviewer signs with. An unknown key shows as key 1a2b3c4d.
Caveats:
(1) keys on who opened the PR. If the agent account pushes commits to a PR a person opened, that PR passes with no agent review. The seat-branch rule (agents push only to seat/<id>/...) covers this as long as it holds.
(2) With @tenuo/core 0.3.7-beta.0 the verifier can't read a warrant's expiry without the holder's key, so the limit comes from the approvals, which the reviewer signs and the author can't extend. Once feat(ts): add holder-independent warrant diagnostics tenuo-ai/tenuo#1119 is released the verifier can check the warrant's expiry directly too. Nothing revokes a record before it expires.
Records stored before this change have no expiry, so they no longer count; those PRs need to ask again.
Sounds good on running it non-required first. I left comments on the ADR-036 questions in #4223.
Read b23e392 through the API. All four fixes work the way we hoped, and each has its test.
On caveat (1), the seat-branch rule doesn't cover it for us. That rule lives in our tool broker and binds hosted seats, which push through our GitHub App. commonly-agent is a plain account that can push to any branch, and our local agent sessions push as it to ordinary branches (fix/..., docs/...). Nothing on GitHub stops it pushing to a PR someone else opened.
Could the check also key on who pushed each head? On pull_requestopened and synchronize, the webhook's sender is the account that pushed. Store it per head and require a record when it's an agent. A head with no stored pusher counts as an agent, same as your unknown-author rule. The agent list would then hold commonly-agent and the App's bot login.
Two small ones:
If no approval counts, expiresAt is Math.min() of nothing, so Infinity. The memory store keeps that forever, and the file store writes it as null, which reads as expired after a restart. It takes a warrant with no approval step, so it's unlikely, but refusing when nothing counts would close it.
The fallback for multi-approval warrants keeps every validly signed approval, and inspectApproval doesn't check which request an approval was for. So an approval signed for another PR could end up named in the title. It can't authorize anything, since verify() already passed on the full set. Filtering on requestHash keeps the title honest.
(2) and (3) are fine by us. Still happy to run it non-required first.
All three are in a67c316 on tenuo/signed-agent-review, each with a test:
Who pushed. A PR needs a review if an agent opened it or an agent pushed its current head. The pusher is the sender on pull_requestopened/synchronize, plus push, so a branch an agent pushed before a person opened the PR is covered too. Once a head is marked as pushed by an agent, a later event doesn't clear it. A head with no known pusher counts as an agent's. The App needs the push event added to its subscriptions.
No approval counts: the request is refused (NO_APPROVAL) instead of storing an Infinity expiry.
Multi-approval titles: approvals are grouped by requestHash, and only the group that passes verify() is kept, so one signed for another PR isn't named.
Two limits: the local harness polls, so it can't see who pushed and treats every head as an agent's. And with the memory store a restart forgets pushers, so PRs people opened need a new push or review afterwards. The file store keeps them.
Activity
lilyshen0722 commentedon Aug 2, 2026
Confirmed empirically, and not by me predicting it.
sprint-reviewtried to approve #792 and hit the wall — and notably reported it as "Tried it just now rather than telling you from memory", which is the discipline this sprint has been failing at repeatedly.Reproduced directly:
pod-architectauthored #792.sprint-reviewreviewed it. GitHub sees one person, so the approval is refused as self-approval.This moves the issue from predicted to demonstrated: the agents are already producing review work that GitHub structurally will not accept. They are not failing to review — they reviewed well, twice, and the second pass caught fixes to its own earlier findings. The platform simply has nowhere to put the verdict.
That also sharpens the recommended first step. Giving one agent its own GitHub principal is not a nice-to-have for future gating — it is the minimum for the review work already happening to count for anything.
sprint-reviewis the obvious candidate, since it is the only one whose entire job is producing verdicts it currently cannot record.Strategic framing in ADR-018 (#790) unchanged; this is the concrete instance.
lilyshen0722 commentedon Aug 2, 2026
Second instance, wider than the first: the operator seat is undifferentiated too.
This issue scoped the problem to agents sharing one GitHub identity, so their reviews cannot be attributed or gated. The same defect just appeared inside the pod itself, and the cost was provenance rather than permissions.
What happened. The assistant orchestrating the sprint posts to the pod under the operator's account. On #798 it proposed a fix (parse the cursor to a
Dateat the route so the service signature becomesbefore?: Date). A reviewing agent, tracing who authored that argument, credited it topod-architect— which correctly replied "I have no record of the analysis you're crediting me with."Verified from the message log: the proposal is message
52204, authored under the operator account.Why it matters beyond etiquette. A design decision now traces to a seat that did not make it. When someone later asks why the cursor is a
Date, the trail points at an agent that cannot defend reasoning it never had — and the agent that can is invisible. That is exactly the provenance property the memory work (#632) treats as a kernel primitive, failing in our own operating practice.It also collapses two different kinds of message into one voice. Operator instructions ("take #795 next", "do not build a subscription system") and assistant analysis ("here is my read of the taint path") arrive from the same identity, so an agent cannot tell a directive from an argument. A directive should be followed; an argument should be checked. Today they are indistinguishable, which is a bad property in a pod whose entire discipline is verify rather than accept.
Widens the recommendation. The first step was: give one agent (the reviewer) its own GitHub principal. Add: give the orchestrating assistant its own pod identity, separate from the operator's. Cheap — it is an attach, not an account — and it makes instruction-vs-analysis legible without any platform change.
The general form, now demonstrated twice in one day: indistinguishable principals break attribution before they break authorization, and attribution failures are quieter.
docs(ax): entry 7 — directives and arguments share one identity
docs: ADR-016 + ADR-017 full drafts, reviewer checklist (#792)
docs(ax): sixth misattribution — I claimed a peer's action as my own
docs(ax): entries 8 + 9 — write paths and error paths that report the…
docs(ax): delivered mentions drop the author field (entry 11)
docs(ax): delivered mentions drop the author field (entry 11) (#813)
docs(ax): entry 12 — a protocol field promised, never written, routed…
d8joseph commentedon Nov 16, 2026
I maintain Tenuo, and I opened #4190 on the broader idea. This issue is the sharpest version of it, so a concrete proposal here.
There's a middle path between advisory reviews and N machine users: each agent gets its own key, delegated by its owner. The reviewing agent signs its verdict bound to the PR's head SHA. One GitHub App verifies the chain (reviewer key differs from the author's, both delegated for this repo, not expired) and reports a required status check. Branch protection requires that check instead of an approving review.
What it gets you: an agent review that blocks a merge, one App to manage instead of an account per agent, and a review record anyone can verify later. What it doesn't: GitHub still shows one human as the author, so the native "approved by" badge stays a human's. The signed tokens follow an IETF draft (AAT), so the format isn't specific to us.
If you'd like to see it, I can build it against your #792 case on a fork and link it here.
samxu01 commentedon Nov 18, 2026
Yes, please build it against #792 on a fork and link it here. One update since August: agents now commit and merge as a separate machine account instead of an operator's, but they all share that one account, so the self-approval wall is still there. A per-agent key that gates through a required check is exactly the missing piece.
d8joseph commentedon Nov 18, 2026
Prototype is up on forks.
How it works:
Code:
Walkthrough on tenuo-ai/demo-day#1, with every comment posted from one GitHub account: no approval fails, pod-architect approving itself fails, sprint-review's approval passes, a new push fails until sprint-review approves the new SHA, then it merges.
Two things we'd like your take on:
Where the required check comes from in production. The prototype runs it as a GitHub Action, and branch protection can only pin that to "GitHub Actions", which also covers workflows a PR branch adds itself. Fine for trying it, but the real gate should come from something a PR can't produce: a small dedicated verifier App, one of your existing Apps (simplest, though the check is then only as independent as the server), or an org ruleset pinning the workflow from a protected repo. Which fits how you run things?
Do agents merge only through the broker's merge tool, or also with gh pr merge? If it's only the broker, its check is the gate and branch protection is a backstop.
Next would be keys generated by the seat, issuing the warrant when the owner grants the GitHub connection, and the merge tool requiring the check. Not wired into the CLI or broker yet.
feat(tenuo-review): verifier app with merge queue support (Team-Commo…
d8joseph commentedon Nov 20, 2026
Merge queue version is working, tested on tenuo-ai/demo-day without an App: a repo ruleset requires a merge queue and tenuo/agent-review, and a local harness runs the verifier and posts a commit status in place of the App.
How it works: before enqueueing, the author agent sends the instance a presented merge_pr call (warrant, fresh proof of possession, reviewer approvals). The instance runs Tenuo's verify(), records the authorized commit, and reports the check on the PR head. On merge_group it passes only if every PR in the group is authorized at its queued head.
Code: tenuo-ai/commonly, branch tenuo/signed-agent-review, packages/tenuo-review. src/verifier.js is what your App would call: requestMerge() for the agent's request, onPullRequest() and onMergeGroup() for the webhooks. bin/verifier-app.js wraps it as a small App server, and bin/verifier-local.js is the no-App harness used here. Over to you for trying it behind your own App.
d8joseph commentedon Nov 22, 2026
The four changes from your review of bff8e4f are in b23e392 on
tenuo/signed-agent-review, with a test for each:TENUO_REVIEW_AGENT_LOGINS. A PR opened by any other account passes, on its head and in a merge group, titled "not opened by an agent".commonly-agentandcommonly-agent[bot]count as the same account. With the list empty, every PR still needs a review.TENUO_REVIEW_REVIEWERS=name=keyhex,...), never the name a reviewer signs with. An unknown key shows askey 1a2b3c4d.Caveats:
seat/<id>/...) covers this as long as it holds.@tenuo/core0.3.7-beta.0 the verifier can't read a warrant's expiry without the holder's key, so the limit comes from the approvals, which the reviewer signs and the author can't extend. Once feat(ts): add holder-independent warrant diagnostics tenuo-ai/tenuo#1119 is released the verifier can check the warrant's expiry directly too. Nothing revokes a record before it expires.Sounds good on running it non-required first. I left comments on the ADR-036 questions in #4223.
commonly-agent commentedon Nov 22, 2026
Read b23e392 through the API. All four fixes work the way we hoped, and each has its test.
On caveat (1), the seat-branch rule doesn't cover it for us. That rule lives in our tool broker and binds hosted seats, which push through our GitHub App.
commonly-agentis a plain account that can push to any branch, and our local agent sessions push as it to ordinary branches (fix/...,docs/...). Nothing on GitHub stops it pushing to a PR someone else opened.Could the check also key on who pushed each head? On
pull_requestopenedandsynchronize, the webhook'ssenderis the account that pushed. Store it per head and require a record when it's an agent. A head with no stored pusher counts as an agent, same as your unknown-author rule. The agent list would then holdcommonly-agentand the App's bot login.Two small ones:
expiresAtisMath.min()of nothing, soInfinity. The memory store keeps that forever, and the file store writes it asnull, which reads as expired after a restart. It takes a warrant with no approval step, so it's unlikely, but refusing when nothing counts would close it.inspectApprovaldoesn't check which request an approval was for. So an approval signed for another PR could end up named in the title. It can't authorize anything, sinceverify()already passed on the full set. Filtering onrequestHashkeeps the title honest.(2) and (3) are fine by us. Still happy to run it non-required first.
d8joseph commentedon Nov 22, 2026
All three are in a67c316 on
tenuo/signed-agent-review, each with a test:pull_requestopened/synchronize, pluspush, so a branch an agent pushed before a person opened the PR is covered too. Once a head is marked as pushed by an agent, a later event doesn't clear it. A head with no known pusher counts as an agent's. The App needs thepushevent added to its subscriptions.NO_APPROVAL) instead of storing anInfinityexpiry.requestHash, and only the group that passesverify()is kept, so one signed for another PR isn't named.Two limits: the local harness polls, so it can't see who pushed and treats every head as an agent's. And with the memory store a restart forgets pushers, so PRs people opened need a new push or review afterwards. The file store keeps them.