Kurian07 commited on
Commit
932389d
·
verified ·
1 Parent(s): 37224c9

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -0
app.py CHANGED
@@ -61,6 +61,15 @@ if uploaded_file is not None:
61
  st.subheader("Listen to the Speech")
62
  st.audio(temp_file_path, format="audio/mp3")
63
 
 
 
 
 
 
 
 
 
 
64
  # Clean up the temporary file after use
65
  os.remove(temp_file_path)
66
 
 
61
  st.subheader("Listen to the Speech")
62
  st.audio(temp_file_path, format="audio/mp3")
63
 
64
+ # Add download button
65
+ with open(temp_file_path, "rb") as audio_file:
66
+ st.download_button(
67
+ label="Download MP3",
68
+ data=audio_file,
69
+ file_name="output_audio.mp3",
70
+ mime="audio/mp3"
71
+ )
72
+
73
  # Clean up the temporary file after use
74
  os.remove(temp_file_path)
75