doc + a bit of cleanup