only consider sam when arity matches
cleanup, better error messages for arity mismatches
figured out arity checks