Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -20,11 +20,10 @@ def custom_sent_tokenize(text):
|
|
20 |
def transcribe(audio_path):
|
21 |
with open(audio_path, "rb") as audio_file:
|
22 |
audio_data = audio_file.read()
|
23 |
-
|
24 |
-
groq_api_endpoint = "https://api.groq.com/openai/v1/audio/transcriptions"
|
25 |
headers = {
|
26 |
"Authorization": "Bearer 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", # Replace with your actual API key
|
27 |
-
|
28 |
files = {
|
29 |
'file': ('audio.wav', audio_data, 'audio/wav'),
|
30 |
}
|
|
|
20 |
def transcribe(audio_path):
|
21 |
with open(audio_path, "rb") as audio_file:
|
22 |
audio_data = audio_file.read()
|
23 |
+
groq_api_endpoint = "https://api.groq.com/openai/v1/audio/transcriptions"
|
|
|
24 |
headers = {
|
25 |
"Authorization": "Bearer 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", # Replace with your actual API key
|
26 |
+
}
|
27 |
files = {
|
28 |
'file': ('audio.wav', audio_data, 'audio/wav'),
|
29 |
}
|