·6 min read

A startup research agent that can't make things up (Pi Durable + Blade.sh)

I built Richelieu, an agent that researches startups and records a fact only when it can quote the exact sentence it came from. Pi Durable keeps the runs alive, Blade.sh runs the models, web search and transcripts with one API key.

  • agents
  • pi-durable
  • blade
On this page
Resend63 facts
Total raised$21M✓ verified
Headcount57disputed
Founded2023✓ verified

Crunchbase says a startup raised $21M. Where does that number come from? A press release? A form the founder filled in? Someone's guess in 2023? You don't know. You just trust it.

I wanted the opposite: a startup database where every number comes with the sentence it was copied from.

So I built Richelieu. You give it a domain. An agent reads the company's site, blog, Hacker News threads, news, GitHub and founder interviews on YouTube. It writes down facts, and every fact links to the exact sentence it came from.

Named after the cardinal, who ran one of the best spy networks of 17th-century Europe. I like to think he asked for sources too.

Richelieu's page for Resend: total raised $21M, headcount 57, founded 2023, key facts with verified and disputed badges, and the list of investors
The Resend dossier, 30 minutes after typing its domain.

That's Resend's page. Typed resend.com, waited 30 minutes, got this. Here's what happened in between.

63facts
37documents
120tool calls
€0.15cost
context_dev_scrape
28 · 1.1 s
record_fact
36 · 3 ✗
record_investment
27 · 9 ✗
record_event
13 · 1 ✗
web + news search
6 · 36 s
pnpm agent research resend.com, November 15, 2026. ✗ = citations the quote check rejected.

The one rule

The agent can fetch whatever it wants. But there's exactly one way to put a value in the database: the record_fact tool. And record_fact checks one thing before anything else.

That's it. The quote must be a substring of a document the agent actually fetched. Not a paraphrase. Not "something like". The exact characters.

It sounds strict. It's the whole product. Here's why.

record_fact · resend · headcount = 57
the model cites

“57 humans on the team, 100% remote, and 100% good humans.”

✗ quote not found verbatimthe tool throws, the model retries
resend.com/humanssha256 6d3a186a
Humans · ResendWe're a team of 57 makers who believes in building great software that inspires others.Zeno Rocha FounderCo-founder & CEO at Resend and building react.email.Bu Kinoshita FounderCo-founder & CTO at Resend and building react.email.
A real exchange from the Resend run. Flip between the two attempts.

That's from the Resend run. The model wanted to record a headcount of 57, and "quoted" Resend's team page: "57 humans on the team, 100% remote, and 100% good humans." Cute. Also not on the page. The model made up a plausible sentence and put quote marks around it.

The tool threw. The model read the error, went back to the page, and found the real sentence: "We're a team of 57 makers who believes in building great software that inspires others." Accepted.

Citations were rejected 13 times in that run. After one of them, the model wrote itself a note: "must be an exact substring including whitespace. Safer to quote shorter fragments." It learns.

Without the check, all 13 would be in the database, looking exactly as true as the other 63.

The receipts

Each tool stores what it fetched as a document: raw text, URL, the tool call that fetched it, and a SHA-256 of the content. The document page re-hashes the content every time you open it, so you can see it hasn't been edited since.

Bladeqwen3.8-27bpicks the next tool calls
→
tools, in parallel
context_dev_brandcontext_dev_scrapecontext_dev_web_searchnews_searchhn_searchgithub_activitytranscribe_videoresearch_investor
→
document storeraw text + SHA-256doc_8ddfc674… · 6d3a186a
↓
record_factquote must be a substring of a stored document
✓ verifieddisputed → human✗ rejected
→
the dossierfacts with receiptsweb, API, llms.txt, .md
under all of itPi Durable · sessions.sqliteevery token, tool call and fact is committed before anyone sees it
Tools fetch, the store hashes, record_fact refuses anything it can't find.

Click any fact and you get the whole chain: which run, which tool call, which document, which hash, which characters.

The provenance chain of a fact: run started, tool call, document stored with its SHA-256, and the supporting quote highlighted in the page text
Every fact opens on its receipt: the tool call, the hash, the highlighted sentence.

And when sources disagree, the agent doesn't pick a winner quietly. Resend's team page says 57. A June blog post says 43. A December post says 28. Their YC page says 45. All true at some point. The agent records the fact as disputed and it goes to a review inbox.

A disputed headcount fact waiting in the review inbox, with the model's reasoning about 57, 43, 28 and 45
Four sources, four numbers. A human decides.

A human picks. That's the job a human should do anyway.

Why Pi Durable

An agent that researches a company for 30 minutes makes about 120 tool calls. Downloads videos. Starts subagents. Over that much time, something will crash: my laptop sleeps, a deploy restarts the server, I hit Ctrl-C by mistake.

A normal agent loop keeps all of that in memory. Crash, and you start over. And you pay for the tokens twice.

Pi Durable is the agent runtime from the Pi folks. It commits everything to SQLite before anyone sees it: every streamed token, every tool call's intent, every result. After a crash, harness.resume() picks up from the last checkpoint.

The fun part is tools calling tools. transcribe_video downloads the audio with yt-dlp, then transcribes it. Both steps are nested tool calls with a key:

If the process dies mid-transcription, the rerun calls yt_dlp_download with the same key, and Pi returns the stored result. No second download. Try it:

transcribe_video("youtube.com/watch?v=…")
  1. 0s
    Tool call committedtranscribe_video · intent saved before execute()
  2. t1
    yt_dlp_downloadnested call, key "download" · audio on disk
  3. t1
    Result committedpath + metadata stored with the task
  4. t2
    whisper_transcribenested call, key "whisper" · audio sent to Blade
What happens when the process dies mid-transcription. Press the button.

Investors work the same way. When the agent finds the people behind a round, it calls research_investor once per investor, in parallel. Each one starts a subagent: a whole conversation, with its own model and its own turn budget, owned by the tool call that created it.

The Resend run recorded 15 investors across two rounds: Andreessen Horowitz, Y Combinator, SV Angel, and a dozen angels, each with the quote that names them. A follow-up run, pnpm agent research resend.com --focus investors, sends one subagent to each of them to fill their own pages.

Why Blade

The first version ran on Claude Opus, with Context.dev for brand data and web search, ScrapeCreators for X and LinkedIn, and whisper.cpp on my laptop for transcripts. Four services, three API keys, and my laptop fans at full speed every time it transcribed an interview.

Then I wanted to give Blade a try. It's made by Shadow, the French cloud gaming company: the GPUs that stream games in the evening run open-weight models the rest of the time. Cocorico. 🐓

It's also cheap, because those GPUs would otherwise sit idle. And it does more than chat: an OpenAI-compatible API, with server-side web search and Whisper transcription on the same endpoint. One key covers all of it.

needbeforeon Bladeendpoint
The agentClaude Opus 5.5qwen3.8-27b/v1/chat/completions
SubagentsClaude Sonnet 5.5qwen3.6-35b-a3b/v1/chat/completions
Web and news searchContext.devweb_search server tool/v1/responses
Transcriptswhisper.cpp, localwhisper-large-v3-turbo/v1/audio/transcriptions
Brand, pages, sitemapsContext.devthe site itself, plain HTTPno key
.env.devBLADE_API_KEY=sk-blade-…
Five dependencies, one key.

Plugging it into Pi was one provider. I build the model list from Blade's live catalog, so the context windows and prices are always right:

Web search was the interesting one. Blade's web_search returns an answer written by a model, with links. That's exactly the kind of text Richelieu doesn't trust. So search results are stored as leads, never as evidence: the agent has to open the page and quote it there. Same rule as everything else.

Brand profiles, page scraping and sitemaps don't need an API at all. The homepage already has its title, description, icons and social links in its HTML. I just read them.

What it costs

The whole Resend run, on Blade's list prices:

Modelqwen3.8-27b
Time30 min 25 s
Turns32
Tool calls120
Documents37
Facts63
Tokens355,076 in, 45,185 out
Prices€0.152 per million input tokens, €2.041 per million output tokens
Total€0.15

That's the agent's own tokens; the six web searches run on Blade too and add their own on top. Fifteen cents for a sourced dossier, with every fact clickable.

It's not fast. Each web search takes about 36 seconds, and the model takes its time between tool rounds. For a research agent that runs in the background, that's fine. Nobody's waiting. And when it's done, I don't have to trust it: I can click.

Try it

The stack: Pi Durable for the runtime, Blade for the models, SQLite for everything (node:sqlite, no native deps), Next.js and Twenty UI for the app. Every page also has a Markdown twin and an llms.txt, so other agents can read the dossiers too, receipts included.