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.
npx agentmods add skills/hainrixz/claude-db/db-engine-selectionnpx skills add Hainrixz/claude-db --skill db-engine-selectiongit clone --depth 1 https://github.com/Hainrixz/claude-dbWrote 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.
[](https://agentmods.dev/skills/hainrixz/claude-db/db-engine-selection)<a href="https://agentmods.dev/skills/hainrixz/claude-db/db-engine-selection"><img src="https://agentmods.dev/badge/skills/hainrixz/claude-db/db-engine-selection.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00107 | $0.01092 |
| Opus 5 | $0.00053 | $0.00546 |
| Sonnet 5 | $0.00021 | $0.00218 |
| Haiku 4.5 | $0.00011 | $0.00109 |
Grade A, and why
db-engine-selection 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 5d 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.
How it starts
The opening of the file, as written. The whole thing — 62 lines — stays where its author put it; the contents beside it link to each section on GitHub.
db-engine-selection (M0) — recommend, don't score
M0 runs at design / /claude-db:start time, when there may be no schema yet — only a described
workload. It answers "which database should this be?" It is not a scored module: it emits no
findings, has no axis, no severity, and never enters score.mjs or either of the two scores. Its
output is a separate recommendation contract (below). It walks the decision tree in
references/engine-selection-tree.md.
Inputs it gathers
From the user's description (or detected stack via references/detection-signals.md):
- Access patterns — point lookups by key, range scans, complex multi-entity joins, full-text / semantic search, time-ordered analytics, graph traversal, fan-out reads/writes.
- Consistency & integrity needs — strong/transactional vs eventual; multi-row invariants; need for DB-enforced referential integrity.
- Scale & shape — expected size, write rate, read/write ratio, cardinality, whether data is append-only/time-series, vector/embedding workloads.
- Operability & team — managed vs self-hosted, serverless/edge, existing expertise, platform
constraints (cross-checks
db-platform-fitM21).
How it decides (tree summary; full tree in the reference)
- Relational by default for transactional, multi-entity, integrity-heavy workloads (Postgres as the safe default; MySQL/MariaDB where the ecosystem dictates).
- Document (Mongo/Firestore) when the data is aggregate-oriented, read by one access pattern, and embedding beats joining — and the team accepts app-enforced integrity.
- Key-value (Redis/DynamoDB) for known-key point access, caching, sessions, high-throughput simple ops.
- Wide-column (Cassandra/Scylla) for massive write-heavy, table-per-query, partition-first workloads.
- Vector (pgvector/Qdrant/etc.) for semantic search / RAG — often alongside a primary store, not instead of one.
- Time-series (Timescale/ClickHouse/Influx) for append-only metrics/events with time-range analytics.
- Graph (Neo4j) when traversal depth/relationship queries are the core workload, not an afterthought. Polyglot is a valid answer: name each store and its job. Prefer "Postgres + an extension" (pgvector, JSONB, partitioning, FTS) before adding a second engine, when one engine credibly covers the workload.
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.
- 5d ago First seen · 62 lines · 107 tokens per session scan A 18023cadb5fa
db-engine-selection is a skill published in the GitHub repository Hainrixz/claude-db (19 stars, last pushed 2mo ago), licensed MIT. It adds 107 tokens to every session and 1,092 once invoked, about $0.0005 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.
Other skills, from other repositories
dynamodb
Use when modeling or operating a DynamoDB table: deriving partition/sort keys from access patterns, single-table vs table-per-entity, adding a GSI/LSI, on-demand vs provisioned capacity, or diagnosing hot-partition throttling. NOT relational schema/SQL/EXPLAIN (that is postgresdb), NOT aggregation-pipeline document…
malloy-lookml-review
Analyze LookML files as prior art for Malloy modeling. Used during Step 1 (DISCOVER) when .lkml files are present. Coordinates reference files that extract business logic, relationships, and curation decisions. Works with or without a database connection.
convex-migrations
Schema migration strategies for evolving applications including adding new fields, backfilling data, removing deprecated fields, index migrations, and zero-downtime migration patterns.
database-design-patterns
Database schema design patterns and optimization strategies for relational and NoSQL databases. Use when designing database schemas, optimizing query performance, or implementing data persistence layers at scale.
terrabase-db-changes
Use when making Postgres schema or migration changes (CREATE/ALTER/DROP TABLE, indexes, columns, constraints, backfills) IN A PROJECT THAT DECLARES A TERRABASE TARGET (a TERRABASEDATABASEURL in its .env). Routes the change through terrabase's MCP tools for a deterministic safety analysis plus a local-Qwen plan, and…
erd-studio
Schema rules for ERD Studio data model files — the .erd-studio/ directory uses a two-file system (YAML model definitions + JSON domain diagrams) with strict format rules you must read before editing. Use this skill whenever the task touches files in .erd-studio/ (domain JSON, logical-models YAML, or .sync-plan.json)…