need to make quite a few changes to get repl to work.
first pass sorta working, but not true repl yet.