Skip to content

Commit ba1184c

Browse files
authored
[OpenAI] Suppress null warnings (#24120)
* [OpenAI] Suppress null warnings * move suppress lines
1 parent ae9d07f commit ba1184c

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

specification/cognitiveservices/OpenAI.Inference/models/chat.completions.tsp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,7 @@ model ChatChoice {
156156
@projectedName("json", "index")
157157
index: int32;
158158

159+
#suppress "@azure-tools/typespec-azure-core/no-nullable" "The operation already returns nulls"
159160
@doc("The reason that this chat completions choice completed its generated.")
160161
@projectedName("json", "finish_reason")
161162
finishReason: CompletionsFinishReason | null;

specification/cognitiveservices/OpenAI.Inference/models/completions.create.tsp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -186,11 +186,13 @@ model Choice {
186186
@projectedName("json", "index")
187187
index: int32;
188188

189+
#suppress "@azure-tools/typespec-azure-core/no-nullable" "The operation already returns nulls"
189190
@doc("The log probabilities model for tokens associated with this completions choice.")
190191
@projectedName("json", "logprobs")
191192
@projectedName("csharp", "LogProbabilityModel")
192193
logprobs: CompletionsLogProbabilityModel | null;
193194

195+
#suppress "@azure-tools/typespec-azure-core/no-nullable" "The operation already returns nulls"
194196
@doc("Reason for finishing")
195197
@projectedName("json", "finish_reason")
196198
finishReason: CompletionsFinishReason | null;

0 commit comments

Comments
 (0)