Restructuring
Proper lib/cli seperation