mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-10-29 18:03:18 -06:00
make sure that neither I nor I'm is recognized as name in English
This commit is contained in:
1 parent
386ec87405
commit
e41ec32ba9
1 file changed
+6
-2
@@ -38,6 +38,12 @@ public class NercLiteralCallback implements LiteralCallback {
|
||||
|
||||
if (i > 0) {
|
||||
String name = sbuilder.toString();
|
||||
|
||||
if (concr.getName().contains("Eng") &&
|
||||
("I".equals(name) || "I'm".equals(name))) {
|
||||
return null;
|
||||
}
|
||||
|
||||
Expr expr = null;
|
||||
double prob = 0;
|
||||
for (MorphoAnalysis an : concr.lookupMorpho(name)) {
|
||||
@@ -49,8 +55,6 @@ public class NercLiteralCallback implements LiteralCallback {
|
||||
} else if ("Language".equals(cat)) {
|
||||
expr = new Expr(an.getLemma(), new Expr[0]);
|
||||
expr = new Expr("languagePN", expr);
|
||||
} else if ("Pron".equals(cat)) { // to capture I in English
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user