rouge-score
Pure python implementation of ROUGE-1.5.5.
What it is and what it does
rouge-score is a pure Python implementation of ROUGE, the automatic evaluation metric for text summarization. It replicates the original Perl ROUGE package's behavior, implementing ROUGE-N (n-gram overlap), ROUGE-L (longest common subsequence at sentence level), and ROUGE-Lsum (summary-level LCS with union computation). The package also supports optional Porter stemming and bootstrap resampling for confidence intervals, with text normalization built in.
The package is designed for researchers and practitioners who need to evaluate generated summaries against reference summaries. It can be used programmatically via RougeScorer or as a command-line tool to batch-score target and prediction files. No external dependencies are required at runtime, though the source distribution has high install friction.
Use it for:
- Evaluate machine-generated summaries in NLP research pipelines against gold-standard references.
- Benchmark summarization models during development and compare results with published papers.
- Batch-score large sets of predictions and targets from command line with CSV output.
- Compute ROUGE metrics with optional stemming to handle morphological variations in summary text.
- Calculate confidence intervals via bootstrap resampling to assess score stability.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Computes ROUGE scores (ROUGE-N, ROUGE-L, ROUGE-Lsum) to evaluate the quality of generated text summaries against reference summaries using n-gram overlap and longest common subsequence metrics.
Yes, with conditions. rouge-score is the standard pure-Python ROUGE implementation and is actively maintained with no known vulnerabilities. Install it if you need ROUGE metrics for summarization evaluation and can tolerate high install friction from source-only distribution. The gap since the last release in 2022 is a minor concern for stability but not a blocker given active repository maintenance. Suitable for research, benchmarking, and production evaluation pipelines.
Install
rouge-score on PyPI
pip
pip install rouge-scoreuv
uv add rouge-scorepoetry
poetry add rouge-scoreInstalling rouge-score
Before you install
High install friction: the package is distributed as a source tarball with no wheels, requiring compilation or build tools on installation. Maintenance is active with recent commits, but the latest release was in 2022.
License in practice
Licensed under Apache 2.0 (permissive), allowing commercial and private use with minimal restrictions. No notable licensing constraints for typical adoption.
Quickstart
pip install rouge-score
from rouge_score import rouge_scorer
scorer = rouge_scorer.RougeScorer(['rouge1', 'rougeL'], use_stemmer=True)
scores = scorer.score('The quick brown fox jumps over the lazy dog',
'The quick brown dog jumps on the log.')
Requires Python >= 3.7; high install friction due to source-only distribution (no wheels).
Verify before relying
- Whether the package's implementation continues to match the original perl ROUGE results given the time since last release.
- Performance characteristics when scoring large batches of summaries or very long texts.
- Whether bootstrap resampling for confidence intervals is documented with examples.
Package facts
| License | not declared (permissive) |
| Python support | supports the current Python release (>=3.7) |
| Install friction | high — source build required |
| Runtime dependencies | none |
| Maintenance | actively maintained — 1,484 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 3,486,792/month — #2,605 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: rouge_score-0.1.2.tar.gz
Tags
More Artificial Intelligence packages
LiteLLM provides a unified Python interface to…
permissive · top 100 on PyPI
huggingface-hubClient library and CLI tool for downloading,…
permissive · top 100 on PyPI
langchainLangChain provides a framework for building…
permissive · top 1,000 on PyPI
hf-xethf-xet provides chunk-based deduplication and…
permissive · top 1,000 on PyPI
tokenizersTokenizers converts raw text into token…
permissive · top 1,000 on PyPI
transformersTransformers provides a unified framework for…
permissive · top 1,000 on PyPI
rouge-metricComputes ROUGE metrics (ROUGE-N, ROUGE-L,…
permissive · top 15,000 on PyPI
rougeComputes ROUGE scores (Recall-Oriented…
unclear · top 5,000 on PyPI
rouge-chineseComputes ROUGE evaluation metrics for Chinese…
unclear · top 15,000 on PyPI
redlinesRedlines compares two strings or text documents…
permissive · top 15,000 on PyPI
pycocoevalcapEvaluates image captions using multiple…
unclear · top 5,000 on PyPI
bert-scoreBERTScore computes automatic evaluation metrics…
permissive · top 15,000 on PyPI
pylcsComputes longest common subsequence, longest…
permissive · top 15,000 on PyPI
rank-bm25Implements BM25 ranking algorithms (Okapi BM25,…
permissive · top 5,000 on PyPI
strsimpyImplements a dozen string similarity and…
permissive · top 15,000 on PyPI
DistanceComputes distance metrics (Levenshtein,…
copyleft · top 15,000 on PyPI