File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed
articles/ai-services/agents/includes/azure-search Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -69,7 +69,7 @@ Get the connection ID of the Azure AI Search connection in the project. You can
69
69
conn_list = project_client.connections.list()
70
70
conn_id = " "
71
71
for conn in conn_list:
72
- if conn.connection_type == " CognitiveSearch " :
72
+ if conn.connection_type == " AZURE_AI_SEARCH " :
73
73
print (f " Connection ID: { conn.id} " )
74
74
```
75
75
# [ C#] ( #tab/csharp )
@@ -97,8 +97,7 @@ conn_id = "/subscriptions/<your-subscription-id>/resourceGroups/<your-resource-
97
97
98
98
# Initialize agent AI search tool and add the search index connection ID and index name
99
99
# TO DO: replace <your-index-name> with the name of the index you want to use
100
- ai_search = AzureAISearchTool()
101
- ai_search.add_index(conn_id, " <your-index-name>" )
100
+ ai_search = AzureAISearchTool(index_connection_id = conn_id, index_name = " <your-index-name>" )
102
101
```
103
102
# [ C#] ( #tab/csharp )
104
103
``` csharp
You can’t perform that action at this time.
0 commit comments