rebuilt scaffolding backend.  Still needs work but should be more flexible now.