Repository navigation
feat(berd-call): report voice conversation telemetry - #466
Merged
Merged
Conversation
The standalone Berd Call CLI now sends berd_voice_conversation_started and berd_voice_conversation_ended to the gateway as service berd-call under schema berd-call-otlp-logs-v1. Events carry the input and output backends, the TTS rate and catalog voice (or "custom"), and on end the duration, final user utterances, completed assistant responses and end reason. Consent is Berd's: a shared telemetry_store holds the settings file and installation id for both the app and the CLI, and `berd-call telemetry status|enable|disable` edits the same preference. Internal builds enforce it through telemetry-enforced, mirroring the app's block-telemetry-enforced. The app now rereads the persisted preference at its upload boundaries, so a CLI disable stops a running Berd.app. Signed-off-by: John Matthew Tennant <jtennant@block.xyz> Co-authored-by: Maeve <be734facf808af9bc7720a1cb69aeb2a3d136149938eedf4d0667a70ef433961@buzz.block.builderlab.xyz> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Consent granted mid-call starts reporting at a later session, so the ended counts now cover the same span as its duration. Signed-off-by: John Matthew Tennant <jtennant@block.xyz> Co-authored-by: Maeve <be734facf808af9bc7720a1cb69aeb2a3d136149938eedf4d0667a70ef433961@buzz.block.builderlab.xyz> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
johnmatthewtennant
marked this pull request as ready for review
November 4, 2026 14:33
Signed-off-by: John Matthew Tennant <jtennant@block.xyz> Co-authored-by: Maeve <be734facf808af9bc7720a1cb69aeb2a3d136149938eedf4d0667a70ef433961@buzz.block.builderlab.xyz> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
kalvinnchau
previously approved these changes
Nov 4, 2026
kalvinnchau
left a comment
Collaborator
There was a problem hiding this comment.
🤖 LGTM. Nit: the berd-call telemetry help text (cli_help.rs) lists start, end, duration, turn counts and audio backends, but events also carry tts_rate and tts_voice; worth listing them since this is the consent disclosure.
The help text is the CLI's consent disclosure, so it names the end reason, speech rate, voice, app version and installation id that events also carry. Signed-off-by: John Matthew Tennant <jtennant@block.xyz> Co-authored-by: Maeve <be734facf808af9bc7720a1cb69aeb2a3d136149938eedf4d0667a70ef433961@buzz.block.builderlab.xyz> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
Author
|
🤖 Good catch, thanks. 4c34e02 lists every field events carry in the |
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.
Context
Berd.app reports voice usage, but the standalone Berd Call CLI doesn't, so calls started from agents are invisible. The gateway side is squareup/berd-monitoring#42, which accepts
berd-call-otlp-logs-v1fromservice.name=berd-calland shares the selected-voice validator with app schema v4.Solution
berd_voice_conversation_startedcarriesinput_backend,output_backend,voice_mode=chainedand, when valid,tts_rateandtts_voice.berd_voice_conversation_endedaddsduration_ms,user_utterance_count(final transcripts only),assistant_response_count(completed speech only) andend_reason. The reason isuserfor an explicit stop,clean-shutdownfor parent exit anderrorfor a fatal failure. The voice is a catalog id for the selected backend,customotherwise, and omitted when empty, the same rules as feat(voice): report the selected voice in voice telemetry #460.berd_call::telemetry_storenow owns the settings file, schema check, atomic writes and installation id for both the app and the CLI. The app still passes its Tauri app-data dir. The CLI resolves the same platform path.berd-call telemetry [status|enable|disable]edits that shared preference. A missing or invalid file means off.consent_grantedrereads the persisted preference at the upload and bootstrap boundaries alongside the epoch checks, so disabling via the CLI stops a running Berd.app.telemetry-enforcedis the CLI's twin ofblock-telemetry-enforced, enabled from the sameVITE_TELEMETRY_ENFORCED=1.build-macos.shpasses the environment (empty, so the feature is compiled out, when a custom build setsVITE_TELEMETRY=0), the distro'stelemetry.channel(default public) and the release version. Builds without an environment, including local dev, send nothing.Validation
just tauri-test(includes berd-call, apptelemetrywith and withoutblock-telemetry-enforced),just tauri-check,just clippy,just tauri-fmt-check.an_external_revocation_stops_a_running_app_from_uploading, and restoring it passes.host_session. Alltelemetrytests pass with and withouttelemetry-enforced.just release-scripts-testpasses 110/110. Existing failures in untouched code remain:siri::tests::exact_uninstalled_voice_is_rejected_without_synthesisalso fails on main,outboundandmenu_bartiming tests are intermittent, and berd-call clippy has existing lints instatus_sounds,saved_settings,mainandhost_session.🤖 Generated with Claude Code