Committing clean up and modifications preparing to merge back to Amit's v1 branch