Ask Perplexity
perplexity_askQuery the Perplexity AI model with conversation history to get responses that incorporate real-time web search and research capabilities.
Instructions
Engages in a conversation using the Sonar API. Accepts an array of messages (each with a role and content) and returns a chat completion response from the Perplexity model.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"messages": "<messages>"
},
"name": "perplexity_ask"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| messages | Yes | Array of conversation messages |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| response | Yes | The response from Perplexity |