Cronista — I built an autonomous historiography research engine on Cloudflare
My graduate work was on Mexican historiography. My day job is web infrastructure. Cronista is what happens when you combine them — a self-driving research agent that searches the scholarly record, captures evidence, and writes citeable historiographic notes on its own.
I studied modern Mexico in graduate school. The historiography of the Mexican Revolution, agrarian reform, state formation. The arguments historians make about those questions, how the schools shift over time, what evidence the debates rest on. I still read in the area. The gap between what I know I don’t know and what I have time to read keeps widening.
My day job is building web infrastructure. After Cloudflare’s Agents Week this August, I realized the tooling to close that gap finally exists. Not as a research assistant you talk to, but as something closer to one you send out.
What it does
Cronista is an autonomous historiography research engine. You give it a topic like “How has the historiography of the agrarian question evolved?” and it runs an expedition:
- Plans bilingual OpenAlex and Internet Archive searches
- Gathers scholarly works, resolves entities against Wikidata, citation-chases shared references (the canon of a debate surfaces mechanically)
- Captures every raw record immutably to R2 storage with a retrieval date
- Extracts arguments, schools, and positions from the most relevant works
- Synthesizes the findings into an Obsidian-compatible wiki note with citations, wikilinks, and honest uncertainty flags
- Commits to a branch and opens a pull request (the PR diff is the human review)
The first corpus is the historiography of modern Mexico. The engine itself is subject-agnostic: a new corpus is one config file.
It’s been running for four days and has already produced 18 digest notes on topics ranging from “The cultural turn in Mexican Revolutionary historiography” to “Corporate legal archives (Standard Oil, El Águila, International Harvester) and their intersection with diplomatic correspondence.” Each note has citations that resolve to captured evidence in the vault, and the system proposes its own follow-up questions, so the research queue refills itself.
Four rules that make it trustworthy
The engineering is Cloudflare Workers, Workflows, D1, R2, Workers AI, and cron triggers (about $8/month of infrastructure). But the architecture that matters is epistemic, not technical:
-
Git is the source of truth. The knowledge base is a plain markdown repo. Cloudflare holds working memory (evidence, catalog, index). Delete the cloud and the wiki still stands, complete and citable.
-
No claim without a citation; no citation without a captured source. Every claim in a note cites a work by ID. Every work has a catalog record (author, title, venue, DOI). Every record has an immutable snapshot in R2 with a retrieval date. A generated “Fuentes” section in every note materializes the whole chain.
-
Honest uncertainty is mandatory. Where synthesis leans on model background knowledge beyond captured evidence, the sentence is flagged
[!verificar]. Flags are epistemic debt: they get resolved by a separate verification pass that gathers targeted evidence, or they stay. They are never deleted by hand. -
The agent never commits to main. Notes arrive on weekly expedition branches as pull requests. The PR diff is the review surface. One PR per week, not per topic.
Why Cloudflare specifically
Workflows is the linchpin. Each expedition runs as a Cloudflare Workflow instance, which means every step is a durable checkpoint. If the isolate dies, the machine restarts, or a step throws, the engine resumes exactly at the first incomplete step instead of re-executing. The plan step produces search queries; if the gather step times out on a slow API, only gather retries. The plan result is already persisted.
Three production lessons from the first day:
-
OpenAlex went credit-metered in 2026. On Cloudflare Workers, you inherit the whole platform’s egress reputation. Other people’s Workers had drained the free pool, so requests that worked from a laptop failed from the cloud with 23-hour retry-afters. The fix was Crossref as a same-role fallback plus optional OpenAlex key support. On shared egress, upstream rate limits are a platform property, not a per-application one.
-
Reasoning models eat their own token budgets. Kimi K2.6 emits reasoning tokens before answering; with
max_tokens: 8192on a large synthesis prompt, it would spend the entire budget thinking and return an empty response. Per-tier budgets (32k for synthesis) fixed it. For reasoning models,max_tokensmust cover thinking and the deliverable. -
Steps have a default 10-minute timeout. The first monolithic “gather” step (six searches plus citation chasing plus entity resolution plus PDF downloads) blew it. The fix was splitting into four bounded steps, each with its own timeout and retry policy, PDFs strictly best-effort with a hard time box.
The autonomy loop
The agenda is a D1 table with three sources: seed questions from the corpus config, topics typed into the console, and follow-ups proposed by expeditions themselves. Each digest must propose three to five follow-ups. A cron trigger claims pending topics nightly and spawns one Workflow instance each. They run in parallel.
Because digests keep proposing follow-ups, the queue refills itself. Research begets research. My touchpoints are the weekly PR review and occasionally pruning the agenda. Everything else runs on its own.
What’s next
A verification pass that retires [!verificar] flags against targeted evidence. A weekly digest email so findings arrive Sunday morning instead of being pulled. MCP and search endpoints over the wiki, so the corpus is queryable by any historian’s agent (a scholarly resource whose primary interface is an API). And eventually the mass-reading tier: Kitesurf patiently working through the Hemeroteca Nacional Digital de México’s 7 million newspaper pages.
The console is live at cronista.boconnell.workers.dev. The code and corpus config are open in my working repo. If the idea of an autonomous research pipeline that produces real, citable, reviewed output interests you — whether for historiography, legal research, technical documentation, or any domain with a structured scholarly record — I’d enjoy talking about what that looks like in your field.