22 references to WordTokenize
Microsoft.Extensions.AI.Evaluation.NLP (6)
BLEUEvaluator.cs (2)
86
reference => SimpleWordTokenizer.
WordTokenize
(reference).ToArray()).ToArray();
88
string[] hypothesis = SimpleWordTokenizer.
WordTokenize
(modelResponse.Text).ToArray();
F1Evaluator.cs (2)
75
string[] reference = SimpleWordTokenizer.
WordTokenize
(context.GroundTruth).ToArray();
76
string[] hypothesis = SimpleWordTokenizer.
WordTokenize
(modelResponse.Text).ToArray();
GLEUEvaluator.cs (2)
85
reference => SimpleWordTokenizer.
WordTokenize
(reference).ToArray()).ToArray();
87
string[] hypothesis = SimpleWordTokenizer.
WordTokenize
(modelResponse.Text).ToArray();
Microsoft.Extensions.AI.Evaluation.NLP.Tests (16)
BLEUAlgorithmTests.cs (6)
203
SimpleWordTokenizer.
WordTokenize
("It is a guide to action that ensures that the military will forever heed Party commands").ToArray(),
204
SimpleWordTokenizer.
WordTokenize
("It is the guiding principle which guarantees the military forces always being under the command of the Party").ToArray(),
205
SimpleWordTokenizer.
WordTokenize
("It is the practical guide for the army always to heed the directions of the party").ToArray(),
207
string[] hypothesis = SimpleWordTokenizer.
WordTokenize
("It is a guide to action which ensures that the military always obeys the commands of the party").ToArray();
218
SimpleWordTokenizer.
WordTokenize
("he was interested in world history because he read the book").ToArray(),
220
string[] hypothesis = SimpleWordTokenizer.
WordTokenize
("he read the book because he was interested in world history").ToArray();
GLEUAlgorithmTests.cs (6)
127
SimpleWordTokenizer.
WordTokenize
("It is a guide to action that ensures that the military will forever heed Party commands").ToArray(),
128
SimpleWordTokenizer.
WordTokenize
("It is the guiding principle which guarantees the military forces always being under the command of the Party").ToArray(),
129
SimpleWordTokenizer.
WordTokenize
("It is the practical guide for the army always to heed the directions of the party").ToArray(),
131
string[] hypothesis = SimpleWordTokenizer.
WordTokenize
("It is a guide to action which ensures that the military always obeys the commands of the party").ToArray();
142
SimpleWordTokenizer.
WordTokenize
("he was interested in world history because he read the book").ToArray(),
144
string[] hypothesis = SimpleWordTokenizer.
WordTokenize
("he read the book because he was interested in world history").ToArray();
SimpleTokenizerTests.cs (4)
49
var result = SimpleWordTokenizer.
WordTokenize
(input);
58
var result = SimpleWordTokenizer.
WordTokenize
(input);
67
var result = SimpleWordTokenizer.
WordTokenize
(input);
76
var result = SimpleWordTokenizer.
WordTokenize
(input);