If you add a query type to the corresponding entity attribute that is used by a condition in the out-of-the-box template XML file, then the condition with the newly created query type can be used to define the validation rule or the override rule.
To add a new query type to an entity attribute: