Skip to content

Commit af839a9

Browse files
committed
additions
1 parent aef25ff commit af839a9

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

src/backend/sql_agents_start.py

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,6 @@
6666
# Add the handler to the logger
6767
logger.addHandler(ch)
6868

69-
# DEPLOYMENT_NAME = os.environ["AZURE_OPENAI_CHAT_DEPLOYMENT_NAME"]
70-
7169
# configure agents
7270
agent_dialect_config = create_config(sql_dialect_in="informix", sql_dialect_out="tsql")
7371

@@ -304,7 +302,7 @@ async def convert(
304302
semver_response or ""
305303
)
306304

307-
# Fake a problematic response for testing
305+
# Fake a problematic response for testing warning condition
308306
# semver_response = SemanticVerifierResponse(
309307
# analysis="",
310308
# judgement="",
@@ -450,10 +448,18 @@ async def process_batch_async(batch_id: str):
450448
logger.error("Error updating batch status.{}".format(exc))
451449
# raise exc
452450

451+
# Add client and auto cleanup
452+
# async with (
453+
# DefaultAzureCredential() as creds,
454+
# AzureAIAgent.create_client(credential=creds) as client,
455+
# ):
456+
453457
# setup agents once per batch
454458
agent_config = await configure_agents()
455459

456460
# Walk through each file name and retrieve it from blob storage
461+
# Send file to the agents for processing
462+
# Send status update to the client of type in progress, completed, or failed
457463
for file in batch_files:
458464
# Get the file from blob storage
459465
try:

0 commit comments

Comments
 (0)