def StandardAnalyzer(expression=default_pattern, stoplist=STOP_WORDS, minsize=2, maxsize=None, gaps=False):
 ret = RegexTokenizer(expression=expression, gaps=gaps)
 chain = (ret | LowercaseFilter())
 if (stoplist is not None):
  chain = (chain | StopFilter(stoplist=stoplist, minsize=minsize, maxsize=maxsize))
 return chain

def StandardAnalyzer ( expression = default_pattern , stoplist = STOP_WORDS , minsize = 2 , maxsize = None , gaps = False ) : ret = RegexTokenizer ( expression = expression , gaps = gaps ) chain = ( ret | LowercaseFilter ( ) ) if ( stoplist is not None ) : chain = ( chain | StopFilter ( stoplist = stoplist , minsize = minsize , maxsize = maxsize ) ) return chain
composes a regextokenizer with a lowercasefilter and optional stopfilter .