ASG Models commited on
Commit
bb1a6ad
·
verified ·
1 Parent(s): d9ceaee

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -9
app.py CHANGED
@@ -146,17 +146,9 @@ def generate_audio_ai(text,name_model):
146
  for chunk in _inference_forward_stream(model,input_ids=inputs.input_ids,attention_mask=inputs.attention_mask,speaker_embeddings= speaker_embeddings,chunk_size=256):
147
  yield 16000,remove_noise_nr(chunk)#.cpu().numpy().squeeze()#.astype(np.int16).tobytes()
148
 
149
- # yield generate_audio(text_answer,name_model)
150
  def remove_extra_spaces(text):
151
- """
152
- Removes extra spaces between words in a string.
153
 
154
- Args:
155
- text: The string to process.
156
-
157
- Returns:
158
- The string with extra spaces removed.
159
- """
160
  return ' '.join(text.split())
161
 
162
  def query(text,API_URL):
 
146
  for chunk in _inference_forward_stream(model,input_ids=inputs.input_ids,attention_mask=inputs.attention_mask,speaker_embeddings= speaker_embeddings,chunk_size=256):
147
  yield 16000,remove_noise_nr(chunk)#.cpu().numpy().squeeze()#.astype(np.int16).tobytes()
148
 
149
+
150
  def remove_extra_spaces(text):
 
 
151
 
 
 
 
 
 
 
152
  return ' '.join(text.split())
153
 
154
  def query(text,API_URL):