How to set up "Limit responses to your data content" on python api?

Dairton Lopes Martins Filho 0 Reputation points
2023-08-02T02:49:56.31+00:00
I am trying to make the model to respond using my data only, in the playground it works fine, but when I use the python API the model ignores it.



I used the following code to no avail:

messages= [
    {"role": "system", "content": "Assistant use only the data in Azure Cognitive Search result"},
    {"role": "user", "content": "Quais são as pessoas envolvidas no procedimento de curatela?"}
]


response = openai.ChatCompletion.create(
    engine=deployment_name,
    messages=messages,
)

Can someone help me? 
Thanks!
Azure OpenAI Service
Azure OpenAI Service
An Azure service that provides access to OpenAI’s GPT-3 models with enterprise capabilities.
1,893 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Ramr-msft 17,521 Reputation points
    2023-08-17T07:05:36.4+00:00

    Thanks for the details, Can you check your have contributor access or you can use the following repo chat on your data + search Chat on your docs using Azure Search + OpenAI solution accelerator.

    0 comments No comments