diff --git a/setup.py b/setup.py index 5d9a0af..2bd1447 100644 --- a/setup.py +++ b/setup.py @@ -2,14 +2,14 @@ from setuptools import find_packages setup(name='bert-extractive-summarizer', - version='0.10.0', + version='0.10.1', description='Extractive Text Summarization with BERT', keywords=['bert', 'pytorch', 'machine learning', 'deep learning', 'extractive summarization', 'summary'], long_description=open("README.md", "r", encoding='utf-8').read(), long_description_content_type="text/markdown", url='https://github.com/dmmiller612/bert-extractive-summarizer', - download_url='https://github.com/dmmiller612/bert-extractive-summarizer/archive/0.10.0.tar.gz', + download_url='https://github.com/dmmiller612/bert-extractive-summarizer/archive/0.10.1.tar.gz', author='Derek Miller', author_email='dmmiller612@gmail.com', install_requires=['transformers', 'scikit-learn', 'spacy'], diff --git a/tests/test_summary_items.py b/tests/test_summary_items.py index 869e850..d4628dc 100644 --- a/tests/test_summary_items.py +++ b/tests/test_summary_items.py @@ -56,6 +56,11 @@ def passage(): ''' +def test_space_in_sentences(summarizer, passage): + result = summarizer(passage, num_sentences=3) + assert result == 'The Chrysler Building, the famous art deco New York skyscraper, will be sold for a small fraction of its previous sales price. Mubadala, an Abu Dhabi investment fund, purchased 90% of the building for $800 million in 2008. He kept secret the plans for the spire that would grace the top of the building, building it inside the structure and out of view of the public until 40 Wall Street was complete.' + + def test_transformer_summarizer(transformer_summarizer, passage): result = transformer_summarizer(passage, num_sentences=2, return_as_list=True) assert len(result) == 2