[Snowball-discuss] modifying Java English stemmer to accept new exceptions

From: Brian Riordan (briordan@indiana.edu)
Date: Sun May 07 2006 - 20:26:17 BST


Hello, I'm trying to add a set of irregular verbs to the exceptions for the
Java English stemmer. After reading the section on "Exceptional forms in
general" and inspecting the "englishStemmer.java" code, it appeared that I
could add new amongs to the a_10 list and new cases to the exception1()
method, e.g.:
 
new Among("am", -1, 12, "", this),
 
and
 
case 12:
slice_from("is");
            break;
 
I also changed this line in exception1():
 
among_var = find_among(a_10, 19);
 
However, after making these changes, "am" is not changed to "is". The
"find_among" method above produces 0, instead of finding the new case, 12.
 
Any guidance on how to modify the java code to accept new exceptions would
be gratefully appreciated.
 
Brian Riordan
Indiana University
 



This archive was generated by hypermail 2.1.3 : Thu Sep 20 2007 - 12:02:48 BST