add DEBUG mode, and backup models