Add documentation comments for functions