Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -63,7 +63,7 @@ def api_calling(audio_file, prompt, api_key):
|
|
63 |
}
|
64 |
response = requests.post("https://api.openai.com/v1/chat/completions", headers=headers, json=payload)
|
65 |
audio_text_res = response.json()
|
66 |
-
return audio_text_res
|
67 |
|
68 |
|
69 |
|
|
|
63 |
}
|
64 |
response = requests.post("https://api.openai.com/v1/chat/completions", headers=headers, json=payload)
|
65 |
audio_text_res = response.json()
|
66 |
+
return audio_text_res["choices"][0]["message"]["content"]
|
67 |
|
68 |
|
69 |
|