QnAMakerDialog Constructors
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.
Overloads
| QnAMakerDialog(String, Int32) |
Initializes a new instance of the QnAMakerDialog class. The JSON serializer uses this constructor to deserialize objects of this class. |
| QnAMakerDialog(String, String, String, Activity, Single, String, String, Int32, Activity, Metadata[], Filters, ServiceType, HttpClient, String, Int32, Boolean) |
Initializes a new instance of the QnAMakerDialog class. |
| QnAMakerDialog(String, String, String, String, Activity, Single, String, String, Int32, Activity, Metadata[], Filters, ServiceType, HttpClient, String, Int32, Boolean) |
Initializes a new instance of the QnAMakerDialog class. |
QnAMakerDialog(String, Int32)
Initializes a new instance of the QnAMakerDialog class. The JSON serializer uses this constructor to deserialize objects of this class.
public QnAMakerDialog(string sourceFilePath = "", int sourceLineNumber = 0);
new Microsoft.Bot.Builder.AI.QnA.Dialogs.QnAMakerDialog : string * int -> Microsoft.Bot.Builder.AI.QnA.Dialogs.QnAMakerDialog
Public Sub New (Optional sourceFilePath As String = "", Optional sourceLineNumber As Integer = 0)
Parameters
- sourceFilePath
- String
The source file path, for debugging. Defaults to the full path of the source file that contains the caller.
- sourceLineNumber
- Int32
The line number, for debugging. Defaults to the line number in the source file at which the method is called.
Applies to
QnAMakerDialog(String, String, String, Activity, Single, String, String, Int32, Activity, Metadata[], Filters, ServiceType, HttpClient, String, Int32, Boolean)
Initializes a new instance of the QnAMakerDialog class.
public QnAMakerDialog(string knowledgeBaseId, string endpointKey, string hostName, Microsoft.Bot.Schema.Activity noAnswer = default, float threshold = 0.3, string activeLearningCardTitle = "Did you mean:", string cardNoMatchText = "None of the above.", int top = 3, Microsoft.Bot.Schema.Activity cardNoMatchResponse = default, Microsoft.Bot.Builder.AI.QnA.Metadata[] strictFilters = default, Microsoft.Bot.Builder.AI.QnA.Models.Filters filters = default, Microsoft.Bot.Builder.AI.QnA.Models.ServiceType qnAServiceType = Microsoft.Bot.Builder.AI.QnA.Models.ServiceType.QnAMaker, System.Net.Http.HttpClient httpClient = default, string sourceFilePath = "", int sourceLineNumber = 0, bool useTeamsAdaptiveCard = false);
new Microsoft.Bot.Builder.AI.QnA.Dialogs.QnAMakerDialog : string * string * string * Microsoft.Bot.Schema.Activity * single * string * string * int * Microsoft.Bot.Schema.Activity * Microsoft.Bot.Builder.AI.QnA.Metadata[] * Microsoft.Bot.Builder.AI.QnA.Models.Filters * Microsoft.Bot.Builder.AI.QnA.Models.ServiceType * System.Net.Http.HttpClient * string * int * bool -> Microsoft.Bot.Builder.AI.QnA.Dialogs.QnAMakerDialog
Public Sub New (knowledgeBaseId As String, endpointKey As String, hostName As String, Optional noAnswer As Activity = Nothing, Optional threshold As Single = 0.3, Optional activeLearningCardTitle As String = "Did you mean:", Optional cardNoMatchText As String = "None of the above.", Optional top As Integer = 3, Optional cardNoMatchResponse As Activity = Nothing, Optional strictFilters As Metadata() = Nothing, Optional filters As Filters = Nothing, Optional qnAServiceType As ServiceType = Microsoft.Bot.Builder.AI.QnA.Models.ServiceType.QnAMaker, Optional httpClient As HttpClient = Nothing, Optional sourceFilePath As String = "", Optional sourceLineNumber As Integer = 0, Optional useTeamsAdaptiveCard As Boolean = false)
Parameters
- knowledgeBaseId
- String
The ID of the QnA Maker knowledge base to query.
- endpointKey
- String
The QnA Maker endpoint key to use to query the knowledge base.
- hostName
- String
The QnA Maker host URL for the knowledge base, starting with "https://" and ending with "/qnamaker".
- noAnswer
- Activity
The activity to send the user when QnA Maker does not find an answer.
- threshold
- Single
The threshold for answers returned, based on score.
- activeLearningCardTitle
- String
The card title to use when showing active learning options to the user, if active learning is enabled.
- cardNoMatchText
- String
The button text to use with active learning options, allowing a user to indicate none of the options are applicable.
- top
- Int32
The maximum number of answers to return from the knowledge base.
- cardNoMatchResponse
- Activity
The activity to send the user if they select the no match option on an active learning card.
- strictFilters
- Metadata[]
QnA Maker metadata with which to filter or boost queries to the knowledge base; or null to apply none.
- filters
- Filters
Assigns Filters to filter QnAs based on given metadata list and knowledge base sources.
- qnAServiceType
- ServiceType
Valid value Language for Language Service, QnAMaker for QnAMaker.
- httpClient
- HttpClient
An HTTP client to use for requests to the QnA Maker Service;
or null to use a default client.
- sourceFilePath
- String
The source file path, for debugging. Defaults to the full path of the source file that contains the caller.
- sourceLineNumber
- Int32
The line number, for debugging. Defaults to the line number in the source file at which the method is called.
- useTeamsAdaptiveCard
- Boolean
Boolean value to determine whether an Adaptive card formatted for Teams should be used for responses.
Applies to
QnAMakerDialog(String, String, String, String, Activity, Single, String, String, Int32, Activity, Metadata[], Filters, ServiceType, HttpClient, String, Int32, Boolean)
Initializes a new instance of the QnAMakerDialog class.
public QnAMakerDialog(string dialogId, string knowledgeBaseId, string endpointKey, string hostName, Microsoft.Bot.Schema.Activity noAnswer = default, float threshold = 0.3, string activeLearningCardTitle = "Did you mean:", string cardNoMatchText = "None of the above.", int top = 3, Microsoft.Bot.Schema.Activity cardNoMatchResponse = default, Microsoft.Bot.Builder.AI.QnA.Metadata[] strictFilters = default, Microsoft.Bot.Builder.AI.QnA.Models.Filters filters = default, Microsoft.Bot.Builder.AI.QnA.Models.ServiceType qnAServiceType = Microsoft.Bot.Builder.AI.QnA.Models.ServiceType.QnAMaker, System.Net.Http.HttpClient httpClient = default, string sourceFilePath = "", int sourceLineNumber = 0, bool useTeamsAdaptiveCard = false);
new Microsoft.Bot.Builder.AI.QnA.Dialogs.QnAMakerDialog : string * string * string * string * Microsoft.Bot.Schema.Activity * single * string * string * int * Microsoft.Bot.Schema.Activity * Microsoft.Bot.Builder.AI.QnA.Metadata[] * Microsoft.Bot.Builder.AI.QnA.Models.Filters * Microsoft.Bot.Builder.AI.QnA.Models.ServiceType * System.Net.Http.HttpClient * string * int * bool -> Microsoft.Bot.Builder.AI.QnA.Dialogs.QnAMakerDialog
Public Sub New (dialogId As String, knowledgeBaseId As String, endpointKey As String, hostName As String, Optional noAnswer As Activity = Nothing, Optional threshold As Single = 0.3, Optional activeLearningCardTitle As String = "Did you mean:", Optional cardNoMatchText As String = "None of the above.", Optional top As Integer = 3, Optional cardNoMatchResponse As Activity = Nothing, Optional strictFilters As Metadata() = Nothing, Optional filters As Filters = Nothing, Optional qnAServiceType As ServiceType = Microsoft.Bot.Builder.AI.QnA.Models.ServiceType.QnAMaker, Optional httpClient As HttpClient = Nothing, Optional sourceFilePath As String = "", Optional sourceLineNumber As Integer = 0, Optional useTeamsAdaptiveCard As Boolean = false)
Parameters
- knowledgeBaseId
- String
The ID of the QnA Maker knowledge base to query.
- endpointKey
- String
The QnA Maker endpoint key to use to query the knowledge base.
- hostName
- String
The QnA Maker host URL for the knowledge base, starting with "https://" and ending with "/qnamaker".
- noAnswer
- Activity
The activity to send the user when QnA Maker does not find an answer.
- threshold
- Single
The threshold for answers returned, based on score.
- activeLearningCardTitle
- String
The card title to use when showing active learning options to the user, if active learning is enabled.
- cardNoMatchText
- String
The button text to use with active learning options, allowing a user to indicate none of the options are applicable.
- top
- Int32
The maximum number of answers to return from the knowledge base.
- cardNoMatchResponse
- Activity
The activity to send the user if they select the no match option on an active learning card.
- strictFilters
- Metadata[]
QnA Maker Metadata with which to filter or boost queries to the knowledge base; or null to apply none.
- filters
- Filters
Assigns Filters to filter QnAs based on given metadata list and knowledge base sources.
- qnAServiceType
- ServiceType
Valid value Language for Language Service, QnAMaker for QnAMaker.
- httpClient
- HttpClient
An HTTP client to use for requests to the QnA Maker Service;
or null to use a default client.
- sourceFilePath
- String
The source file path, for debugging. Defaults to the full path of the source file that contains the caller.
- sourceLineNumber
- Int32
The line number, for debugging. Defaults to the line number in the source file at which the method is called.
- useTeamsAdaptiveCard
- Boolean
Boolean value to determine whether an Adaptive card formatted for Teams should be used for responses.