clean up and fix bugs
clean up docs