Open yoyhosoft opened 7 years ago
That's a good question. I do not know why "req" is not returned. It may be worthwhile to use the "explain" feature and see the actual numeric feature-vectors.
intentClassifier = new limdu.classifiers.EnhancedClassifier({
classifierType: TextClassifier,
normalizer: limdu.features.LowerCaseNormalizer,
featureExtractor: WordExtractor
});
intentClassifier.trainOnline("switch on the fan", "fanon");
intentClassifier.trainOnline("switch off the fan", "fanoff");
console.dir(intentClassifier.classify("switch on the fan pls",4));
and the result:
positive: fanoff: (4) ["switch+0.80", "the+0.80", "fan+0.80", "bias+0.80"] fanon: (4) ["on+0.64", "switch+0.14", "the+0.14", "fan+0.14"]
why fan off has a higher number than fan on?
Hi, I have some question as below:
Here is my code:
An actual results are:
There're correct results or should be like this: