see TODO; lots of progress made