lvwerra HF staff commited on
Commit
7696081
1 Parent(s): 54aaa2b

Update Space (evaluate main: a45df1eb)

Browse files
Files changed (1) hide show
  1. google_bleu.py +4 -4
google_bleu.py CHANGED
@@ -19,7 +19,7 @@ import datasets
19
  from nltk.translate import gleu_score
20
 
21
  import evaluate
22
- from evaluate import EvaluationModuleInfo
23
 
24
  from .tokenizer_13a import Tokenizer13a
25
 
@@ -125,9 +125,9 @@ Examples:
125
 
126
 
127
  @evaluate.utils.file_utils.add_start_docstrings(_DESCRIPTION, _KWARGS_DESCRIPTION)
128
- class GoogleBleu(evaluate.EvaluationModule):
129
- def _info(self) -> EvaluationModuleInfo:
130
- return evaluate.EvaluationModuleInfo(
131
  description=_DESCRIPTION,
132
  citation=_CITATION,
133
  inputs_description=_KWARGS_DESCRIPTION,
 
19
  from nltk.translate import gleu_score
20
 
21
  import evaluate
22
+ from evaluate import MetricInfo
23
 
24
  from .tokenizer_13a import Tokenizer13a
25
 
 
125
 
126
 
127
  @evaluate.utils.file_utils.add_start_docstrings(_DESCRIPTION, _KWARGS_DESCRIPTION)
128
+ class GoogleBleu(evaluate.Metric):
129
+ def _info(self) -> MetricInfo:
130
+ return evaluate.MetricInfo(
131
  description=_DESCRIPTION,
132
  citation=_CITATION,
133
  inputs_description=_KWARGS_DESCRIPTION,