web-research

A command for researching current events, technical documentation, and other topics through the Perplexity AI service. It can return research results with citations when requested.

In plain words
What is it for?
It helps investigate recent information, compare sources, research technical subjects, fact-check claims, and produce cited results.
Why use it?
It helps gather and check information from multiple sources instead of relying only on memory or manually opening pages one by one.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/danielmiessler/paiplugin/web-research
Clone the repo
git clone --depth 1 https://github.com/danielmiessler/PAIPlugin
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 309 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.00309
Opus 5 $0.00000 $0.00154
Sonnet 5 $0.00000 $0.00062
Haiku 4.5 $0.00000 $0.00031

Measured 2d ago against content hash 2709821371b5, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

web-research scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

source ${PAI_DIR}/.env && curl -s -X POST https://api.perplexity.ai/chat/completions \
commands/web-research.md · 30 lines

What it actually says

Web Research Command - Perplexity AI

Quick Usage

# Basic research query (API key in ${PAI_DIR}/.env as PERPLEXITY_API_KEY)
source ${PAI_DIR}/.env && curl -s -X POST https://api.perplexity.ai/chat/completions \
  -H "Authorization: Bearer $PERPLEXITY_API_KEY" \
  -H "Content-Type: application/json" \
  -d "{\"model\":\"sonar\",\"messages\":[{\"role\":\"user\",\"content\":\"YOUR_QUERY_HERE\"}]}" \
  | python3 -c "import sys, json; data = json.load(sys.stdin); print(data['choices'][0]['message']['content'])"

With Citations

source ${PAI_DIR}/.env && curl -s -X POST https://api.perplexity.ai/chat/completions \
  -H "Authorization: Bearer $PERPLEXITY_API_KEY" \
  -H "Content-Type: application/json" \
  -d "{\"model\":\"sonar\",\"messages\":[{\"role\":\"user\",\"content\":\"YOUR_QUERY_HERE\"}],\"return_citations\":true}" \
  | python3 -m json.tool

Models

  • sonar-pro - Deeper analysis with more sources

When to Use

  • Current events and recent information
  • Technical documentation research
  • Multi-source information synthesis
  • Fact-checking and verification
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 30 lines · 0 tokens per session scan A 2709821371b5

Subscribe to this mod's changes

web-research is a command published in the GitHub repository danielmiessler/PAIPlugin (56 stars, last pushed 9mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 309 tokens. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.