Agent skill

System Design

by wondelai in wondelai/skills

Design scalable distributed systems using structured approaches for load balancing, caching, database scaling, and message queues.

MITAuto-check passedBackend & APIs

Install System Design

skills CLI
$ npx skills add wondelai/skills --skill system-design -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install wondelai/skills system-design --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/wondelai/skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/system-design .claude/skills/system-design && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
system-design
GitHub stars
2.4k
Token cost
~4k tokens
SKILL.md length
1,877 words
Files
7 (incl. references)
Skills in repo
62
Repo updated
First seen
Licence
MIT

At a glance

Design scalable distributed systems using structured approaches for load balancing, caching, database scaling, and message queues.

  • Works in 6 steps: The Four-Step Process → Back-of-the-Envelope Estimation → Building Blocks → …
  • The user mentions system design
  • SKILL.md covers Core Principle, Scoring, The System Design Framework and Common Mistakes, plus 3 more sections
  • Reaches short.ly

What it does

System Design is an agent skill from wondelai/skills. Design scalable distributed systems using structured approaches for load balancing, caching, database scaling, and message queues. Use when the user mentions "system design", "scale this", "high availability", "rate limiter", "design a URL shortener", "design Twitter", "design Uber", "design a news feed", "system design interview", "capacity planning", or "distributed architecture". Also trigger when estimating infrastructure requirements, choosing between microservices and monoliths, or designing for millions of…

Its SKILL.md is about 4k tokens, which your agent loads only when the skill is triggered. The skill folder holds 7 other files, including reference files (for example `references/building-blocks.md`, `references/common-designs.md` and `references/database-scaling.md`).

It sits in Backend & APIs, covering Microservices, Software architecture and Cloud networking. It works with X (Twitter). The repository describes itself as: Wondel.ai Agent Skills — Business, Marketing, UX & Coding Frameworks from Bestselling Books. 50 skills + 12 guided journeys for Claude Code, Codex, Cursor & other agentskills.io… The licence is MIT.

When your agent uses it

  • The user mentions system design
  • High availability
  • Design a URL shortener
  • Design a news feed

Example prompts

  • “system design”
  • “scale this”
  • “high availability”
  • “/system-design”

Workflow steps

6 steps, taken from the step headings in SKILL.md.

  1. The Four-Step Process
  2. Back-of-the-Envelope Estimation
  3. Building Blocks
  4. Database Design and Scaling
  5. Common System Designs
  6. Reliability and Operations

What it can do on your machine

Read from SKILL.md and the folder at commit c172996. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md.

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Hosts in commands or code, which the agent is likely to contact:

    • short.ly

    Also links to:

    • amazon.com
    • bytebytego.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

System Design loads about 4k tokens when it runs, and up to ~21k if it reads all its reference files. Until then it costs about 178 tokens; SKILL.md has 1,877 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~178
When it runs · the whole SKILL.md, loaded when a task matches
~4k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~21k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from wondelai/skills at commit c172996, republished under its MIT licence (© wondelai). 1,877 words, ~4,001 tokens.

Download SKILL.mdSave it as .claude/skills/system-design/SKILL.md (or your agent's skills folder). This skill also uses 6 other files; get the full folder from GitHub.
name
system-design
description
Design scalable distributed systems using structured approaches for load balancing, caching, database scaling, and message queues. Use when the user mentions "system design", "scale this", "high availability", "rate limiter", "design a URL shortener", "design Twitter", "design Uber", "design a news feed", "system design interview", "capacity planning", or "distributed architecture". Also trigger when estimating infrastructure requirements, choosing between microservices and monoliths, or designing for millions of concurrent users. Covers common system designs (TinyURL, feeds, chat) and back-of-the-envelope estimation. For data fundamentals, see ddia-systems. For resilience, see release-it.
license
MIT
metadata.author
wondelai
metadata.version
1.4.1

System Design Framework

A structured approach to designing large-scale distributed systems. Apply these principles when architecting new services, reviewing designs, estimating capacity, or preparing for system design discussions.

Core Principle

Start with requirements, not solutions. Jumping to architecture before understanding constraints produces over- or under-engineered systems. Scalable systems are assembled from well-understood building blocks (load balancers, caches, queues, databases, CDNs) — the skill lies in choosing the right blocks, sizing them with estimates, and owning the tradeoffs each choice introduces.

Scoring

Goal: 10/10. Score a design by how many of the eight Quick Diagnostic rows it satisfies — score = round(passed / 8 × 10): 9-10 = all/nearly all rows pass — explicit requirements, real estimates, redundancy, a stated DB-scaling and caching strategy, async via queues, monitoring, and a deployment plan, with tradeoffs named; 5-6 = the design works but skips estimation, redundancy, or operations; <=3 = architecture proposed before requirements or estimates exist. Always state the current score, name the failing diagnostic rows, and give the specific fix for each.

The System Design Framework

Six areas for building reliable, scalable distributed systems:

1. The Four-Step Process

Core concept: Every design follows four stages: (1) understand the problem and establish scope, (2) propose a high-level design and get buy-in, (3) dive deep into critical components, (4) wrap up with tradeoffs and future improvements.

Why it works: Without structure, designs either stay too abstract or get lost in premature detail. The four steps invest time proportionally — broad strokes first, depth where it matters.

Key insights:

  • Step 1 (~5-10 min): clarifying questions, functional and non-functional requirements, agreed scale (DAU, QPS, storage)
  • Step 2 (~15-20 min): high-level diagram with APIs, services, data stores, data flow arrows
  • Step 3 (~15-20 min): design the 2-3 hardest or most critical components in detail
  • Step 4 (~5 min): tradeoffs, bottlenecks, future improvements
  • Never skip Step 1 — ambiguous scope wastes all downstream effort; get explicit agreement on assumptions

Code applications:

ContextPatternExample
New service kickoffOne-page design doc covering all four steps before codingRequirements, API contract, data model, capacity estimate, then implementation
Architecture reviewWalk reviewers through the steps sequentiallyScope, diagram, deep-dive on riskiest component, open questions
Incident postmortemTrace the failure through the four-step lensWhich requirement was missed? Which block failed? What tradeoff bit us?

See references/four-step-process.md when running a design end-to-end — per-stage time allocation, example clarifying questions, and tips for each of the four steps.

2. Back-of-the-Envelope Estimation

Core concept: Use powers of two, latency numbers, and simple arithmetic to estimate QPS, storage, bandwidth, and server count before committing to an architecture.

Why it works: Estimation prevents over-provisioning (wasted money) and under-provisioning (outages under load). A 2-minute calculation can save weeks of rework.

Key insights:

  • Powers of two: 2^10 ≈ 1 thousand, 2^20 ≈ 1 million, 2^30 ≈ 1 billion, 2^40 ≈ 1 trillion
  • Latency: memory read ~100 ns, SSD read ~100 us, disk seek ~10 ms, same-datacenter round trip ~0.5 ms, cross-continent ~150 ms
  • Availability nines: 99.9% = 8.77 hours downtime/year; 99.99% = 52.6 minutes/year
  • QPS: DAU x actions-per-day / 86,400 seconds; peak is typically 2-5x average
  • Storage: records-per-day x record-size x retention
  • Round aggressively — the goal is order of magnitude, not precision

Code applications:

ContextPatternExample
Capacity planningEstimate QPS, multiply by growth factor100M DAU x 5 actions / 86400 = ~5,800 QPS avg, ~30K peak
Storage budgetingPer-record size x volume x retention500M tweets/day x 300 bytes x 365 days = ~55 TB/year
SLA definitionConvert nines to allowed downtimeFour nines = ~52 minutes downtime per year

See references/estimation-numbers.md when sizing a system — full latency table, availability-nines table, and worked QPS/storage/bandwidth calculations.

3. Building Blocks

Core concept: Scalable systems are assembled from a standard toolkit: DNS, CDN, load balancers, reverse proxies, application servers, caches, message queues, and consistent hashing.

Why it works: Each block trades one cost for another (a cache trades freshness for read speed; a queue trades latency for decoupling), so introduce a block only once its specific bottleneck appears — adding all of them up front just multiplies failure modes.

Key insights:

  • Load balancers: L4 (transport layer — fast, simple) vs L7 (application layer — content-aware routing)
  • Cache layers: client, CDN, web server, application (Redis/Memcached), database query cache
  • Cache strategies: cache-aside (app manages), read-through, write-through (synchronous), write-behind (asynchronous)
  • Message queues (Kafka, RabbitMQ, SQS): decouple producers from consumers, absorb spikes, enable async processing
  • Consistent hashing: distributes keys across nodes with minimal redistribution when nodes change

Code applications:

ContextPatternExample
Read-heavy workloadCache-aside Redis in front of databaseCache user profiles with TTL; invalidate on write
Traffic spikesMessage queue between API and workersEnqueue image-resize jobs; workers pull at their own pace
Global usersCDN for static assetsServe JS/CSS/images from edge; origin serves only API
Uneven loadConsistent hashing for shard assignmentAdding a node moves only ~1/n keys

See references/building-blocks.md when choosing components — how each of DNS, CDN, load balancers, caching strategies, message queues, and consistent hashing works and when to introduce it.

4. Database Design and Scaling

Core concept: Choose SQL vs NoSQL based on data shape and access patterns; scale vertically first, then horizontally (replication and sharding) when vertical limits are reached.

Why it works: The database is usually the first bottleneck. Understanding replication, sharding, and denormalization tradeoffs delays expensive re-architectures and makes growth deliberate.

Key insights:

  • Vertical scaling is simpler but has a ceiling; horizontal is harder but nearly unlimited
  • Replication: leader-follower (one writer, many readers) for read-heavy; multi-leader for multi-region writes
  • Sharding: hash-based (even distribution, hard range queries), range-based (easy ranges, hotspot risk), directory-based (flexible, extra lookup)
  • SQL for ACID transactions, joins, defined schema; NoSQL for flexible schema, horizontal scale, very high write throughput
  • Denormalization trades storage and write complexity for read speed — use when reads dominate and data changes rarely
  • Celebrity/hotspot problem: one hot shard needs secondary partitioning or a cache layer

Code applications:

ContextPatternExample
Read-heavy APILeader-follower with read replicasReads to replicas, writes to leader; accept slight lag
User data at scaleHash-based sharding on user_idhash(user_id) % num_shards; even, independent shards
Analytics dashboardDenormalized materialized viewsPre-join and aggregate nightly; serve from materialized table

See references/database-scaling.md when the database is the bottleneck — replication topologies, the three sharding strategies compared, denormalization tradeoffs, and a SQL-vs-NoSQL selection guide.

Show full SKILL.md (855 more words)Show less
5. Common System Designs

Core concept: Most systems are variations of a small set of well-known designs: URL shortener, rate limiter, notification system, news feed, chat, search autocomplete, web crawler, unique ID generator.

Why it works: A mental library of known designs lets you recognize which pattern a new problem resembles and adapt it, rather than inventing from scratch.

Key insights:

  • URL shortener: base62 encoding, key-value store, 301 vs 302 redirect tradeoff (caching vs analytics)
  • Rate limiter: token bucket or sliding window at the gateway; return 429 with Retry-After
  • News feed: fanout-on-write (push at post time) vs fanout-on-read (pull at read time); hybrid for celebrities
  • Chat: WebSocket for real-time bidirectional messages, queue for delivery guarantees, heartbeat presence service
  • Autocomplete: trie of top-k frequent queries; precompute and cache popular prefixes
  • Web crawler: BFS with URL frontier, politeness (robots.txt, per-domain rate limit), dedup via content hash
  • Unique IDs: UUID (simple, no coordination) vs Snowflake (64-bit, time-sortable, datacenter-aware)

Code applications:

ContextPatternExample
Short link serviceBase62-encode auto-increment ID or hashhttps://short.ly/a1B2c3 maps to a key-value row
API protectionToken bucket at gateway100 tokens/min per key; steady refill; reject with 429
Social feedHybrid fanoutPrecompute feeds for <10K-follower accounts; merge celebrity posts at read time

See references/common-designs.md when a problem resembles a known design — full walkthroughs of URL shortener, rate limiter, news feed, chat, autocomplete, web crawler, and unique ID generator.

6. Reliability and Operations

Core concept: A system is only as good as its ability to stay up, recover, and be observed. Health checks, monitoring, logging, and deployment strategies are first-class design concerns, not afterthoughts.

Why it works: Production systems fail in ways diagrams never predict. Operational readiness — metrics, alerts, rollback plans, redundancy — determines whether a failure is a blip or an outage.

Key insights:

  • Health checks: liveness (is the process alive?) and readiness (can it serve traffic?) — Kubernetes uses both
  • Three pillars of observability: metrics (Prometheus, Datadog), logging (ELK, CloudWatch), tracing (Jaeger, Zipkin)
  • Deployments: rolling (gradual), blue-green (instant switch between identical environments), canary (small percentage first)
  • Disaster recovery: RPO (acceptable data loss) and RTO (acceptable recovery time) drive backup and failover strategy
  • Multi-datacenter: active-passive (failover) or active-active (requires data sync and conflict resolution)
  • Autoscaling: scale on CPU, memory, queue depth, or custom metrics; always set min and max counts

Code applications:

ContextPatternExample
Zero-downtime deployBlue-green with health check gatesSwitch to green after checks pass; keep blue as instant rollback
Gradual rolloutCanary with metric comparison5% traffic to new version; compare errors and latency; promote or rollback
Data safetyDefine RPO/RTO, implement accordinglyRPO 1 hour = hourly backups; RTO 5 min = automated failover

See references/reliability-operations.md when hardening for production — health-check patterns, the observability pillars, deployment strategies, disaster-recovery (RPO/RTO), and autoscaling.

Common Mistakes

MistakeWhy It FailsFix
Architecture before requirementsSolves the wrong problem, misses constraintsSpend the first 5-10 minutes on scope: features, scale, SLA
No estimationProvisioning off by orders of magnitudeEstimate QPS, storage, bandwidth before choosing components
Single point of failureOne component takes down the systemRedundancy at every layer: multi-server, multi-AZ, multi-region
Premature shardingHuge operational complexity before it's neededVertical first, read replicas, cache aggressively, shard last
Caching without invalidationStale data causes bugs and confusionDefine TTL; cache-aside with explicit invalidation on writes
Synchronous calls everywhereOne slow service cascades latency to all callersQueues for non-latency-critical paths; timeouts on sync calls
Ignoring hotspotsOne shard or key hammered, others idleDetect hot keys; add secondary partitioning or local caches
No monitoring or alertingUsers find failures before you doInstrument metrics, logs, and traces from day one

Quick Diagnostic

QuestionIf NoAction
Are functional and non-functional requirements listed?Design rests on assumptionsWrite down features, DAU, QPS, storage, latency and availability SLAs
Is there a QPS and storage estimate?Capacity is a guessDAU x actions / 86400 for QPS; records x size x retention for storage
Is every component redundant?Single points of failureAdd replicas, failover, or multi-AZ per component
Is the database scaling strategy defined?You hit a wall under growthVertical first, then read replicas, then sharding with a clear shard key
Is there a cache for read-heavy paths?Database takes unnecessary loadRedis/Memcached cache-aside with defined TTL
Are async paths using queues?Tight coupling, cascading failuresDecouple with Kafka/SQS for jobs, notifications, analytics
Is there a monitoring and alerting plan?Blind to production failuresDefine metrics, log aggregation, tracing, alert thresholds
Is the deployment strategy defined?Risky all-at-once releasesRolling, blue-green, or canary with automated rollback

Further Reading

For the complete guides with detailed diagrams and walkthroughs:

About the Author

Alex Xu is a software engineer who previously worked at Twitter, Apple, and Oracle, and the creator of ByteByteGo. His two-volume System Design Interview series, with over 500,000 copies sold, turned system design into a learnable, repeatable skill through structured thinking, estimation, and clear communication.

© wondelai, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 6 other files (references) in system-design of wondelai/skills.

  • SKILL.md
  • references/building-blocks.md
  • references/common-designs.md
  • references/database-scaling.md
  • references/estimation-numbers.md
  • references/four-step-process.md
  • references/reliability-operations.md

Open the folder on GitHubat commit c172996

Compare with similar skills

System Design next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

System Design compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
System Design this skillwondelai/skills2.4k—~4kAutomated safety check: PassMIT
System Designninehills/skills280—~4.7kAutomated safety check: PassMIT
System Design Building BlocksHoangNguyen0403/agent-skills-standard571—~970Automated safety check: PassMIT
LLM Gatewaysickn33/agentic-awesome-skills47k1 repos~2.1kAutomated safety check: PassMIT
Cloudfrontaws/agent-toolkit-for-aws2.8k—~1.3kAutomated safety check: PassApache-2.0
AWS Networkingaws/agent-toolkit-for-aws2.8k—~2.9kAutomated safety check: PassApache-2.0

Similar skills

  • System Design

    ninehills/skills

    Design scalable distributed systems using structured approaches for load balancing, caching, database scaling, and message queues.

    280 GitHub stars~4.7k tokensUpdated 3 mo ago
    Backend & APIsAuto-check passed
  • System Design Building Blocks

    HoangNguyen0403/agent-skills-standard

    Select infrastructure components by the constraint each removes: load balancers, caches and invalidation, queues and pub/sub, CDN, API gateway, rate limiting, consistent hashing.

    571 GitHub stars~970 tokensUpdated today
    Backend & APIsAuto-check passed
  • LLM Gateway

    sickn33/agentic-awesome-skills

    Deploy an API gateway for LLM traffic with load balancing, rate limiting, key management, semantic caching, fallback routing, and cost tracking.

    47k GitHub starsUsed in 1 repo~2.1k tokens
    Backend & APIsAuto-check passed
  • Cloudfront

    aws/agent-toolkit-for-aws

    Official

    Configures Amazon CloudFront content delivery across six workflows: when to use CloudFront and how it fits with AWS WAF, Shield, CloudFront Functions, Lambda@Edge, Route 53, and origins (creating a…

    2.8k GitHub stars~1.3k tokensUpdated today
    Backend & APIsAuto-check passed
  • AWS Networking

    aws/agent-toolkit-for-aws

    Official

    Routes AWS networking requests to the correct service skill for implementation.

    2.8k GitHub stars~2.9k tokensUpdated today
    Backend & APIsAuto-check passed
  • NestJS Modular Monolith Architect

    tech-leads-club/agent-skills

    Designs scalable NestJS modular monoliths with domain-driven design, Clean Architecture layers and optional CQRS, defining bounded contexts and strict module boundaries.

    7k GitHub stars~3.9k tokensUpdated yesterday
    Backend & APIsAuto-check passed

More from wondelai/skills

All 62 skills in this repo
  • Crossing The Chasm

    wondelai/skills

    Navigate the technology adoption lifecycle from early adopters to mainstream market.

    2.4k GitHub stars~3.6k tokensUpdated 29 days ago
    Auto-check passed
  • Design Everyday Things

    wondelai/skills

    Apply foundational design principles: affordances, signifiers, constraints, feedback, and conceptual models.

    2.4k GitHub stars~4k tokensUpdated 29 days ago
    Auto-check passed
  • Design Sprint

    wondelai/skills

    Run a structured 5-day process to prototype, test, and validate product ideas with real users.

    2.4k GitHub stars~3.8k tokensUpdated 29 days ago
    Auto-check passed
  • Hooked UX

    wondelai/skills

    Design habit-forming product loops using the Hook Model (Trigger, Action, Variable Reward, Investment).

    2.4k GitHub stars~3.5k tokensUpdated 29 days ago
    Auto-check passed
  • Improve Retention

    wondelai/skills

    Diagnose and fix retention problems using behavior design (B=MAP).

    2.4k GitHub stars~3.8k tokensUpdated 29 days ago
    Auto-check passed
  • Monetizing Innovation

    wondelai/skills

    Design products and pricing around validated willingness to pay, from Ramanujam & Tacke's "Monetizing Innovation".

    2.4k GitHub stars~5.2k tokensUpdated 29 days ago
    Auto-check passed

Works with

Questions about System Design

What does System Design do?

Design scalable distributed systems using structured approaches for load balancing, caching, database scaling, and message queues. System Design is an agent skill from wondelai/skills. Design scalable distributed systems using structured approaches for load balancing, caching, database scaling, and message queues.

When should I use System Design?

System Design fits situations like: the user mentions system design; high availability; design a URL shortener; design a news feed.

How do I install System Design in Claude Code?

Run `npx skills add wondelai/skills --skill system-design -a claude-code`. Or copy the skill folder (system-design in wondelai/skills) into .claude/skills/system-design in your project. Claude Code loads it when a task matches its description.

How do I install System Design in Codex?

Run `npx skills add wondelai/skills --skill system-design -a codex`. Or copy the skill folder (system-design in wondelai/skills) into .agents/skills/system-design in your project. Codex loads it when a task matches its description.

Can I use System Design in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add wondelai/skills --skill system-design -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/system-design, .gemini/skills/system-design, .github/skills/system-design and .opencode/skills/system-design in your project.

What does System Design need to run?

SKILL.md names no scripts, command-line tools or credentials: System Design is instructions for the agent only.

Does System Design access the network?

SKILL.md names 3 domains. In commands or code: short.ly; the agent is likely to contact it when it follows the instructions. As links in the text: amazon.com and bytebytego.com. This is read from the text; nothing was executed.

Is System Design safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does System Design use?

System Design is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does System Design use?

About 4k tokens (SKILL.md is roughly 16k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 17k tokens, read only when the agent opens those files.

What are the alternatives to System Design?

Skills that share tags, products or a category with System Design: System Design (ninehills/skills, 280 stars), System Design Building Blocks (HoangNguyen0403/agent-skills-standard, 571 stars), LLM Gateway (sickn33/agentic-awesome-skills, 47k stars) and Cloudfront (aws/agent-toolkit-for-aws, 2.8k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains System Design?

wondelai (a GitHub organization) maintains it in wondelai/skills, which has 2,362 GitHub stars. The repository holds 62 skills in this directory. The repository was last updated on September 10, 2026.

Source: wondelai/skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.