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 skills add kouroshez/coding-os --skill db-designgit clone --depth 1 https://github.com/kouroshez/coding-osWrote 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/kouroshez/coding-os/db-design)<a href="https://agentmods.dev/skills/kouroshez/coding-os/db-design"><img src="https://agentmods.dev/badge/skills/kouroshez/coding-os/db-design/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.
<a href="https://agentmods.dev/skills/kouroshez/coding-os/db-design"><img src="https://agentmods.dev/badge/skills/kouroshez/coding-os/db-design.svg" alt="Reviewed on agentmods" width="80" 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.1 | $0.00101 | $0.03526 |
| Opus 5.5 | $0.00040 | $0.01410 |
| Sonnet 5.5 | $0.00020 | $0.00705 |
| Haiku 4.5 | $0.00010 | $0.00353 |
Grade A, and why
db-design 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 3mo 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 — 328 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Database Design — PostgreSQL First
A practical design playbook for the project's stack: PostgreSQL as the system of record, accessed by the Go+Fiber business core and the Python+FastAPI AI adapter, with hexagonal repositories isolating the rest of the codebase from schema specifics.
When to Use This Skill
- Modeling the schema for a new bounded context (orders, users, lessons, payments).
- Adding a column or table that will see growth.
- Choosing PK / FK shapes (UUID? bigint? prefixed string?).
- Designing indexes after seeing query patterns or EXPLAIN output.
- Writing migrations that touch live data (never just on a fresh DB).
- Picking ORM (sqlc / GORM / SQLAlchemy / Drizzle) vs raw SQL for a feature.
- Deciding on soft delete vs hard delete + audit table.
- Evaluating Redis (cache/queue) vs Postgres (LISTEN/NOTIFY, advisory locks) for a side-channel.
Skip when: prototyping with a sqlite that will be thrown away. Use this skill before the throw-away gets promoted.
The Three Rules
- Constraints in the database, not the application.
NOT NULL,CHECK,UNIQUE,FOREIGN KEYenforced by Postgres survive bugs in the app, replays of stale code, and direct DBA fixes. Application-only invariants are constantly violated by accident. - Migrations are forward-only and additive. Never drop a column the same release you stop writing to it. Two-phase: stop writing → wait → drop. See references/migration-discipline.md.
- Your queries determine your indexes, not the other way around. Don't index speculatively; index after you see EXPLAIN output for the queries that matter.
Modeling Choices
Primary Keys
| Style | Pros | Cons | Use when |
|---|---|---|---|
| bigint identity | Compact, sequential, fast B-tree, predictable | Leaks count, predictable, one-DB-only | Internal high-volume tables (audit log, events). |
| UUID v7 (time-ordered) | Globally unique, mergeable, sortable | 16 bytes, slightly bigger indexes | Default for user-visible entities. Postgres 18 has built-in uuidv7(); on 16/17 use pg_uuidv7 extension or app-side. |
| UUID v4 (random) | Globally unique, no info leakage | Index bloat from random insertion order, 4× page splits vs v7 | Avoid for primary keys at scale. Fine for IDs that never get indexed. |
Prefixed text (ord_8h2k4n9d3p7q) |
Self-documenting in logs, debug-friendly | App-side ID generation, slightly larger | Public API surface (Stripe pattern). Pair with a UUID v7 internally if needed. |
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.
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.
- 3mo ago First seen · 328 lines · 101 tokens per session scan A eb565a5ee03a
db-design is a skill published in the GitHub repository kouroshez/coding-os (7 stars, last pushed yesterday), licensed Apache-2.0. It adds 101 tokens to every session and 3,526 once invoked, about $0.0004 per session on Opus 5.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-31.
db-design compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| db-designkouroshez/coding-os | Skill | 7 | yesterday | Apache-2.0 | A | 101 | Claude Code, Codex |
| pg-graphmicrosoft/postgres-skills | Skill | 63 | 10d ago | MIT | A | 57 | Claude Code |
| postgreseSlider/2dph | Skill | 3 | 19d ago | MIT | A | 41 | Claude Code, Codex |
| setup-people-memorymichelgrolet/people-memory-mcp | Skill | 2 | 22d ago | MIT | A | 107 | Claude Code, Codex |
| upgrade-people-memorymichelgrolet/people-memory-mcp | Skill | 2 | 22d ago | MIT | A | 94 | Claude Code, Codex |
| connectorspretensor-ai/pretensor | Skill | 5 | 2mo ago | MIT | A | 0 | Claude Code, Codex |
| alloydb-basicsgoogle/skills | Skill | 25k | today | Apache-2.0 | A | 72 | Claude Code, Codex |