generate.py: implement arity definition in infra profiles