DistributedCachingChatClient.WriteCacheStreamingAsync Método
Definição
Importante
Algumas informações se referem a produtos de pré-lançamento que podem ser substancialmente modificados antes do lançamento. A Microsoft não oferece garantias, expressas ou implícitas, das informações aqui fornecidas.
Armazena uma lista de ChatResponseUpdate valores no cache subjacente. Isso é usado quando há uma chamada para GetStreamingResponseAsync(IEnumerable<ChatMessage>, ChatOptions, CancellationToken).
protected:
override System::Threading::Tasks::Task ^ WriteCacheStreamingAsync(System::String ^ key, System::Collections::Generic::IReadOnlyList<Microsoft::Extensions::AI::ChatResponseUpdate ^> ^ value, System::Threading::CancellationToken cancellationToken);
protected override System.Threading.Tasks.Task WriteCacheStreamingAsync(string key, System.Collections.Generic.IReadOnlyList<Microsoft.Extensions.AI.ChatResponseUpdate> value, System.Threading.CancellationToken cancellationToken);
override this.WriteCacheStreamingAsync : string * System.Collections.Generic.IReadOnlyList<Microsoft.Extensions.AI.ChatResponseUpdate> * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Protected Overrides Function WriteCacheStreamingAsync (key As String, value As IReadOnlyList(Of ChatResponseUpdate), cancellationToken As CancellationToken) As Task
Parâmetros
- key
- String
A chave de cache.
- value
- IReadOnlyList<ChatResponseUpdate>
O ChatResponse a ser armazenado.
- cancellationToken
- CancellationToken
O CancellationToken para monitorar solicitações de cancelamento.
Retornos
Um Task que representa a conclusão da operação.