Skip to content

Commit 2d3b8f3

Browse files
committed
updating tools
1 parent f3af948 commit 2d3b8f3

File tree

5 files changed

+37
-12
lines changed

5 files changed

+37
-12
lines changed

articles/ai-foundry/agents/how-to/tools/bing-custom-search-samples.md

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ zone_pivot_groups: selection-bing-custom-grounding
1616

1717
# How to use Grounding with Bing Custom Search (preview)
1818

19+
Use this article to find step-by-step instructions and code samples for using the Grounding with Bing Custom Search tool in the Azure AI Foundry Agent Service.
1920

2021
::: zone pivot="portal"
2122

@@ -38,6 +39,20 @@ zone_pivot_groups: selection-bing-custom-grounding
3839

3940
::: zone pivot="python"
4041

42+
## Prerequisites
43+
44+
* Your Azure AI Foundry Project endpoint.
45+
46+
[!INCLUDE [endpoint-string-portal](../../includes/endpoint-string-portal.md)]
47+
48+
Save this endpoint to an environment variable named `PROJECT_ENDPOINT`.
49+
50+
* The name of your Grounding with Bing Search resource name. You can find it in the Azure AI Foundry portal by selecting **Management center** from the left navigation menu. Then selecting **Connected resources**.
51+
52+
:::image type="content" source="../../media/tools/deep-research/bing-resource-name.png" alt-text="A screenshot showing the Grounding with Bing Search resource name. " lightbox="../../media/tools/deep-research/bing-resource-name.png":::
53+
54+
Save this resource name to an environment variable named `BING_CUSTOM_CONNECTION_NAME`.
55+
4156
## Create a project client
4257

4358
Create a client object, which will contain the connection string for connecting to your AI project and other resources.
@@ -55,15 +70,15 @@ project_endpoint = os.environ["PROJECT_ENDPOINT"] # Ensure the PROJECT_ENDPOINT
5570

5671
# Create an AIProjectClient instance
5772
project_client = AIProjectClient(
58-
endpoint=os.environ["PROJECT_ENDPOINT"],
73+
endpoint=project_endpoint,
5974
credential=DefaultAzureCredential(),
6075
)
6176
```
6277

6378

6479
## Create an Agent with the Grounding with Bing Custom Search tool enabled
6580

66-
To make the Grounding with Bing Custom Search tool available to your agent, use a connection to initialize the tool and attach it to the agent. You can find your connection in the **connected resources** section of your project in the [Azure AI Foundry portal](https://ai.azure.com/?cid=learnDocs).
81+
To make the Grounding with Bing Custom Search tool available to your agent, use a connection to initialize the tool and attach it to the agent.
6782

6883
```python
6984
bing_custom_connection = project_client.connections.get(connection_name=os.environ["BING_CUSTOM_CONNECTION_NAME"])

articles/ai-foundry/agents/how-to/tools/deep-research-samples.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,8 @@ Use this article to learn how to use the Deep Research tool with the Azure AI Pr
2929

3030
* Your Azure AI Foundry Project endpoint.
3131

32-
You can find your endpoint in the main project **overview** for your project in the [Azure AI Foundry portal](https://ai.azure.com/?cid=learnDocs), under **Endpoint and keys** > **Libraries** > **Azure AI Foundry**.
33-
34-
:::image type="content" source="../../media/quickstart/portal-endpoint-string.png" alt-text="A screenshot showing the endpoint in the Azure AI Foundry portal." lightbox="../../media/quickstart/portal-endpoint-string.png":::
32+
33+
[!INCLUDE [endpoint-string-portal](../../includes/endpoint-string-portal.md)]
3534

3635
Save this endpoint to an environment variable named `PROJECT_ENDPOINT`.
3736

articles/ai-foundry/agents/how-to/tools/sharepoint-samples.md

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,20 @@ Use this article to find step-by-step instructions and code samples for using th
2222

2323
:::zone pivot="python"
2424

25+
## Prerequisites
26+
27+
* Your Azure AI Foundry Project endpoint.
28+
29+
[!INCLUDE [endpoint-string-portal](../../includes/endpoint-string-portal.md)]
30+
31+
Save this endpoint to an environment variable named `PROJECT_ENDPOINT`.
32+
33+
34+
* The name of your SharePoint connection name. You can find it in the Azure AI Foundry portal by selecting **Management center** from the left navigation menu. Then selecting **Connected resources**.
35+
36+
:::image type="content" source="../../media/tools/sharepoint-connection.png" alt-text="A screenshot showing the SharePoint connection name. " lightbox="../../media/tools/sharepoint-connection.png":::
37+
38+
Save this endpoint to an environment variable named `SHAREPOINT_RESOURCE_NAME`
2539

2640
## Create a project client
2741

@@ -48,11 +62,8 @@ project_client = AIProjectClient(
4862
To make the Microsoft Fabric tool available to your agent, use a connection to initialize the tool and attach it to the agent. You can find your connection in the **connected resources** section of your project in the Azure AI Foundry portal.
4963

5064
```python
51-
# The Fabric connection id can be found in the Azure AI Foundry project as a property of the Fabric tool
52-
# Your connection id is in the format /subscriptions/<your-subscription-id>/resourceGroups/<your-resource-group>/providers/Microsoft.MachineLearningServices/workspaces/<your-project-name>/connections/<your-fabric-connection-name>
5365

54-
# Retrieve the Fabric connection ID from environment variables
55-
conn_id = os.environ["SHAREPOINT_CONNECTION_ID"] # Ensure the environment variable is set
66+
conn_id = project_client.connections.get(name=os.environ["SHAREPOINT_RESOURCE_NAME"]).id
5667

5768
# Initialize Sharepoint tool with connection id
5869
sharepoint = SharepointTool(connection_id=conn_id)

articles/ai-foundry/agents/includes/endpoint-string-portal.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,6 @@ ms.topic: include
77
ms.date: 12/11/2024
88
---
99

10-
> [!TIP]
11-
> You can find your endpoint in the **overview** for your project in the [Azure AI Foundry portal](https://ai.azure.com/?cid=learnDocs), under **Libraries** > **Azure AI Foundry**.
12-
> :::image type="content" source="../media/quickstart/portal-endpoint-string.png" alt-text="A screenshot showing the endpoint in the Azure AI Foundry portal." lightbox="../media/quickstart/portal-endpoint-string.png":::
10+
You can find your endpoint in the **overview** for your project in the [Azure AI Foundry portal](https://ai.azure.com/?cid=learnDocs), under **Libraries** > **Azure AI Foundry**.
11+
12+
:::image type="content" source="../media/quickstart/portal-endpoint-string.png" alt-text="A screenshot showing the endpoint in the Azure AI Foundry portal." lightbox="../media/quickstart/portal-endpoint-string.png":::
85.7 KB
Loading

0 commit comments

Comments
 (0)