Skip to content

Commit 3073f73

Browse files
authored
Merge pull request #34 from BoHomola/master
fixing ResponseFormat serialization
2 parents e62998e + 190872b commit 3073f73

File tree

3 files changed

+2
-1
lines changed

3 files changed

+2
-1
lines changed

LlmTornado/Assistants/Assistant.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@ public long CreatedAt
9191
/// Compatible with GPT-4, GPT-4 Turbo, and all GPT-3.5 Turbo models since `gpt-3.5-turbo-1106`.
9292
/// </summary>
9393
[JsonProperty("response_format")]
94+
[JsonConverter(typeof(ResponseFormatConverter))]
9495
public ResponseFormat? ResponseFormat { get; set; }
9596

9697
/// <summary>

LlmTornado/Assistants/ResponseFormat.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ namespace LlmTornado.Assistants;
99
/// Specifies the format that the model must output.
1010
/// Compatible with GPT-4o, GPT-4 Turbo, and all GPT-3.5 Turbo models since gpt-3.5-turbo-1106.
1111
/// </summary>
12-
[JsonConverter(typeof(ResponseFormatConverter))]
1312
public abstract class ResponseFormat
1413
{
1514
}

LlmTornado/Threads/TornadoRun.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -221,5 +221,6 @@ public DateTime? CompletedAt
221221
/// Specifies the format that the model must output.
222222
/// </summary>
223223
[JsonProperty("response_format")]
224+
[JsonConverter(typeof(ResponseFormatConverter))]
224225
public ResponseFormat ResponseFormat { get; set; } = null!;
225226
}

0 commit comments

Comments
 (0)