Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Temporarily override 'W' format check in deserialization #171

Merged
merged 1 commit into from
Aug 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/Generated/Models/Assistant.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,7 @@ internal static Assistant DeserializeAssistant(JsonElement element, ModelReaderW
responseFormat = AssistantResponseFormat.DeserializeAssistantResponseFormat(property.Value, options);
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ internal static AssistantChatMessage DeserializeAssistantChatMessage(JsonElement
DeserializeContentValue(property, ref content);
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,7 @@ internal static AssistantCreationOptions DeserializeAssistantCreationOptions(Jso
responseFormat = AssistantResponseFormat.DeserializeAssistantResponseFormat(property.Value, options);
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,7 @@ internal static AssistantModificationOptions DeserializeAssistantModificationOpt
responseFormat = AssistantResponseFormat.DeserializeAssistantResponseFormat(property.Value, options);
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
2 changes: 1 addition & 1 deletion src/Generated/Models/AssistantThread.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ internal static AssistantThread DeserializeAssistantThread(JsonElement element,
metadata = dictionary;
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
2 changes: 1 addition & 1 deletion src/Generated/Models/AudioTranscription.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ internal static AudioTranscription DeserializeAudioTranscription(JsonElement ele
segments = array;
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ internal static AudioTranscriptionOptions DeserializeAudioTranscriptionOptions(J
timestampGranularities = array;
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
2 changes: 1 addition & 1 deletion src/Generated/Models/AudioTranslation.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ internal static AudioTranslation DeserializeAudioTranslation(JsonElement element
segments = array;
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ internal static AudioTranslationOptions DeserializeAudioTranslationOptions(JsonE
temperature = property.Value.GetSingle();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
2 changes: 1 addition & 1 deletion src/Generated/Models/ChatCompletion.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ internal static ChatCompletion DeserializeChatCompletion(JsonElement element, Mo
usage = ChatTokenUsage.DeserializeChatTokenUsage(property.Value, options);
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -509,7 +509,7 @@ internal static ChatCompletionOptions DeserializeChatCompletionOptions(JsonEleme
functions = array;
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
2 changes: 1 addition & 1 deletion src/Generated/Models/ChatFunction.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ internal static ChatFunction DeserializeChatFunction(JsonElement element, ModelR
parameters = BinaryData.FromString(property.Value.GetRawText());
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
2 changes: 1 addition & 1 deletion src/Generated/Models/ChatFunctionCall.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ internal static ChatFunctionCall DeserializeChatFunctionCall(JsonElement element
name = property.Value.GetString();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
2 changes: 1 addition & 1 deletion src/Generated/Models/ChatResponseFormat.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ internal static ChatResponseFormat DeserializeChatResponseFormat(JsonElement ele
type = new InternalCreateChatCompletionRequestResponseFormatType(property.Value.GetString());
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ internal static ChatTokenLogProbabilityInfo DeserializeChatTokenLogProbabilityIn
topLogprobs = array;
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ internal static ChatTokenTopLogProbabilityInfo DeserializeChatTokenTopLogProbabi
bytes = array;
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
2 changes: 1 addition & 1 deletion src/Generated/Models/ChatTokenUsage.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ internal static ChatTokenUsage DeserializeChatTokenUsage(JsonElement element, Mo
totalTokens = property.Value.GetInt32();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
2 changes: 1 addition & 1 deletion src/Generated/Models/ChatTool.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ internal static ChatTool DeserializeChatTool(JsonElement element, ModelReaderWri
function = InternalFunctionDefinition.DeserializeInternalFunctionDefinition(property.Value, options);
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
2 changes: 1 addition & 1 deletion src/Generated/Models/ChatToolCall.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ internal static ChatToolCall DeserializeChatToolCall(JsonElement element, ModelR
function = InternalChatCompletionMessageToolCallFunction.DeserializeInternalChatCompletionMessageToolCallFunction(property.Value, options);
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ internal static CodeInterpreterToolDefinition DeserializeCodeInterpreterToolDefi
type = property.Value.GetString();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ internal static CodeInterpreterToolResources DeserializeCodeInterpreterToolResou
fileIds = array;
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
2 changes: 1 addition & 1 deletion src/Generated/Models/Embedding.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ internal static Embedding DeserializeEmbedding(JsonElement element, ModelReaderW
@object = new InternalEmbeddingObject(property.Value.GetString());
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ internal static EmbeddingGenerationOptions DeserializeEmbeddingGenerationOptions
user = property.Value.GetString();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ internal static EmbeddingTokenUsage DeserializeEmbeddingTokenUsage(JsonElement e
totalTokens = property.Value.GetInt32();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ internal static FileSearchToolDefinition DeserializeFileSearchToolDefinition(Jso
type = property.Value.GetString();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ internal static FileSearchToolResources DeserializeFileSearchToolResources(JsonE
vectorStores = array;
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ internal static FunctionToolDefinition DeserializeFunctionToolDefinition(JsonEle
type = property.Value.GetString();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
2 changes: 1 addition & 1 deletion src/Generated/Models/GeneratedImage.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ internal static GeneratedImage DeserializeGeneratedImage(JsonElement element, Mo
revisedPrompt = property.Value.GetString();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
2 changes: 1 addition & 1 deletion src/Generated/Models/ImageEditOptions.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ internal static ImageEditOptions DeserializeImageEditOptions(JsonElement element
user = property.Value.GetString();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ internal static ImageGenerationOptions DeserializeImageGenerationOptions(JsonEle
user = property.Value.GetString();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ internal static ImageVariationOptions DeserializeImageVariationOptions(JsonEleme
user = property.Value.GetString();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ internal static InternalAssistantToolsFileSearchFileSearch DeserializeInternalAs
maxNumResults = property.Value.GetInt32();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ internal static InternalAssistantToolsFileSearchTypeOnly DeserializeInternalAssi
type = new InternalAssistantToolsFileSearchTypeOnlyType(property.Value.GetString());
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ internal static InternalAssistantsApiResponseFormat DeserializeInternalAssistant
type = new InternalAssistantsApiResponseFormatType(property.Value.GetString());
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ internal static InternalAssistantsNamedToolChoiceFunction DeserializeInternalAss
name = property.Value.GetString();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ internal static InternalAutoChunkingStrategy DeserializeInternalAutoChunkingStra
type = property.Value.GetString();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ internal static InternalAutoChunkingStrategyRequestParam DeserializeInternalAuto
type = property.Value.GetString();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
2 changes: 1 addition & 1 deletion src/Generated/Models/InternalBatchError.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ internal static InternalBatchError DeserializeInternalBatchError(JsonElement ele
line = property.Value.GetInt32();
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ internal static InternalBatchErrors DeserializeInternalBatchErrors(JsonElement e
data = array;
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
2 changes: 1 addition & 1 deletion src/Generated/Models/InternalBatchJob.Serialization.cs
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@ internal static InternalBatchJob DeserializeInternalBatchJob(JsonElement element
metadata = dictionary;
continue;
}
if (options.Format != "W")
if (true)
{
rawDataDictionary ??= new Dictionary<string, BinaryData>();
rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText()));
Expand Down
Loading
Loading