def importance(
      self,
      memory: str,
      context: Sequence[tuple[str, float]] = ()) -> float:
    """Computes importance of a memory by quering LLM.

    Args:
      memory: memory to compute importance of
      context: a sequence of tuples of (old memory (str), importance
        (float between 0 and 1)) used to provide context and relative scale for
        the decision of the importance of the new memory.

    Returns:
      Value of importance in the [0,1] interval
    """
    zero, *_, one = self._importance_scale
    prompt = interactive_document.InteractiveDocument(self._model)
    if context:
      context_string = '\n'.join(
          f'{context[0]} -- how memorable: {context[1]}'
          for context in context)
      prompt.statement(context_string)
    question = (
        f'on a scale from {zero} to'
        f' {one}, where {zero} is'
        ' entirely mundane (e.g., brushing teeth, making bed) and'
        f' {one} is extremely poignant (e.g., a breakup of a romantic '
        'relationship, college acceptance, a wedding), rate the likely '
        'memorableness of the following new memory.\nMemory:'
        + memory
        + '\nRating: ')
    if context is not None:
      question = (
          f'{context}\nRelative to the life memories above, {question}')
    action = prompt.multiple_choice_question(
        question=question, answers=self._importance_scale)
    return action / len(self._importance_scale)
Computes importance of a memory by quering LLM.

    Args:
      memory: memory to compute importance of
      context: a sequence of tuples of (old memory (str), importance
        (float between 0 and 1)) used to provide context and relative scale for
        the decision of the importance of the new memory.

    Returns:
      Value of importance in the [0,1] interval
    
concordia/associative_memory/deprecated/importance_function.py