extra error checking
docs
Add a predicate type
predicate type improvements