Add documentation for functions.