Skip to content

Commit 48a6926

Browse files
committed
Merge branch 'macae-v3-dev-v2-vip' into macae-v3-fr-dev-92
2 parents ce02065 + 89c33d7 commit 48a6926

File tree

3 files changed

+22
-21
lines changed

3 files changed

+22
-21
lines changed

infra/main.bicep

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1525,7 +1525,7 @@ module containerApp 'br/public:avm/res/app/container-app:0.18.1' = {
15251525
}
15261526
{
15271527
name: 'AZURE_AI_SEARCH_CONNECTION_NAME'
1528-
value: searchService.outputs.name
1528+
value: aiSearchConnectionName
15291529
}
15301530
{
15311531
name: 'AZURE_AI_SEARCH_INDEX_NAME'
@@ -2041,7 +2041,7 @@ output COSMOSDB_ACCOUNT_NAME string = cosmosDbResourceName
20412041
output AZURE_SEARCH_ENDPOINT string =searchService.outputs.endpoint
20422042
output AZURE_CLIENT_ID string = userAssignedIdentity!.outputs.clientId
20432043
output AZURE_TENANT_ID string = tenant().tenantId
2044-
output AZURE_AI_SEARCH_CONNECTION_NAME string = searchService.outputs.name
2044+
output AZURE_AI_SEARCH_CONNECTION_NAME string = aiSearchConnectionName
20452045
output AZURE_COGNITIVE_SERVICES string = 'https://cognitiveservices.azure.com/.default'
20462046
output REASONING_MODEL_NAME string = aiFoundryAiServicesReasoningModelDeployment.name
20472047
output MCP_SERVER_NAME string = 'MACAE MCP Server'

infra/main_custom.bicep

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1556,7 +1556,7 @@ module containerApp 'br/public:avm/res/app/container-app:0.18.1' = {
15561556
}
15571557
{
15581558
name: 'AZURE_AI_SEARCH_CONNECTION_NAME'
1559-
value: searchService.outputs.name
1559+
value: aiSearchConnectionName
15601560
}
15611561
{
15621562
name: 'AZURE_AI_SEARCH_INDEX_NAME'
@@ -2096,7 +2096,7 @@ output COSMOSDB_ACCOUNT_NAME string = cosmosDbResourceName
20962096
output AZURE_SEARCH_ENDPOINT string =searchService.outputs.endpoint
20972097
output AZURE_CLIENT_ID string = userAssignedIdentity!.outputs.clientId
20982098
output AZURE_TENANT_ID string = tenant().tenantId
2099-
output AZURE_AI_SEARCH_CONNECTION_NAME string = searchService.outputs.name
2099+
output AZURE_AI_SEARCH_CONNECTION_NAME string = aiSearchConnectionName
21002100
output AZURE_COGNITIVE_SERVICES string = 'https://cognitiveservices.azure.com/.default'
21012101
output REASONING_MODEL_NAME string = aiFoundryAiServicesReasoningModelDeployment.name
21022102
output MCP_SERVER_NAME string = 'MACAE MCP Server'

infra/scripts/index_datasets.py

Lines changed: 18 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -48,23 +48,24 @@
4848
sys.exit(1)
4949

5050
for idx, blob in enumerate(blob_list, start=1):
51-
if blob.name.endswith(".csv"):
52-
title = blob.name.replace(".csv", "")
53-
csv_data = container_client.download_blob(blob.name).readall()
54-
55-
try:
56-
print(f"Reading data from blob: {blob.name}...")
57-
csv_text = csv_data.decode('utf-8')
58-
data_list.append({
59-
"content": csv_text,
60-
"id": str(idx),
61-
"title": title
62-
})
63-
success_count += 1
64-
except Exception as e:
65-
print(f"Error reading CSV file - {blob.name}: {e}")
66-
fail_count += 1
67-
continue
51+
#if blob.name.endswith(".csv"):
52+
title = blob.name.replace(".csv", "")
53+
title = blob.name.replace(".json", "")
54+
data = container_client.download_blob(blob.name).readall()
55+
56+
try:
57+
print(f"Reading data from blob: {blob.name}...")
58+
text = data.decode('utf-8')
59+
data_list.append({
60+
"content": text,
61+
"id": str(idx),
62+
"title": title
63+
})
64+
success_count += 1
65+
except Exception as e:
66+
print(f"Error reading file - {blob.name}: {e}")
67+
fail_count += 1
68+
continue
6869

6970
if not data_list:
7071
print(f"No data to upload to Azure Search index. Success: {success_count}, Failed: {fail_count}")

0 commit comments

Comments
 (0)