feat(desktop): register existing external agent references - #6321
feat(desktop): register existing external agent references#6321camaragon wants to merge 12 commits into
Conversation
Signed-off-by: Cameron Aragon <69489633+camaragon@users.noreply.github.com>
Signed-off-by: Cameron Aragon <69489633+camaragon@users.noreply.github.com>
Signed-off-by: Cameron Aragon <69489633+camaragon@users.noreply.github.com>
Signed-off-by: Cameron Aragon <69489633+camaragon@users.noreply.github.com>
Signed-off-by: Cameron Aragon <69489633+camaragon@users.noreply.github.com>
Signed-off-by: Cameron Aragon <69489633+camaragon@users.noreply.github.com>
Signed-off-by: Cameron Aragon <69489633+camaragon@users.noreply.github.com>
Signed-off-by: Cameron Aragon <69489633+camaragon@users.noreply.github.com>
Signed-off-by: Cameron Aragon <69489633+camaragon@users.noreply.github.com>
Signed-off-by: Cameron Aragon <69489633+camaragon@users.noreply.github.com>
Signed-off-by: Cameron Aragon <69489633+camaragon@users.noreply.github.com>
Signed-off-by: Cameron Aragon <69489633+camaragon@users.noreply.github.com>
|
Hi Buzz team, @camaragon. This PR is close to a use case we have, so consider this a design question for a possible follow up, not a request to expand the current PR. We operate agents through an external controller that governs their identity and credentials. The Nostr pubkey already gives each agent a stable identity in Buzz, but we're missing a structured, inspectable link from that pubkey to the controller's public per-agent record. Free text such as the local Would you consider one optional structured field on the reference, for example This may belong on the device-local reference introduced here, or probably on the signed, relay-published side in #3556... I think that local storage can act as an operator bookmark, while a portable claim should probably be relay-published. Happy to write up a short follow-up proposal if useful. |
|
Thanks, @PabloReyes. I think you've got the split right. A local reference can hold a bookmark, but a portable governance claim should be signed and published to the relay. I went back through both implementations. The reference in #6321 is deliberately narrow: keyless, stored only on the current device, used for display and profile navigation. Registering one doesn't add the pubkey to the trusted-agent set, and it doesn't touch bot classification, mentions, config-message authorization, or lifecycle controls. Given that boundary, I'd rather not add a #3556 is the better home for the portable version. It already discovers agents through signed I looked at the nearby NIPs and didn't find a clean fit. NIP-05 links an identifier to a pubkey, NIP-39 links to external-platform identities, and NIP-89 covers app handlers. NIP-46 is the closest in spirit, but it's about remote signing, not a public governance pointer. So there does seem to be a gap. A minimal version could specify:
I still think there's a real local use case here, the operator bookmark you mentioned. I'd just name it something like If you want to write it up, please do. I'd open a new issue and link both #3556 and this thread. #3556 is Ali's and still waiting on review, with an open pagination finding on the owner-tagged |
|
@block/buzz-oss-team This is ready for maintainer review. Scope is intentionally narrow: register keyless local references for existing external agents without changing trusted-agent membership, authorization, or lifecycle controls. DCO is green and the branch is mergeable. |
|
@block/buzz-oss-team This desktop agent-reference change is ready for maintainer review; all currently reported DCO checks pass. Please review when available. |
feat(desktop): register existing external agent references
Summary
Related to #3054 and #3556.
Why
Desktop currently models locally managed agents and relay-discovered agents, but it has no explicit way to retain a display reference to an existing identity that is operated elsewhere and may not be discoverable through current relay ownership metadata.
This change adds a narrow local reference type instead of importing the identity as a managed agent. It complements the relay-discovery approach in #3556: relay discovery remains useful when verified ownership metadata exists, while an explicit local reference covers identities that must be selected directly by public key.
Safety boundary
A registered reference contains only:
It never contains or owns a private key, authorization credential, runtime, provider, model, environment, system prompt, process, or auto-start configuration.
Registered references are display/navigation metadata only. They are not added to the application-wide trusted-agent set and do not affect bot classification, mention eligibility, or configuration-message authorization. Their cards expose no Start, Stop, Restart, Deploy, model, runtime-error, auto-start, or secret controls.
Managed-agent lifecycle/configuration/delete commands validate ownership before side effects and return
agent <pubkey> not foundfor registered references.Storage and rollback
References are stored separately from managed agents in a restricted, atomically written JSON file. Invalid JSON is preserved and fails closed. Removing a reference deletes only the local display reference; it does not delete an identity or stop an external process.
Older builds ignore the separate reference file, so code rollback does not alter managed-agent state.
Verification
cargo fmt --checkcargo test registered_references --lib— 17 passedcargo test registered_agent_references --lib— 10 passedcargo test --lib— 2,608 passed, 17 ignoredpnpm typecheckpnpm checkpnpm build:e2enode scripts/check-registered-agent-boundary.mjsIndependent implementation review found no unresolved blocking, high, or medium correctness findings.