wip
added opt_out and lots of import/export stuff