MicrosoftExtensionsAIChatExtensions.AsOpenAIChatCompletion Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Creates an OpenAI ChatCompletion from a ChatResponse.
public:
[System::Runtime::CompilerServices::Extension]
static OpenAI::Chat::ChatCompletion ^ AsOpenAIChatCompletion(Microsoft::Extensions::AI::ChatResponse ^ response);
public static OpenAI.Chat.ChatCompletion AsOpenAIChatCompletion(this Microsoft.Extensions.AI.ChatResponse response);
static member AsOpenAIChatCompletion : Microsoft.Extensions.AI.ChatResponse -> OpenAI.Chat.ChatCompletion
<Extension()>
Public Function AsOpenAIChatCompletion (response As ChatResponse) As ChatCompletion
Parameters
- response
- ChatResponse
The ChatResponse to convert to a ChatCompletion.
Returns
A converted ChatCompletion.
Exceptions
response is null.