In progress refactoring on filter compiler