|
| 1 | +--- |
| 2 | +title: 'How to use Agents with your licensed data' |
| 3 | +titleSuffix: Azure AI services |
| 4 | +description: Learn how to connect your licensed data for grounding with Azure AI Agent Service. |
| 5 | +services: cognitive-services |
| 6 | +manager: nitinme |
| 7 | +ms.service: azure |
| 8 | +ms.topic: how-to |
| 9 | +ms.date: 03/04/2025 |
| 10 | +author: aahill |
| 11 | +ms.author: aahi |
| 12 | +recommendations: false |
| 13 | +--- |
| 14 | + |
| 15 | +# Bring your licensed data |
| 16 | + |
| 17 | +Azure AI Agent Service integrates your own licensed data from specialized data providers, |
| 18 | +such as Tripadvisor. This integration enhances the quality of your agent's responses with high-quality, fresh data, |
| 19 | +such as travel guidance and reviews. These insights empower your agents to deliver nuanced, informed |
| 20 | +solutions tailored to specific use cases. |
| 21 | + |
| 22 | +Tripadvisor is the first licensed data provider and you can ground with your licensed Tripadvisor data through the API, SDK, and Azure AI Foundry portal. |
| 23 | + |
| 24 | +> [!IMPORTANT] |
| 25 | +> - Your use of connected non-Microsoft services is subject to the terms between you and the service provider. By connecting to a non-Microsoft service, you acknowledge that some of your data, such as prompt content, is passed to the non-Microsoft service, and/or your application might receive data from the non-Microsoft service. You're responsible for your use of non-Microsoft data. |
| 26 | +> - Grounding with licensed data incurs usage with licensed data providers, review the pricing plan with your selected licensed data providers. |
| 27 | +
|
| 28 | +## Prerequisites |
| 29 | + |
| 30 | +* Obtain an API key for your [Tripadvisor developer account](https://www.tripadvisor.com/developers?screen=credentials). |
| 31 | + |
| 32 | +## Setup |
| 33 | +1. Go to [Azure AI Foundry portal](https://ai.azure.com/) and select your AI Project. Select **Management Center**. |
| 34 | + |
| 35 | + :::image type="content" source="../../media/tools/licensed-data/project-assets.png" alt-text="A screenshot showing the selectors for the management center for an AI project." lightbox="../../media/tools/licensed-data/project-assets.png"::: |
| 36 | + |
| 37 | +1. Select **+new connection** in the settings page. |
| 38 | + |
| 39 | + :::image type="content" source="../../media/tools/licensed-data/connected-resources.png" alt-text="A screenshot showing the connections for the selected AI project." lightbox="../../media/tools/licensed-data/connected-resources.png"::: |
| 40 | + |
| 41 | +1. Select **custom keys** in **other resource types**. |
| 42 | + |
| 43 | + :::image type="content" source="../../media/tools/licensed-data/custom-keys.png" alt-text="A screenshot showing the custom key option in the settings page." lightbox="../../media/tools/licensed-data/custom-keys.png"::: |
| 44 | + |
| 45 | +1. Enter the following information to create a connection to store your Tripadvisor key: |
| 46 | + 1. Set **Custom keys** to "key", with the value being your Tripadvisor API key. |
| 47 | + 1. Make sure **is secret** is checked. |
| 48 | + 1. Set the connection name to your connection name. You use this connection name in your sample code or Foundry Portal later. |
| 49 | + 1. For the **Access** setting, you can choose either *this project only* or *shared to all projects*. Just make sure in your code, the connection string of the project you entered has access to this connection. |
| 50 | + |
| 51 | + :::image type="content" source="../../media/tools/licensed-data/connect-custom-resource.png" alt-text="A screenshot showing the screen for adding Tripadvisor connection information." lightbox="../../media/tools/licensed-data/connect-custom-resource.png"::: |
| 52 | + |
| 53 | +## Use Tripadvisor tool through Foundry portal |
| 54 | + |
| 55 | +1. To use the Tripadvisor tool in the Azure AI Foundry, in the **Create and debug** screen for your agent, scroll down the **Setup** pane on the right to **action**. Then select **Add**. |
| 56 | + |
| 57 | + :::image type="content" source="../../media/tools/knowledge-tools.png" alt-text="A screenshot showing the available tool categories in the Azure AI Foundry portal." lightbox="../../media/tools/knowledge-tools.png"::: |
| 58 | + |
| 59 | +1. Select **Tripadvisor** and follow the prompts to add the tool. |
| 60 | + |
| 61 | + :::image type="content" source="../../media/tools/knowledge-tools-list.png" alt-text="A screenshot showing available knowledge tools." lightbox="../../media/tools/knowledge-tools-list.png"::: |
| 62 | + |
| 63 | +1. Give a name for your Tripadvisor tool and provide an optional description. |
| 64 | + |
| 65 | + :::image type="content" source="../../media/tools/licensed-data/add-data-source.png" alt-text="A screenshot showing the Tripadvisor data source." lightbox="../../media/tools/licensed-data/add-data-source.png"::: |
| 66 | + |
| 67 | +1. Select the custom key connection you just created. |
| 68 | + |
| 69 | + :::image type="content" source="../../media/tools/licensed-data/add-connection.png" alt-text="A screenshot showing the connection for your Tripadvisor tool, and a JSON example." lightbox="../../media/tools/licensed-data/add-connection.png"::: |
| 70 | + |
| 71 | +1. Finish and start chatting. |
| 72 | + |
| 73 | +## Connect Tripadvisor through code-first experience |
| 74 | + |
| 75 | +You can follow the instructions in [OpenAPI Spec tool](./openapi-spec.md) to connect Tripadvisor through OpenAPI spec. |
| 76 | + |
| 77 | +1. Remember to store and import Tripadvisor OpenAPI spec. You can find it through Foundry Portal. |
| 78 | + |
| 79 | +1. Make sure you have updated the authentication method to be `connection` and fill in the connection ID of your custom key connection. |
| 80 | + ``` python |
| 81 | + auth = OpenApiConnectionAuthDetails(security_scheme=OpenApiConnectionSecurityScheme(connection_id="your_connection_id")) |
| 82 | + ``` |
0 commit comments