You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@opennlp.apache.org by "mawiesne (via GitHub)" <gi...@apache.org> on 2023/01/22 11:05:31 UTC

[GitHub] [opennlp-sandbox] mawiesne commented on a diff in pull request #73: Update sandbox component 'tf-ner-poc' to be compatible with latest opennlp-tools release

mawiesne commented on code in PR #73:
URL: https://github.com/apache/opennlp-sandbox/pull/73#discussion_r1083431975


##########
tf-ner-poc/src/main/java/org/apache/opennlp/namefinder/WordIndexer.java:
##########
@@ -36,32 +37,39 @@ public class WordIndexer {
   public static String UNK = "$UNK$";
   public static String NUM = "$NUM$";
 
-  private boolean lowerCase = false;
-  private boolean allowUnk = false;
+  private final boolean lowerCase = false;
+  private final boolean allowUnk = true;

Review Comment:
   With `allowUnk = true` the tests are at least to some extent executable.
   
   In any case, the code on master is broken/untestable, atm. Nice to see, you ran into the same issues than I did. The PR fixes most of that.
   
   A deeper follow-up c/should clarify what needs changes or fixing.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@opennlp.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org