Buckets:
AnonymousSpottedToad/candidate_bucket / codebase /python /agno-agi_agno /cookbook /91_tools /exa_tools.py
| """ | |
| Exa Tools | |
| ============================= | |
| Demonstrates exa tools. | |
| """ | |
| from agno.agent import Agent | |
| from agno.tools.exa import ExaTools | |
| # --------------------------------------------------------------------------- | |
| # Create Agent | |
| # --------------------------------------------------------------------------- | |
| # Example 1: Enable all tools | |
| agent_all = Agent( | |
| tools=[ | |
| ExaTools( | |
| all=True, # Enable all exa tools | |
| show_results=True, | |
| ) | |
| ], | |
| markdown=True, | |
| ) | |
| # Example 2: Enable specific tools only | |
| agent_specific = Agent( | |
| tools=[ | |
| ExaTools( | |
| enable_search=True, | |
| enable_answer=True, | |
| enable_get_contents=False, | |
| enable_find_similar=False, | |
| enable_research=False, | |
| include_domains=["cnbc.com", "reuters.com", "bloomberg.com"], | |
| show_results=True, | |
| text=False, | |
| ) | |
| ], | |
| markdown=True, | |
| ) | |
| # Example 3: Default behavior (most functions enabled by default) | |
| agent = Agent( | |
| tools=[ | |
| ExaTools( | |
| include_domains=["cnbc.com", "reuters.com", "bloomberg.com"], | |
| show_results=True, | |
| text=False, | |
| ) | |
| ], | |
| markdown=True, | |
| ) | |
| # --------------------------------------------------------------------------- | |
| # Run Agent | |
| # --------------------------------------------------------------------------- | |
| if __name__ == "__main__": | |
| agent.print_response("Search for AAPL news", markdown=True) | |
| agent = Agent( | |
| tools=[ | |
| ExaTools( | |
| show_results=True, | |
| ) | |
| ], | |
| markdown=True, | |
| ) | |
| agent.print_response("Search for AAPL news", markdown=True) | |
| agent.print_response( | |
| "What is the paper at https://arxiv.org/pdf/2307.06435 about?", markdown=True | |
| ) | |
| agent.print_response( | |
| "Find me similar papers to https://arxiv.org/pdf/2307.06435 and provide a summary of what they contain", | |
| markdown=True, | |
| ) | |
| agent.print_response( | |
| "What is the latest valuation of SpaceX?", | |
| markdown=True, | |
| ) | |
Xet Storage Details
- Size:
- 2.09 kB
- Xet hash:
- 8a88542ce6d551eaf79b31f4e3bb6f6383786aee8dfbf5c4eeecc0b845869e54
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.