Refactoring for percolator API filtering.