This is an automated email from the ASF dual-hosted git repository.
sergeykamov pushed a commit to branch NLPCRAFT-70_NEW
in repository https://gitbox.apache.org/repos/asf/incubator-nlpcraft.git
The following commit(s) were added to refs/heads/NLPCRAFT-70_NEW by this push:
new 1d06a5b WIP.
1d06a5b is described below
commit 1d06a5b4f50eceb0264adebefde7c801661dbf30
Author: Sergey Kamov <[email protected]>
AuthorDate: Fri Jun 18 18:52:01 2021 +0300
WIP.
---
.../server/nlp/enrichers/ctxword/NCContextWordEnricher.scala | 5 ++---
.../scala/org/apache/nlpcraft/model/ctxword/NCContextWordSpec.scala | 2 +-
2 files changed, 3 insertions(+), 4 deletions(-)
diff --git
a/nlpcraft/src/main/scala/org/apache/nlpcraft/server/nlp/enrichers/ctxword/NCContextWordEnricher.scala
b/nlpcraft/src/main/scala/org/apache/nlpcraft/server/nlp/enrichers/ctxword/NCContextWordEnricher.scala
index 79cd9a2..55fae72 100644
---
a/nlpcraft/src/main/scala/org/apache/nlpcraft/server/nlp/enrichers/ctxword/NCContextWordEnricher.scala
+++
b/nlpcraft/src/main/scala/org/apache/nlpcraft/server/nlp/enrichers/ctxword/NCContextWordEnricher.scala
@@ -154,8 +154,7 @@ object NCContextWordEnricher extends NCServerEnricher {
flatMap { case (req, suggs) => suggs.map(_ -> req) }
// TODO:
- println("suggsReq=" + reqs.mkString("|"))
- println("suggs="+suggs.keys.mkString("\n"))
+ println("suggs="+suggs.mkString("\n"))
suggs.map { case(sugg, req) => (stem(sugg.word), sugg.score, req) }.
@@ -165,7 +164,7 @@ object NCContextWordEnricher extends NCServerEnricher {
if (map.contains(stem)) {
// TODO:
- println(s"!!!FOUND BY stem=$stem, elem=$elemId,
map=$map")
+ println(s"!!!FOUND BY suggStem=$stem,
index=${req.index}, suggScore=${suggScore}, elem=$elemId, map=$map")
map.map { case (_, score) => (ElementScore(elemId,
score), req.index) }
}
diff --git
a/nlpcraft/src/test/scala/org/apache/nlpcraft/model/ctxword/NCContextWordSpec.scala
b/nlpcraft/src/test/scala/org/apache/nlpcraft/model/ctxword/NCContextWordSpec.scala
index 8193464..6df491d 100644
---
a/nlpcraft/src/test/scala/org/apache/nlpcraft/model/ctxword/NCContextWordSpec.scala
+++
b/nlpcraft/src/test/scala/org/apache/nlpcraft/model/ctxword/NCContextWordSpec.scala
@@ -65,7 +65,7 @@ class NCContextWordSpecModel extends NCModel {
"The fox was already in your chicken house",
"What is the local temperature ?",
"This is the first day of heavy rain",
- "The beautiful day, the sun is shining ",
+ "It is the beautiful day, the sun is shining ",
)
)
@NCIntent(