query interface following the same syntax as !lookup