Add gitignores
Refactor interface to be more like cdec batch optimizer interface. Add test verification