Initial incarnation that mostly works