minor fixes

- misplaced docstring
- some defs private