DistributedCachingChatClient.ReadCacheStreamingAsync Método
Definición
Importante
Parte de la información hace referencia a la versión preliminar del producto, que puede haberse modificado sustancialmente antes de lanzar la versión definitiva. Microsoft no otorga ninguna garantía, explícita o implícita, con respecto a la información proporcionada aquí.
Devuelve una lista previamente almacenada en caché de ChatResponseUpdate valores, si está disponible. Esto se usa cuando hay una llamada a GetStreamingResponseAsync(IEnumerable<ChatMessage>, ChatOptions, CancellationToken).
protected:
override System::Threading::Tasks::Task<System::Collections::Generic::IReadOnlyList<Microsoft::Extensions::AI::ChatResponseUpdate ^> ^> ^ ReadCacheStreamingAsync(System::String ^ key, System::Threading::CancellationToken cancellationToken);
protected override System.Threading.Tasks.Task<System.Collections.Generic.IReadOnlyList<Microsoft.Extensions.AI.ChatResponseUpdate>?> ReadCacheStreamingAsync(string key, System.Threading.CancellationToken cancellationToken);
override this.ReadCacheStreamingAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.Collections.Generic.IReadOnlyList<Microsoft.Extensions.AI.ChatResponseUpdate>>
Protected Overrides Function ReadCacheStreamingAsync (key As String, cancellationToken As CancellationToken) As Task(Of IReadOnlyList(Of ChatResponseUpdate))
Parámetros
- key
- String
Clave de caché.
- cancellationToken
- CancellationToken
que CancellationToken se va a supervisar para las solicitudes de cancelación.
Devoluciones
Los datos almacenados en caché anteriormente, si están disponibles, de lo contrario null, .