←vuotogeometrico
November 28, 2026

Letting the Garlasco LLM Wiki Run on Its Own

Part 3 — How the wiki learned to find its own sources, extract them in a single call and run unattended, what it cost, and what I would do differently

At the end of the second part the investigation wiki on the murder of Chiara Poggi had become something closer to a database than to a notebook. Every fact sat in a claims ledger and was anchored to a verbatim quote from its raw file, a verifier rejected anything it could not match, and a generator rebuilt the timeline, the indexes and the chronologies from the claims on every build. Maintenance had become mechanical. What had not, as I wrote at the end of that part, was everything around it: the sources still had to be found, converted and filed by hand, and every ingest session still started with a model reading the operating manual, the workflow, the schema and the entity registry before it even looked at the article.

This third part is about those two costs and what I did about them: a crawler that looks for new material on its own and lets a model sort the inbox, an extraction that turns an article into claims with a single call instead of a session of agents, and a loop that decides what the wiki needs next and runs it unattended, sometimes for a whole night. All of it was measured as it went, so this part has more numbers than the previous two. It also closes the series, so the last two chapters step back from the machinery and look at the project as a whole, with everything I think is wrong with it and what I would do differently if I started over. As before, you can browse the public wiki while you read, and everything I quote comes from the repository1.

1. What was left

By the time the backfill was finished, the work of keeping the wiki consistent had moved almost entirely into code, and I could finally see what an ingest actually cost once the bookkeeping was taken away. The answer was a little embarrassing, because most of the cost had nothing to do with the wiki.

On my side there was sourcing. For months every article reached the vault through the same ritual: I found it, opened it in the browser, clipped it to markdown with Obsidian's Web Clipper, checked the name and the folder, and only then did the agent see it. The two big jumps in the chart of Part 1, the local paper's archive and the batch from Panorama and Libero, were each the result of a few long evenings of that, and in between the corpus only grew as fast as my free time allowed. Court documents and police reports were worse, because they almost never come from a newspaper's website and turn up instead as links shared by journalists or by YouTube channels that follow the case, so finding them meant watching and reading a lot of material that was not itself going into the wiki.

On the model's side there was the agent loop. An ingest was still a session in which an orchestrating agent read the manual, delegated each source to a subagent, and each subagent in turn read the manual, the workflow, the schema and the registry before reading its article. Distill sessions were heavier still, since they had to open the large curated pages they were supposed to rewrite. None of this was wrong, and the guarantees from Part 2 held throughout, but it meant that the price of adding one more article was set by the ceremony around it, not by the article itself.

2. A crawler with no budget

I started with sourcing, because it was the part that depended on me, and I wrote down the constraints before any code. The crawler had to run on my own Mac, with a launchd job firing every hour. It had to cost nothing, which ruled out paid scraping services and paid APIs and left only public feeds, free search radars and open source tools. It had to find sources of every kind (articles from any outlet, YouTube videos, linked PDFs, radio and TV), and above all it had to leave the decision to me, at least at first: the crawler would propose and I would approve, and only the approved items would be converted into markdown and enter the wiki.

The most important design choice was also the most boring one, and it came straight from the first hard rule of the vault, the one that says raw/ is immutable. A queue of candidates is by definition something you edit and throw away, so it could not live inside raw/. It lives instead in a crawler/ directory at the root of the vault, with its state in a small SQLite database, and the only command allowed to write into raw/ is the one that converts an approved item, which writes it under raw/converted/ and never moves it again. Whether a converted file has been ingested is not a flag anyone sets either, since the status command simply checks whether any claims file cites it, which is the same trick the duplicate check of Part 2 relies on.

flowchart TB
    L["launchd, every hour"] --> D["discover<br/>news radars, feeds, YouTube"]
    D --> Q[("queue<br/>crawler/state.sqlite")]
    Q --> I["INBOX.md<br/>checkboxes in Obsidian"]
    I -->|approved| C["convert"]
    C --> R["raw/converted/"]
    C --> J["converted.jsonl"]
    R -->|ingest| W["claims and<br/>source page"]
    W -.->|"cited = ingested&nbsp;"| J

Approval happens in Obsidian, which was already where I read the wiki. Every run of the crawler rewrites a digest file, crawler/INBOX.md, with one checkbox per candidate showing its title, outlet, date, relevance score, a short excerpt and a flag when it sits behind a paywall, and I approve an item by ticking it with [x] and reject it with [-], a second kind of checkbox that the Obsidian theme I use happens to render. When the hourly job finds something above the relevance threshold, it sends a macOS notification, which I have to say is the first feature of the whole project that made it feel a bit like a product.

The converted files keep the exact frontmatter the Web Clipper used to write (title, source URL, author, publication date, description, tags with the year quoted as a string), so that from the point of view of the ingest a crawled article is indistinguishable from one I clipped by hand. The file name follows the convention of the rest of the corpus, the publication date followed by an ASCII slug of the title, and before writing it the crawler checks that the name is unique across the whole of raw/, because some of the old migration scripts look files up by name and expect exactly one match.

3. Finding sources nobody listed

The part I enjoyed designing the most was discovery, because I did not want to maintain lists of outlets, channels and programmes by hand, which would have been a smaller version of the same bookkeeping problem that Part 2 was about. So the lists build themselves, and whatever the crawler learns is written to crawler/discovered.yaml, a file tracked in git, so that I can see what it has learned and when.

Google News is the main radar. Its RSS search endpoint, queried with a handful of fixed terms such as the name of the town and the names of the people at the centre of the case, returns about a hundred items per query from dozens of outlets, but its links turned out to be encoded redirects that a plain HTTP request cannot resolve. So the crawler uses it as a radar rather than as a source: it takes the title, the outlet and the date from Google News, and then looks for the real article, first by matching it against the outlets' own RSS feeds, then by decoding the link with a fragile method kept isolated in a function of its own, and finally, when converting, with a headless browser. GDELT, a free news index with no key, works as a second radar, and the fixed set of queries is enriched automatically with the names that appear in the most recent sources of the wiki, with a cap so that a busy week does not multiply the requests.

Outlets and channels are learned from what the radars find. An outlet that turns up with three or more relevant articles gets its RSS feed looked up from the page itself and is queried directly from then on, and a YouTube channel with two or more relevant videos is promoted to "followed", which means that its own video feed is read on every run, so that no video is missed even when the search does not show it. The YouTube search itself goes through yt-dlp, which needs no API key and finds videos from any channel, including the dozens of small ones that have made the case their main subject.

Two things keep this from drowning in noise. The first is deduplication, which matters more than it seems, because the same story reaches the radars through several paths (the outlet's site, its AMP version, its mobile version, a syndicated copy on another site). Every URL is normalized, with tracking parameters, AMP suffixes and the www removed, and compared against the source URLs of every file in raw/ and every source page of the wiki, while a second key made of the outlet's domain, the date and the normalized title catches the copies whose URLs differ, and PDFs are compared by their hash. The second is relevance, which is scored without any model: the crawler counts how often the aliases of the wiki's entities (taken from the generated entities.json) appear in the title and in the body, and an item whose title names one of the core terms scores high, while one that mentions them only in the body needs more than one entity to make it into the digest.

4. Where the paywall line goes

A good part of the Italian press that covers the case is behind a paywall, and this is the point where I had to decide what the crawler was allowed to do, so I would like to be explicit about it.

The crawler does three things, in this order. It first looks for a free version of the same story, since almost every article in a national paper about a hearing or a new expert report is also covered by a news agency, a public broadcaster or a free regional outlet, and what the wiki needs is the fact with a citable source, not a particular newspaper. It then tries the outlet's full-text RSS feed, when there is one. Finally, it asks the Internet Archive whether a snapshot of the page already exists, through the Wayback Machine's public API, and uses it when it contains the full text, keeping the original URL in the frontmatter and adding the address of the snapshot next to it. Whatever is left ends up in a list of articles to clip by hand, which I open with my own subscriptions when I think they are worth it.

What the crawler does not do is query the services that remove paywalls, such as archive.today or 12ft and their many clones. The reasoning, as I wrote it in the design document at the time, is that those sites are not archives that happened to index a page, since the full texts they serve are obtained by getting around the paywall, and calling them systematically for an entire corpus would mean building the bypass by proxy. What I do by hand from my browser remains my choice, but the crawler does not automate it.

There is also the question of what gets published. The converted files stay in the private vault, because the configuration of the public site already excluded raw/ (and, after one small change, crawler/ as well), so what appears on the site is what has always appeared there: source pages with a summary, claims with short attributed quotes, and the pages built from them.

5. Videos, documents and scans

Articles were the easy case. A large part of the public conversation about this case, including a surprising amount of primary material, happens on YouTube, in live streams where lawyers and consultants are interviewed for hours, in TV segments re-uploaded by their broadcasters, and in videos where someone reads a document aloud and puts a link to it in the description.

For a video, the crawler downloads only the automatic Italian subtitles, without the video itself, and turns them into a markdown file with the description, the links and the transcript split into paragraphs with timestamps. When a video has no subtitles, it can be transcribed locally with OpenAI's speech recognition model, Whisper (the large-v3-turbo version, run through mlx-whisper, a port for Apple Silicon), which on my machine takes about an eighth of the video's duration, so a two-hour live stream is ready in a quarter of an hour. Links to PDFs, Google Drive folders and shared documents found in descriptions and articles go into the queue on their own as new items, and scanned PDFs are run through Tesseract's Italian OCR model, at a few seconds per page.

The converted files reflect this. Of the roughly seven hundred items the crawler has converted so far, more than half are videos, about a third are articles and only a handful are documents, and in the claims ledger today almost four hundred sources come from YouTube transcripts. That is a big change in the nature of the corpus, and the operating manual tries to account for it: automatic transcripts are not verbatim in any reliable sense, so claims extracted from them have to carry a cautious confidence, and the source page has to say so in its reliability notes. I will come back to whether that is enough.

6. Letting a model sort the inbox

The inbox worked as designed, and it was the design that turned out to be wrong, because a crawler that finds everything also finds an enormous amount of commentary. In the busiest weeks a single day could bring dozens of candidates, most of them talk shows re-uploaded in pieces, opinion videos and articles repeating each other, and ticking boxes for half an hour every evening was not much better than clipping articles by hand.

So I gave the inbox to a model, with a command called garlasco smista (which means "sort" in Italian), and the way the work is split between the model and the code is, I think, the most reusable idea of this part. The model, Claude Haiku in this case, receives about twenty candidates published around the same dates, together with the wiki sources already published within three days of them and a few of their claims, and for each candidate it gives two judgments and nothing else: a relevance from 0 to 3, from "not about the case" through "commentary without facts" and "facts or statements" to "new documents, wiretaps, expert reports or decisions", and a novelty, which says whether the candidate brings something new, adds detail to a story the wiki already has, or repeats it. The decision is not the model's. It is made by a few lines of code, which also take into account a tier I assign to each outlet and channel by hand:

scripts/crawler/gcrawl/triage.pypython
1def verdict(tier: str, rilevanza: int, novita: str, dubbio: bool = False) -> str:
2 """The decision rule (code, not model): 'approve', 'reject' or 'doubt' (left to the user).
3 A model doubt (title and description too thin to judge) goes the source's way: a preferred source gets the
4 benefit of the doubt when it is about the case, a low one is dropped, only a normal one is left to the user."""
5 if dubbio:
6 if tier == "preferred":
7 return "approve" if rilevanza >= 1 else "reject"
8 return "reject" if tier == "low" or rilevanza == 0 else "doubt"
9 if tier == "preferred":
10 ok = rilevanza >= 2 and novita in ("nuova", "parziale")
11 elif tier == "low":
12 ok = rilevanza >= 3 and novita == "nuova"
13 else:
14 ok = rilevanza >= 2 and novita == "nuova"
15 return "approve" if ok else "reject"

The preferred tier is made of national dailies, news agencies, public broadcasters and the local paper, and also one YouTube channel that follows the hearings closely, while the low tier holds the channels whose videos I had rejected almost every time when I was still doing it myself. A preferred source is approved when it brings facts that are new or more detailed, a normal one only when they are new, a low one only when it brings new primary material. Items that are the same story from different outlets are grouped by similar title within a day of each other and judged once, keeping the best version (preferred, free, highest score) and rejecting the others as duplicates. There is also a cap on how many items are approved per run, so that a flood of news is ingested gradually instead of in one huge batch. Every decision is written to a log with the model's reason, and stays visible in the inbox for a week, where I can reverse it by flipping the checkbox.

Since I started using it, the triage has rejected several times more items than it approved, and has left me only a small number of genuine doubts, usually videos with generic titles and empty descriptions. The proportion is not a measure of quality, though, and I will come back to what this filter might be getting wrong systematically.

7. Measuring the loop before fixing it

By then I had already built the loop that I describe in section 9, a command that decides what the wiki needs and launches the right session without me, and it was running ingest, distill and audit sessions one after the other, first with Claude Code and then mostly with OpenCode. The switch was a matter of arithmetic: OpenCode Go, a plan that costs ten dollars a month, gave me access to DeepSeek V4.1 Flash, which in my experience had the best ratio between performance and cost of all the models I tried, and on the same budget it let me process a lot more work than my Claude subscription did. With a backlog of five hundred articles waiting on disk, the obvious next step was to make the ingest cheaper, and I almost did exactly that without looking. Then I measured what the loop had actually been spending, using the logs it writes for every session, and the numbers did not say what I expected2:

First week of the loopIngestDistillAudit
Claude Code, nominal cost$25 (about $3 per batch of 8)$69.5 (about $7 per session)$21.4
OpenCode, minutes of model time837 in 35 sessions1,251 in 70 sessions238 in 14 sessions

Distill and audit took between sixty and almost eighty percent of the total, depending on how you measure it, because every ingest batch was followed on average by two distill sessions and a fraction of an audit. And the backlog itself was much smaller than it looked: five hundred articles, but only about 345,000 words in all, a couple of megabytes of text that a model can read in no time. The expensive part was not reading the articles but the procedure wrapped around them, with each subagent rereading the manual, the workflow, the schema and the registry, and then working in turns with the orchestrator. Merging articles would not have helped either, since among those five hundred there were only two textual duplicates.

I had also been toying with a different idea, which I think is worth mentioning because it is the kind of idea that seems clever and is not. Instead of ingesting five hundred articles, why not have a model write one long summary of the period they cover, and ingest that? The answer came from Part 2: the claims extracted from such a document would be anchored to a text written by a model rather than to the articles themselves, so the quote check would still pass, but it would be verifying that the claim matches the summary, which is precisely the guarantee the whole architecture was built to provide. The two good halves of that idea, recognizing when different sources report the same fact and giving the distill a compact view of what is new, ended up in the plan at the level where they belong. The first was measured and abandoned, as I described in Part 2, when it turned out that fewer than three claims in a hundred were truly redundant. The second became the digest that I will come to in section 10.

8. One call per article

The new extraction, garlasco estrai ("extract"), starts from a simple observation: for an article, the agent loop was doing very little that needed an agent. A subagent with tools would read the raw file, search the registry for the entities it mentioned, write a claims file and a source page, run the build and check the result, but the only part of that which required a language model was reading the article and deciding what it said. Everything else could be done by code, and done better.

So the extraction makes a single call to the model for each article, with no tools at all. The call receives a fixed system prompt with the extraction rules (the same ones the ingest workflow had accumulated, including the lessons on profile articles and on facts buried inside quotes), a list of candidate entities taken from the registry by matching names and aliases against the text, and the article itself. It must answer with a JSON object that follows a schema: the source's title, authors and tags, a short summary, a reliability rating with its reasons, notes on possible contradictions, any new entities it wants to create, and the claims. With Claude Code, the call is a headless invocation with tools disabled and the schema passed on the command line:

scripts/crawler/gcrawl/llm.pypython
1cmd = [exe, "-p", user, "--system-prompt", system, "--tools", "", "--safe-mode", "--no-session-persistence",
2 "--output-format", "json", "--model", model or CLAUDE_MODEL]
3if effort: # thinking budget: the main driver of cost per source
4 cmd += ["--effort", effort]
5if schema:
6 cmd += ["--json-schema", json.dumps(schema, ensure_ascii=False)]

The part I care about the most is what happens to the answer. Before anything is written, every claim goes through the same rules the verifier applies at commit time, and to make sure they really are the same rules, and not a copy that would slowly drift away from the original, the extraction loads the verifier script itself as a module and uses its functions and its lists of allowed values:

scripts/crawler/gcrawl/pipeline.pypython
1def rules():
2 """scripts/verify-ingest.py as a module: normalize_for_quote, the enums and the regexes it enforces."""
3 global _RULES
4 with _RULES_LOCK:
5 if _RULES is None:
6 script = CRAWLER_CODE_DIR.parent / "verify-ingest.py"
7 spec = importlib.util.spec_from_file_location("verify_ingest_rules", script)
8 mod = importlib.util.module_from_spec(spec)
9 …
10 spec.loader.exec_module(mod)
11 …
12 _RULES = mod
13 return _RULES

The quote must be found in the article after the usual normalization, the type and the confidence must come from their lists, the date must have a sortable format, every subject must exist in the registry (or be a new entity that passes a guard against near-identical names), and a timeline entry must have a title and a date. The extraction is actually stricter than the verifier in one respect, since it requires a quote for every claim, background and hypotheses included, after a trial showed that recaps without quotes were impossible to compare. Claims that fail go back to the model, together with the list of what is wrong with each of them, for at most two rounds of corrections, and whatever is still wrong after that is dropped and recorded in a log, never written. A source whose share of dropped claims is too high, or whose answer cannot be read, is left for the old agent path, and the files themselves (the claims YAML, the source page, the stubs for new entities) are written by code from the templates, so the source page and its claims cannot disagree.

Every twenty-four articles, the extraction runs the build, writes one log entry for the batch and commits it through the same pre-commit hook as everything else, so from the point of view of the verifier nothing has changed: the commit is accepted or rejected for the same reasons as before.

Before running it on the backlog, I wanted to know whether a single call could do as well as a session of agents, so I ran it on twenty articles that had already been ingested, chosen to include short and long pieces, profiles and recaps, and compared the new claims with the committed ones. The comparison measures coverage, that is, the share of committed claims whose quote is covered by a new claim, which is a comparison with the previous extraction and not with any absolute truth, and part of those twenty articles had been ingested by one of these same models in the first place:

EngineCoverage (median)Valid on first passDroppedCost per sourceModel seconds per source
DeepSeek V4.1 Flash on OpenCode, high effort100%321 of 3311$10 a month, flat113
Claude Haiku, high effort83%377 of 3961$0.01376
Claude Sonnet, medium effort74%225 of 2260$0.08221

The detail that surprised me was that the reasoning effort mattered more than the model. Sonnet left on my default effort produced almost as much as the others, but at more than a dozen times the cost of Haiku, and two thirds of its tokens were reasoning. With low or medium effort, it extracted half as many claims. None of the engines put a number in the text of a claim that was not in the article, which was the failure I had feared the most.

Two more lessons came out of the trial, and both are typical of what happens when you move from an agent to a single call. The first was that the longest answers, the ones with thirty claims or so, sometimes arrived truncated, and the tolerant JSON reader I had written found the first complete object inside them, which was a single claim, and reported that the article had produced nothing valid. Now an answer counts only if it is an object with the top-level claims key (or a skip), and otherwise the call is repeated once before the source is handed back to the agents. The second was that the estimate on which the whole plan rested was wrong by a factor of two. I had assumed about ten claims per article, based on the short pieces of the local paper, while a real batch of eight long magazine articles produced about twenty each, and since the cost of distill grows with the number of claims, the number of distill sessions needed for the backlog went from about twenty to about seventy.

The backlog itself took about fifteen hours of model time in a single unattended run, with DeepSeek on OpenCode making four calls in parallel. Of the 512 articles waiting, 499 were extracted, producing 9,118 claims (a median of seventeen per article), eleven were excluded as empty, duplicated or off topic, two were left to the agents, and sixteen claims in total were dropped, which is about two in a thousand. The verifier and the build check passed on every batch.

What the verifier could not check showed up in the entities. The extraction created about a hundred new person stubs, and twelve of them turned out to be duplicates of people already in the wiki, mostly the same surname spelled in different ways by different newspapers (the three spellings of the same consultant's name I mentioned in Part 2 come from here). The guard at that point only refused a new person when someone with the same surname already existed, so a misspelled surname went straight through. It now also refuses a slug that is one edit away from an existing one, or with the same first name and a surname two edits away, and when it does so, it tells the model which existing slug it probably meant.

9. The loop

The loop is the piece that ties everything together, and it has two commands. garlasco prossimo ("next") looks at the state of the vault and says what the wiki needs now and why, with the numbers behind the decision, and garlasco auto asks it again and again and launches the corresponding session, headless, one after the other, until there is nothing left to do or something goes wrong. The decision is a plain function, and I think it is readable even without knowing the details:

scripts/crawler/gcrawl/autopilot.pypython
1def decide(s: Stats, cfg: dict | None = None) -> Decision:
2 cfg = cfg or DEFAULTS
3 if not s.build_ok:
4 return Decision("stop", "build.py --check non è pulito: …")
5 if s.in_progress:
6 return Decision("ingest", f"{s.in_progress} file con ingest rimasto a metà: si completano per primi")
7 if s.dirty:
8 return Decision("stop", f"modifiche non committate nella wiki ({shown}): controlla git status")
9 if s.articles and cfg.get("estrai", True):
10 return Decision("estrai", f"{s.articles} articoli in attesa: …")
11 total = sum(n for _, n in s.undistilled)
12 if s.undistilled and total >= cfg["distill_threshold"]:
13 return Decision("distill", f"{total} claims non distillati (soglia {cfg['distill_threshold']})", …)
14 due = _audit_due(s, cfg)
15 if due:
16 return Decision("audit", due)
17 …
18 if s.pending:
19 return Decision("ingest", f"{s.pending} file in attesa di ingest (convertiti o arretrato di raw/articles)")
20 …
21 return Decision("idle", "niente da fare: …")

The order says a lot about what I had learned by then. A build that is not clean, or uncommitted changes in the wiki, stop everything, because they mean that something happened that nobody can explain, and the loop should not build on top of it. An ingest left halfway is completed before anything else. Articles waiting go to the single-call extraction before any distill, so that a backlog is extracted completely and then distilled in chronological order, instead of being distilled one fragment at a time. A distill starts when at least fifty new claims (not counting background) are waiting, an audit after four distill sessions or a month without one, and the agent sessions for videos, documents and anything the extraction gave up on come after that. Each kind of session has its own model, the cheapest one that does the job, with Haiku for extraction, Sonnet for the agent ingest and Opus for distill and audit when running on Claude, and DeepSeek V4.1 Flash for everything when running on OpenCode, at high effort for ingest, extraction and backfill and at maximum effort for distill and audit, where the judgment happens.

flowchart TD
    S["garlasco prossimo<br/>reads the vault"] --> B{"build clean and<br/>nothing uncommitted?"}
    B -- no --> STOP["stop and notify"]
    B -- yes --> A1{"articles<br/>waiting?"}
    A1 -- yes --> E["estrai"]
    A1 -- no --> A2{"≥ 50 claims<br/>not distilled?"}
    A2 -- yes --> DI["distill"]
    A2 -- no --> A3{"audit due?"}
    A3 -- yes --> AU["audit"]
    A3 -- no --> IN["agent ingest"]
    E --> CK{"right commit,<br/>clean wiki?"}
    DI --> CK
    AU --> CK
    IN --> CK
    CK -- yes --> S
    CK -- no --> STOP

After every session, the loop checks that the session left exactly what it was supposed to leave, a commit with the right prefix and a clean working tree, and if something is missing it reminds the session once and then stops with a notification. A session that needs a human decision (whether two people with similar names are the same person, say) ends with a line starting with SERVE_DECISIONE ("decision needed"), which makes the loop play a sound, show the question in the terminal and wait for my answer. When the usage limits of the Claude subscription run out, the loop waits for the reset and resumes the same session, committing the articles already extracted first, so that nothing is lost.

Most of the hard work of the loop was not in the decision, though, but in the many ways an unattended session can fail, and almost all of them were discovered by letting it run overnight and reading the logs in the morning. Two of them are worth telling, because they are the kind of failure no design document predicts. The first time I ran an ingest batch on OpenCode, one of the subagents decided to search the web, and OpenCode's web search tool opened an interactive form asking which search provider to use. In a headless run nobody can answer a form, and the command-line tool treated the cancelled form as a failure of the entire call, killing the orchestrator and every subagent with it: two sources were complete, one had its files written but not committed, one had never started. The loop reminded the session to finish, the session (resumed without its subagents) answered that it would not commit in the middle of a batch and was waiting for the two remaining ones, and the loop stopped. I completed the batch by hand, web search was removed from the agents' permissions, and the loop learned to recognize that kind of interruption and to tell the resumed session that its subagents no longer exist.

The second was a single night in which the provider kept answering that its inference service was overloaded. OpenCode retries that error on its own after thirty seconds, and in the end every request would have gone through, but my wrapper treated it as fatal and killed four sessions in a row, while the startup check, which sent a tiny request and waited for a fixed three minutes, timed out and reported that OpenCode could not be started at all, as if the installation were broken. Nothing was broken, and reproducing the command by hand gave an answer in about half a minute. Now that error is treated as transient, the wrapper lets the provider retry for a few minutes inside the same call, and the startup check follows the stream of events as they arrive and says, when that is the case, that the provider is overloaded and to try again later. Each of these stories ended up in the bug history of the vault, with the rule it produced, which by now is perhaps the most useful document in the repository.

This is what the loop looks like when it works, from the last night it ran, shortly before the monthly limit of my OpenCode plan was reached and the loop, as designed, stopped instead of retrying:

crawler/logs/auto-2026-11.logtext
1INFO auto giro 51: estrai — 9 articoli in attesa: estrazione a chiamata singola, prima di distill e audit
2INFO auto estrai: estratti 9, esclusi 0, lasciati agli agenti 0, errori 0, commit 647427b8, stop ''
3INFO auto giro 52: distill — 171 claims non distillati (soglia 50)
4INFO auto distill: opencode start sessione ses_38c2… (opencode-go/deepseek-v4.1-flash#max)
5INFO auto distill: fine chiamata rc=0 errore=False durata=15.0 min costo nominale=0.0
6INFO auto giro 53: distill — 50 claims non distillati (soglia 50)
7INFO auto distill: opencode start sessione ses_e95a… (opencode-go/deepseek-v4.1-flash#max)
8INFO auto distill: fine chiamata rc=1 errore=True durata=9.0 min costo nominale=0.0
9WARNING Sessione distill non conclusa: credito del piano OpenCode Go esaurito (…). Mi fermo, nessun tentativo automatico.

10. Distill becomes the bottleneck

With extraction cheap and sourcing automated, the only expensive operation left was the one that cannot be checked by code, the distill session that reads the new claims and rewrites the curated prose, and that is where most of the remaining effort went.

The first change was to stop having the distill session discover its own input. It now starts from a digest that the code generates for it, with the new claims of its slice grouped by entity, one line per claim with its address, background claims left out, plus the notes left by the extraction and a limited number of candidate conflicts. I had initially included all the conflict groups touching the slice, and the digest came out at well over a megabyte, almost all of it conflicts, because seventeen claims per article on the same subjects and dates produce a large number of groups that are not conflicts at all, so now only the thirty smallest groups are included.

The second change was the size of the slice, and here a measurement saved me from a mistake. To finish the distill of the backlog faster, I tried a session with 250 new claims instead of the usual sixty or so, and measured the result in a way I could apply to the previous sessions as well, that is, the share of the twelve entities with the most new claims whose curated part had actually been revised. The previous sessions averaged two thirds, the large one reached about forty percent, and the page of the man at the centre of the new investigation, with seventy new claims of his own, was not touched at all. The slice went back to its previous size.

That session, though, also showed something else. Like the sessions before it, it appended much more than it rewrote, and every page it touched grew, although the first rule of distill is to rewrite rather than append. When I looked at the sizes, the reason seemed obvious: the curated part of some pages was in the hundreds of kilobytes (the case overview was about 90,000 tokens, and every agent session read it in full at the start), and a session cannot rewrite a page it cannot hold. Part of it was not even the distill's fault, since the largest section of one person's page, more than two hundred kilobytes, was a leftover of the cutover described in Part 2 that nobody had touched since.

So I wrote a command to shrink a single section of a page, garlasco condensa ("condense"), and it is built on the same principle as the extraction, a model call with no tools surrounded by code that does not trust it. The section is split into its entries and grouped into chunks of about twenty-eight kilobytes, and each chunk goes to the model with a target size. The model may only remove, and the code checks its answer against the original and rejects it when it contains a number, a link, a capitalised name or one of the wiki's labels that was not in the text it received:

scripts/crawler/gcrawl/condense.pypython
1old, new = _plain(original), _plain(condensed)
2seen_tokens, allowed = set(NUM_RE.findall(old)), _allowed_numbers(old)
3nums = sorted({n for n in NUM_RE.findall(new) if n not in seen_tokens
4 and not all(int(p) in allowed for p in re.findall(r"\d+", n))})
5if nums:
6 out.append("numeri o date che non sono nel testo originale: " + ", ".join(nums[:12]))
7links = sorted({m.group(1) for m in LINK_RE.finditer(condensed)} - {m.group(1) for m in LINK_RE.finditer(original)})
8if links:
9 out.append("link che non sono nel testo originale: " + ", ".join(links[:8]))

A rejected chunk is retried once and then left as it was, and the full original text of the section is saved, identical, in an archive outside the published wiki, with a line on the page pointing to it. The checks did catch the model adding things: in one of the hypothesis pages it had added links to three sources that were not in the text, and in the page of the man convicted in 2015 it had added a link to the victim's mother's page in two chunks. But the first real run also left two chunks out of nine untouched because of three mistakes of mine in the checks (numeric dates and ranges read as new numbers, a lower-case label, a faithful answer thrown away for being too long), which were fixed, with tests, before running it again.

Applied to nine sections of the largest pages, it brought them from about 710 kilobytes to about 260, and the largest section of all went from more than two hundred kilobytes to about sixty-five. I read a sample of the results against the originals, and dates, attributions, conditionals and notes on discrepancies between sources were all kept, while minor details and the links to the sources of many entries were lost (they remain in the claims and in the generated chronology). At the same time, the session start of the operating manual was changed so that the overview is no longer read in full but only its summary, with the other sections opened when needed. A distill session run afterwards revised eight of its twelve main entities, which is back to the earlier average, and on the large pages it removed about as many lines as it added, which no session had done in a long time. That is a single session, with three changes made at once, so I cannot say which of them mattered, but it was the first sign that the pages had stopped growing on their own.

11. What it cost

Here is the whole loop, from the day it first ran to the night it stopped, counted from the logs it writes for every session2:

SessionSessionsModel timeNotes
Distill194about 73 hoursalmost all on OpenCode, about 68 million input tokens
Agent ingest62about 19 hoursvideos, documents and sources the extraction gave up on
Audit29about 8 hoursone every four distills
Backfill and legacy12about 1.5 hoursthe tail of the work described in Part 2
Single-call extractionabout 700 articlesabout 20 hoursabout 18 claims, 18,000 input tokens and 100 seconds per article

On Claude Code, where the headless output reports a nominal cost for each session, the loop spent about $120 in its first couple of days, and three quarters of it went on distill and audit. On OpenCode, the ten-dollar Go plan reports no cost per session, so the bulk of the work in the table above, almost all the distill and most of the extraction, fit into a single month of that plan and ended when its monthly limit was reached. All of this was paid through subscriptions I already had, so the nominal cost is not what I paid, but it is a fair way to compare the operations with each other, and the comparison says the same thing every time: reading and extracting sources is cheap, while the judgment over what they mean, the part that keeps the curated pages honest, is where the money goes.

Two numbers summarize the change for me. An article that used to go through a subagent session now costs about one hundredth of a dollar with Haiku, a few seconds of my attention when I glance at the inbox and nothing at all when the triage handles it, and the wiki has grown from about eight hundred source pages at the end of the backfill to more than seventeen hundred, most of them added while I was doing something else.

12. The good and the bad

What I am fairly sure works is the backbone, which by now has been tested in conditions I did not plan for. Raw files that are never modified, claims anchored to verbatim quotes and checked by code, views generated from the claims and never edited by hand, and a verifier that runs on every commit and again on the server, have survived several months of models of different sizes and providers writing into the vault, sometimes for nights in a row with nobody watching, and the build check never let the published views drift away from the claims. The idea of letting the model judge and the code decide (in the triage, in the extraction, in the condensing) seems to me the one most worth reusing elsewhere, together with the habit of measuring before building, which saved me from at least two pieces of machinery that would have cost a lot and helped little. But I promised to list everything I think is wrong with the project, and the list is longer.

The first problem is the one I already raised in Part 2, and it has not gone away. A verbatim quote proves that the words exist in the source, not that they support the claim built on them, and the only defence against a claim that says more than its quote is an audit that reads a sample of claims against their raw files. With almost twenty-seven thousand claims, most of them written by small models in single calls, a sample is a small fraction of the whole, and I do not know how many claims overstate their quote, because I have never measured it properly.

The second is the corpus itself. The wiki is built mostly from the press and from YouTube, so statements outnumber facts, and what the wiki knows is to a large extent what journalists, lawyers and commentators chose to say in public, in the order and with the emphasis they chose. The automation makes this worse in ways that are easy to miss, since several of its mechanisms reinforce whatever the wiki already contains: the crawler's queries are enriched with the names that are most present in recent sources, the triage judges novelty against what the wiki already has, and the tiers I assigned by hand favour the large outlets, so the material that keeps coming in is the material that looks like what came before. A document that nobody wrote about, or a minor channel that got something right before the others, has a harder time getting in.

Then there are transcripts. Almost four hundred sources are automatic YouTube subtitles, which are not verbatim, misspell names and sometimes invert the meaning of a sentence, and the quote check that is so convincing for a newspaper article is much weaker when the text it checks against is itself a machine's guess at what was said. The instruction to use a cautious confidence is a rule written in prose, the kind of rule Part 1 taught me not to rely on.

The curated prose is still unverifiable. Everything a distill session writes (the profile of a person, the state of a hypothesis, the summary of the case) goes into the wiki on the strength of the model's judgment alone, and the pages kept growing for months despite a rule telling the sessions to rewrite rather than append, which shows how much a rule in prose is worth when nothing enforces it. The condensing brought the hand-written part back to a manageable size, but it did so by deleting minor details and many links to sources from the curated text, and the checks that protect it cannot see an addition written in lower case or a sentence that changes meaning while keeping the same words.

Contradictions, which the idea file put at the centre of everything, are now the weakest part of the system. The report of candidate conflicts has grown to several megabytes and well over a thousand groups, most of them false, and no session opens it whole. The contradiction pages that exist were written by distill and audit sessions noticing a disagreement, so the wiki preserves the contradictions that a model happened to notice, which is not the same as preserving the contradictions in the record.

Entities are still a weak spot. Guards against near-identical names catch most duplicates now, but not all of them, and they also risk the opposite mistake of refusing two different people with almost the same name. There are a few unresolved questions of identity, and a few dozen stubs for marginal people (politicians, commentators, victims of other cases) that probably should not be in the wiki at all.

Many of the decisions described in this part rest on thin evidence. Coverage was measured against the previous extraction, not against a set of claims checked by hand, the trial of the engines used twenty articles, the slice size was decided on one session and the benefit of condensing on another, and I said so each time, but a series of reasonable decisions taken on small samples is still a series of guesses.

There is the cost, and the dependence that comes with it. The loop ran on two consumer subscriptions, stopped every time one of them ran out, and had to be taught the particular failure modes of each provider, from interactive forms to overload errors. Distill alone took more than seventy hours of model time, and none of the prices or limits it depends on are under my control.

There is complexity. The crawler's command-line tool has about thirty commands, the operating manual and the workflows have grown long enough that the session start had to be rationed, and the bug history is a long list of failures that each required a new rule or a new check. I would argue that the project is no longer quite an LLM wiki in Karpathy's sense, where a model maintains a set of pages, but a data pipeline with a few carefully fenced model calls in it, and whether that is a betrayal of the pattern or its natural evolution probably depends on how large your corpus is.

Then there are the pages themselves, which are still incredibly long. The condensing only touched the part written by hand, while the bulk of a page like Alberto Stasi's is the chronology the build generates from the claims, every claim about him in date order, and today that page is about two and a half megabytes, nine tenths of it generated. Nobody reads a page like that from top to bottom, neither a person nor a model, and it will only get longer, since every new source adds its claims to it and nothing ever takes them away. This was, in a sense, deliberate: at some point the wiki started collecting everything, whether or not it mattered to the case, and in particular who said what and when, so that anyone who spoke publicly about the case could be held to what they said.

And that leads to the question of purpose, which I find the most uncomfortable one. Keeping everyone accountable is a perfectly legitimate goal, but it is not the goal the project started with. In Part 1 I described what I wanted: a tool that would collect what is valuable for solving the case, answer complex questions in seconds, propose hypotheses, even estimate how likely each person was to be guilty, the kind of software an investigator could use with the help of a model. Somewhere along the way the project drifted from that into a general wiki on the case, an archive of everything that has been written and said about it, and the drift happened without my ever deciding it, one reasonable rule at a time. Almost all of the work since then has gone into ingest, extraction, verification and automation, I have run very few queries, and the wiki has filed exactly one report. I built an excellent machine for accumulating a case file, and I have barely used it for what a case file is for.

And finally there is the ethical side, which a project like this one should never treat as a footnote. The wiki is about real people, some of whom are under investigation in a case that is still open, with a preliminary hearing ahead of it, and it is public. It keeps full texts of articles in a private archive, publishes their summaries and short quotes, and gives the same structural weight to a ruling of the Supreme Court and to a claim made by a commentator on a live stream, distinguished only by a confidence field that a reader may or may not look at. The labels and the conservative language help, and I have tried to be careful, but there is only one human in the loop, and with seventeen hundred sources even that human reads only a fraction of what the models write.

13. What I would do differently

If I started over today, the first thing I would keep is the order from Part 1, the idea file first and the implementation afterwards, but I would put a lot more into the idea file, starting with the architecture that it took me two rewrites to reach. I would have a claims ledger from the very first source, with every redundant view generated from it, and the schema enforced by code from the first commit instead of after four hundred pages. Most of the cleanup scripts in the repository, and most of the months spent on the backfill, exist because I let the model write the data in prose first and tried to impose structure afterwards.

I would build the crawler much earlier, because sourcing turned out to be the real limit of the project long before the model was, and I would rank primary documents above the press from the start, both in the crawler and in the triage, so that the wiki would lean towards what the record says rather than towards what is said about it.

I would build a small set of claims checked by hand, a few hundred of them taken from different kinds of sources, before choosing any model or any prompt, and measure every change against it, instead of comparing each new extraction with the previous one. It would have answered the question of how many claims overstate their quote, and it would have made every decision in this part rest on something firmer than twenty articles.

I would set size limits on the curated pages from the beginning, along with a check that blocks a commit making an oversized page grow, rather than discovering after months that some pages had become too large to rewrite.

I would measure the cost of the agent loop before scaling it, which is what I eventually did, but only after it had been running for a while, and I would keep the agents for the work that really needs them, giving the narrow and checkable tasks to single tool-less calls from the start.

And I would decide much earlier what the wiki is for, in the sense of the concrete questions it must be able to answer, and build towards queries and reports as early as towards ingest. A case file that only grows is an archive, and the point of all this structure was to be able to ask it something.

If I am honest, I think that what I have built is two projects that were never separated. One is a general wiki on the case, whose job is to collect everything and keep it accountable, and that is what the current software does reasonably well. The other is a tool for investigation, which should start from a completely different question, namely what an investigator actually needs to focus on, and would probably be organized around the open questions of the case (the time of death, the bicycle, the DNA under the fingernails) and the evidence for and against each answer, rather than around people and the chronology of everything said about them. I do not know yet what that second project looks like, and I suspect it would have to be designed from the ground up, as a separate piece of software, although I would argue that it does not need to start from nothing: the raw archive, the crawler and the quote-anchored claims are exactly the foundation it would need, and the part to redesign is everything built on top of them, from what gets rendered to what counts as relevant. Bear in mind, too, that investigators work on the case file, while this corpus is mostly what the press and the parties chose to make public, so whatever that tool becomes, it will be limited by its sources long before it is limited by its design.

That said, I do not regret the order in which things happened, because most of what I know about this kind of system I learned from the failures described in these three parts, and I doubt I would have designed the second version properly without having seen the first one break. The wiki is still running and still growing, now mostly on its own, and you can find it here.