lcapriles commited on
Commit
4f47d72
·
verified ·
1 Parent(s): 34c1584
Files changed (1) hide show
  1. tools.py +4 -4
tools.py CHANGED
@@ -100,13 +100,13 @@ def ocr(base64_image: str) -> str:
100
  Returns: a string summary or description of what the image contains.
101
  """
102
  client = AzureOpenAI(
103
- azure_endpoint=os.environ.get("AZURE_OPENAI_ENDPOINT"),
104
- api_key=os.environ.get("AZURE_OPENAI_API_KEY"),
105
- api_version=os.environ.get("OPENAI_API_VERSION")
106
  )
107
 
108
  response = client.chat.completions.create(
109
- model=os.environ["AZURE_OPENAI_MODEL"],
110
  messages=[
111
  {"role": "user", "content": [
112
  {"type": "text", "text": "Describe the image"},
 
100
  Returns: a string summary or description of what the image contains.
101
  """
102
  client = AzureOpenAI(
103
+ azure_endpoint=os.environ.get("AZendpoint"),
104
+ api_version=os.environ.get("api_version"),
105
+ api_key=os.environ.get("api_key")
106
  )
107
 
108
  response = client.chat.completions.create(
109
+ model=os.environ["model"],
110
  messages=[
111
  {"role": "user", "content": [
112
  {"type": "text", "text": "Describe the image"},