remove Entity
add some extra filtering to the input data.