class_docstr: Validates a "DefaultV1" configuration against the training data and domain.
class_docstr_tok: ["Validates","a","``","DefaultV1","''","configuration","against","the","training","data","and","domain","."]
docstr: Validates that all training data will be consumed by some component.
  
  For example, if you specify response examples in your training data, but there
  is no `ResponseSelector` component in your configuration, then this method
  issues a warning.
  
  Args:
      training_data: The training data for the NLU components.
docstr_tok: ["Validates","that","all","training","data","will","be","consumed","by","some","component",".","For","example",",","if","you","specify","response","examples","in","your","training","data",",","but","there","is","no","`","ResponseSelector","`","component","in","your","configuration",",","then","this","method","issues","a","warning",".","Args",":","training_data",":","The","training","data","for","the","NLU","components","."]
code: def _warn_if_some_training_data_is_unused(
      self, training_data: TrainingData
  ) -> None:
      """Validates that all training data will be consumed by some component.
  
      For example, if you specify response examples in your training data, but there
      is no `ResponseSelector` component in your configuration, then this method
      issues a warning.
  
      Args:
          training_data: The training data for the NLU components.
      """
      if (
          training_data.response_examples
          and ResponseSelector not in self._component_types
      ):
          rasa.shared.utils.io.raise_warning(
              f"You have defined training data with examples for training a response "
              f"selector, but your NLU configuration does not include a response "
              f"selector component. "
              f"To train a model on your response selector data, add a "
              f"'{ResponseSelector.__name__}' to your configuration.",
              docs=DOCS_URL_COMPONENTS,
          )
  
      if (
          training_data.entity_examples
          and self._component_types.isdisjoint(TRAINABLE_EXTRACTORS)
      ):
          rasa.shared.utils.io.raise_warning(
              f"You have defined training data consisting of entity examples, but "
              f"your NLU configuration does not include an entity extractor "
              f"trained on your training data. "
              f"To extract non-pretrained entities, add one of "
              f"{_types_to_str(TRAINABLE_EXTRACTORS)} to your configuration.",
              docs=DOCS_URL_COMPONENTS,
          )
  
      if (
          training_data.entity_examples
          and self._component_types.isdisjoint(
              {DIETClassifier, CRFEntityExtractor}
          )
      ):
          if training_data.entity_roles_groups_used():
              rasa.shared.utils.io.raise_warning(
                  f"You have defined training data with entities that "
                  f"have roles/groups, but your NLU configuration does not "
                  f"include a '{DIETClassifier.__name__}' "
                  f"or a '{CRFEntityExtractor.__name__}'. "
                  f"To train entities that have roles/groups, "
                  f"add either '{DIETClassifier.__name__}' "
                  f"or '{CRFEntityExtractor.__name__}' to your "
                  f"configuration.",
                  docs=DOCS_URL_COMPONENTS,
              )
  
      if (
          training_data.regex_features
          and self._component_types.isdisjoint(
              [RegexFeaturizer, RegexEntityExtractor]
          )
      ):
          rasa.shared.utils.io.raise_warning(
              f"You have defined training data with regexes, but "
              f"your NLU configuration does not include a 'RegexFeaturizer' "
              f" or a "
              f"'RegexEntityExtractor'. To use regexes, include either a "
              f"'{RegexFeaturizer.__name__}' or a "
              f"'{RegexEntityExtractor.__name__}' "
              f"in your configuration.",
              docs=DOCS_URL_COMPONENTS,
          )
  
      if (
          training_data.lookup_tables
          and self._component_types.isdisjoint(
              [RegexFeaturizer, RegexEntityExtractor]
          )
      ):
          rasa.shared.utils.io.raise_warning(
              f"You have defined training data consisting of lookup tables, but "
              f"your NLU configuration does not include a featurizer "
              f"or an entity extractor using the lookup table."
              f"To use the lookup tables, include either a "
              f"'{RegexFeaturizer.__name__}' "
              f"or a '{RegexEntityExtractor.__name__}' "
              f"in your configuration.",
              docs=DOCS_URL_COMPONENTS,
          )
  
      if training_data.lookup_tables:
          if self._component_types.isdisjoint(
              [CRFEntityExtractor, DIETClassifier]
          ):
              rasa.shared.utils.io.raise_warning(
                  f"You have defined training data consisting of lookup tables, but "
                  f"your NLU configuration does not include any components "
                  f"that uses the features created from the lookup table. "
                  f"To make use of the features that are created with the "
                  f"help of the lookup tables, "
                  f"add a '{DIETClassifier.__name__}' or a "
                  f"'{CRFEntityExtractor.__name__}' "
                  f"with the 'pattern' feature "
                  f"to your configuration.",
                  docs=DOCS_URL_COMPONENTS,
              )
  
          elif CRFEntityExtractor in self._component_types:
              crf_schema_nodes = [
                  schema_node
                  for schema_node in self._graph_schema.nodes.values()
                  if schema_node.uses == CRFEntityExtractor
              ]
              has_pattern_feature = any(
                  CRFEntityExtractorOptions.PATTERN in feature_list
                  for crf in crf_schema_nodes
                  for feature_list in crf.config.get("features", [])
              )
  
              if not has_pattern_feature:
                  rasa.shared.utils.io.raise_warning(
                      f"You have defined training data consisting of "
                      f"lookup tables, but your NLU configuration's "
                      f"'{CRFEntityExtractor.__name__}' "
                      f"does not include the "
                      f"'pattern' feature. To featurize lookup tables, "
                      f"add the 'pattern' feature to the "
                      f"'{CRFEntityExtractor.__name__}' "
                      "in your configuration.",
                      docs=DOCS_URL_COMPONENTS,
                  )
  
      if (
          training_data.entity_synonyms
          and EntitySynonymMapper not in self._component_types
      ):
          rasa.shared.utils.io.raise_warning(
              f"You have defined synonyms in your training data, but "
              f"your NLU configuration does not include an "
              f"'{EntitySynonymMapper.__name__}'. "
              f"To map synonyms, add an "
              f"'{EntitySynonymMapper.__name__}' to your "
              f"configuration.",
              docs=DOCS_URL_COMPONENTS,
          )
  
imports: from __future__ import annotations
  from collections import defaultdict
  from typing import Iterable, List, Dict, Text, Any, Set, Type, cast
  from rasa.core.featurizers.precomputation import CoreFeaturizationInputConverter
  from rasa.engine.graph import ExecutionContext, GraphComponent, GraphSchema, SchemaNode
  from rasa.engine.storage.storage import ModelStorage
  from rasa.engine.storage.resource import Resource
  from rasa.nlu.featurizers.featurizer import Featurizer
  from rasa.nlu.extractors.mitie_entity_extractor import MitieEntityExtractor
  from rasa.nlu.extractors.regex_entity_extractor import RegexEntityExtractor
  from rasa.nlu.extractors.crf_entity_extractor import CRFEntityExtractor, CRFEntityExtractorOptions
  from rasa.nlu.extractors.entity_synonyms import EntitySynonymMapper
  from rasa.nlu.featurizers.sparse_featurizer.regex_featurizer import RegexFeaturizer
  from rasa.nlu.classifiers.diet_classifier import DIETClassifier
  from rasa.nlu.selectors.response_selector import ResponseSelector
  from rasa.nlu.tokenizers.tokenizer import Tokenizer
  from rasa.core.policies.rule_policy import RulePolicy
  from rasa.core.policies.policy import Policy, SupportedData
  from rasa.core.policies.memoization import MemoizationPolicy
  from rasa.core.policies.ted_policy import TEDPolicy
  from rasa.core.constants import POLICY_PRIORITY
  from rasa.shared.core.training_data.structures import RuleStep, StoryGraph
  from rasa.shared.constants import DEFAULT_CONFIG_PATH, DOCS_URL_COMPONENTS, DOCS_URL_DEFAULT_ACTIONS, DOCS_URL_POLICIES, DOCS_URL_RULES
  from rasa.shared.core.domain import Domain, InvalidDomain
  from rasa.shared.core.constants import ACTION_BACK_NAME, ACTION_RESTART_NAME, USER_INTENT_BACK, USER_INTENT_RESTART
  from rasa.shared.exceptions import InvalidConfigException
  from rasa.shared.importers.importer import TrainingDataImporter
  from rasa.shared.nlu.training_data.training_data import TrainingData
  import rasa.shared.utils.io
label_desc: Use image node_id 5 for calling the DefaultV1RecipeValidator obj's underlying member method code with example usage: obj._warn_if_some_training_data_is_unused(training_data) without return types