Update digestor.py
Browse files- digestor.py +1 -2
digestor.py
CHANGED
|
@@ -41,7 +41,7 @@ class Digestor:
|
|
| 41 |
]) = None
|
| 42 |
|
| 43 |
# Summarization params:
|
| 44 |
-
token_limit: int =
|
| 45 |
word_limit: int = 400
|
| 46 |
SUMMARIZATION_PARAMETERS = {
|
| 47 |
"do_sample": False,
|
|
@@ -88,7 +88,6 @@ class Digestor:
|
|
| 88 |
# Start chunk timer
|
| 89 |
with Timer(name=f"{stub.hed}_chunk_time", logger=None):
|
| 90 |
chunk_list = self.chunk_piece(text, self.word_limit, stub.source.source_summarization_checkpoint)
|
| 91 |
-
print(f"""\n\n=============\nchunkList: {len(chunk_list)}\n===========================\n\n""")
|
| 92 |
# start totoal summarization timer. Summarization queries are timed in 'perform_summarzation()'
|
| 93 |
with Timer(name=f"{stub.hed}_summary_time", text="Whole article summarization time: {:.4f} seconds"):
|
| 94 |
summary = self.perform_summarization(
|
|
|
|
| 41 |
]) = None
|
| 42 |
|
| 43 |
# Summarization params:
|
| 44 |
+
token_limit: int = 512
|
| 45 |
word_limit: int = 400
|
| 46 |
SUMMARIZATION_PARAMETERS = {
|
| 47 |
"do_sample": False,
|
|
|
|
| 88 |
# Start chunk timer
|
| 89 |
with Timer(name=f"{stub.hed}_chunk_time", logger=None):
|
| 90 |
chunk_list = self.chunk_piece(text, self.word_limit, stub.source.source_summarization_checkpoint)
|
|
|
|
| 91 |
# start totoal summarization timer. Summarization queries are timed in 'perform_summarzation()'
|
| 92 |
with Timer(name=f"{stub.hed}_summary_time", text="Whole article summarization time: {:.4f} seconds"):
|
| 93 |
summary = self.perform_summarization(
|