Skip to content

Port "QnAMaker GenerateAnswer filters need to support OR operation" #1392

@stevengum

Description

@stevengum

PR

microsoft/botbuilder-dotnet#4446

Issue

Description copied from microsoft/botbuilder-dotnet#4454

Is your feature request related to a problem? Please describe.
QnAMaker GenerateAnswer Filters do not support "OR" operation for Join. They currently support AND operation.
QnAMaker GenerateAnswer API has been enhanced to provide choice to user for join condition. User can choose the Compound Operation for joining strictfilters a.k.a metadata. The values for the Compound Operation Type are 'AND' and 'OR'. The default behaviour is 'AND', to support backward compatibility.

Describe the solution you'd like
QnAMaker API has introduced support for "OR" operation. The feature needs to be implemented in SDKs.

Example: {
"question":"what is metadata",
"istest": false,
"top": 3,
"strictFilters": [
{
"name": "country",
"value": "in"
},
{
"name": "country",
"value": "us"
}],
"strictFiltersCompoundOperationType": "OR"
}

Response Body:
{
"answers": [
{
"questions": [
"what is metadata"
],
"answer": "It is interface to Azure Search filters",
"score": 100.0,
"id": 1,
"source": "Editorial",
"metadata": [
{
"name": "country",
"value": "in"
}
],
"context": {
"isContextOnly": false,
"prompts": []
}
}
]
}

Metadata

Metadata

Assignees

Labels

Area: AI-QnAMakerThe issue is related to QnA MakerP1Painful if we don't fix, won't block releasingSize: SThe issue is simple and well understood, it will take a day or less to complete

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions