Skip to content

feat: Add Perplexity CLI tool for researcher agent#214

Closed
Steffen025 wants to merge 1 commit into
danielmiessler:mainfrom
Steffen025:feat/perplexity-cli
Closed

feat: Add Perplexity CLI tool for researcher agent#214
Steffen025 wants to merge 1 commit into
danielmiessler:mainfrom
Steffen025:feat/perplexity-cli

Conversation

@Steffen025

Copy link
Copy Markdown

Summary

Adds a working Perplexity CLI tool and updates the PerplexityResearcher agent to use it.

Problem

The PerplexityResearcher agent mentions "Perplexity API integration for deep search" but only instructs to "use the research skill" - there's no concrete implementation to actually call the Perplexity API.

Solution

  • New CLI tool (.claude/tools/perplexity): A Bun-based wrapper that calls the Perplexity API directly
  • Updated agent: Concrete CLI usage instructions with query decomposition methodology

CLI Features

  • Loads API key from ~/.claude/.env (PERPLEXITY_API_KEY)
  • Supports sonar (fast) and sonar-pro (deep) models
  • Returns formatted results with citations
  • Simple usage: perplexity "your query" or perplexity --model sonar-pro "deep query"

Example Usage

# Basic query
perplexity "What are the latest developments in AI agents 2025?"

# Deep research with sonar-pro
perplexity --model sonar-pro "Compare different approaches to building AI agent systems"

Test plan

  • Tested CLI with valid API key
  • Verified citation output formatting
  • Tested both sonar and sonar-pro models

🤖 Generated with Claude Code

Adds a Bun-based CLI wrapper for the Perplexity API that:
- Loads API key from ~/.claude/.env
- Supports sonar (fast) and sonar-pro (deep) models
- Returns formatted results with citations

Updates PerplexityResearcher agent to use the CLI instead of
generic "research skill" instructions, with query decomposition
methodology for comprehensive research.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@danielmiessler

Copy link
Copy Markdown
Owner

Hey, thank you so much for this submission. We're about to change the project significantly to solve a number of core issues. Once we do that, let's revisit if it makes sense.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants