add rules, define input and output options