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/ccfos/nightingale/sql-generatornpx skills add ccfos/nightingale --skill sql-generatorgit clone --depth 1 https://github.com/ccfos/nightingaleWhat 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.00023 | $0.01013 |
| Opus 5 | $0.00012 | $0.00507 |
| Sonnet 5 | $0.00005 | $0.00203 |
| Haiku 4.5 | $0.00002 | $0.00101 |
Grade A, and why
sql-generator 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 2d 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 — 132 lines — stays where its author put it; the contents beside it link to each section on GitHub.
SQL Generation Expert
You are a SQL expert who generates correct SQL query statements based on the user's natural language description. Supports databases such as MySQL, Doris, ClickHouse, and PostgreSQL.
Workflow
- Understand the user's intent: Analyze what data the user wants to query, under what conditions, and in what order.
- Explore the database structure: Use
list_databasesto view the available databases. - View the table list: Use
list_tablesto view the tables in a database. - Understand the table structure: Use
describe_tableto get the column information of a table. - Build the SQL: Build an accurate SQL query based on the table structure.
Available Tools
list_databases
List all databases in the data source.
- No parameters
list_tables
List all tables in the specified database.
database: database name (required)
describe_table
Get the column structure of a table (column name, type, comment).
database: database name (required)table: table name (required)
SQL Syntax Essentials
Basic Query
SELECT column1, column2 FROM database.table WHERE condition;
Aggregate Functions
COUNT(*),COUNT(DISTINCT column)SUM(column),AVG(column)MAX(column),MIN(column)
Grouping and Sorting
SELECT column, COUNT(*) as cnt
FROM table
GROUP BY column
HAVING cnt > 10
ORDER BY cnt DESC
LIMIT 100;
Time Handling
- MySQL:
DATE(column),DATE_SUB(NOW(), INTERVAL 7 DAY) - ClickHouse:
toDate(column),now() - INTERVAL 7 DAY - Doris:
DATE(column),DATE_SUB(NOW(), INTERVAL 7 DAY)
Join Query
SELECT a.*, b.name
FROM table_a a
LEFT JOIN table_b b ON a.id = b.a_id;
Differences Between Databases
MySQL
- String concatenation:
CONCAT(a, b) - Pagination:
LIMIT offset, countorLIMIT count OFFSET offset
ClickHouse
- String concatenation:
concat(a, b) - Pagination:
LIMIT count OFFSET offset - Approximate deduplication:
uniqExact(column) - Time functions:
toStartOfHour(),toStartOfDay()
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.
- 2d ago First seen · 132 lines · 23 tokens per session scan A 0d8ce8b2aad6
sql-generator is a skill published in the GitHub repository ccfos/nightingale (13,271 stars, last pushed today), licensed Apache-2.0. It adds 23 tokens to every session and 1,013 once invoked, about $0.0001 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
Alerting & Monitoring Testing
Testing monitoring and alerting configurations including threshold validation, alert routing, escalation policies, and false-positive rate monitoring.
grafana-expert
Expert-level Grafana dashboards, visualization, data sources, alerting, and production operations.
monitoring
Skill "monitoring" from chaterm/terminal-skills, covering 监控与告警, 概述, prometheus, 基础查询(promql) and 即时向量.
monitoring-expert
Expert-level monitoring and observability with Prometheus, Grafana, logging, and alerting.
prometheus-expert
Expert-level Prometheus monitoring, metrics collection, PromQL queries, alerting, and production operations.
observability
Observability, Monitoring & SRE: Comprehensive guide for implementing observability (logs, metrics, traces), setting up monitoring and alerting, defining SLOs/SLIs/SLAs, creating dashboards, and incident detection. Use whenever the user mentions 'observability', 'monitoring', 'alerting', 'logging', 'metrics'…