rewrite complex type docstring and cleanup