add basic REPL support and code generation