QnAMaker.FillQnAEventAsync Metodo

Definizione

Riempie le proprietà degli eventi e le metriche per l'evento QnaMessage per i dati di telemetria. Queste proprietà vengono registrate quando viene chiamato il metodo GetAnswers QnA.

protected System.Threading.Tasks.Task<(System.Collections.Generic.Dictionary<string,string> Properties, System.Collections.Generic.Dictionary<string,double> Metrics)> FillQnAEventAsync (Microsoft.Bot.Builder.AI.QnA.QueryResult[] queryResults, Microsoft.Bot.Builder.ITurnContext turnContext, System.Collections.Generic.Dictionary<string,string> telemetryProperties = default, System.Collections.Generic.Dictionary<string,double> telemetryMetrics = default, System.Threading.CancellationToken cancellationToken = default);
member this.FillQnAEventAsync : Microsoft.Bot.Builder.AI.QnA.QueryResult[] * Microsoft.Bot.Builder.ITurnContext * System.Collections.Generic.Dictionary<string, string> * System.Collections.Generic.Dictionary<string, double> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<ValueTuple<System.Collections.Generic.Dictionary<string, string>, System.Collections.Generic.Dictionary<string, double>>>
Protected Function FillQnAEventAsync (queryResults As QueryResult(), turnContext As ITurnContext, Optional telemetryProperties As Dictionary(Of String, String) = Nothing, Optional telemetryMetrics As Dictionary(Of String, Double) = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of ValueTuple(Of Dictionary(Of String, String), Dictionary(Of String, Double)))

Parametri

queryResults
QueryResult[]

Risultati del servizio QnA.

turnContext
ITurnContext

Oggetto context contenente informazioni per un singolo turno di conversazione con un utente.

telemetryProperties
Dictionary<String,String>

Proprietà da aggiungere/eseguire l'override per l'evento.

telemetryMetrics
Dictionary<String,Double>

Metriche da aggiungere/eseguire l'override per l'evento.

cancellationToken
CancellationToken

Token di annullamento utilizzabile da altri oggetti o thread per ricevere l'avviso dell'annullamento.

Restituisce

Tupla di Proprietà e metriche che verranno inviate al metodo IBotTelemetryClient.TrackEvent per l'evento QnAMessage. Le proprietà e le metriche hanno restituito le proprietà standard registrate con le proprietà passate dal metodo GetAnswersAsync.

Si applica a