From c2164e14a35f31f3eae355d82da4a350ee996c7b Mon Sep 17 00:00:00 2001 From: Russell Martin Date: Fri, 10 Jul 2026 14:25:38 -0400 Subject: [PATCH] generated: add realtime reporter methods to gatewayobs Regenerated from cloud-observability schema/gateway.yaml realtime (speech-to-speech) billing columns (#502). Adds ReportRealtime{DurationSeconds, Input{Text,Audio,Image, Video}Tokens, Output{Text,Audio}Tokens, Cached{Text,Audio}Tokens} to the gateway model reporter, so agent-gateway can emit the realtime_* metrics that populate the observability rollup consumed by analytics-recorder (#949) and backend-common (#939). --- .changeset/realtime-gateway-obs.md | 5 +++++ observability/gatewayobs/gen_reporter.go | 11 ++++++++++- observability/gatewayobs/gen_reporter_noop.go | 18 ++++++++++++++++++ 3 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 .changeset/realtime-gateway-obs.md diff --git a/.changeset/realtime-gateway-obs.md b/.changeset/realtime-gateway-obs.md new file mode 100644 index 000000000..fcd7c23cb --- /dev/null +++ b/.changeset/realtime-gateway-obs.md @@ -0,0 +1,5 @@ +--- +"github.com/livekit/protocol": patch +--- + +Add realtime (speech-to-speech) reporter methods to gatewayobs, regenerated from cloud-observability schema/gateway.yaml realtime billing columns (#502). diff --git a/observability/gatewayobs/gen_reporter.go b/observability/gatewayobs/gen_reporter.go index 5eb9ef119..3c8dee4a9 100644 --- a/observability/gatewayobs/gen_reporter.go +++ b/observability/gatewayobs/gen_reporter.go @@ -6,7 +6,7 @@ import ( "time" ) -const Version_9V68R3G = true +const Version_J1BFFVO = true type KeyResolver interface { Resolve(string) @@ -109,6 +109,15 @@ type modelReporter interface { ReportInferenceTotalTokens(v uint64) ReportInferenceCacheCreateTokens(v uint64) ReportInferenceCacheReadTokens(v uint64) + ReportRealtimeDurationSeconds(v uint32) + ReportRealtimeInputTextTokens(v uint64) + ReportRealtimeInputAudioTokens(v uint64) + ReportRealtimeInputImageTokens(v uint64) + ReportRealtimeInputVideoTokens(v uint64) + ReportRealtimeOutputTextTokens(v uint64) + ReportRealtimeOutputAudioTokens(v uint64) + ReportRealtimeCachedTextTokens(v uint64) + ReportRealtimeCachedAudioTokens(v uint64) ReportSttDuration(v uint32) ReportTtsChars(v uint32) ReportBargeInRequests(v uint64) diff --git a/observability/gatewayobs/gen_reporter_noop.go b/observability/gatewayobs/gen_reporter_noop.go index 7722f116d..241f1ebb6 100644 --- a/observability/gatewayobs/gen_reporter_noop.go +++ b/observability/gatewayobs/gen_reporter_noop.go @@ -164,6 +164,15 @@ func (r *noopModelReporter) ReportInferenceCompletionTokens(v uint64) func (r *noopModelReporter) ReportInferenceTotalTokens(v uint64) {} func (r *noopModelReporter) ReportInferenceCacheCreateTokens(v uint64) {} func (r *noopModelReporter) ReportInferenceCacheReadTokens(v uint64) {} +func (r *noopModelReporter) ReportRealtimeDurationSeconds(v uint32) {} +func (r *noopModelReporter) ReportRealtimeInputTextTokens(v uint64) {} +func (r *noopModelReporter) ReportRealtimeInputAudioTokens(v uint64) {} +func (r *noopModelReporter) ReportRealtimeInputImageTokens(v uint64) {} +func (r *noopModelReporter) ReportRealtimeInputVideoTokens(v uint64) {} +func (r *noopModelReporter) ReportRealtimeOutputTextTokens(v uint64) {} +func (r *noopModelReporter) ReportRealtimeOutputAudioTokens(v uint64) {} +func (r *noopModelReporter) ReportRealtimeCachedTextTokens(v uint64) {} +func (r *noopModelReporter) ReportRealtimeCachedAudioTokens(v uint64) {} func (r *noopModelReporter) ReportSttDuration(v uint32) {} func (r *noopModelReporter) ReportTtsChars(v uint32) {} func (r *noopModelReporter) ReportBargeInRequests(v uint64) {} @@ -184,6 +193,15 @@ func (t *noopModelTx) ReportInferenceCompletionTokens(v uint64) {} func (t *noopModelTx) ReportInferenceTotalTokens(v uint64) {} func (t *noopModelTx) ReportInferenceCacheCreateTokens(v uint64) {} func (t *noopModelTx) ReportInferenceCacheReadTokens(v uint64) {} +func (t *noopModelTx) ReportRealtimeDurationSeconds(v uint32) {} +func (t *noopModelTx) ReportRealtimeInputTextTokens(v uint64) {} +func (t *noopModelTx) ReportRealtimeInputAudioTokens(v uint64) {} +func (t *noopModelTx) ReportRealtimeInputImageTokens(v uint64) {} +func (t *noopModelTx) ReportRealtimeInputVideoTokens(v uint64) {} +func (t *noopModelTx) ReportRealtimeOutputTextTokens(v uint64) {} +func (t *noopModelTx) ReportRealtimeOutputAudioTokens(v uint64) {} +func (t *noopModelTx) ReportRealtimeCachedTextTokens(v uint64) {} +func (t *noopModelTx) ReportRealtimeCachedAudioTokens(v uint64) {} func (t *noopModelTx) ReportSttDuration(v uint32) {} func (t *noopModelTx) ReportTtsChars(v uint32) {} func (t *noopModelTx) ReportBargeInRequests(v uint64) {}