Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -31,30 +31,14 @@ demo = gr.Interface(
|
|
| 31 |
title="Audio Transcription HNM",
|
| 32 |
description="Upload an audio file to transcribe it into text",
|
| 33 |
)
|
| 34 |
-
|
| 35 |
|
| 36 |
if __name__ == "__main__":
|
| 37 |
-
|
| 38 |
-
# Add the Groq badge
|
| 39 |
-
gr.HTML("""
|
| 40 |
-
<div id="groq-badge">
|
| 41 |
-
<div style="color: #f55036; font-weight: bold;">POWERED BY GROQ</div>
|
| 42 |
-
</div>
|
| 43 |
-
""")
|
| 44 |
-
|
| 45 |
-
submit_button.click(
|
| 46 |
-
process_audio,
|
| 47 |
-
inputs=[audio_input, api_key_input],
|
| 48 |
-
outputs=[transcription_output, response_output]
|
| 49 |
-
)
|
| 50 |
-
|
| 51 |
-
gr.Markdown("""
|
| 52 |
-
## How to use this app:
|
| 53 |
-
1. Enter your [Groq API Key](https://console.groq.com/keys) in the provided field.
|
| 54 |
-
2. Click on the upload section and provide a supported audio file. Supported audio files include mp3, mp4, mpeg, mpga, m4a, wav, and webm file types.
|
| 55 |
-
3. Click the "Process" button to transcribe your speech and generate a response from our AI assistant.
|
| 56 |
-
4. The transcription and AI assistant response will appear in the respective text boxes.
|
| 57 |
-
|
| 58 |
-
""")
|
| 59 |
-
|
| 60 |
demo.launch()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 31 |
title="Audio Transcription HNM",
|
| 32 |
description="Upload an audio file to transcribe it into text",
|
| 33 |
)
|
|
|
|
| 34 |
|
| 35 |
if __name__ == "__main__":
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 36 |
demo.launch()
|
| 37 |
+
|
| 38 |
+
"""
|
| 39 |
+
## How to use this app:
|
| 40 |
+
1. Enter your [Groq API Key](https://console.groq.com/keys) in the provided field.
|
| 41 |
+
2. Click on the upload section and provide a supported audio file. Supported audio files include mp3, mp4, mpeg, mpga, m4a, wav, and webm file types.
|
| 42 |
+
3. Click the "Process" button to transcribe your speech and generate a response from our AI assistant.
|
| 43 |
+
4. The transcription and AI assistant response will appear in the respective text boxes.
|
| 44 |
+
"""
|