code: def jsonify_artifact_dict(
      artifact_dict: Dict[str, List[Artifact]]
  ) -> str:
      """Serialize a dict from key to list of Artifact into json format."""
      d = {}
      for k, l in artifact_dict.items():
          d[k] = [v.to_json_dict() for v in l]
      return json.dumps(d)
  
file_path: tfx/tfx/types/artifact_utils.py
imports: import itertools
  import json
  import os
  from typing import Dict, List, Optional, Type, Union
  from absl import logging
  from tfx.dsl.io import fileio
  from tfx.types import artifact
  from tfx.types import standard_artifact_utils
  from tfx.types import value_artifact
  from ml_metadata.proto import metadata_store_pb2
label_desc: Use image node_id 2 for calling a global function with example usage: jsonify_artifact_dict(artifact_dict) and returns: json