feat(comms): peer-DM T0 name-addressing cutover — agents address channels+topics by name (RIG-2956) - #730
Merged
Conversation
|
Compass engineering docs preview: https://compass-rig-2956-t0-name-add.compass-eng-docs.pages.dev Deployed from |
rigel-mintaka
force-pushed
the
compass/rig-2956-t0-name-addressing
branch
2 times, most recently
from
August 30, 2026 04:26
27e07bd to
497cfab
Compare
mattwilkinsonn
approved these changes
Aug 30, 2026
…nels+topics by name (RIG-2956) The T0 slice of the peer-DM name-addressing cutover (frozen record docs/designs/product/compass-agent-peer-dm/design.md §T0). Agents and UIs address channels and topics by NAME; the wire and store stay id-typed, resolved at the service edge (mirrors the merged handle-addressing cutover #698 / DL-270). Proto denorm fields + Go edge + delivery denorm + TS tools, one atomic change. Proto (regen committed): - DeliverControl.channel_name=5, SteerControl.topic_name=4/channel_name=5: the source channel/topic NAMES ride the deliver/steer control op so the agent renders them without a roster lookup. - PostMessageRequest.create_topic=6: the get-or-create gate (R5). Go comms edge: - store.ChannelByNameForViewer: viewer-scoped name→id resolve, sharing channelVisiblePredicate with ListChannels (no read/resolve drift). Unknown OR invisible name → ErrNotFound (D9 merge); ambiguous name → ErrInvalidArgument naming the collision (no ErrAmbiguous sentinel). - TopicRef.Create gates get-or-create in resolveTopicForAppend: set → mint; unset → a name-miss is ErrNotFound, not a silent create (R5). Archived revival unchanged. - comms_post_message / comms_post_ask route through the new PostAsAccountByName / ListAsAccountByName tool-arm wrappers, which resolve the channel NAME → id then delegate to the UNCHANGED id-typed PostAsAccount / ListAsAccount. Post/ask drop the home default (R2 — the agent must name its channel, even its own home); list keeps omit-=home (a read has no misroute hazard). - defaultChannel: preserve CreateTopic on its home-channel request copy (latent bug the create_topic gate would have surfaced as a silent mint-failure on CommitAgentPost's frame-relay path). - Internal producers that legitimately mint set Create=true (serve_seed Setup seed, CommitAgentPost frame relay, test helpers). Go delivery denorm: - store.TopicChannelNames(topicID) → (topicName, channelName): id-typed join, ErrNotFound on miss. - Consumer.sourceNames mirrors authorHandle (empty topic id → empty; store miss → log + empty, never blocks delivery); deliverOp/steerOp carry ChannelName+TopicName on both DeliverControl and SteerControl. TS agent tools: - comms_post_message / comms_post_ask require an explicit channel NAME (home default dropped) + optional create_topic; comms_list_messages flips to a channel NAME param, keeps omit-=home. The name rides the existing container channelId arm (the Go edge resolves). - formatDeliversForPrompt renders "Channel <name> › topic <name>:" + a reply cue naming both required post params; source names plumbed per message via #deliverSourceNames, mirroring #deliverFromHandles. Resolve misses degrade (topic → id, channel → placeholder). Spec-impact: none. The name-addressing invariant (agents/UIs address by name; wire + store stay id-typed) is already recorded in the frozen design record and DL-291..297; this is its T0 implementation. Refs RIG-2956 Co-authored-by: Matt Wilkinson <matt@rigel.build>
rigel-mintaka
force-pushed
the
compass/rig-2956-t0-name-addressing
branch
from
August 30, 2026 05:19
497cfab to
076b877
Compare
mattwilkinsonn
approved these changes
Aug 30, 2026
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.
The T0 slice of the peer-DM name-addressing cutover (frozen record
docs/designs/product/compass-agent-peer-dm/design.md §T0). Agents and UIs
address channels and topics by NAME; the wire and store stay id-typed,
resolved at the service edge (mirrors the merged handle-addressing cutover
#698 / DL-270). Proto denorm fields + Go edge + delivery denorm + TS tools,
one atomic change.
Proto (regen committed):
the source channel/topic NAMES ride the deliver/steer control op so the
agent renders them without a roster lookup.
Go comms edge:
channelVisiblePredicate with ListChannels (no read/resolve drift).
Unknown OR invisible name → ErrNotFound (D9 merge); ambiguous name →
ErrInvalidArgument naming the collision (no ErrAmbiguous sentinel).
unset → a name-miss is ErrNotFound, not a silent create (R5). Archived
revival unchanged.
PostAsAccountByName / ListAsAccountByName tool-arm wrappers, which resolve
the channel NAME → id then delegate to the UNCHANGED id-typed
PostAsAccount / ListAsAccount. Post/ask drop the home default (R2 — the
agent must name its channel, even its own home); list keeps omit-=home
(a read has no misroute hazard).
(latent bug the create_topic gate would have surfaced as a silent
mint-failure on CommitAgentPost's frame-relay path).
Setup seed, CommitAgentPost frame relay, test helpers).
Go delivery denorm:
join, ErrNotFound on miss.
miss → log + empty, never blocks delivery); deliverOp/steerOp carry
ChannelName+TopicName on both DeliverControl and SteerControl.
TS agent tools:
(home default dropped) + optional create_topic; comms_list_messages flips
to a channel NAME param, keeps omit-=home. The name rides the existing
container channelId arm (the Go edge resolves).
cue naming both required post params; source names plumbed per message via
#deliverSourceNames, mirroring #deliverFromHandles. Resolve misses degrade
(topic → id, channel → placeholder).
Spec-impact: none. The name-addressing invariant (agents/UIs address by name; wire + store stay id-typed) is already recorded in the frozen design record and DL-291..297; this is its T0 implementation.
Refs RIG-2956
Co-authored-by: Matt Wilkinson matt@rigel.build