Skip to content

Conversation

joperezr
Copy link
Member

@joperezr joperezr commented Apr 8, 2025

joperezr and others added 16 commits April 2, 2025 22:28
….4 release

Flowing stable internal versions and get ready for 9.4 release

----
#### AI description  (iteration 1)
#### PR Classification
Preparing for the 9.4 release by updating internal dependencies and configurations.

#### PR Summary
This pull request updates various dependencies to their latest stable versions and adjusts configurations for the upcoming 9.4 release.
- `Version.Details.xml` and `Versions.props`: Updated multiple dependencies from version 9.0.3 to 9.0.4.
- `azure-pipelines.yml`: Removed the code coverage stage and related configurations.
- `NuGet.config`: Added new internal package sources and removed package source mappings.
- `Directory.Build.props`: Disabled NU1507 warning for internal branches.
- `BuildAndTest.yml`: Added steps to set up private feed credentials for both Windows and non-Windows agents.
<!-- GitOpsUserAgent=GitOps.Apps.Server.pullrequestcopilot -->
* Add TextReasoningContent

* Coalesce TextReasoningContent
* Use ErrorContent in OpenAIResponseChatClient

* Address feedback
* OpenAI: Parse detail additional property

* Update tests to use AsIChatClient

* Don't throw when type is not string

* Match OpenAI.Chat.ChatImageDetailLevel
* Minimal change in AIJsonUtilities from SHA256 to SHA384

* Update GetCacheKey API to have explicit messages/options params

The point of this is to make it easier and more reliable for people overriding the logic to obtain specific values from messages/options to include in cache key without having to search through an opaque list of `object` values.
Several git cherry-picks with no conflicts or manual changes.

----
#### AI description  (iteration 1)
#### PR Classification
Backport recent changes from the main branch to the current branch.

#### PR Summary
This pull request backports recent changes related to AI functionalities and tests from the main branch.
- `OpenAIChatClientTests.cs`: Added new tests for image content handling in chat messages.
- `ChatResponseExtensions.cs`: Enhanced content coalescing to handle multiple content types.
- `TextReasoningContent.cs` and `TextReasoningContentTests.cs`: Added new class and corresponding tests for text reasoning content.
- `AIFunctionFactory.cs`: Improved result marshalling logic for async methods.
- `DistributedCachingChatClient.cs`: Updated cache key computation to include messages and options.
<!-- GitOpsUserAgent=GitOps.Apps.Server.pullrequestcopilot -->
#### AI description  (iteration 1)
#### PR Classification
New feature

#### PR Summary
This pull request marks release builds as "stable" by setting the `DotNetFinalVersionKind` property to "release".
- `eng/Versions.props`: Added `DotNetFinalVersionKind` property to mark builds as stable for release branches.
- `eng/MSBuild/ProjectStaging.props`: Removed redundant setting of `DotNetFinalVersionKind` property.
<!-- GitOpsUserAgent=GitOps.Apps.Server.pullrequestcopilot -->
…fety evaluators

The new evaluators ship in a new Microsoft.Extensions.AI.Evaluation.Safety package.

Also includes the following public API changes:
- Add a Metadata dictionary on EvaluationMetric.
- Make EvaluationMetric.Diagnostics nullable.
- Convert instance functions on some (fully mutable) result types to extension methods in the same namespace.

And some reporting improvements including:
- Change boolean metric UI representation in metric card from Pass / Fail to Yes / No
- Display the above Metadata contents in a table in the metric details view when a metric card is clicked
- Improve display for diagnostics in metric details - diagnostics are now also displayed in a table with with proper formatting and an option copy diagnostics to the clipboard
…unction invocations (dotnet#6250)

We try to use ConfigureAwait(false) throughout our libraries. However, we exempt ourselves from that in cases where user code is expected to be called back from within the async code, and there's a reasonable presumption that such code might care about the synchronization context. AIFunction fits that bill. And FunctionInvokingChatClient needs to invoke such functions, which means that we need to be able to successfully flow the context from where user code calls Get{Streaming}ResponseAsync through into wherever a FunctionInvokingChatClient is in the middleware pipeline. We could try to selectively avoid ConfigureAwait(false) on the path through middleware that could result in calls to FICC.Get{Streaming}ResponseAsync, but that's fairly brittle and hard to maintain. Instead, this PR just removes ConfigureAwait use from the M.E.AI library. It also fixes a few places where tasks were explicitly being created and queued to the thread pool.
…ns.AI.dll for AIFunction...

Remove use of ConfigureAwait from Microsoft.Extensions.AI.dll for AIFunction invocations (dotnet#6250)

We try to use ConfigureAwait(false) throughout our libraries. However, we exempt ourselves from that in cases where user code is expected to be called back from within the async code, and there's a reasonable presumption that such code might care about the synchronization context. AIFunction fits that bill. And FunctionInvokingChatClient needs to invoke such functions, which means that we need to be able to successfully flow the context from where user code calls Get{Streaming}ResponseAsync through into wherever a FunctionInvokingChatClient is in the middleware pipeline. We could try to selectively avoid ConfigureAwait(false) on the path through middleware that could result in calls to FICC.Get{Streaming}ResponseAsync, but that's fairly brittle and hard to maintain. Instead, this PR just removes ConfigureAwait use from the M.E.AI library. It also fixes a few places where tasks were explicitly being created and queued to the thread pool.
…t execution

Avoid displaying tags that are only present on previous runs since clicking on them filters out all the tests in the view. Tags from older runs also mess up the global tags display (since tags that are global to the latest execution are not considered global anymore unless they are all also present on older runs).

Also includes fixes for some minor issues I noticed:
* Avoid displaying the pointer (hand) cursor when hovering over controls that are not interactive (such as the global tags list and the section that displays historical trends for non-leaf nodes).
* Make styling for some buttons more consistent.
@joperezr joperezr requested review from a team as code owners April 8, 2025 21:06
@joperezr
Copy link
Member Author

joperezr commented Apr 8, 2025

This PR should be merged, not squashed.

@joperezr joperezr merged commit 398f7f6 into dotnet:release/9.4 Apr 8, 2025
6 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators May 9, 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.

8 participants