Adds some docs and comments