skillfed

sumy

Module for automatic summarization of text documents and HTML pages.

sumy v0.13.0 173.5K downloads/30d#10,305 on PyPI3,701
Permissive license Apache License, Version 2.0 Active released

What it is and what it does

Sumy is a Python library for automatic text summarization that works with both HTML pages and plain text. It implements multiple summarization algorithms—LSA, LexRank, Luhn, and Edmundson—allowing you to choose the approach that fits your use case. The package includes a command-line tool for quick summarization tasks and an evaluation framework to measure summary quality against reference texts.

The library handles multilingual content and provides tokenizers for language-specific processing. It depends on nltk for natural language processing, lxml-html-clean for HTML parsing, requests for fetching web content, and breadability for content extraction. You can use it as a library in your Python code or invoke it from the command line, making it flexible for both programmatic and ad-hoc summarization tasks.

Use it for:

  • Summarize web articles or Wikipedia pages to extract key information without manual reading.
  • Build a bot that automatically generates TL;DR summaries for forum discussions or social media posts.
  • Reduce large document collections to key sentences for quick review or archival purposes.
  • Evaluate the quality of generated summaries against reference texts using built-in evaluation methods.
  • Integrate multilingual summarization into applications serving non-English-speaking users.
  • Extract summaries from video transcripts or meeting notes by parsing plain text output.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Sumy extracts summaries from HTML pages or plain text using multiple automatic summarization algorithms (LSA, LexRank, Luhn, Edmundson) and provides evaluation tools for summary quality.

Yes. Sumy is actively maintained, has no known vulnerabilities, low install friction, and a permissive Apache License, Version 2.0. It offers multiple summarization algorithms and multilingual support, making it suitable for both simple summarization tasks and more complex NLP pipelines. The recent release and strong GitHub presence indicate ongoing development and community use.

Install

sumy on PyPI

pip

pip install sumy

uv

uv add sumy

poetry

poetry add sumy

Installing sumy

Before you install

Low friction install with 7 runtime dependencies including nltk, lxml-html-clean, and requests. Package is actively maintained with a recent release 2 days ago and 3701 GitHub stars. Supports Python 3.8 through 3.14.

License in practice

Licensed under Apache License, Version 2.0 (permissive), allowing commercial and private use with minimal restrictions beyond attribution and liability disclaimers.

Quickstart

pip install sumy

from sumy.parsers.html import HtmlParser
from sumy.nlp.tokenizers import Tokenizer
from sumy.summarizers.lsa import LsaSummarizer
from sumy.utils import get_stop_words

parser = HtmlParser.from_url("https://example.com", Tokenizer("english"))
summarizer = LsaSummarizer()
summarizer.stop_words = get_stop_words("english")
for sentence in summarizer(parser.document, 10):
    print(sentence)

Requires Python 3.8+; nltk and lxml-html-clean are compiled/system-dependent dependencies that may need additional setup on some platforms.

Verify before relying

  • Whether all listed natural languages are fully supported or require additional tokenizer configuration.
  • Performance characteristics and memory usage for large documents or batch processing.
  • Accuracy or ROUGE scores for the implemented summarization algorithms relative to alternatives.

Package facts

License Apache License, Version 2.0 (permissive)
Python support supports the current Python release (>=3.8)
Install friction low — pure-Python wheel
Runtime dependencies 7 — breadability, docopt-ng, lxml-html-clean, nltk, pycountry, requests, setuptools
Maintenance actively maintained — 2 days since the last release
Last repo commit
First released
Downloads 173,532/month — #10,305 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: sumy-0.13.0-py3-none-any.whl

Keywords: LSA, LexRank, NLP, TextRank, automatic summarization, data mining, data reduction, latent semantic analysis, natural language processing, web-data extraction

Development Status :: 4 - BetaIntended Audience :: DevelopersIntended Audience :: EducationLicense :: OSI Approved :: Apache Software LicenseNatural Language :: ArabicNatural Language :: Chinese (Simplified)Natural Language :: CzechNatural Language :: EnglishNatural Language :: FrenchNatural Language :: GermanNatural Language :: GreekNatural Language :: HebrewNatural Language :: ItalianNatural Language :: JapaneseNatural Language :: PolishNatural Language :: PortugueseNatural Language :: SlovakNatural Language :: SpanishNatural Language :: SwedishNatural Language :: ThaiNatural Language :: UkrainianOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9Programming Language :: Python :: Implementation :: CPythonProgramming Language :: Python :: Implementation :: PyPyTopic :: EducationTopic :: InternetTopic :: Scientific/Engineering :: Information AnalysisTopic :: Text Processing :: FiltersTopic :: Text Processing :: LinguisticTopic :: Text Processing :: Markup :: HTML

Tags

automatic text summarizationextract summary from HTMLNLP text summarizerdocument summarization libraryLSA LexRank summarizermultilingual text summarizationcommand-line summarization tool
nlptext-summarizationmultilingual

More Internet packages