Code best practices for Go FunctionGraph functions