ThreadAbort commited on
Commit
148f2de
1 Parent(s): ca02c10

A little more toxic, a little more conversation!

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -85,7 +85,7 @@ E2TTS_ema_model, E2TTS_base_model = load_model("E2TTS_Base", UNetT, E2TTS_model_
85
  @spaces.GPU
86
  def infer(ref_audio_orig, ref_text, gen_text, exp_name, remove_silence, progress = gr.Progress()):
87
  print(gen_text)
88
- if model.predict(gen_text)['toxicity'] > 0.8:
89
  print("Flagged for toxicity:", gen_text)
90
  raise gr.Error("Your text was flagged for toxicity, please try again with a different text.")
91
  gr.Info("Converting audio...")
 
85
  @spaces.GPU
86
  def infer(ref_audio_orig, ref_text, gen_text, exp_name, remove_silence, progress = gr.Progress()):
87
  print(gen_text)
88
+ if model.predict(gen_text)['toxicity'] > 0.2:
89
  print("Flagged for toxicity:", gen_text)
90
  raise gr.Error("Your text was flagged for toxicity, please try again with a different text.")
91
  gr.Info("Converting audio...")