Provenance for AI-written notes: citations, staleness and conflicts

Updated · By the Cozy team

AI-written notes become trustworthy when each claim points to the source it came from, the note is flagged when that source later changes, and disagreements are written down instead of silently overwritten. In Cozy, that means links into sources/, a stale-page check, and CONFLICT: lines that Health counts.

The problem with unsourced agent notes

An agent that writes notes for you is summarizing something: a meeting, an email thread, a ticket, a document. Once the summary is saved, the connection to the original usually disappears. Weeks later you or another agent reads "the client prefers quarterly billing" and has no way to check where that came from, whether it was a firm statement or a passing remark, or whether anything has changed since.

Three failures follow from this:

Provenance is the fix. It means every note can answer three questions: where did this come from, has that source changed, and does anything contradict it.

Cite the source, not just the claim

In Cozy, evidence lives in a separate folder. The sources/ folder holds material from connectors and importers (meetings, mail, Slack channels, Notion pages, files you push through the ingest API). Each source has a stable ID, a URL where one exists, and timestamps. Cozy treats these files as untrusted data, so an instruction buried in an email is read as evidence, not obeyed.

Curated pages in wiki/ cite a source by linking to it with a normal wikilink. On every save, Cozy reads links into sources/ as cites relations. You do not need a special citation syntax. A line such as the following is enough:

Billing is quarterly, confirmed on the kickoff call. [[sources/granola/kickoff-call]]

The agent can then call cozy_context for a page and get the page, its typed neighbors with excerpts, its evidence, and any warnings in one response. Evidence is the list of sources the page cites, so a reader can open the original in one step.

Staleness: when the source changes after the note

A citation proves where a claim came from at one moment. It does not prove the claim is still true. Cozy handles this with a simple rule: a page is stale when a source it cites changed after the page's last edit.

Stable IDs make this work. If you re-push a document through the ingest API with the same ID, it updates the same source rather than creating a copy. The source's timestamp moves forward, and every page citing it is now older than its evidence. Health lists those pages, and the agent knows to re-read the source and update the note. The same applies to connector-synced sources that update over time.

Cozy does not decide whether the note is wrong. A changed source may leave the claim intact. The flag only says that a human or agent should check, which is the right amount of automation for a check that needs judgment.

Pages can also carry as_of in frontmatter, so a reader sees the date a claim was last verified, not only the date the file was saved.

CONFLICT: lines for disagreements

Sometimes two sources disagree. The kickoff call says quarterly billing and a later email says monthly. An agent that picks one and deletes the other has destroyed the evidence that a disagreement existed.

Cozy's convention is a line starting with CONFLICT: that states both values and cites both sources:

CONFLICT: billing cadence is quarterly per [[sources/granola/kickoff-call]] but monthly per [[sources/gmail/billing-thread]]. Unresolved as of 2026-11-02.

Cozy counts these lines, and they appear in Health, so unresolved disagreements are visible work and not hidden text. When someone settles the question, the agent keeps the superseded value with its date and removes the CONFLICT: marker. The history of what was believed and when stays in the page.

Where the check runs: Health and Dreaming

Two features turn the conventions into a routine.

Health scores each workspace. It flags stale pages, conflicts, unsourced pages, and uncited sources, along with broken links, orphans and missing metadata. Each page starts at 1.0 and loses weight per issue. The workspace score is the average times 100, and a "next" list gives fixes in priority order. See wiki health for the full list of checks.

Dreaming is an offline consolidation pass that your own agent runs, using the dream prompt. It orients with cozy_health, limits itself to pages changed since the last run (recorded in agents/dream/state.md), verifies claims against their sources, keeps superseded values with dates, records CONFLICT: lines, and merges duplicates. Cozy runs no model itself, so the pass uses whichever agent you connect. More in memory consolidation.

Why this makes agent memory trustworthy

Trust in memory comes from being able to check it. A store that returns a fact with no origin asks you to trust the model that wrote it. A store that returns the fact, the source, the source's age and any known contradiction lets you or the next agent verify it quickly.

This also limits damage. Edits require an expectedRevision, concurrent edits return a conflict, and the last 50 revisions of a page can be read and restored. If an agent writes a bad claim, history shows what changed, and cozy_restore rolls it back.

QuestionWhere Cozy answers it
Where did this claim come from?Links into sources/ become cites relations
Has the source changed?Stale pages in Health
Does anything disagree?CONFLICT: lines counted in Health
What did this page say before?cozy_history and cozy_restore
Which pages lack evidence?Unsourced pages in Health

What this does not do

Cozy does not read a source and certify that a note matches it. There is no semantic fact-checking, and search is lexical, not embedding-based. The system makes provenance cheap to record and easy to audit, but an agent or a person still has to do the verifying. Other agent memory tools take different approaches, and our agent memory page covers where the trade-offs sit.

To try it, connect your agent through the MCP server, push a few documents into the Inbox, and ask the agent to write notes that link back to them. Typed relations like cites are described in typed links.

Frequently asked questions

How does Cozy know a note is stale?

A page is stale when a source it cites changed after the page's last edit. Re-pushing a document with the same ID updates the same source, which moves its timestamp past the page and makes Health list the page.

What is a CONFLICT: line?

It is a line in a page that starts with CONFLICT: and states two disagreeing claims, ideally with a link to each source. Cozy counts these lines so unresolved disagreements show up in Health.

Do I need special citation syntax?

No. Link to the file in sources/ with a normal wikilink and Cozy records a cites relation on save. Links inside code blocks are ignored.

Does Cozy verify that a note matches its source?

No. Cozy runs no model itself. It records provenance and flags changes, and your own agent or you do the checking, for example during a Dreaming pass.

Can I undo a bad edit by an agent?

Yes. The last 50 revisions of a page are readable and restorable, and deletion is a tombstone. See wiki health for how problems surface.

Give your agents a memory worth keeping

Cozy gives every account a private wiki that Claude, Codex, ChatGPT and other MCP clients can read and maintain.

Start your wiki