Spaces:
Running on Zero
Running on Zero
Update app.py
Browse filesJoin only really small sentences.
app.py
CHANGED
|
@@ -26,7 +26,7 @@ def split_to_parts(text):
|
|
| 26 |
index = 0
|
| 27 |
for s in text:
|
| 28 |
parts[index] += s
|
| 29 |
-
if s in split_symbols and len(parts[index]) >
|
| 30 |
index += 1
|
| 31 |
parts.append('')
|
| 32 |
return parts
|
|
|
|
| 26 |
index = 0
|
| 27 |
for s in text:
|
| 28 |
parts[index] += s
|
| 29 |
+
if s in split_symbols and len(parts[index]) > 20:
|
| 30 |
index += 1
|
| 31 |
parts.append('')
|
| 32 |
return parts
|