class_docstr: Slot type which can be used to branch conversations based on its value.
class_docstr_tok: ["Slot","type","which","can","be","used","to","branch","conversations","based","on","its","value","."]
docstr: Creates a `Categorical  Slot` (see parent class for detailed docstring).
code: def __init__(
      self,
      name: Text,
      mappings: List[Dict[Text, Any]],
      values: Optional[List[Any]] = None,
      initial_value: Any = None,
      value_reset_delay: Optional[int] = None,
      influence_conversation: bool = True,
  ) -> None:
      """Creates a `Categorical  Slot` (see parent class for detailed docstring)."""
      super().__init__(
          name,
          mappings,
          initial_value,
          value_reset_delay,
          influence_conversation,
      )
      if values and None in values:
          rasa.shared.utils.io.raise_warning(
              f"Categorical slot '{self.name}' has `null` listed as a possible value"
              f" in the domain file, which translates to `None` in Python. This value"
              f" is reserved for when the slot is not set, and should not be listed"
              f" as a value in the slot's definition."
              f" Rasa will ignore `null` as a possible value for the '{self.name}'"
              f" slot. Consider changing this value in your domain file to, for"
              f" example, `unset`, or provide the value explicitly as a string by"
              f' using quotation marks: "null".',
              category=UserWarning,
          )
      self.values = (
          [str(v).lower() for v in values if v is not None]
          if values
          else []
      )
  
imports: import logging
  from abc import ABC, abstractmethod
  from typing import Any, Dict, List, Optional, Text, Type
  import rasa.shared.core.constants
  from rasa.shared.exceptions import RasaException
  import rasa.shared.utils.common
  import rasa.shared.utils.io
  from rasa.shared.constants import DOCS_URL_SLOTS
label_desc: Use image node_id 1 to create a new CategoricalSlot object from inherited base classes: Slot with example: obj = CategoricalSlot(name, mappings, values, initial_value, value_reset_delay, influence_conversation)