Method GetResponseAsync
GetResponseAsync(IEnumerable<ChatMessage>, ChatOptions?, CancellationToken)
Implemented as GetStreamingResponseAsync(...).ToChatResponseAsync(ct), so the two
paths cannot diverge, plus one hoist: MEAI's aggregation lands an update's
AdditionalProperties on the aggregated assistant message, and spec section 6.6 puts
the turn record on the ChatResponse, so the two documented keys are copied up.
Nothing else differs between the two paths.
public Task<ChatResponse> GetResponseAsync(IEnumerable<ChatMessage> messages, ChatOptions? options = null, CancellationToken cancellationToken = default)
Parameters
messagesIEnumerable<ChatMessage>The conversation.
optionsChatOptionsThe per-call options. Never mutated.
cancellationTokenCancellationTokenCancels the turn. Never converted into another exception.
Returns
- Task<ChatResponse>
The aggregated response.