Skip to content

Commit d2e4731

Browse files
Remove OpenAI API call reference from chat_with_data_plugin.py file
1 parent 6189680 commit d2e4731

File tree

1 file changed

+0
-12
lines changed

1 file changed

+0
-12
lines changed

src/App/backend/plugins/chat_with_data_plugin.py

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import logging
22
from typing import Annotated
33

4-
import openai
54
from azure.ai.agents.models import (
65
Agent,
76
AzureAISearchQueryType,
@@ -223,17 +222,6 @@ async def get_answers_from_calltranscripts(
223222
logging.error(f"Error in get_answers_from_calltranscripts: {str(e)}")
224223
return "Error retrieving data from call transcripts"
225224

226-
def get_openai_client(self):
227-
token_provider = get_bearer_token_provider(
228-
get_azure_credential(config.MID_ID), "https://cognitiveservices.azure.com/.default"
229-
)
230-
openai_client = openai.AzureOpenAI(
231-
azure_endpoint=config.AZURE_OPENAI_ENDPOINT,
232-
azure_ad_token_provider=token_provider,
233-
api_version=config.AZURE_OPENAI_PREVIEW_API_VERSION,
234-
)
235-
return openai_client
236-
237225
def get_project_openai_client(self):
238226
project = AIProjectClient(
239227
endpoint=config.AI_PROJECT_ENDPOINT, credential=get_azure_credential(config.MID_ID)

0 commit comments

Comments
 (0)