class MatchesWeigher implements Weigher<InputSentence, List<RuleMatch>> {
    @Override
    public int weigh(InputSentence sentence, List<RuleMatch> matches) {<FILL_FUNCTION_BODY>}
  }

      // this is just a rough guesstimate so that the cacheSize given by the user
      // is very roughly the number of average sentences the cache can keep:
      return sentence.getText().length() / 75 + matches.size();
    
<no_super_class>