Refactoring, Cleanup and Documentation.