Emulate django's QuerySet API for filtering tasks