General cleanup and additional documentation.