docs(articles): VC investment memo agent with LangGraph + Perplexity Agent API#74
Closed
rbuchmayer-pplx wants to merge 4 commits into
Closed
Conversation
An auditable, citation-grounded VC research agent built with LangGraph and the Perplexity Agent API (built-in web_search/finance_search), plus a LangSmith eval harness comparing search providers. Self-contained code under scripts/memo/.
…tool-loop shim The client-side tool round-trip shipped upstream in langchain-ai/langchain#37934 (langchain-perplexity 1.4.0), so the _compat.py shim is no longer needed. Section 2 now binds search tools with the standard bind_tools API, and the Perplexity tool gets an explicit parameter schema so model tool calls stay well-formed.
- build_graph() snippet now matches scripts/memo/graph.py - synthesizer section states the 7-sections-from-4-nodes citation model (sections 1-6 cite, Thesis is analysis-only) - results paragraph states the run's numbers and invites re-scoring - rename Code explanation -> Directory structure, trim keywords
- no em dashes; feature/limitation bullets use the blog's bolded-lead style - synthesizer, wiring, and limitations wording now identical to the blog - remove undefined 'Section 2' references (notebook-speak); say 'provider comparison' - add the blog's source-availability limitation for parity
8b7c917 to
0f97f0c
Compare
Author
|
Closing in favor of ppl-ai/api-docs#451 — per discussion with Albert, new cookbook content goes directly into the api-docs repo ( |
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 an Articles integration guide: an auditable VC investment-memo agent built with LangGraph + the Perplexity Agent API (built-in
web_search/finance_search), plus a LangSmith eval harness that compares search providers. Self-contained runnable code underscripts/memo/.The design highlight: four research nodes fan out in parallel, and a tool-less synthesizer can only cite evidence the research nodes gathered — a structural guard against fabricated citations, fully auditable in LangSmith.
Type of Contribution
Checklist
Project Details
What problem does this solve?
A first-pass VC memo takes an analyst 4–8 hours across Crunchbase, PitchBook, IR pages, and news, with every number hand-checked. This agent produces a seven-section, primary-source-cited memo in ~90s for ~$0.40.
What makes this contribution valuable to other developers?
It demonstrates the Agent API's built-in tools end-to-end, a reusable reliability pattern (split search from synthesis → auditable citation chain), and a LangSmith workflow for turning "which search provider?" into a measured decision.
External Links (if applicable):
Testing
Ran the agent end-to-end (
python -m memo --company "Anthropic") and the LangSmith comparison across 10 companies onopenai/gpt-5.5. MDX validated withscripts/validate-mdx.js(all files pass).Additional Notes
Companion to an upcoming Perplexity × LangChain blog post; the article URL is referenced there, so this is ready for review and merge.
Recent updates:
langchain-perplexity1.4.0 shipped client-side tool calling (langchain-ai/langchain#37934), so the provider comparison now uses the standardbind_toolsAPI and the temporary_compat.pyshim is gone.Note on CI: the
mdx-validationred X is the workflow failing at setup (org policy requires SHA-pinned actions;pr-validation.ymlonmainuses@v6tags), so it fails for every PR in this repo. All three of its checks pass locally on this branch:scripts/validate-mdx.js(42/42 valid), no localhost links, frontmatter present.