Split out nosql filters into functions instead of slow Evals