mirror of
https://github.com/block/buzz.git
synced 2026-11-24 18:21:59 +00:00
buzz-acp derives harness identity from the command's BASENAME (normalize_agent_command_identity, buzz-acp/src/config.rs:600-615) and already has a "buzz-agent" arm meaning "no extra args" (default_agent_args, :617-624). Naming the binary `buzz-agent` makes this a drop-in swap: point BUZZ_ACP_AGENT_COMMAND at the built path and buzz-acp cannot tell the difference -- same identity, same args, same ACP contract, goose underneath. That is the whole premise, so the artifact should reflect it. Crate stays buzz-agent-core (it is workspace-excluded and owns its lockfile); only the emitted binary is renamed. 35 tests green. Signed-off-by: Michael Neale <michael.neale@gmail.com>
86 lines
3.5 KiB
TOML
86 lines
3.5 KiB
TOML
# buzz-agent-core — buzz-agent's ACP wire layer on top of the Goose Rust
|
|
# library (used as an SDK, not as a subprocess).
|
|
#
|
|
# WHY A SEPARATE CRATE, EXCLUDED FROM THE WORKSPACE
|
|
#
|
|
# `crates/buzz-agent` is a *library* linked into both `crates/sprig` and
|
|
# `desktop/src-tauri` (which uses only `catalog`/`config` for the Databricks
|
|
# model picker). Adding goose to that crate would pull goose's ~700-crate
|
|
# dependency graph into the Tauri app and into the workspace lockfile.
|
|
#
|
|
# So this crate is excluded from the workspace (see the root Cargo.toml
|
|
# `exclude` list) and carries its own Cargo.lock, exactly as PR #1526 did for
|
|
# `goose-acp`. Goose's ACP/MCP dependency versions move independently.
|
|
#
|
|
# Build: cargo build --release --manifest-path buzz-agent-core/Cargo.toml
|
|
#
|
|
# THIS IS NOT "GOOSE AS THE HARNESS". The binary keeps buzz-agent's identity
|
|
# (`agentInfo.name = "buzz-agent"`), its 6-method ACP surface, its
|
|
# `activeRunId` steering contract and its `usage_update` ordering. Only the
|
|
# agent loop underneath is Goose's instead of hand-written. Picking "Goose"
|
|
# from the harness gallery remains a separate thing: that shells out to a
|
|
# user-installed `goose` CLI.
|
|
|
|
[package]
|
|
name = "buzz-agent-core"
|
|
version = "0.1.0"
|
|
edition = "2021"
|
|
publish = false
|
|
|
|
[lib]
|
|
name = "buzz_agent_core"
|
|
path = "src/lib.rs"
|
|
|
|
# Emitted as `buzz-agent`, not `buzz-agent-core`, on purpose. buzz-acp derives
|
|
# a harness identity from the command's BASENAME
|
|
# (`normalize_agent_command_identity`, buzz-acp/src/config.rs:600-615) and
|
|
# already has a `"buzz-agent"` arm meaning "no extra args"
|
|
# (`default_agent_args`, :617-624). Naming the binary this way makes it a
|
|
# drop-in swap: point BUZZ_ACP_AGENT_COMMAND at it and buzz-acp cannot tell the
|
|
# difference.
|
|
[[bin]]
|
|
name = "buzz-agent"
|
|
path = "src/main.rs"
|
|
|
|
# Test-only fake MCP server, copied from crates/buzz-agent. Built
|
|
# unconditionally because cargo can't gate bins on `cfg(test)`.
|
|
[[bin]]
|
|
name = "fake-mcp"
|
|
path = "tests/bin/fake_mcp.rs"
|
|
|
|
[dependencies]
|
|
# Pinned to a release commit deliberately: goose's public `Agent` surface is
|
|
# not semver-stable (many fields are `pub(super)`) and its MSRV moves quickly.
|
|
# 305849b71 == goose 1.44.0.
|
|
#
|
|
# default-features = false drops: telemetry, otel, aws-providers,
|
|
# local-inference (candle/whisper), code-mode (pctx/V8), system-keyring, nostr.
|
|
# We name only rustls-tls, which is mandatory — `goose` pulls reqwest/sqlx/rmcp
|
|
# with default-features = false, so a TLS backend only arrives via this feature
|
|
# (and `rustls-tls` + `native-tls` are mutually exclusive: see the
|
|
# compile_error! at goose/src/lib.rs:3-4).
|
|
goose = { git = "https://github.com/aaif-goose/goose", rev = "305849b71709b95b86ed9f11bd3bc939899c0aab", default-features = false, features = ["rustls-tls"] }
|
|
goose-provider-types = { git = "https://github.com/aaif-goose/goose", rev = "305849b71709b95b86ed9f11bd3bc939899c0aab" }
|
|
|
|
tokio = { version = "1", features = ["rt-multi-thread", "macros", "io-std", "io-util", "sync", "time"] }
|
|
tokio-util = { version = "0.7", features = ["rt"] }
|
|
futures = "0.3"
|
|
serde = { version = "1", features = ["derive"] }
|
|
serde_json = "1"
|
|
anyhow = "1"
|
|
tracing = "0.1"
|
|
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
|
|
rmcp = { version = "1.8", default-features = false, features = ["schemars"] }
|
|
|
|
[dev-dependencies]
|
|
tempfile = "3"
|
|
|
|
# Size-optimized. PR #1526 measured 32.5 MiB (macOS arm64) for a comparable
|
|
# goose-linked binary; re-measure rather than trusting that number.
|
|
[profile.release]
|
|
opt-level = "z"
|
|
lto = "fat"
|
|
codegen-units = 1
|
|
panic = "abort"
|
|
strip = true
|