Skip to content

Conversation

stephentoub
Copy link
Member

@stephentoub stephentoub commented Sep 24, 2025

This is basically the chat client OpenTelemetry client copy/pasted/tweaked to compile. The otel spec doesn't have anything specific to this modality yet, so this is making best guesses on what things should be and also being minimal in what's tracked, effectively a pure subset of what chat client outputs.

Microsoft Reviewers: Open in CodeFlow

This is basically the chat client OpenTelemetry client copy/pasted/tweaked to compile. The otel spec doesn't have anything specific to this modality yet, so this is making best guesses on what things should be and also being minimal in what's tracked.
@stephentoub stephentoub requested a review from a team as a code owner September 24, 2025 20:59
@Copilot Copilot AI review requested due to automatic review settings September 24, 2025 20:59
@github-actions github-actions bot added the area-ai Microsoft.Extensions.AI libraries label Sep 24, 2025
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds OpenTelemetry support for speech-to-text clients by implementing OpenTelemetry telemetry tracking that follows the OpenTelemetry Semantic Conventions for Generative AI systems. The implementation includes comprehensive activity tracing, metrics collection, and sensitive data handling options.

  • Adds OpenTelemetrySpeechToTextClient with full telemetry support including activities, metrics, and error tracking
  • Provides builder extension methods for easy integration into the speech-to-text client pipeline
  • Includes comprehensive test coverage for both streaming and non-streaming scenarios with sensitive data handling

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
OpenTelemetrySpeechToTextClient.cs Core implementation with activity tracing, metrics collection, and response handling for both streaming and non-streaming operations
OpenTelemetrySpeechToTextClientBuilderExtensions.cs Extension methods to add OpenTelemetry support to the speech-to-text client builder pipeline
OpenTelemetrySpeechToTextClientTests.cs Comprehensive test suite covering streaming/non-streaming scenarios and sensitive data configuration
SpeechToTextClientBuilder.cs Documentation fixes changing "audio transcription" references to "speech-to-text"
LoggingSpeechToTextClientBuilderExtensions.cs Documentation fix changing "audio transcription" to "speech-to-text"

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@stephentoub stephentoub enabled auto-merge (squash) September 24, 2025 21:32
@stephentoub stephentoub merged commit 76737b4 into dotnet:main Sep 30, 2025
7 checks passed
This was referenced Oct 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area-ai Microsoft.Extensions.AI libraries

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants