---
title: "onediff docs"
url: https://recursiveai.org/onediff/docs/
description: "Everything about OneDiff 1.0.1: getting started, the text core (diff algorithms, patches, three-way merge), document comparison (the compare model…"
version: "1.0.1"
---

# onediff docs

Everything about OneDiff 1.0.1: getting started, the text core (diff algorithms, patches, three-way merge), document comparison (the compare model, alignment, grouping, change semantics, combine and chains), HTML, PDF and scan output, migrating from DiffPlex and WmlComparer, the measured results with the rows that lose, and building from source.

## Start

- [Getting started](https://recursiveai.org/onediff/docs/getting-started/index.md): Install OneDiff 1.0.1 for .NET 10, diff and merge text, compare two documents into a verified change list, and write a redline as HTML, JSON or PDF. Pure…
- [Overview](https://recursiveai.org/onediff/docs/overview/index.md): What OneDiff is: a text diff core (diff, patches, three-way merge) and document comparison for PDFs and scans, the five 1.0.1 packages, the happy path, the low-level stages, what comes in later releases, and known issues.
- [Samples and redline looks](https://recursiveai.org/onediff/docs/samples/index.md): The runnable code samples (one task per method) are in samples/OneDiff.Samples. This page covers the rendered files and the choice of form.
- [Migrating from DiffPlex](https://recursiveai.org/onediff/docs/migrating-from-diffplex/index.md): This page maps the calls in DiffPlex's README, checked against the public members of DiffPlex 1.9.0, to the RecursiveAI.OneDiff calls that do the same…
- [Migrating from WmlComparer](https://recursiveai.org/onediff/docs/migrating-from-wmlcomparer/index.md): This page maps the calls in the README of Docxodus 15.0.0 (the NuGet package page; it is the maintained descendant of Open-Xml-PowerTools' WmlComparer…

## Text core

- [Diff algorithms](https://recursiveai.org/onediff/docs/diff-algorithms/index.md): Behaviour of MyersDiff, PatienceDiff and HistogramDiff. All three take two ReadOnlySpan of item ids (equal ids are equal items) and return a canonical…
- [Patches](https://recursiveai.org/onediff/docs/patches/index.md): How OneDiff reads, writes and applies unified diffs and diff-match-patch patch text. The code is in src/OneDiff/Patching; every rule below is checked by…
- [Three-way merge](https://recursiveai.org/onediff/docs/merge/index.md): ThreeWayMerge (and Diff.Merge) merge a common ancestor (base) with two descendants (ours, theirs) over any sequence; the text form works on lines. The…
- [Terminal and Markdown output](https://recursiveai.org/onediff/docs/text-output/index.md): Renderers over a line-token TextDiff. Output is a pure function of the diff and the renderer's settings: the same input gives the same bytes on every…

## Document comparison

- [The compare model](https://recursiveai.org/onediff/docs/compare-model/index.md): This note describes the contracts of RecursiveAI.OneDiff.Documents: what a compared document is, how a comparison is built from five stages, and how every…
- [Alignment](https://recursiveai.org/onediff/docs/alignment/index.md): What Stages.Align does, in the order it does it, so that a different implementation (or a person correcting one) can follow the same rules. The result is…
- [In-pair diff and grouping](https://recursiveai.org/onediff/docs/grouping/index.md): How the edits inside a pair of aligned blocks are found, and how they become the changes a reader sees. Everything here is deterministic: the same inputs…
- [Change semantics](https://recursiveai.org/onediff/docs/semantics/index.md): What a change is about, and which changes belong together. Everything here is deterministic and works without a model. Nothing here alters an edit…
- [Combine and version chains](https://recursiveai.org/onediff/docs/combine/index.md): Normative description of Combination, ComparisonChain and ChangeReport in RecursiveAI.OneDiff.Documents (namespace OneDiff.Documents.Combine). The compare…
- [HTML output and Redline](https://recursiveai.org/onediff/docs/output-html/index.md): This note describes what RecursiveAI.OneDiff.Documents writes as HTML, how a page maps back to the comparison it came from, and how adapter packages plug…

## PDF and scans

- [PDF comparison](https://recursiveai.org/onediff/docs/pdf/index.md): How RecursiveAI.OneDiff.Pdf reads a digital PDF into the compare model, and how it marks a comparison on the original pages. Everything stated here is…
- [Scans and images](https://recursiveai.org/onediff/docs/ocr/index.md): How RecursiveAI.OneDiff.Ocr reads a scanned PDF or an image into the compare model, what the possible-OCR-error flag means, and how the scan gold set is…

## Evidence

- [Results](https://recursiveai.org/onediff/docs/results/index.md): The measured results of the 1.0 packages (RecursiveAI.OneDiff, .Documents, .Pdf, .Ocr and the onediff tool): the text core's exact gates, fuzzing and…
- [How it is measured](https://recursiveai.org/onediff/docs/measurement/index.md): How the exactness gates and the speed rows are reproduced. Everything here is tooling: it lives in tools/ and bench/, nothing in it ships in a package…

## Reference

- [Building from source](https://recursiveai.org/onediff/docs/building/index.md): The SDK version is pinned in global.json. Build output goes outside the checkout: set ONEDIFF_ARTIFACTS to choose the folder. Without it, output goes to…
- [Changelog](https://recursiveai.org/onediff/docs/changelog/index.md): What changed in each OneDiff release, from the first preview to 1.0.0, the first stable release of the text core, .Documents, .Pdf, .Ocr and the onediff tool, and 1.0.1, which fixes the Office-file messages and the labels in redlines.
