Repository navigation
feat(j5): a steer or restart reaches an agent on a peer server - #563
Open
Jacksondr5 wants to merge 2 commits into
Open
Jacksondr5 wants to merge 2 commits into
Jacksondr5 wants to merge 2 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Jacksondr5
force-pushed
the
j5code/spawn-519
branch
from
October 12, 2026 06:31
0dbcbf8 to
2a9c1a6
Compare
Jacksondr5
force-pushed
the
j5code/remote-steer-519
branch
from
October 12, 2026 06:31
3d87d04 to
fbeef15
Compare
Jacksondr5
force-pushed
the
j5code/spawn-519
branch
from
October 12, 2026 06:43
2a9c1a6 to
af1d67b
Compare
Jacksondr5
force-pushed
the
j5code/remote-steer-519
branch
from
October 12, 2026 06:43
fbeef15 to
6b5d4c2
Compare
Jacksondr5
force-pushed
the
j5code/spawn-519
branch
from
October 12, 2026 06:45
af1d67b to
572fb63
Compare
Jacksondr5
force-pushed
the
j5code/remote-steer-519
branch
from
October 12, 2026 06:45
6b5d4c2 to
7e0014d
Compare
Jacksondr5
force-pushed
the
j5code/spawn-519
branch
from
October 12, 2026 07:23
572fb63 to
2d415cd
Compare
Jacksondr5
force-pushed
the
j5code/remote-steer-519
branch
from
October 12, 2026 07:23
7e0014d to
19016b3
Compare
j5_send_message's steer and restart reached agents on this server only. They now cross to a peer server (#519): - The request and the sender's permission limit travel as `landing` on the peer delivery, two optional fields, so the protocol version stays 2. - The receiving server applies upstream's rule, since only it knows its agent's modes: an agent above the limit refuses the delivery with `landing_refused`, and the sender gets the not-delivered notice. - A server advertises a `landing` capability. An older peer would queue the message and say nothing, so the tool refuses the send in its result. - A roster answer now carries capabilities, so a peer updated after it was added is believed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ent modes, and a rolled-back peer loses its capability Review found that the permission check on a received steer or restart read the frozen pre-V2 thread table, so a current thread was never refused. It reads upstream's V2 projection now, and the test seeds upstream's real schema. A peer that went back to an older build kept the landing capability its newer build had advertised. A roster answer that names no capabilities clears it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Jacksondr5
force-pushed
the
j5code/spawn-519
branch
from
October 12, 2026 07:31
2d415cd to
9b87419
Compare
Jacksondr5
force-pushed
the
j5code/remote-steer-519
branch
from
October 12, 2026 07:31
19016b3 to
e4900a2
Compare
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
j5_send_messagecan ask for a message to steer or restart the receiver's turn, but only for an agent on the same server (#553). Jackson decided on 2026-10-11 that it reaches agents on peer servers too (#519, the decision record).This is the third PR of a stack: #553, then #557, then this one. With it, everything decided in #519 is built, so it closes the issue once the stack merges.
Closes #519
What changed
On the wire. A peer delivery gains one optional field,
landing: the mode (steerorrestart) and the broadest permission and interaction modes the sender could touch when it sent. It is an additive change, so the peer protocol version stays 2 and an updated server keeps working with one that is not.On the receiving server. Only that server knows its agent's modes, so it applies upstream's rule when the message arrives: an agent that runs above the sender's limit refuses the delivery with a new final answer,
landing_refused. An accepted one keeps the request on its received record, and local delivery then lands it exactly as a local steer or restart does, including upstream's second check at dispatch.On the sending server.
mode.landingcapability. A peer that does not advertise it would drop the field and queue the message without saying so, so the tool refuses the send in its result and names the server to update.Attachments still reach an agent on this server only.
Things a reviewer should know
orchestration_v2_projection_threadstable, by SQL. The inbound service has no orchestrator dependency today and I did not add one for two columns. Other J5 reads use that table the same way.envelopes.v1.jsongoes from 24 to 25 for the send tool's description.Review so far
An Astra peer reviewed the first commit and found two defects, fixed in the second. The receiving server read the agent's modes from the frozen pre-V2 thread table, so a current thread was never refused; my test hid it by creating that table itself, and it now runs upstream's migrations and seeds the real one. And a peer that rolled back to an older build kept the capability its newer build had advertised; a roster answer that names no capabilities now clears it.
Tests
PeerRoundTrip.test.ts, two servers with real ledgers and delivery workers: a steer crosses with its limit and reaches the receiving server's transport as a steer; a restart for an agent raised above the limit is refused, and nothing is recorded or delivered there. The same test pins the HTTP answer for the refusal and the notice wording.handlers.test.ts: the tool refuses a steer to a peer that does not advertise the capability, and sends the caller's limit to one that does.PeerDirectory.test.ts: a roster read records what the peer says it can do, and forgets it when the answer no longer says.PeerHttp.test.tsandPeerStoreService.test.ts: the hello, the roster answer and the poll answer advertise the capability.No unit test drives a steer through the polling link mode. A polled delivery is built by the same
buildPeerDeliveryBodyand refused through the samepeerDeliveryRefusal, and the polling steer was verified live, below.Live testing
Verdict: pass. A tester agent ran the whole stack (#553, #557, #563) on a live-test server with real agents on Claude Haiku and GPT Luna, following the
j5-live-testskill. The full matrix ran on6b5d4c25a7, a focused retest on19016b3f48after one wording fix, and a last check of the listing one4900a23f7, the head of the stack. Report:test-reports/j5code-remote-steer-519.md.What ran live for this PR, on two peered test servers on one machine:
Not exercised live:
Nothing needs testing by hand.
Upstream impact
No upstream-owned file is edited. FORK.md case 26 records the new path. The read of upstream's thread projection table is noted above.
Checklist
FORK.md(case text and file-table row) in this PRdocs/j5/product/upstream.mdAGENTS.md)docs/j5/product/and user docs rewritten where this changes themSurfaces that applied:
PeerDeliveryRequest,PeerCapabilitiesandPeerRosterResponseinpackages/contracts, each with an optional addition.Surfaces that did not apply: no client or settings change, and no provider adapter.
Built by Claude Opus 5.5 in Claude Code.
🤖 Generated with Claude Code