feat(orchestrators): add Buzz (block/buzz) orchestrator detection - #12
Conversation
|
Warning Review limit reachedYou’ve reached a temporary PR review limit under our Fair Usage Limits Policy. Next review available in: 2 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (10)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
94c3a5d to
fa77255
Compare
What
Adds Buzz (block/buzz) as a
RoleOrchestrator, alongside Conductor / OpenClaw / Gas City. Buzz is Block's chat/agent platform whosebuzz-acpharness spawns Claude Code / Codex / Goose as sub-agents over ACP. Downstream tools (e.g. ox) need to recognize when they're running under Buzz to tag telemetry/attribution and adapt behavior.Why a process-ancestry probe (not just env vars)
Buzz sets no fixed "spawned by Buzz" marker on the child it launches (
crates/buzz-acp/src/acp.rsAcpClient::spawn()never.env_clear()s and sets noBUZZ_ORCHESTRATOR=1). The one signal that is always present and config-independent is process ancestry —buzz-acpis by construction an ancestor of the agent it spawns. agentx'sEnvironmentonly exposed env/files/exec/paths, so this PR adds an ancestry probe.Detection precedence (
orchestrators/buzz.go)ORCHESTRATOR_ENV == "buzz"BUZZ_ACP_AGENT_COMMAND != ""--agent-commandflag)buzz-acpinProcessAncestry()BUZZ_RELAY_URL/BUZZ_PRIVATE_KEYChanges
Environment.ProcessAncestry() ([]string, error)— new interface method returning ancestor executable base names (parent → PID 1).ps -A -o pid=,ppid=,comm=snapshot walked in memory — no new dependency (works on macOS/BSD/Linux, doesn't rely on/proc).internal/procapproach; implement via Toolhelp32 if Buzz-on-Windows detection is ever needed.MockEnvironmentgains anAncestry []stringfield as the test seam.orchestrators/buzz.go— fullAgentimpl, pure orchestrator (nil hook/command/rules managers;Capabilities.MCPServers=true, since MCP forwarding over ACPsession/newis Buzz's durable integration surface).AgentTypeBuzzadded to the enum +SupportedAgents; registered insetup/setup.go.Tests
orchestrators/buzz_test.go— table-drivenDetectcovering all three positive signals (incl. deep-in-chain and prefix ancestry) and, crucially, negative guards thatBUZZ_RELAY_URL/BUZZ_PRIVATE_KEYalone do not detect (prevents re-adding the rejected heuristic) and that barebuzz≠buzz-acp.agent_test.goSupportedAgentscount bumped 20 → 21.make testgreen,golangci-lint run→ 0 issues.Real-host validation: a throwaway check of
SystemEnvironment.ProcessAncestry()on a live dev host returned[go zsh claude conductor-runtime conductor]— correctly surfacing the actual orchestrator (Conductor) as an ancestor, exactly the mechanism Buzz detection relies on. Underbuzz-acp,buzz-acpwould occupy that slot.Release
Cut
v0.1.11after merge so consumers (ox) can bumpgo.mod.Note
Commit is unsigned (the signing key's passphrase wasn't available in the automation environment) — re-sign on merge if the repo requires signed commits.