Practical overview
When it fits
Use it when reference and generated summaries are available as two line-aligned files and you need ROUGE scores for their corresponding sequences.
Who it is for
- Researchers and developers evaluating generated text summaries against reference summaries.
- Developers adding file-based ROUGE scoring to a summarization evaluation script or command-line workflow.
Documented uses
- Calculate ROUGE-1, ROUGE-2 and ROUGE-L scores for paired reference and summary sequences.
- Save score output to a file or adjust ROUGE arguments and sentence boundaries.
- Call the scoring wrapper from a Python script.
Requirements & limits
The public repository declares an MIT license.
- Reference and summary files must have the same number of lines.
- For multi-sentence sequences, choose the correct
--eosdelimiter; the README warns that a wrong delimiter may produce an incorrect ROUGE-L score. - The documented setup installs pyrouge from Git because the README says its PyPI package is out of date.
- The README identifies a possible ROUGE-1.5.5.pl XML::Parser dependency error.
Check current requirements in the official documentation. Source-based guidance does not mean OpenViST has run or independently tested this project.
Set up Files2Rouge and score paired text files
Install the documented prerequisites and calculate ROUGE scores for line-matched reference and summary files.
Before you start
- Python and pip, for the documented pyrouge installation and setup commands.
- Reference and summary text files with the same number of lines.
Steps
Install pyrouge from its Git repository with the command below.
pip install -U git+https://github.com/pltrdy/pyrougeClone
https://github.com/pltrdy/files2rouge.gitand change into thefiles2rougedirectory.Run the command below, then the command below.
python setup_rouge.pypython setup.py installRun
files2rouge references.txt summaries.txt, replacing the filenames with the input paths.
Expected outcome
The tool reports average ROUGE scores for the paired sequences; the documented output includes ROUGE-1, ROUGE-2 and ROUGE-L precision, recall and F-measure.
Guide limitations
- The input files must have the same number of lines.
- For sequences containing multiple sentences, set
--eosto the sentence-ending delimiter; an incorrect delimiter may affect ROUGE-L. - The README notes a possible ROUGE-1.5.5.pl XML::Parser dependency error.
Sources & review
Source record details
- Source availability
- Active
- Sources checked
- 17 October 2026
- Original website title
- pltrdy/files2rouge · Official homepage title · retained in its source language

