Skip to main content

Monolithic research CLI powered by Perplexity Sonar API with auto-classification and iterative gap analysis

Project description

PPLX Research

A monolithic, versatile research CLI powered by Perplexity's Sonar API. Features auto-classification, iterative gap analysis, multi-perspective synthesis, and comprehensive output formats.

CI PyPI Python 3.9+ License: MIT

Why This Exists

Other Perplexity wrappers are simple API clients. PPLX Research is a research orchestration layer that adds:

  • Auto-classification: Analyzes your query and picks the optimal mode/depth/sources
  • Gap analysis: Iteratively identifies and fills knowledge gaps (deep mode)
  • Multi-perspective synthesis: Gathers insights from academic, news, forums, docs, and code sources
  • Full API coverage: All Perplexity features including search_domain_filter, reasoning_effort, return_images, etc.

Installation

pip install pplx-research

Quick Start

# Set your API key
export PERPLEXITY_API_KEY="pplx-..."

# Basic research
pplx-research "what is quantum computing"

# Let AI pick the best approach
pplx-research "React vs Vue performance" --auto

# Deep academic research
pplx-research "transformer architecture" --mode deep --sources academic --depth 4

# Multi-perspective analysis
pplx-research "microservices pros and cons" --mode synthesis

Modes

Mode Description Best For
quick Single query, fast response Facts, definitions, current events
deep Iterative gap analysis Complex topics, research reports
synthesis Multi-source perspectives Comparisons, debates, pros/cons

Options

pplx-research <query> [options]

Modes:
  -m, --mode {quick,deep,synthesis}  Research mode (default: quick)

Scope:
  -s, --site DOMAIN         Constrain to specific domain
  -e, --exclude DOMAIN      Exclude domain (can use multiple times)
  -t, --time-range {hour,day,week,month,year}
  -r, --region CODE        Country/region code (US, UK, JP)
  --sources TYPES          academic,news,docs,forums,code,all

Output:
  -f, --format {markdown,json,summary,plain}
  -d, --depth 1-5          Iteration depth (default: 3)

Automation:
  -a, --auto               Auto-classify query
  -o, --output PATH        Save to file
  -q, --quiet              Suppress progress

Python API

from pplx_research import ResearchEngine, PerplexitySDK

# High-level research
engine = ResearchEngine(query="quantum computing", mode="deep", sources=["academic"])
report = engine.run()

# Low-level SDK
sdk = PerplexitySDK()
result = sdk.chat("Hello", model="sonar-pro")

License

MIT License - see LICENSE for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pplx_research-1.0.2.tar.gz (18.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pplx_research-1.0.2-py3-none-any.whl (15.1 kB view details)

Uploaded Python 3

File details

Details for the file pplx_research-1.0.2.tar.gz.

File metadata

  • Download URL: pplx_research-1.0.2.tar.gz
  • Upload date:
  • Size: 18.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for pplx_research-1.0.2.tar.gz
Algorithm Hash digest
SHA256 0db002481a9d5dceaae1905d769756538a0498984652ad68276c09c42dc2609d
MD5 dc00edb7d782a120e9b9b6668df1c944
BLAKE2b-256 b2152edb704d98f9fca18b20cd41b542c8bf24815d8b12821ecd643ae831d531

See more details on using hashes here.

File details

Details for the file pplx_research-1.0.2-py3-none-any.whl.

File metadata

  • Download URL: pplx_research-1.0.2-py3-none-any.whl
  • Upload date:
  • Size: 15.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for pplx_research-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 4494ca08149bce93c1563634fa2db79bb1b282be3530548fdcc21fcbb2e6657a
MD5 37385675c5c59642d1c2b5ba59b3da4a
BLAKE2b-256 9d3d69ce6cc3576f4d4d444c77183f1083db6e33fc77b7bee73ab9ee57d7cce0

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page