aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/test_chunking.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/test_chunking.py b/tests/test_chunking.py
index 659a771..d1d95bd 100644
--- a/tests/test_chunking.py
+++ b/tests/test_chunking.py
@@ -2,9 +2,19 @@
import unittest
+from converter import config
from converter.chunking import split_into_chunks
+class ChunkSizeDefaultTests(unittest.TestCase):
+ """Guard the default chunk size: each API call is one model generation,
+ and long single generations lose prosody, can turn garbled, and are
+ truncated at the model's token limit (text past it is never spoken)."""
+
+ def test_default_chunk_size_within_single_generation_budget(self):
+ self.assertLessEqual(config.CHUNK_SIZE_WORDS, 60)
+
+
class SplitIntoChunksTests(unittest.TestCase):
def test_empty_input(self):
self.assertEqual(split_into_chunks(""), [])