def __init__(
      self,
      model: language_model.LanguageModel,
      map_game_master_names_to_choices: Mapping[str, str],
      call_to_action: str = DEFAULT_CALL_TO_NEXT_GAME_MASTER,
      components: Sequence[str] = (),
      pre_act_label: str = DEFAULT_NEXT_GAME_MASTER_PRE_ACT_LABEL,
  ):
    """Initializes the component.

    Args:
      model: The language model to use for the component.
      map_game_master_names_to_choices: Names of game masters (rule sets) to
        choose from, mapped to the multiple choice question option corresponding
        to that game master.
      call_to_action: The question to ask the model to select a game master.
      components: Keys of components to condition the game master selection on.
      pre_act_label: Prefix to add to the output of the component when called
        in `pre_act`.

    Raises:
      ValueError: If the component order is not None and contains duplicate
        components.
    """
    super().__init__()
    self._model = model
    self._game_master_names = list(map_game_master_names_to_choices.keys())
    self._game_master_choices = list(map_game_master_names_to_choices.values())
    self._call_to_action = call_to_action
    self._components = components
    self._pre_act_label = pre_act_label

    self._currently_active_game_master = None
Initializes the component.

    Args:
      model: The language model to use for the component.
      map_game_master_names_to_choices: Names of game masters (rule sets) to
        choose from, mapped to the multiple choice question option corresponding
        to that game master.
      call_to_action: The question to ask the model to select a game master.
      components: Keys of components to condition the game master selection on.
      pre_act_label: Prefix to add to the output of the component when called
        in `pre_act`.

    Raises:
      ValueError: If the component order is not None and contains duplicate
        components.
    
concordia/components/game_master/next_game_master.py