code: def validate_training_data(
      json_data: Dict[Text, Any], schema: Dict[Text, Any]
  ) -> None:
      """Validate rasa training data format to ensure proper training.
  
      Args:
          json_data: the data to validate
          schema: the schema
  
      Raises:
          SchemaValidationError if validation fails.
      """
      from jsonschema import validate
      from jsonschema import ValidationError
  
      try:
          validate(json_data, schema)
      except ValidationError as e:
          e.message += (
              f". Failed to validate data, make sure your data "
              f"is valid. For more information about the format visit "
              f"{DOCS_URL_TRAINING_DATA}."
          )
          raise SchemaValidationError.create_from(e) from e
  
imports: import logging
  import os
  from typing import Text, Dict, List, Optional, Any
  from packaging import version
  from packaging.version import LegacyVersion
  from pykwalify.errors import SchemaError
  from ruamel.yaml.constructor import DuplicateKeyError
  import rasa.shared
  from rasa.shared.exceptions import YamlException, YamlSyntaxException, SchemaValidationError
  import rasa.shared.utils.io
  from rasa.shared.constants import DOCS_URL_TRAINING_DATA, PACKAGE_NAME, LATEST_TRAINING_DATA_FORMAT_VERSION, SCHEMA_EXTENSIONS_FILE, RESPONSES_SCHEMA_FILE
label_desc: Use image node_id 2 for calling a global function with example usage: validate_training_data(json_data, schema) without return types