Add METEOR score to the text package - #3477
Open
ChrisJr404 wants to merge 1 commit into
Open
Conversation
ChrisJr404
force-pushed
the
add-meteor-score
branch
from
August 25, 2026 03:34
aa6f356 to
a6cf54c
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Fixes #595
Adds a METEOR metric to the text package, both the functional
meteor_scoreand the modularMETEORScore. It follows the sequential exact, stemmed and WordNet synonym alignment from the Lavie and Agarwal paper, scores each hypothesis against the best matching reference, and averages over the corpus. Thenltkstemmer and WordNet corpus are reused (nltk is already a text dependency), so the results line up withnltk.translate.meteor_score, which is what the tests compare against.alpha,betaandgammaare exposed with the usual defaults (0.9, 3.0, 0.5), and there's areturn_sentence_level_scoreoption like chrF and TER have.Before submitting
Did you have fun?
Always do 🙂