Add docs and assert