Update main.py
Browse files
main.py
CHANGED
@@ -67,7 +67,7 @@ def transcribe(audio_path):
|
|
67 |
def transcribe_audio():
|
68 |
# Record the time when the request was received
|
69 |
request_received_time, _ = get_time()
|
70 |
-
print(f"
|
71 |
|
72 |
if 'audio' not in request.files:
|
73 |
print("Error: No audio file provided", flush=True)
|
@@ -107,7 +107,8 @@ def transcribe_audio():
|
|
107 |
|
108 |
# Return the transcription, detected language, and timing information
|
109 |
#print(f" Transcription: {transcription}, Language: {language}, Processing Time: {transcription_duration}\n", flush=True)
|
110 |
-
print(f" \033[92mTranscription: {transcription}, Language: {language},
|
|
|
111 |
return jsonify({
|
112 |
"transcription": transcription,
|
113 |
"language": language,
|
|
|
67 |
def transcribe_audio():
|
68 |
# Record the time when the request was received
|
69 |
request_received_time, _ = get_time()
|
70 |
+
print(f"Query {request_received_time}", flush=True)
|
71 |
|
72 |
if 'audio' not in request.files:
|
73 |
print("Error: No audio file provided", flush=True)
|
|
|
107 |
|
108 |
# Return the transcription, detected language, and timing information
|
109 |
#print(f" Transcription: {transcription}, Language: {language}, Processing Time: {transcription_duration}\n", flush=True)
|
110 |
+
print(f" \033[92mTranscription: {transcription}, Language: {language}, Processing Time: {transcription_duration}\033[0m\n", flush=True)
|
111 |
+
|
112 |
return jsonify({
|
113 |
"transcription": transcription,
|
114 |
"language": language,
|