Added interactive setup

Added interactive setup and cleanup up some code.