add documentation, fix byte-compilation errors