GenAI – What Is BLUE Score ?


Data Science – What Is BLUE Score ?

Table Of Contents:

  1. What Is BLUE Score ?
  2. Key Concepts Behind BLUE .
  3. BLUE Formula.
  4. Brevity Penalty.
  5. BLUE Score Range.
  6. Pro & Cons Of BLUE Score.
  7. When To Use BLUE Score?
  8. Python Example.

(1) What Is BLUE Score ?

(2) Key Concepts Behind BLUE Score

N-Gram Precision:

Modified Precision:

Brevity Penalty:

(3) BLUE Score

(4) BLUE Score Range

(5) Pro & Cons Of BLUE Score

(6) Example Of BLUE Score

(7) Python Example

from nltk.translate.bleu_score import sentence_bleu

reference = [['this', 'is', 'a', 'test']]
candidate = ['this', 'is', 'test']
score = sentence_bleu(reference, candidate)
print(f"BLEU Score: {score:.2f}")

Leave a Reply

Your email address will not be published. Required fields are marked *