|
| 1 | +--- |
| 2 | +title: Migrate QnA Maker to Azure OpenAI on your data |
| 3 | +titleSuffix: Azure AI services |
| 4 | +description: Learn how to migrate your QnA Maker projects to Azure OpenAI. |
| 5 | +ms.service: cognitive-services |
| 6 | +ms.subservice: language-service |
| 7 | +author: aahill |
| 8 | +ms.author: aahi |
| 9 | +ms.topic: how-to |
| 10 | +ms.date: 09/08/2023 |
| 11 | +--- |
| 12 | + |
| 13 | +# Migrate QnA Maker to Azure OpenAI on your data |
| 14 | + |
| 15 | +QnA Maker was designed to be a cloud-based Natural Language Processing (NLP) service that allowed users to create a natural conversational layer over their data. This service is being retired, having been replaced by [custom question answering](../../language-service/question-answering/overview.md). AI runtimes however, are evolving due to the development of Large Language Models (LLMs), such as GPT-35-Turbo and GPT-4 offered by [Azure OpenAI](../../openai/overview.md), which can address many chat-based use cases. Use this article to learn how to migrate your existing QnA Maker projects to Azure OpenAI. |
| 16 | + |
| 17 | + |
| 18 | +## Prerequisites |
| 19 | + |
| 20 | +* A QnA Maker project. |
| 21 | +* An existing Azure Open AI resource. If you don't already have an Azure Open AI resource, then [create one and deploy a model](../../openai/how-to/create-resource.md). |
| 22 | + * Azure OpenAI requires registration and is currently only available to approved enterprise customers and partners. See [Limited access to Azure OpenAI Service](/legal/cognitive-services/openai/limited-access?context=/azure/ai-services/openai/context/context) for more information. You can apply for access to Azure OpenAI by completing the form at https://aka.ms/oai/access. Open an issue on this repo to contact us if you have an issue. |
| 23 | + * Be sure that you are assigned at least the [Cognitive Services OpenAI Contributor role](/azure/role-based-access-control/built-in-roles#cognitive-services-openai-contributor) for the Azure OpenAI resource. |
| 24 | + |
| 25 | +## Migrate to Azure OpenAI |
| 26 | + |
| 27 | +1. Log into the [Azure portal](https://portal.azure.com/) and navigate to an existing QnA Maker project. Then select it to open the **Overview** section. |
| 28 | + |
| 29 | + :::image type="content" source="../media/openai/project-overview.png" alt-text="A screenshot showing a QnA Maker project in the Azure portal." lightbox="../media/openai/project-overview.png"::: |
| 30 | + |
| 31 | +1. Verify that the QnA Maker project you've selected is the one you want to migrate, including its Azure subscription and resource group. |
| 32 | + |
| 33 | +1. Go to the associated resource group and filter the resources by **search service** to find the associated Cognitive Search service. |
| 34 | + |
| 35 | + :::image type="content" source="../media/openai/search-service.png" alt-text="A screenshot showing a QnA Maker project's search service in the Azure portal." lightbox="../media/openai/search-service.png"::: |
| 36 | + |
| 37 | +1. Select the search service and open its **Overview** section. Note down the details, such as the Azure Search resource name, subscription, and location. You will need this information when you migrate to Azure Open AI. |
| 38 | + |
| 39 | + :::image type="content" source="../media/openai/search-service-details.png" alt-text="A screenshot showing a QnA Maker project's search service details in the Azure portal." lightbox="../media/openai/search-service-details.png"::: |
| 40 | + |
| 41 | +1. Navigate to the **Search management** > **Indexes** section on the left menu and note the index that you want to migrate to Azure OpenAI. |
| 42 | + |
| 43 | + :::image type="content" source="../media/openai/index-name.png" alt-text="A screenshot showing a search index name in the Azure portal." lightbox="../media/openai/index-name.png"::: |
| 44 | + |
| 45 | +1. Go to [Azure OpenAI Studio](https://oai.azure.com/) and select **Bring your own data**. |
| 46 | + |
| 47 | + :::image type="content" source="../media/openai/studio-homepage.png" alt-text="A screenshot showing the Azure OpenAI studio." lightbox="../media/openai/studio-homepage.png"::: |
| 48 | + |
| 49 | + You can also select **Chat playground** and then select **Add your data**. |
| 50 | + |
| 51 | + :::image type="content" source="../media/openai/chat-playground.png" alt-text="A screenshot showing the chat playground in Azure OPenAI studio." lightbox="../media/openai/chat-playground.png"::: |
| 52 | + |
| 53 | + |
| 54 | +1. In the pane that appears, select **Azure Cognitive Search** under **Select or add data source**. This will update the screen with **Data field mapping** options depending on your data source. Select the subscription, Azure Cognitive Search service and Azure Cognitive Search Index associated with your QnA maker project. Select the acknowledgment that connecting it will incur usage on your account. Then select **Next**. |
| 55 | + |
| 56 | + :::image type="content" source="../media/openai/azure-search-data-source.png" alt-text="A screenshot showing the data source selections in Azure OpenAI Studio." lightbox="../media/openai/azure-search-data-source.png"::: |
| 57 | + |
| 58 | +1. On the **Index data field mapping** screen, select *answer* for **Content data** field. The other fields such as **File name**, **Title** and **URL** are optional depending on the nature of your data source. |
| 59 | + |
| 60 | + :::image type="content" source="../media/openai/data-field-mapping.png" alt-text="A screenshot showing index field mapping information for Azure Cognitive Search in Azure OpenAI Studio." lightbox="../media/openai/data-field-mapping.png"::: |
| 61 | + |
| 62 | +1. Select **Next**. Select a search type from the dropdown menu. You can choose **Keyword** or **Semantic**. semantic” search requires an existing semantic search configuration, which may or may not be available for your project. |
| 63 | + |
| 64 | + :::image type="content" source="../media/openai/data-management.png" alt-text="A screenshot showing the data management options for Azure Cognitive Search indexes." lightbox="../media/openai/data-management.png"::: |
| 65 | + |
| 66 | +1. Review the information you provided, and select **Save and close**. |
| 67 | + |
| 68 | + :::image type="content" source="../media/openai/confirm-details.png" alt-text="A screenshot showing the confirmation screen." lightbox="../media/openai/confirm-details.png"::: |
| 69 | + |
| 70 | +1. Your data source has now been added. Select your model's deployment name under the **Configuration** > **Deployment** tab on the menu to the right. |
| 71 | + |
| 72 | + :::image type="content" source="../media/openai/chat-playground-after-deployment.png" alt-text="A screenshot of the playground page of the Azure OpenAI Studio with sections highlighted." lightbox="../media/openai/chat-playground-after-deployment.png"::: |
| 73 | + |
| 74 | +You can now start exploring Azure OpenAI capabilities with a no-code approach through the chat playground. It's simply a text box where you can submit a prompt to generate a completion. From this page, you can quickly iterate and experiment with the capabilities. You can also launch a [web app](../../openai/concepts/use-your-data.md#using-the-web-app) to chat with the model over the web. |
| 75 | + |
| 76 | +## Next steps |
| 77 | +* [Using Azure OpenAI on your data](../../openai/concepts/use-your-data.md) |
0 commit comments