module documentation and cleanup