haive.agents.research.open_perplexity.examples.run_from_file¶
Example script that demonstrates running the open_perplexity research agent. from typing import Any with a research question loaded from a text file.
Functions¶
|
Load research question from a text file. |
Parse command line arguments. |
|
|
Run research based on a question from a file. |
|
Set up logging configuration. |
Module Contents¶
- haive.agents.research.open_perplexity.examples.run_from_file.load_research_question(file_path)¶
Load research question from a text file.
- Return type:
Any
- haive.agents.research.open_perplexity.examples.run_from_file.parse_arguments()¶
Parse command line arguments.
- Return type:
Any
- haive.agents.research.open_perplexity.examples.run_from_file.run_research(question_file, output_dir=None, research_depth=2, max_sources=5)¶
Run research based on a question from a file.
- Parameters:
question_file – Path to file containing the research question
output_dir – Directory for outputs (default: ./outputs)
research_depth – Depth of research (1-3)
max_sources – Maximum number of sources per query
- Returns:
Boolean indicating success or failure
- Return type:
- haive.agents.research.open_perplexity.examples.run_from_file.setup_logging(log_file='research_run.log')¶
Set up logging configuration.
- Return type:
Any