PerplexitySearchTool with AG2 Agents.
Configuring Your Perplexity API Key
-
Create a Perplexity Account:
- Visit Perplexity AI
- Click
Sign Upand create an account - Select Free Tier during registration
-
Get API Key:
- Navigate to API Settings
- Add payment method (required)
- Generate API key under API Keys
-
Set Environment Variable:
Package Installation
To get started with thePerplexity Search integration in AG2, follow
these steps:
Install AG2 with openai extra since we use openai in our examples:
Note: If you have been usingYou’re all set! Now you can start using Perplexity AI Search with AG2.autogenorag2, all you need to do is upgrade it using:orasautogen, andag2are aliases for the same PyPI package.
Implementation
ThePerplexitySearchTool enables agents to perform real time AI
Powered web search.