added substr and word filters, reorganised methods to be more consistent