10 references to new
Microsoft.Extensions.AI.Evaluation.NLP (6)
Common\BLEUAlgorithm.cs (2)
71
MatchCounter<NGram<string>> hypCounts =
new
(hypGrams);
78
MatchCounter<NGram<string>> refCounts =
new
(refGrams);
Common\F1Algorithm.cs (2)
27
MatchCounter<string> referenceTokens =
new
(groundTruth);
28
MatchCounter<string> predictionTokens =
new
(response);
Common\GLEUAlgorithm.cs (2)
27
MatchCounter<NGram<string>> hypNGrams =
new
(hypothesis.CreateAllNGrams(minN, maxN));
36
MatchCounter<NGram<string>> refNGrams =
new
(reference.CreateAllNGrams(minN, maxN));
Microsoft.Extensions.AI.Evaluation.NLP.Tests (4)
MatchCounterTests.cs (4)
24
var counter = new
MatchCounter
<string>(new[] { "a", "b", "a", "c", "b", "a" });
61
var counter = new
MatchCounter
<string>(new[] { "x", "y", "x" });
70
MatchCounter<int> counter1 =
new
(new[] { 1, 2, 2, 3 });
71
MatchCounter<int> counter2 =
new
(new[] { 2, 2, 4 });