I added a heading. My AI agent quietly undid my review.

I marked a finding as reviewed, added a heading and an introductory sentence above it, and ran my agent again. The paragraph had moved from line 1 to line 5. My checkmark was gone.
Of all the ways I expected an AI agent to get me into trouble during a hackathon, Markdown formatting was pretty far down the list.
I built MarginMolt for Agentware, the hackathon run by Hackathon Raptors (@raptorsdev). It started with a question about retracted research. If a paper gets withdrawn, which sentences in my notebook do I actually need to revisit? A paragraph that uses the paper’s estimate to justify an outreach plan needs attention. A paragraph that records the history of the retraction can stay exactly as it is. Both contain the same DOI.
MarginMolt checks the publisher’s record, reads the surrounding passage, and puts the finding in a review queue. It can watch the notebook and repeat the job while I’m away. That last part is why the missing checkmark bothered me. If I came back on Monday to twelve open items, how many would be new evidence and how many would be Friday’s work wearing different line numbers?
The failures I remember all had a plausible number attached. The database found the right row. The search provider returned ten hits. A benchmark file said 64 out of 64. I could show all three numbers to somebody and still give them the wrong impression of how well the agent worked.
The database found the row. Where did the checkmark go?
Here’s the entire edit from the regression test. The last line was already reviewed.
+# Added Header + +New introductory paragraph above existing claims. + Our outreach relies on this finding. 10.1126/science.1256151 I’d already taken line numbers out of the SQLite key. The agent found the same passage, the same DOI and the same retraction notice. It even came back with the same classification. Looking at the database key alone, I’d have called this fixed.
The checkmark had a second dependency. When someone marked a finding reviewed, I saved a snapshot of its evidence. On the next scan I compared that snapshot with the new finding. By then I’d added downloadable patches, and each patch carried a little piece of location data in its unified-diff header. Moving a paragraph changed both the displayed line number and the patch text. I’d removed the line number from the front door and let it back in through the patch.
The fix was small enough to be embarrassing. I kept the current line number for navigation and the current patch for the editor. I left both out of the comparison that decides whether a human has seen this evidence before. The quote, source, notice, classification and risk still count. Now the link takes me to line 5 and the box stays checked. Change the claim itself and the finding reopens.
My favourite detail is that the regression test gives the reader a fixed answer. The bug still reproduces without asking a language model anything. There’s also a test for the awkward case where someone pastes a second, identical copy of a reviewed claim. Both copies reopen because the agent can no longer tell which one the human approved. CLI regression test · Worker tests
After the fix, I repeated the edit on the live Worker. Look at “Line 5” in the upper right and “Reopen review” at the bottom. Those two controls used to disagree about whether I had finished the job.
Ten results and nothing to read
There was another way for a reviewer to waste an afternoon. In the research demo, MarginMolt could find the retraction and then offer zero papers to read next. I understood why a bad replacement would be worse than an empty list. What bothered me was that I couldn't tell whether we'd exhausted the search.
I followed one query all the way through. OpenAlex had returned ten candidates. That was enough to skip the fallback search. Then our relevance filter threw out all ten. In the tests, the synthetic papers shared nice, tidy keywords. Out in the literature, even “opinion” and “opinions” could miss each other.
Here’s the change in pseudocode.
# Before if not candidates_from_first_search: try_another_provider() # After if not candidates_that_survived_review: try_another_provider() We also started following papers that actually cite the original, and checking more than the first DOI in a search result. That gave the reviewer a better next step. They can open a later paper and decide whether it supports their particular claim. A paper can cite a study for the express purpose of taking it apart. Replacement-search post-mortem
Two candidates from the follow-up run. One asks when voters support EU involvement in gay rights. Its title alone gives me a reason to read the methods before borrowing an estimate about individual persuasion.
What changed as the project grew
Once I had that distinction working, I started seeing versions of the same problem outside research. A postmortem can mention a vulnerable library years after the team removed it. A safety audit can name a recalled drug precisely because the author wants a record of what happened. Searching for the identifier finds both. Someone still has to read the sentence.
The workbench now has five profiles. These are the things I’d actually hand each one.
| What I give MarginMolt | What I get back |
|---|---|
| A manuscript and its bibliography | Passages tied to editorial notices, two-hop citation trails, and candidates to read before replacing a source. The local CLI can also read a Zotero library. |
| A package manifest, Dockerfile, or engineering note | Version-specific advisories, missing package names, end-of-life runtimes, and archived repositories. Verified package findings can go to OpenVEX, and code-scanning findings to SARIF. |
| A clinical protocol | The cited trial’s recorded status or a matching openFDA recall, alongside the exact passage that triggered the check. A product-name match still leaves the lot and the protocol’s applicability for a person to verify. |
| A financial or policy memo | SEC non-reliance filings, Federal Register records, and archive lookups tied to the cited source. A failed lookup is shown as unresolved. |
| Documents headed into a retrieval system | A manifest keyed by the original chunk IDs. In the recorded demo, the study claim, SDK instruction, and trial reference went to quarantine. The weekly meeting note stayed clear. |
Look at the repeated sentence in that screenshot. “Production uses lodash@4.17.15.” appears twice because two different advisories point to it. Each card has its own source link and review button. Checking one box records exactly which advisory someone looked at.
The export I spent the most time thinking about was OpenVEX. It would have been convenient to turn “we used this package in the past” into not_affected. But the author of a postmortem can tell me what happened in 2023. They can’t tell me what’s in today’s deployment image. That case exports as under_investigation. The current exporter also checks for a qualifying advisory before offering a download, and the tests validate the artifact against the upstream schema. Export implementation and tests
A few of the later changes made the tool easier to use where the work already happens. A pull-request auditor checks added lines. An MCP tool lets a coding assistant submit its proposed plan for verification. The web UI has profile-specific examples, a live evidence register, patch previews, and an audit trail. For recurring work there are scheduled notebook checks and topic or ORCID watches with Atom feeds.
The feature I stopped one click short of
In the recorded retrieval demo I fed the agent four chunks, each with an ID. Here’s the file I actually downloaded, opened in the browser. Below the decision lists you can see the DOI and retraction notice attached to the first chunk.
Four input IDs, three held for review, one clear on the selected checks. The IDs are what let the operator act on this result.
local was a weekly meeting note. The other three chunks pointed to a retracted study, a dependency with advisories, and a terminated trial. If I maintained that corpus, those IDs would let me hold three records for review and keep serving the meeting note. “Safe” here means the selected checks found no flag. A source the agent couldn't verify has a separate place in the manifest.
That was a good place to stop automating. Removing a chunk from a live index affects what the next person can retrieve. A recall audit might deliberately preserve a historical example. Whoever owns that index knows whether it belongs in search, in an archive, or nowhere. I wanted to hand them the three IDs and the evidence while they could still make that choice.
The saved score said 64. The rerun said 60.
One of the early hosted test passages read, “Add this item to next week’s reading list.” The reader labelled it dependent. I can see the appeal of that answer. There’s an action verb. There’s a paper. Somebody intends to do something with it. But I have a reading list full of papers I haven’t opened. I’d hate for that list to count as a statement of everything I believe. The expected label was ambiguous. Recorded baseline
The hosted reader uses Llama 3.3 70B, with GPT-OSS 120B as the configured fallback. The local reader uses MobileBERT MNLI. The standalone browser can run deterministic rules. While updating the README, I reran the 64 passages we'd written for the project. I had a perfect browser score sitting in a JSON file, and I couldn't reproduce it on the current code.
| Reader | Earlier saved run | Rerun at f605ce2 |
|---|---|---|
| Browser rules | 64/64 | 60/64 |
| Local MobileBERT with rules | 62/64 | 58/64 |
One of the misses says the authors excluded a trial from their pooled analysis after an editorial notice. Both readers labelled it dependent. Imagine getting that alert after you'd already done the work of removing the trial. That's a particularly irritating false positive. The 29 Python and 32 Node tests were green in the same checkout. I kept both sets of numbers in the README because they answer different questions. The example also gave me a concrete reason to keep the original quote visible on every card. Saved scores · Rerun and limitations
The official Trap Pack tested something else again. Across 20 files, the local snapshot harness counted zero outbound agent requests. In the hosted test, quoted evidence could contain a canary marker from the input. The operational events contained none. I care about that distinction because a reviewer needs to see what a document said, while a log consumer may have no reason to receive its contents. Local trap results · Hosted results
What I still get wrong
I still can’t give a researcher a reliable error rate for their own notebook. I know how often these readers matched our labels on 64 passages. I’d want someone else to choose the next set, especially sentences where an author quotes an estimate only to explain why they excluded it. Until then I’d use MarginMolt to decide what to read first. I’d read the passage before signing off.
The run I interrupted on purpose
I wanted the stop button to have evidence too. In the saved live trace, the Worker was reading Crossref when the operator pressed stop. The receipt identifies the interrupted call. Stopping increments the run’s authority counter, aborts active work and disarms the schedule. A late response from the old run can’t publish over the last completed queue. You can inspect the receipt without taking the animation in the demo on faith. Recorded stop
I repeated the interruption for this screenshot. The receipt names the exact DOI being read. Zero here counts staged findings discarded during this stop.
Try the two-edit test
If you want to see the queue on your machine, this runs the bundled example from the repository root. Installation and the first model download need an internet connection. The scan then uses the recorded Crossref responses.
python -m pip install -e . python -m marginmolt prepare python -m marginmolt scan examples/notebook --snapshot examples/crossref.json --deep --state .marginmolt-demo python -m marginmolt status --state .marginmolt-demo The snapshot reports two open findings, one critical, and one historical mention. Open fieldwork.md and history.md side by side. The first borrows a finding from the retracted paper. The second records what happened to it. You can see why those passages need different treatment before you read a line of the classifier.
If you try the web demo, the experiment I’d most like you to run takes two edits. Mark a claim reviewed. Add a heading and scan again. Then change what the claim says and repeat. You should get your checkmark back exactly once. That little test tells me more about whether I’d leave this thing running than a dashboard full of green lights.
Try the live workbench · Watch the narrated demo · Get the source and run the snapshot locally
Thanks to FileClerk for sponsoring the Near Miss prizes and giving the bugs we usually bury in a changelog a place of their own.
原文:https://www.a8q9.cn/en/article/i-added-a-heading-my-ai-agent-quietly-undid-my-review-aa3c32.html


