This repository provides sample code and instructions on how to use Azure OpenAI Service, Azure Search Service, and Azure Speech Service together to perform natural language searches and question answering.
Before you begin, you must have the following:
- A Windows machine with WSL 2.0, Ubuntu 20.04, and VSCode installed, or a Linux machine with VSCode installed.
- Python 3.9 or above and relevant pip packages installed.
- An Azure account with an active subscription. If you don't have an account, you can create a free trial account.
- An instance of Azure OpenAI Service.
- An instance of Azure Search Service.
- An instance of Azure Speech Service.
To use this code, follow these steps:
-
Clone this repository to your local machine:
git clone https://github.com/alezhao/openai.git
-
Navigate to the
notebook
folder. -
Open the desired notebook in VSCode.
-
Replace the placeholder values in the notebook with your Azure service credentials e.g. <OPENAI_API_KEY>.
-
Run the notebook or python code, following the instructions provided in the comments.
This notebook provides an example of how to use Azure OpenAI Service and Azure Search Service together to perform natural language searches on a given query. It demonstrates how to use the OpenAI Service to process natural language queries, and Azure Search Service to perform the search and the summary against the query.
This notebook provides an example of how to use Azure OpenAI Service and Azure Speech Service together to perform question answering, including speech-to-text (STT) and text-to-speech (TTS). It demonstrates how to use the OpenAI Service to process natural language queries and generate responses, and Azure Speech Service to convert audio input to text and text output to audio.