crdts

crdts is a skill for Claude Code, Codex from j4flmao/agent-skills. It costs 0 tokens per session (541 once invoked), scanned A, original, MIT.

A guide to conflict-free replicated data types, or CRDTs: data structures that let copies on different computers accept changes independently and later converge on the same content. It focuses on local-first, peer-to-peer, offline-capable real-time collaboration.

In plain words
What is it for?
Designing collaborative editors and other shared applications where multiple people edit the same data at the same time, using approaches such as Yjs or Automerge.
Why use it?
It addresses the difficulty of keeping simultaneous edits consistent when users may be offline or when there is no single coordinating server.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Designing collaborative editors and other shared applications where multiple people edit the same data at the same time, using approaches such as Yjs or Automerge.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/j4flmao/agent-skills/crdts
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add j4flmao/agent-skills --skill crdts
Clone the repo
git clone --depth 1 https://github.com/j4flmao/agent-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for crdts

README.md
[![agentmods](https://agentmods.dev/badge/skills/j4flmao/agent-skills/crdts/github.svg)](https://agentmods.dev/skills/j4flmao/agent-skills/crdts)
Your own site
<a href="https://agentmods.dev/skills/j4flmao/agent-skills/crdts"><img src="https://agentmods.dev/badge/skills/j4flmao/agent-skills/crdts/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for crdts

Your own site · 80×15
<a href="https://agentmods.dev/skills/j4flmao/agent-skills/crdts"><img src="https://agentmods.dev/badge/skills/j4flmao/agent-skills/crdts.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 541 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.00541
Opus 5 $0.00000 $0.00270
Sonnet 5 $0.00000 $0.00108
Haiku 4.5 $0.00000 $0.00054

Measured 7d ago against content hash fe84b3213e09, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

crdts scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 7d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/architecture/crdts/SKILL.md · 29 lines

How it starts

The opening of the file, as written. The whole thing — 29 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Conflict-free Replicated Data Types (CRDTs)

1. Skill Context

Focus: Building local-first, peer-to-peer, real-time collaborative applications (like Google Docs, Figma, or Notion) where multiple users edit the exact same document simultaneously without locks. Triggers: crdt, real-time-collaboration, yjs, automerge, offline-first.

2. The Legacy Approach: Operational Transformation (OT)

Historically (e.g., early Google Docs), systems used Operational Transformation (OT). If Alice types "A" and Bob types "B", a centralized server intercepts both operations, decides the canonical timeline, transforms the operations, and sends them back.

  • Problem: OT requires a central server and is notoriously difficult to scale. It falls apart in peer-to-peer or offline-first scenarios.

3. The CRDT Paradigm

CRDTs are data structures that can be replicated across multiple computers in a network. They can be updated independently and concurrently without coordination. Mathematical Magic: As long as all peers receive the same set of updates (regardless of the order), they are mathematically guaranteed to converge on the exact same state.

Properties of CRDTs

For operations to merge perfectly regardless of network latency, they must be:

  • Commutative: A + B = B + A (Order doesn't matter).
  • Associative: (A + B) + C = A + (B + C).
  • Idempotent: A + A = A (Receiving the same message twice doesn't break the state).

Common Types

  • G-Counter (Grow-only Counter): Each node has a slot in an array. To increment, it adds 1 to its slot. To merge, you just take the max() of each slot across all peers.
  • LWW-Element-Set (Last Write Wins): Elements carry timestamps. If there is a conflict, the highest timestamp wins.
  • Sequence CRDTs (Text Editing): Instead of saying "Insert 'A' at index 5", elements are assigned fractional IDs (e.g., 'A' is between 0.5 and 0.6). Characters never shift their IDs when other characters are inserted.

4. Architectural Implementation

Modern ecosystems use robust libraries like Yjs or Automerge instead of rolling custom CRDTs. The architecture shifts from standard REST APIs to WebSocket/WebRTC sync engines where the Client holds the source of truth, and the Backend is merely a dumb broadcasting relay and persistence layer.

Read the full file on GitHub · 29 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 7d ago First seen · 29 lines · 0 tokens per session scan A fe84b3213e09

Subscribe to this mod's changes

crdts is a skill published in the GitHub repository j4flmao/agent-skills (23 stars, last pushed 6d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 541 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-05.

Related

Other skills, from other repositories

visual-ralph

Visual Ralph orchestration for frontend UI from generated references, static references, or live URL targets, using $ultragoal with built-in visual verdict and pixel-diff evidence until the implementation matches and leaves a reproducible design system.

Yeachan-Heo/oh-my-codex · 52 tokens

debug-optimize-lcp

Guides debugging and optimizing Largest Contentful Paint (LCP) using Chrome DevTools MCP tools. Use this skill whenever the user asks about LCP performance, slow page loads, Core Web Vitals optimization, or wants to understand why their page's main content takes too long to appear. Also use when the user mentions…

ChromeDevTools/chrome-devtools-mcp · 99 tokens

repro-admin

Reproduce an EmDash admin UI bug. Attach a container, start the demo dev server, drive the admin with agent-browser using the dev-bypass session, and capture the reproduction as screenshots plus a replayable transcript.

emdash-cms/emdash · 48 tokens

create-site

Creates a new Power Pages code site (SPA) using React, Angular, Vue, or Astro. Guides through the full process from initial concept to deployed site: requirements discovery, scaffolding, component planning, design, implementation, validation, and deployment. Use when the user wants to create, build, or scaffold a new…

microsoft/power-platform-skills · 73 tokens

prototype-web

A clickable, high-fidelity web product prototype with navigation, a hero section, feature cards, steps, social proof, and optional pricing. It is designed to resemble a finished landing page while remaining a prototype.

nexu-io/html-anything · 24 tokens

menu-transitions-rtl

Animate react-horizontal-scrolling-menu scrolling and build right-to-left menus: noPolyfill defaults to true since v8, so transitionDuration (default 500), a custom-easing-function transitionBehavior, and per-call ScrollOptions { duration, boundary } on scrollToItem/scrollNext/scrollPrev are silently ignored unless…

asmyshlyaev177/react-horizontal-scrolling-menu · 137 tokens