Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -266,7 +266,7 @@ def load_audio_from_url(url, max_retries=3):
|
|
266 |
return 24000, np.zeros(int(24000)) # 1 second of silence at 24kHz
|
267 |
|
268 |
# Split text into chunks for streaming
|
269 |
-
def split_into_chunks(text, max_length=
|
270 |
"""Split text into smaller chunks based on punctuation and length"""
|
271 |
# First split by sentences
|
272 |
sentence_markers = ['.', '?', '!', ';', ':', '।', '॥']
|
|
|
266 |
return 24000, np.zeros(int(24000)) # 1 second of silence at 24kHz
|
267 |
|
268 |
# Split text into chunks for streaming
|
269 |
+
def split_into_chunks(text, max_length=3000):
|
270 |
"""Split text into smaller chunks based on punctuation and length"""
|
271 |
# First split by sentences
|
272 |
sentence_markers = ['.', '?', '!', ';', ':', '।', '॥']
|