code: def update_pipeline_and_auto_class_table(table):
      """
      Update the table of model class to (pipeline_tag, auto_class) without removing old keys if they don't exist
      anymore.
      """
      auto_modules = [
          transformers_module.models.auto.modeling_auto,
          transformers_module.models.auto.modeling_tf_auto,
          transformers_module.models.auto.modeling_flax_auto,
      ]
      for (
          pipeline_tag,
          model_mapping,
          auto_class,
      ) in PIPELINE_TAGS_AND_AUTO_MODELS:
          model_mappings = [
              model_mapping,
              f"TF_{model_mapping}",
              f"FLAX_{model_mapping}",
          ]
          auto_classes = [
              auto_class,
              f"TF_{auto_class}",
              f"Flax_{auto_class}",
          ]
          # Loop through all three frameworks
          for module, cls, mapping in zip(
              auto_modules, auto_classes, model_mappings
          ):
              # The type of pipeline may not exist in this framework
              if not hasattr(module, mapping):
                  continue
              # First extract all model_names
              model_names = []
              for name in getattr(module, mapping).values():
                  if isinstance(name, str):
                      model_names.append(name)
                  else:
                      model_names.extend(list(name))
  
              # Add pipeline tag and auto model class for those models
              table.update(
                  {
                      model_name: (pipeline_tag, cls)
                      for model_name in model_names
                  }
              )
  
      return table
  
file_path: H2O/h2o_flexgen/benchmark/third_party/transformers/utils/update_metadata.py
imports: import argparse
  import collections
  import importlib.util
  import os
  import re
  import tempfile
  import pandas
  from datasets import Dataset
  from huggingface_hub import Repository
label_desc: Use image node_id 3 for calling a global function with example usage: update_pipeline_and_auto_class_table(table) and returns: table