Mendoza33 commited on
Commit
080b398
·
verified ·
1 Parent(s): 0f01a44

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -2,10 +2,11 @@ from transformers import pipeline
2
  import gradio as gr
3
 
4
  # Load pre-trained models
5
- stt_model = pipeline("automatic-speech-recognition", model="openai/whisper-base")
6
- nlp_model = pipeline("text-generation", model="gpt2")
7
  tts_model = pipeline("text-to-speech", model="tts-coqui/coqui-tts-en")
8
 
 
9
  # Define a function to handle the workflow
10
  def conversation(audio):
11
  # Step 1: Convert speech to text
 
2
  import gradio as gr
3
 
4
  # Load pre-trained models
5
+ stt_model = pipeline("automatic-speech-recognition", model="openai/whisper-tiny")
6
+ nlp_model = pipeline("text-generation", model="sshleifer/tiny-gpt2")
7
  tts_model = pipeline("text-to-speech", model="tts-coqui/coqui-tts-en")
8
 
9
+
10
  # Define a function to handle the workflow
11
  def conversation(audio):
12
  # Step 1: Convert speech to text