Add Deep Agents Launch Intelligence cookbook (Perplexity Agent API)#68
Open
jliounis wants to merge 2 commits into
Open
Add Deep Agents Launch Intelligence cookbook (Perplexity Agent API)#68jliounis wants to merge 2 commits into
jliounis wants to merge 2 commits into
Conversation
…Search) Adds a multi-agent cookbook under docs/articles/ that uses LangChain Deep Agents for orchestration, the Perplexity Search API as the only external tool, and the langchain-perplexity chat integration for the model. The agent investigates a product launch and produces a citation-rich brief covering the official announcement, independent reception, the competitive landscape, and execution risks. Four narrowly-scoped sub-agents each write notes to a virtual workpaper file; the orchestrator synthesizes the final report from those workpapers so the brief is grounded in saved evidence rather than the model's parametric memory. Includes a runnable CLI (with a streaming progress mode for notebooks), a programmatic entry point, and an mdx article walking through the architecture, prompts, citation rules, observability, and how to adapt the four-sub-agent scaffold to other intelligence scenarios.
Switches the cookbook to use only the Perplexity Agent API. Removes the sonar-pro chat-completions framing, the langchain-perplexity / langchain-openai dependencies, and the standalone Search API tool. Keeps the Deep Agents pattern (planner + narrowly-scoped sub-agents + virtual workpaper filesystem) and implements every stage as a client.responses.create call with the pro-search preset and the built-in web_search + fetch_url tools. - Sub-agents are Agent API calls with web_search + fetch_url enabled and write Markdown workpapers (announcement.md, reception.md, competitors.md, risks.md). - Orchestrator is a final Agent API call with no tools that synthesizes the brief from the four workpapers. - requirements.txt reduces to just perplexityai>=0.6.0. - CLI swaps --model sonar-pro for --preset pro-search / --orchestrator-preset. - X-Pplx-Integration cookbook attribution header preserved on every Agent API call via the SDK's default_headers hook.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds a new in-depth cookbook article under
docs/articles/deep-agents-launch-intelligence/showing how to build a multi-agent Product Launch Intelligence Agent with a Deep Agents-style planner/sub-agent/workpaper pattern powered entirely by the Perplexity Agent API.The agent takes a product launch topic (for example, "NVIDIA Rubin GPU announcement" or "Apple Vision Pro 2") and produces a structured, citation-rich brief covering the official announcement, independent reception, competitive landscape, and execution risks. Four narrowly-scoped sub-agents —
announcement-scout,reception-analyst,competitor-mapper, andrisk-auditor— each make an Agent API call withpreset="pro-search"and the built-inweb_searchandfetch_urltools. Their Markdown notes become workpapers (announcement.md,reception.md,competitors.md, andrisks.md), then a final orchestrator Agent API call synthesizesfinal_report.mdfrom those saved workpapers.There is no Sonar chat-completions path, no
sonar-promodel selection, noChatPerplexity, nolangchain-openaifallback, and no standalone Search API tool in this rewrite.Type of Contribution
What's in the PR
docs/articles/deep-agents-launch-intelligence/README.mdxdocs/articles/deep-agents-launch-intelligence/launch_intelligence_agent.pydocs/articles/deep-agents-launch-intelligence/requirements.txtperplexityai>=0.6.0README.mdAPIs / integrations used
client.responses.createfor every model call.web_searchandfetch_urlfor the research sub-agents.X-Pplx-Integration: cookbook/deep-agents-launch-intelligence/0.1.0is forwarded on Agent API calls through SDK default headers.Citation / grounding rules baked in
Validation performed
node scripts/validate-mdx.js— ✅ all 40 MDX files valid.python -m py_compile docs/articles/deep-agents-launch-intelligence/launch_intelligence_agent.py— ✅ compiles clean.DEFAULT_SUBAGENT_PRESET=pro-search, and attribution slug..env, no notebook outputs.Checklist
sonar-proimplementation pathREADME.mdfor discoverability