Skip to main content

SearchAgent

An agent that summarizes text based on a query and evaluates the relevance of an answer. Parameters:
  • model (BaseModelBackend, optional): The model backend to use for generating responses. (default: :obj:OpenAIModel with GPT_4O_MINI)

init

summarize_text

Summarize the information from the text, base on the query. Parameters:
  • text (str): Text to summarize.
  • query (str): What information you want.
Returns: str: Strings with information.
Ask whether to continue search or not based on the provided answer. Parameters:
  • query (str): The question.
  • answer (str): The answer to the question.
Returns: bool: True if the user want to continue search, False otherwise.