code: def guard_input_type(x: Any) -> InputType:
      if x == "dataset":
          return "dataset"
      elif x == "config":
          return "config"
      elif x == "split":
          return "split"
      if x in get_args(InputType):
          raise RuntimeError(
              f"Value {x} should be included in the literal values"
          )
      raise ValueError(f"Invalid input type: {x}")
  
imports: from __future__ import annotations
  from collections.abc import Mapping
  from dataclasses import dataclass, field
  from typing import Any, Literal, Optional, TypedDict, Union, get_args
  import networkx
  from libcommon.constants import DEFAULT_DIFFICULTY, DEFAULT_INPUT_TYPE, DEFAULT_JOB_RUNNER_VERSION, MIN_BYTES_FOR_BONUS_DIFFICULTY
  from libcommon.utils import inputs_to_string
label_desc: Use image node_id 1 for calling a global function with example usage: guard_input_type(x) and returns: str, str, str