Added some docs, minor cleanup.