How to call azure openai API on own data with python?

Parth Bhavsar 20 Reputation points

i want to call the azure openai API from python and get the chat working on my own data which is fetched from the index from the cognitive search of azure

problem is i am able to get the expected answer on the webapp generated from the openai console but not getting the same response in the API call from python or REST call

Azure Cognitive Search
Azure Cognitive Search
An Azure search service with built-in artificial intelligence capabilities that enrich information to help identify and explore relevant content at scale.
387 questions
Azure OpenAI Service
Azure OpenAI Service
An Azure service that provides access to OpenAI’s GPT-3 models with enterprise capabilities.
989 questions
{count} votes

Accepted answer
  1. ajkuma 17,441 Reputation points Microsoft Employee

    @Parth Bhavsar ,

    Following-up, just to clarify, are receiving an error response or is it just the quality of the result isn't as good?


    A good reference is the Python code that generates the HTTP request for the webapp:   - You may compare that with your code to understand any discrepancy.

    1 person found this answer helpful.
    0 comments No comments

0 additional answers

Sort by: Most helpful