code: public Event[] getEvents() {
      ArrayList elist = new ArrayList();
  
      try {
        String s = br.readLine();
        while (s != null) {
          String[] spaceToks = s.split(" ");
          for (int tok = 0; tok < spaceToks.length; tok++) {
            StringBuffer sb = new StringBuffer(spaceToks[tok]);
            if (TokenizerME.alphaNumeric.matcher(spaceToks[tok]).matches()) {
              int lastIndex = sb.length() - 1;
              for (int id = 0; id < sb.length(); id++) {
                String[] context = cg.getContext(new ObjectIntPair(sb, id));
                if (id == lastIndex) {
                  elist.add(new Event("T", context));
                }
                else {
                  elist.add(new Event("F", context));
                }
              }
            }
          }
          s = br.readLine();
        }
      }
      catch (Exception e) {
        e.printStackTrace();
      }
  
  	Event[] events = new Event[elist.size()];
  	elist.toArray(events);
          return events;
  
      }
docs: Builds up the list of features using the Reader as input. For now, this
  should only be used to create training data.