Skip to content

Conversation

Copilot
Copy link
Contributor

@Copilot Copilot AI commented Aug 22, 2025

This change removes the "Experimental" prefix from the default telemetry source name for Microsoft.Extensions.AI, changing it from "Experimental.Microsoft.Extensions.AI" to "Microsoft.Extensions.AI".

Background

The issue raised a concern that keeping "Experimental" in the telemetry source name indefinitely could cause breaking changes in the future. The longer the experimental name stays in use, the more pain there will be when changing it later, as libraries and applications that depend on it (like Aspire integrations) would break if the source name changes without corresponding updates.

Changes Made

  • Updated the DefaultSourceName constant in OpenTelemetryConsts.cs
  • Updated hardcoded references in project templates and test snapshots
  • Ensured all telemetry collection configurations use the new source name

Impact

This affects applications that use the default telemetry source name when creating:

  • OpenTelemetryChatClient instances without a custom sourceName parameter
  • OpenTelemetryEmbeddingGenerator<TInput, TEmbedding> instances without a custom sourceName parameter

Applications that provide a custom source name remain unaffected. Telemetry collection systems that previously monitored "Experimental.Microsoft.Extensions.AI" will need to be updated to monitor "Microsoft.Extensions.AI".

Example

// Before: Uses "Experimental.Microsoft.Extensions.AI" as default source name
var client = new OpenTelemetryChatClient(innerClient);

// After: Uses "Microsoft.Extensions.AI" as default source name  
var client = new OpenTelemetryChatClient(innerClient);

// Custom source names continue to work as before
var client = new OpenTelemetryChatClient(innerClient, logger, "MyCustomSource");

Fixes #6736.

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • sqdvsblobprodcus333.vsblob.vsassets.io
    • Triggering command: /home/REDACTED/work/extensions/extensions/.dotnet/dotnet msbuild /m /nologo /clp:Summary /v:minimal /nr:true /p:TreatWarningsAsErrors=false /p:ContinuousIntegrationBuild=false /home/REDACTED/work/extensions/extensions/artifacts/toolset/restore.proj /t:__WriteToolsetLocation /clp:ErrorsOnly;NoSummary /p:__ToolsetLocationOutputFile=/home/REDACTED/work/extensions/extensions/artifacts/toolset/9.0.0-beta.25415.3.txt (dns block)

If you need me to access, download, or install something from one of these locations, you can either:


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Microsoft Reviewers: Open in CodeFlow

@Copilot Copilot AI changed the title [WIP] [MEAI] Rename telemetry source's from Experimental.Microsoft.Extensions.AI to Microsoft.Extensions.AI [MEAI] Rename telemetry source from Experimental.Microsoft.Extensions.AI to Microsoft.Extensions.AI Aug 22, 2025
@Copilot Copilot AI requested a review from JamesNK August 22, 2025 04:25
Copilot finished work on behalf of JamesNK August 22, 2025 04:25
@JamesNK JamesNK marked this pull request as ready for review August 22, 2025 04:45
@Copilot Copilot AI review requested due to automatic review settings August 22, 2025 04:45
@JamesNK JamesNK requested review from a team as code owners August 22, 2025 04:45
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 removes the "Experimental" prefix from the default telemetry source name for Microsoft.Extensions.AI, changing it from "Experimental.Microsoft.Extensions.AI" to "Microsoft.Extensions.AI" to prevent future breaking changes as the library moves out of experimental status.

  • Updates the core constant definition in OpenTelemetryConsts.cs
  • Updates all project template references to use the new source name
  • Updates test snapshots to reflect the new telemetry source name

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/Libraries/Microsoft.Extensions.AI/OpenTelemetryConsts.cs Updates the DefaultSourceName constant definition
src/ProjectTemplates/Microsoft.Extensions.AI.Templates/src/ChatWithCustomData/ChatWithCustomData-CSharp.ServiceDefaults/Extensions.cs Updates telemetry configuration in project template
test/ProjectTemplates/Microsoft.Extensions.AI.Templates.IntegrationTests/Snapshots/aichatweb.BasicAspire.verified/aichatweb/aichatweb.ServiceDefaults/Extensions.cs Updates test snapshot for basic Aspire template
test/ProjectTemplates/Microsoft.Extensions.AI.Templates.IntegrationTests/Snapshots/aichatweb.AzureOpenAI_Qdrant_Aspire.verified/aichatweb/aichatweb.ServiceDefaults/Extensions.cs Updates test snapshot for Azure OpenAI with Qdrant template
test/ProjectTemplates/Microsoft.Extensions.AI.Templates.IntegrationTests/Snapshots/aichatweb.Ollama_Qdrant.verified/aichatweb/aichatweb.ServiceDefaults/Extensions.cs Updates test snapshot for Ollama with Qdrant template

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

@JamesNK
Copy link
Member

JamesNK commented Aug 22, 2025

This is a design change that requires agreement of MEAI team before merging.

@stephentoub
Copy link
Member

@JamesNK, based on #6736 (comment), this can be closed, right? Thanks.

@JamesNK JamesNK closed this Sep 6, 2025
@github-actions github-actions bot locked and limited conversation to collaborators Oct 6, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[MEAI] Update Aspire to recognize telemetry sources from both Experimental.Microsoft.Extensions.AI and Microsoft.Extensions.AI

3 participants