This is an automated email from the ASF dual-hosted git repository.
aradzinski pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nlpcraft.git
The following commit(s) were added to refs/heads/master by this push:
new ac72ab2 NLPCRAFT-348 fix.
ac72ab2 is described below
commit ac72ab27550eda508c02f58c3abf2b1561072217
Author: Aaron Radzinski <[email protected]>
AuthorDate: Tue Jun 29 18:25:18 2021 -0700
NLPCRAFT-348 fix.
---
.../org/apache/nlpcraft/probe/mgrs/deploy/NCDeployManager.scala | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git
a/nlpcraft/src/main/scala/org/apache/nlpcraft/probe/mgrs/deploy/NCDeployManager.scala
b/nlpcraft/src/main/scala/org/apache/nlpcraft/probe/mgrs/deploy/NCDeployManager.scala
index 0dd5ffe..9e5ec78 100644
---
a/nlpcraft/src/main/scala/org/apache/nlpcraft/probe/mgrs/deploy/NCDeployManager.scala
+++
b/nlpcraft/src/main/scala/org/apache/nlpcraft/probe/mgrs/deploy/NCDeployManager.scala
@@ -1656,19 +1656,22 @@ object NCDeployManager extends NCService {
val processed = mutable.HashSet.empty[Case]
samples.
- flatMap { case (_, samples) =>
samples.flatten.map(_.toLowerCase) }.
+ flatMap { case (_, smp) =>smp.flatten.map(_.toLowerCase) }.
map(s => s -> SEPARATORS.foldLeft(s)((s, ch) =>
s.replaceAll(s"\\$ch", s" $ch "))).
foreach {
case (s, sNorm) =>
if (processed.add(Case(mdlId, s))) {
val seq: Seq[String] = sNorm.split("
").toIndexedSeq.map(NCNlpPorterStemmer.stem)
- if (!allSyns.exists(_.intersect(seq).nonEmpty))
- logger.warn(s"@NCIntentSample sample doesn't
contain any direct synonyms [" +
+ if (!allSyns.exists(_.intersect(seq).nonEmpty)) {
+ // Not a warning since the parent class can
contain direct synonyms (NLPCRAFT-348).
+ // See NLPCRAFT-349 for the additional issue.
+ logger.debug(s"@NCIntentSample sample doesn't
contain any direct synonyms (check if its parent class contains any) [" +
s"mdlId=$mdlId, " +
s"origin=${mdl.getOrigin}, " +
s"""sample="$s"""" +
s"]")
+ }
}
}