Compare Snapshot
compare_snapshotCompare a document snapshot to the current text or another snapshot, showing added and removed paragraphs and net word count change.
Instructions
Compare a document snapshot against the current document text, or against another snapshot (pass againstSnapshotId). Returns the paragraphs added and removed and the net word-count change — use this to see what changed since a snapshot was taken. Read-only. Requires an open project (call open_project first). Get snapshot ids from list_snapshots.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| documentId | Yes | UUID of the document. | |
| snapshotId | Yes | The baseline snapshot id (from list_snapshots). | |
| againstSnapshotId | No | Optional second snapshot id to compare against. Omit to compare against the current document text. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | Yes | What it was compared against ("current" or a snapshot id). | |
| from | Yes | The baseline snapshot. | |
| wordDelta | Yes | to.wordCount minus from.wordCount (negative means text was cut). | |
| documentId | Yes | ||
| wordsAdded | No | Words present in the compared-to text but not the snapshot (word-level). | |
| wordsRemoved | No | Words present in the snapshot but not the compared-to text (word-level). | |
| addedParagraphs | Yes | Paragraphs present in the compared-to text but not the snapshot. | |
| removedParagraphs | Yes | Paragraphs present in the snapshot but not the compared-to text. | |
| unchangedParagraphs | No | Count of paragraphs common to both. |