- Notifications
You must be signed in to change notification settings - Fork845
Use unsafe relaxed escaping inAIJsonUtilities.DefaultOptions.#5850
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
dotnet-comment-bot commentedFeb 6, 2025
🎉Good job! The coverage increased 🎉
Full code coverage report:https://dev.azure.com/dnceng-public/public/_build/results?buildId=943071&view=codecoverage-tab |
src/Libraries/Microsoft.Extensions.AI.Abstractions/Utilities/AIJsonUtilities.Defaults.cs OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
test/Libraries/Microsoft.Extensions.AI.Abstractions.Tests/Utilities/AIJsonUtilitiesTests.csShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
…IJsonUtilities.Defaults.cs
dotnet-comment-bot commentedFeb 6, 2025
🎉Good job! The coverage increased 🎉
Full code coverage report:https://dev.azure.com/dnceng-public/public/_build/results?buildId=943191&view=codecoverage-tab |
11ccd68 intodotnet:mainUh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
It is common for AI vendor APIs to embed JSON documents inside JSON strings, which results in quotes and most non-ASCII content being escaped and confusing consuming LLMs. This updates the default STJ options to use
JavaScriptEncoder.UnsafeRelaxedJsonEscaping.FYI@GrabYourPitchforks@SergeyMenshykh
Microsoft Reviewers:Open in CodeFlow