July 16th, 2024

Automerge: A library of data structures for building collaborative applications

Automerge is a CRDT library for collaborative apps, enabling conflict-free merging of changes across devices without a central server. It supports multiple network protocols and aims to enhance local-first software development.

Read original articleLink Icon
CollaborationPrivacyComparison
Automerge: A library of data structures for building collaborative applications

Automerge is a Conflict-Free Replicated Data Type (CRDT) library designed for creating collaborative applications. It enables automatic merging of concurrent changes made on different devices without the need for a central server. The library supports various network protocols such as client-server, peer-to-peer, or local connections, as well as unidirectional messaging like sending Automerge files via email or storing them on a file server. Automerge is implemented in JavaScript and Rust, with FFI bindings available for platforms like iOS, Electron, Chrome, Safari, Edge, and Firefox. The library aims to facilitate the development of local-first software by providing a versatile and network-agnostic solution for handling data synchronization in distributed systems.

AI: What people are saying
The comments on the article about Automerge discuss various aspects and applications of the CRDT library.
  • Potential applications in digital audio workstations (DAWs) for collaborative tools.
  • Comparison with Yjs and inquiries about user preferences for local-first software.
  • Privacy benefits of local-first design principles and concerns about centralized server-side storage.
  • Mentions of related projects like Pigeon, which focuses on real-time collaboration.
  • Resources and tools built with Automerge, such as Automerge Jumpstart and IndexedDB integration.
Link Icon 11 comments
By @mkl - 5 months
In practice most projects seem to use Yjs rather than Automerge. Is there an up-to-date comparison of the two? Has anyone here chosen Automerge over Yjs?
By @nik-graf - 5 months
Last week I published Automerge Jumpstart https://www.automerge-jumpstart.com/

A boilerplate including user authentication & authorization

Tech: Automerge, tRPC, Prisma and deployment on fly.io and vercel.com Bonus: includes explanation videos on the website

By @zaphod420 - 5 months
I just recently found out about automerge from this youtube channel. https://www.youtube.com/@localfirstfm

I love the idea of "local first software" https://www.inkandswitch.com/local-first/

By @kennethwolters - 5 months
I am a big fan of local-first design principles. For most enthusiasts, it's the performance benefits. However, for me, it's the potential it has for privacy in web clients.

If you have a web client that only does on-client data storage, you're not dependent on centralized server-side storage for persistence (which is the main privacy-loss hazard).

The problem is that the app host still has all the technological freedom to not honor their privacy agreement, and there don't seem to be backstops to that behavior in browsers.

By @elijahbenizzy - 5 months
I love CRDTs, but it really seems like the type of thing where the idea of them is the real impact (many systems are built with structures that enable CRDT-like operations without actually using CRDTs), and the implementations never quite hit product market fit.
By @amelius - 5 months
Why don't we have programming languages that use this as their fundamental design principle?

It would be great if programs were collaborative out of the box.

By @surfingdino - 5 months
Interesting. IndexedDB + Automerge remind me of CouchDB.
By @ttecho - 5 months
Wondering how this can be used in the digital audio tech space. Collaborative tools in DAWs would be amazing!
By @WolfOliver - 5 months
Any insights/research on what kind of users care / don't care about local first software?
By @montroser - 5 months
See also Pigeon[1], which is inspired by automerge but takes a different approach:

> While Automerge optimizes for working offline and merging changes periodically, Pigeon is optimized for online real-time collaboration.

[1]: https://github.com/frameable/pigeon

By @hpen - 5 months
What type of clock is used by this library?