sequencer

sequencer is a skill for Claude Code from proyecto26/system-design-skills. It costs 122 tokens per session (2,895 once invoked), scanned A, original, MIT.

A guide for choosing and implementing unique identifiers, such as UUIDs, ULIDs, Snowflake-style IDs, or database-issued ranges, across distributed systems.

In plain words
What is it for?
Use it when records are created on multiple machines, IDs must exist before a database request, or identifiers need to be roughly ordered by creation time.
Why use it?
It helps avoid duplicate records, write bottlenecks, unwanted time or count information in IDs, and unnecessary distributed infrastructure.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the system-design-skills plugin — 22 skills, 1 command, 1 agent shipped together

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.

agentmods
npx agentmods add skills/proyecto26/system-design-skills/sequencer
Any agent
npx skills add proyecto26/system-design-skills --skill sequencer
Clone the repo
git clone --depth 1 https://github.com/proyecto26/system-design-skills

Made for: Claude Code.

Or install system-design-skills, the plugin that ships this one along with the rest of its 22 skills, 1 command, 1 agent.

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 sequencer

README.md
[![agentmods](https://agentmods.dev/badge/skills/proyecto26/system-design-skills/sequencer.svg)](https://agentmods.dev/skills/proyecto26/system-design-skills/sequencer)
Your own site
<a href="https://agentmods.dev/skills/proyecto26/system-design-skills/sequencer"><img src="https://agentmods.dev/badge/skills/proyecto26/system-design-skills/sequencer.svg" alt="Measured on agentmods" height="20"></a>
Per session 122 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,895 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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.00122 $0.02895
Opus 5 $0.00061 $0.01448
Sonnet 5 $0.00024 $0.00579
Haiku 4.5 $0.00012 $0.00290

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

Security

Grade A, and why

sequencer 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 6d 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/sequencer/SKILL.md · 188 lines

How it starts

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

Sequencer

Hand out identifiers that are unique across every node without a central bottleneck — and decide whether those IDs must also be sortable or monotonic. Getting this wrong shows up late and hard: collisions corrupt data, a single allocator caps write throughput, and IDs that leak a creation time or a sequential count expose business secrets and enable enumeration attacks.

When to reach for this

A system writes new records across multiple nodes and each needs a primary key (orders, messages, uploads, events). Reach for this when a single auto-increment column would serialize all writes, when IDs must be generated before a DB round trip (client-side, offline), or when records must be roughly time-ordered without a separate sort field.

When NOT to

A single relational node still comfortably serves the write load (→ back-of-the-envelope) — then a plain BIGINT AUTO_INCREMENT/SERIAL is the cheapest correct answer; do not build a distributed ID service for it (YAGNI). If a natural unique key already exists (email, ISBN, content hash), use it. Don't demand global monotonicity unless an invariant truly needs it — it is the most expensive property here and usually only per-entity ordering is required.

Clarify first

  • Generation point — client/edge, app server, or database? (Decides whether a DB round trip per ID is acceptable.)
  • Ordering need — none, time-sortable (k-sorted is fine), or strictly monotonic? Per-entity or global? This is the single biggest fork.
  • Write rate & node count — IDs/sec at peak and how many generators (→ back-of-the-envelope). Sets the bits needed for a sequence counter.
  • Size & encoding budget — 64-bit int (fits an indexed key cheaply) vs 128-bit (no coordination ever) vs short URL-safe string?
  • Leakage tolerance — may the ID reveal creation time or a guessable count (enumeration / competitor signal)?

The options

  • Auto-increment / SQL sequence — one DB column hands out IDs. Use when a single node owns the writes and you want zero new infrastructure.
  • UUIDv4 (random 128-bit) — generate anywhere, no coordination, effectively zero collision risk. Use when you only need uniqueness and never sort by ID.
  • ULID / UUIDv7 (time-prefixed 128-bit) — random but with a millisecond timestamp prefix, so IDs sort by creation time. Use when you want UUIDv4's zero-coordination and time-ordering (the modern default for new keys).
  • Snowflake-style (timestamp + node + sequence, 64-bit) — pack a timestamp, a node ID, and a per-ms counter into a sortable 64-bit int. Use at high write rates where a compact, k-sorted integer key matters.
  • DB ticket / range allocation (Flickr-style) — a central table hands out blocks of IDs (e.g. 1000 at a time); each node serves from its block in memory. Use when you want simple monotonic-ish integers without per-ID coordination.

Read the full file on GitHub · 188 lines

Files

What ships with it

4 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 6d ago First seen · 188 lines · 122 tokens per session scan A f8c4209748e4

Subscribe to this mod's changes

sequencer is a skill published in the GitHub repository proyecto26/system-design-skills (68 stars, last pushed 3mo ago), licensed MIT. It adds 122 tokens to every session and 2,895 once invoked, about $0.0006 per session on Opus 5. 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-08-30.

Related

Other skills, from other repositories

data-migration

Moves data from one system to another without losing it or corrupting it — profiling the source before mapping, deciding between big-bang and parallel-run cutover, reconciling counts and values rather than assuming, handling the records that will not map cleanly, and planning a rollback that is actually executable.…

cbrock84/headcount · 102 tokens

data-modeling

Designs the warehouse and semantic layer — source-to-mart structure, dimensional modeling, grain, slowly changing dimensions, and the metric layer analytics reads through. Use this to design or restructure a warehouse, model a new source, decide on grain or table structure, build a semantic or metric layer, or…

cbrock84/headcount · 77 tokens

swiftdata-workflow

Design, implement, migrate, test, and integrate SwiftData persistence in Apple apps using current Apple documentation. Use for @Model schemas, ModelContainer and ModelContext ownership, @Query integration, relationships, uniqueness, deletion, concurrency, migrations, preview or test stores, and boundaries between…

gaelic-ghost/socket · 74 tokens

schema-designer

Database schema design agent that creates complete data models with tables, relationships, indexes, and seed data. Triggers on: database design, schema, data model, tables, ERD, entity relationship, database schema.

batterfried-philosophy172/Agent-Startup-Skills · 47 tokens

postgres

Use this skill for any PostgreSQL database work — table design, indexing, data types, constraints, extensions (pgvector, PostGIS, TimescaleDB), search, and migrations. Trigger when user asks to: Design or modify PostgreSQL tables, schemas, or data models Choose data types, constraints, indexes, or partitioning…

timescale/pg-aiguide · 197 tokens

ecto-patterns

Ecto patterns — schemas, changesets, queries, migrations, Multi, associations, preloads, upserts. Use when editing Repo calls, Ecto.Query, or schema fields. Skip for Ash.

oliver-kriska/claude-elixir-phoenix · 45 tokens