How to set up "Limit responses to your data content" on json file?

N.SAITO 70 Reputation points
2023-07-10T05:52:15.84+00:00

I'm developing chatbot using Azure openAI gpt-35-turbo-16k.

I could use Azure cognitive search with Azure openAI using json file.

But I could not find how to set up "Limit responses to your data content" and on json file.

LimitResponsesOnPlayground

Could you teach me how to setup it on json file?

Azure OpenAI Service
Azure OpenAI Service
An Azure service that provides access to OpenAI’s GPT-3 models with enterprise capabilities.
4,092 questions
{count} votes

Accepted answer
  1. Mohamad Bahri 180 Reputation points
    2023-08-28T09:30:52.1266667+00:00

    Alright so from what I have searched, there isn't any native configuration that can solve this issue, regardless of whether you are using azure openai or openai itself.
    The best possible way that I found in order to limit the response is to either use a binary classifier (detect if a prompt is on-topic or off-topic) or to use a a similarity detector between whatever you are getting from the search results and the answer. I used a similarity detector that returns a score between 0 and 1 based on the similarity between the search results and the prompt, set up a threshold and if the search results fit the user prompt, the score will be high and it'll be on-topic.

    I really hope that they add some sort of configuration setup but I think it'll be challenging as it is very difficult to limit the model's response, and even in the playground the sometimes hallucinates.

    2 people found this answer helpful.

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.