Documentation Index
Fetch the complete documentation index at: https://docs.perplexity.ai/llms.txt
Use this file to discover all available pages before exploring further.
Overview
AG2 ships aPerplexitySearchToolkit that wraps the Perplexity Search API as a native AG2 tool. The tool returns ranked web results — title, URL, snippet, and date — without generating an LLM answer, which keeps token usage minimal and lets the calling agent decide how to consume them.
AG2 (formerly AutoGen) is an open-source framework for building multi-agent conversational AI systems. Learn more at ag2.ai.
Installation
API Key Setup
Set your Perplexity API key as an environment variable, or pass it to the toolkit constructor:Get API Key
Generate your API key from the Perplexity dashboard.
Quick Start
RegisterPerplexitySearchToolkit with an AG2 Agent:
PerplexitySearchResult objects.
Configuration
All search parameters are passed totoolkit.search() and forwarded to the Search API:
Variable so it can be resolved from the conversation context at runtime:
Response Shape
Each call returns aPerplexitySearchResponse with the original query and a list of PerplexitySearchResult items:
Links & Resources
AG2 Docs
Build multi-agent systems with AG2.
Tool Source
PerplexitySearchToolkit implementation.
Search API Quickstart
Learn more about the underlying Perplexity Search API.
Common Toolkits
Browse all built-in AG2 tools.
Support
Need help with the integration?- Browse the AG2 documentation
- Review our FAQ