hexgrad commited on
Commit
480e1dc
β€’
1 Parent(s): 480b27e

Upload app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -6
app.py CHANGED
@@ -109,11 +109,10 @@ VOCAB = get_vocab()
109
  def tokenize(ps):
110
  return [i for i in map(VOCAB.get, ps) if i is not None]
111
 
112
- # πŸ§ͺ Experimental voices may be unstable.
113
- # βš”οΈ Arena voices are averages of other voices.
114
  CHOICES = {
115
- 'πŸ‡ΊπŸ‡Έ 🚺 American Female βš”οΈ': 'af',
116
- 'πŸ‡ΊπŸ‡Έ 🚺 American Female 0': 'af_0',
117
  'πŸ‡ΊπŸ‡Έ 🚺 Alloy πŸ§ͺ': 'af_alloy',
118
  'πŸ‡ΊπŸ‡Έ 🚺 Bella': 'af_bella',
119
  'πŸ‡ΊπŸ‡Έ 🚺 Jessica πŸ§ͺ': 'af_jessica',
@@ -223,7 +222,7 @@ with gr.Blocks() as basic_tts:
223
  with gr.Row():
224
  with gr.Column():
225
  text = gr.Textbox(label='Input Text')
226
- voice = gr.Dropdown(list(CHOICES.items()), label='Voice', info='πŸ§ͺ Experimental voices may be unstable. βš”οΈ Arena voices are averages of other voices.')
227
  with gr.Row():
228
  random_btn = gr.Button('Random Text', variant='secondary')
229
  generate_btn = gr.Button('Generate', variant='primary')
@@ -406,7 +405,7 @@ with gr.Blocks() as lf_tts:
406
  file_input = gr.File(file_types=['.pdf', '.txt'], label='Input File: pdf or txt')
407
  text = gr.Textbox(label='Input Text')
408
  file_input.upload(fn=extract_text, inputs=[file_input], outputs=[text])
409
- voice = gr.Dropdown(list(CHOICES.items()), label='Voice', info='πŸ§ͺ Experimental voices may be unstable. βš”οΈ Arena voices are averages of other voices.')
410
  with gr.Accordion('Text Settings', open=False):
411
  skip_square_brackets = gr.Checkbox(True, label='Skip [Square Brackets]', info='Recommended for academic papers, Wikipedia articles, or texts with citations.')
412
  newline_split = gr.Number(2, label='Newline Split', info='Split the input text on this many newlines. Affects how the text is segmented.', precision=0, minimum=0)
 
109
  def tokenize(ps):
110
  return [i for i in map(VOCAB.get, ps) if i is not None]
111
 
112
+ # ⭐ Starred voices are averages of similar voices. πŸ§ͺ Experimental voices may be unstable.
 
113
  CHOICES = {
114
+ 'πŸ‡ΊπŸ‡Έ 🚺 American Female ⭐': 'af',
115
+ 'πŸ‡ΊπŸ‡Έ 🚺 American Female 1': 'af_1',
116
  'πŸ‡ΊπŸ‡Έ 🚺 Alloy πŸ§ͺ': 'af_alloy',
117
  'πŸ‡ΊπŸ‡Έ 🚺 Bella': 'af_bella',
118
  'πŸ‡ΊπŸ‡Έ 🚺 Jessica πŸ§ͺ': 'af_jessica',
 
222
  with gr.Row():
223
  with gr.Column():
224
  text = gr.Textbox(label='Input Text')
225
+ voice = gr.Dropdown(list(CHOICES.items()), label='Voice', info='⭐ Starred voices are averages of similar voices. πŸ§ͺ Experimental voices may be unstable.')
226
  with gr.Row():
227
  random_btn = gr.Button('Random Text', variant='secondary')
228
  generate_btn = gr.Button('Generate', variant='primary')
 
405
  file_input = gr.File(file_types=['.pdf', '.txt'], label='Input File: pdf or txt')
406
  text = gr.Textbox(label='Input Text')
407
  file_input.upload(fn=extract_text, inputs=[file_input], outputs=[text])
408
+ voice = gr.Dropdown(list(CHOICES.items()), label='Voice', info='⭐ Starred voices are averages of similar voices. πŸ§ͺ Experimental voices may be unstable.')
409
  with gr.Accordion('Text Settings', open=False):
410
  skip_square_brackets = gr.Checkbox(True, label='Skip [Square Brackets]', info='Recommended for academic papers, Wikipedia articles, or texts with citations.')
411
  newline_split = gr.Number(2, label='Newline Split', info='Split the input text on this many newlines. Affects how the text is segmented.', precision=0, minimum=0)