code: def _create_artifact_annotation(
      is_input: bool,
      is_multi: bool,
      describe_type: Type[ArtifactDescribe],
      describe_type_kind: str,
  ):
      def f(
          roles: Optional[List[Role]] = None, desc="", optional=False
      ):
          from .._component_artifact import ArtifactDescribeAnnotation
  
          return ArtifactDescribeAnnotation(
              describe_type=describe_type,
              describe_type_kind=describe_type_kind,
              is_input=is_input,
              roles=roles,
              stages=[],
              desc=desc,
              optional=optional,
              multi=is_multi,
          )
  
      return f
  
imports: import inspect
  import typing
  from typing import Generic, List, Optional, Type, TypeVar, Union
  from fate.arch import URI
  from fate.components.core.essential import Role, Stage
  from fate.components.core.spec.artifact import DataOutputMetadata, Metadata, MetricOutputMetadata, ModelOutputMetadata
  from fate.components.core.spec.component import ArtifactSpec
label_desc: Use image node_id 1 for calling a global function with example usage: _create_artifact_annotation(is_input, is_multi, describe_type, describe_type_kind) and returns: f, ArtifactDescribeAnnotation