Herdr UI
Herdr의 TUI가 뛰어나며, 창을 통해 추가되는 기능
Automerge CRDT 병합이 어떻게 이루어졌는지 설명하고, 적용 순서를 무작위로 테스트해 수렴 위반을 찾아냅니다
Explains why an Automerge CRDT merge resolved the way it did, and empirically fuzzes application order to catch convergence violations.
개발 도구TypeScriptGitHub @jayblast-spec온라인운영자 미확인
써 보셨어요? 한 번만 눌러 주세요. 로그인은 필요 없어요.
개인 계정의 공개 저장소 소유자는 GitHub로 로그인해 운영자를 확인하고 소개를 직접 관리할 수 있습니다. 관리자 승인은 필요하지 않습니다.
로그인한 뒤 확인 파일을 만들어 이 저장소의 기본 브랜치에 30분 안에 커밋해 주세요. 다른 브랜치나 포크의 파일은 인정하지 않습니다. 파일을 올린 뒤 아래에서 확인하면 관리자 승인 없이 관리할 수 있습니다. 자격을 유지하려면 파일을 남겨 두세요.
로그인이 필요하면 로그인 화면으로 이동합니다. 로그인 후 이곳으로 돌아와 원하는 확인 버튼을 다시 눌러 주세요.
프로젝트 폴더에서 /nomorevibe verify를 실행하면 소유권을 확인하고 소개를 직접 관리할 수 있습니다.
1분 만에 확인하기Explains why an Automerge CRDT merge resolved the way it did, and fuzzes application order to catch convergence violations.
저장소 README에서 가져옴
README 전체를 불러오는 중입니다. 아래는 저장된 발췌입니다.
Explains why an Automerge CRDT merge resolved the way it did, and empirically fuzzes application order to catch convergence violations — the debugging tooling local-first frameworks are missing.README 전문 보기 ↗Explains why an Automerge CRDT merge resolved the way it did, and empirically fuzzes application order to catch convergence violations — the debugging tooling local-first frameworks are missing.
Local-first / CRDT tooling matured fast through 2026 — mature libraries (Automerge, Yjs, Loro), production sync engines (PowerSync, ElectricSQL, Zero). But the debugging side lagged behind on purpose: CRDTs guarantee your data converges, not that you can see why it converged to what it did. When two replicas edit the same field concurrently, Automerge deterministically resolves the conflict — but today the only way to know a conflict even happened is to manually call getConflicts() at the exact path where you suspect one, and there's no tooling that walks a whole document for you, and nothing that verifies the underlying convergence guarantee actually held for a given set of changes.
Three independent, composable pieces of Automerge tooling:
getCausalHistory(doc)Every change in the document's full history, topologically sorted by its deps so causality is always visible — not just whatever order the underlying store happens to return.
explainConflicts(doc)Recursively walks the entire document (not just one path you already suspect), and for every key with a live conflict reports every candidate value, which actor wrote it, and which one automerge currently presents — so a conflict isn't just "detected," it's explained.
checkConvergence(changes, options)The one thing a CRDT promises is that applying the same changes in any order produces the same final state. This applies a flat set of changes (gathered from any number of diverged replicas) in many random orders and asserts they all converge to identical heads. If they don't, that's a real bug — almost always non-deterministic or side-effecting code inside a change() callback, which Automerge itself has no way to catch for you. Runs are seeded, so a failure is reproducible.
historyToMermaid(history) / conflictsToMermaid(reports)A JSON array of changes is not how a person actually wants to look at a merge history. These render getCausalHistory and explainConflicts output as Mermaid diagrams — paste the output into a ```mermaid fenced block anywhere that renders Markdown (GitHub does this natively, no library needed) and get an actual picture instead of a wall of hashes.
For the classic concurrent-edit scenario from Automerge's own docs (two actors both rename the same pet), the conflict graph looks like this:
graph TD
classDef won fill:#1a7f37,stroke:#116329,color:#fff
classDef lost fill:#cf222e,stroke:#82071e,color:#fff
path0["pets.0.name"]
path0_e0[""Babe"\n(aaaaaaaa)"]
path0 --> path0_e0
class path0_e0 lost
path0_e1[""Beethoven"\n(bbbbbbbb)"]
path0 --> path0_e1
class path0_e1 won
npm install automerge-lens @automerge/automerge
import * as Automerge from "@automerge/automerge";
import { getCausalHistory, explainConflicts, checkConvergence } from "automerge-lens";
const merged = Automerge.merge(doc1, doc2);
for (const report of explainConflicts(merged)) {
console.log(`Conflict at ${report.path.join(".")}`);
for (const entry of report.entries) {
console.log(` ${entry.isCurrentValue ? "WON " : "lost"} "${entry.value}" (actor ${entry.actor})`);
}
}
const result = checkConvergence([...Automerge.getAllChanges(doc1), ...Automerge.getAllChanges(doc2)]);
if (!result.converged) throw new Error("convergence violated -- see result.divergence");
Run the annotated demo (the exact conflict scenario from Automerge's own docs, explained):
npx tsx examples/demo.ts
getConflicts, getAllChanges, decodeChange) actually usable for whole-document debugging, not a reimplementation of them.getConflicts-equivalent API in the same shape); a v2 direction, not silently half-supported here.historyToMermaid/conflictsToMermaid produce Mermaid source you render (GitHub, most Markdown/docs tools do this for free); a live, clickable, in-browser visualizer is a natural next step, not v1 scope.npm install
npm run typecheck
npm test
npm run build
MIT
This is one of 8 independent open-source infrastructure tools, each built against a real, researched gap:
Built by ArkNet Digital.