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 sql-authoringgit 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/sql-authoring)<a href="https://agentmods.dev/skills/kouroshez/coding-os/sql-authoring"><img src="https://agentmods.dev/badge/skills/kouroshez/coding-os/sql-authoring/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/sql-authoring"><img src="https://agentmods.dev/badge/skills/kouroshez/coding-os/sql-authoring.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.00169 | $0.01559 |
| Opus 5.5 | $0.00068 | $0.00624 |
| Sonnet 5.5 | $0.00034 | $0.00312 |
| Haiku 4.5 | $0.00017 | $0.00156 |
Grade A, and why
sql-authoring 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 2mo 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 — 105 lines — stays where its author put it; the contents beside it link to each section on GitHub.
SQL Authoring
A query is correct, fast, and safe — in that order, none optional. Schema and index design belong to db-design; this skill is the query craft: how to express intent so the planner picks an index, how to read the plan when it doesn't, and how to never hand an attacker a string-built statement.
Read an EXPLAIN plan without eyeballing it:
psql -c 'EXPLAIN (ANALYZE, BUFFERS, FORMAT JSON) <query>' | python3 scripts/analyze_plan.py
Always parameterize — no exceptions
# Wrong — SQL injection; one apostrophe in `name` and the query breaks or leaks
cur.execute(f"SELECT * FROM users WHERE name = '{name}'")
# Correct — the driver binds; the value never touches the SQL text
cur.execute("SELECT * FROM users WHERE name = %s", (name,))
String-built SQL is the #1 OWASP injection vector — the server-side rules are owned by security-web. The query-craft rule: values are always bind parameters; only identifiers you control (validated against an allow-list) are ever interpolated. An ORM gives you this for free until you reach for raw() — then it's on you.
Think in sets, not rows
-- Wrong — N+1: one query per order, 1000 orders = 1001 round trips
SELECT id FROM orders WHERE user_id = $1; -- then, per row:
SELECT * FROM line_items WHERE order_id = $1;
-- Correct — one query, the join does the work
SELECT o.id, li.*
FROM orders o
JOIN line_items li ON li.order_id = o.id
WHERE o.user_id = $1;
N+1 is the most common real-world slowness. It hides behind ORM lazy-loading — for order in orders: order.items issues a query per iteration. Fix with a join, a prefetch/selectinload, or an IN (...) batch. Full recipes → references/query-patterns.md.
Index-aware querying (the query's half of the contract)
Index design is db-design's job; using one is yours. A query defeats its own index when it:
- wraps the indexed column in a function:
WHERE lower(email) = $1skips an index onemail(needs an index onlower(email)); - leads with a wildcard:
LIKE '%foo'cannot use a b-tree; - mismatches type:
WHERE id = '42'(text vs int) may force a cast + seq scan; ORs across columns the planner can't combine — often better asUNION.
What ships with it
5 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.
- 2mo ago First seen · 105 lines · 169 tokens per session scan A eecf33a1e897
sql-authoring is a skill published in the GitHub repository kouroshez/coding-os (7 stars, last pushed yesterday), licensed Apache-2.0. It adds 169 tokens to every session and 1,559 once invoked, about $0.0007 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-09-03.
sql-authoring compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| sql-authoringkouroshez/coding-os | Skill | 7 | yesterday | Apache-2.0 | A | 169 | Claude Code |
| omnigraphModernRelay/omnigraph | Skill | 3.4k | today | MIT | A | 107 | Claude Code, Codex |
| fetch-dataagentscope-ai/QwenPaw-Data | Skill | 210 | today | Apache-2.0 | A | 286 | Claude Code, Codex |
| sql-root-cause-analysiszj-unicom-ai/UniEmployee | Skill | 887 | 10d ago | MIT | A | 47 | Claude Code, Codex |
| hugegraph-regression-testerapache/hugegraph-ai | Skill | 150 | today | Apache-2.0 | A | 54 | Codex |
| hugegraph-schema-designerapache/hugegraph-ai | Skill | 150 | today | Apache-2.0 | A | 51 | Codex |
| hugegraph-data-importerapache/hugegraph-ai | Skill | 150 | today | Apache-2.0 | A | 62 | Codex |