Restructured everything for clarity, maintainability, increased compatibility with sbt