Refactoring CLI to simplify and integrate with Spark model better

NOT READY FOR MERGE
Or, were the indents originally incorrect?