Framework / Argument parsing

Fixed Argument parsing and cleaned up framework.