mirror of
https://github.com/microsoft/agent-framework.git
synced 2026-06-16 21:04:09 +08:00
.Net: Add Structured output ChatClientAgent samples (#250)
* WIP * Structured Output sample * Update dotnet/samples/GettingStarted/Steps/Step06_ChatClientAgent_StructuredOutputs.cs Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Address xml and comment targeting the Structured Output context * Update with proposed fix for Persistent ChatClient * Address PR feedback --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Co-authored-by: Chris <66376200+crickman@users.noreply.github.com>
This commit is contained in:
co-authored by
Copilot
Chris
parent
caee8bfa90
commit
139f033b05
+2
@@ -879,7 +879,9 @@ public class ChatClientAgentThreadTests
|
||||
public void VerifyJsonDeserialization_HandlesMalformedJson()
|
||||
{
|
||||
// Arrange - Invalid JSON structure
|
||||
#pragma warning disable JSON001 // Invalid JSON pattern
|
||||
string invalidJson = "{ invalid json";
|
||||
#pragma warning restore JSON001 // Invalid JSON pattern
|
||||
|
||||
// Act & Assert
|
||||
Assert.Throws<JsonException>(() => JsonSerializer.Deserialize<ChatClientAgentThread>(invalidJson));
|
||||
|
||||
Reference in New Issue
Block a user