Skip to content

SuperInstance/beacon-protocol

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

beacon-protocol

Fleet discovery and registry. Ship Protocol Layer 5. The lighthouse broadcasting.

Agents register their capabilities and services. Other agents discover them. Heartbeats keep the roster alive. Beacons broadcast events fleet-wide.

Usage

from beacon_protocol import BeaconRegistry, AgentDescriptor, ServiceType, Beacon

registry = BeaconRegistry()
registry.register(AgentDescriptor(
    agent_id="oracle1", name="Oracle1",
    services=[ServiceType.KEEPER],
    capabilities=["crates", "coordination"],
    endpoint="keeper:8900",
))

# Discover agents with crate publishing capability
agents = registry.discover(capabilities=["crates"])

# Broadcast an event
registry.broadcast(Beacon(agent_id="oracle1", payload={"event": "crate_published"}))

Zero deps. pip install beacon-protocol

About

Fleet discovery and registry — Ship Protocol Layer 5

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages