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 killvxk/pm-skills-zh --skill sql-queriesgit clone --depth 1 https://github.com/killvxk/pm-skills-zhWrote 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/killvxk/pm-skills-zh/sql-queries)<a href="https://agentmods.dev/skills/killvxk/pm-skills-zh/sql-queries"><img src="https://agentmods.dev/badge/skills/killvxk/pm-skills-zh/sql-queries/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/killvxk/pm-skills-zh/sql-queries"><img src="https://agentmods.dev/badge/skills/killvxk/pm-skills-zh/sql-queries.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.00073 | $0.00885 |
| Opus 5.5 | $0.00029 | $0.00354 |
| Sonnet 5.5 | $0.00015 | $0.00177 |
| Haiku 4.5 | $0.00007 | $0.00089 |
Grade A, and why
sql-queries 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.
What it actually says
SQL 查询生成器
用途
将自然语言需求转化为经过优化的 SQL 查询,支持多种数据库平台。帮助产品经理、分析师和工程师准确生成查询语句,无需手动处理语法细节。
工作原理
第一步:理解数据库结构
- 如果你提供了结构文件(SQL、文档或结构图描述),我将读取并分析
- 提取表名、字段定义、数据类型及关联关系
- 识别主键、外键和索引策略
第二步:处理查询需求
- 明确你需要检索或分析的具体数据
- 确认 SQL 方言(BigQuery、PostgreSQL、MySQL、Snowflake 等)
- 询问额外要求(过滤条件、聚合方式、排序规则)
第三步:生成优化查询
- 编写充分利用数据库结构的高效 SQL
- 添加注释,解释复杂逻辑
- 针对大数据集提供性能优化建议
- 如有适用,提供替代实现方案
第四步:解释与测试
- 用通俗语言解释查询逻辑
- 建议如何测试或验证结果
- 提供性能优化技巧
- 如有需要,生成测试脚本或示例数据
使用示例
示例一:基于结构文件生成查询
上传你的 database_schema.sql 文件,并输入:
"生成一个查询,找出过去 30 天内注册且至少有 5 次活跃会话的用户"
示例二:基于结构描述生成查询
"我的数据库结构如下:Users 表(id, email, created_at),Sessions 表
(id, user_id, timestamp, duration)。生成一个查询,
统计 2026 年 1 月每位用户的平均会话时长。"
示例三:复杂分析查询
"创建一个 BigQuery 查询,按地区和客户等级分析营收,
包含同比增长率。"
核心能力
- 多方言支持:兼容 BigQuery、PostgreSQL、MySQL、Snowflake、SQL Server
- 文件读取:读取结构文件、SQL dump 及数据文档
- 查询优化:建议索引、分区及性能改进方案
- 解释说明:拆解查询逻辑,便于学习和文档化
- 测试支持:可生成测试查询和示例数据脚本
- 脚本执行:为你的数据库创建可执行的 SQL 脚本
最佳实践建议
- 提供背景信息:分享你的数据库结构或表结构
- 描述清晰:明确说明你需要的数据及过滤条件
- 注明数据库类型:指定你使用的 SQL 方言
- 说明限制条件:提及数据量、时间范围和性能要求
- 明确输出格式:如需特定格式的查询结果,请提前说明
输出格式
你将收到:
- SQL 查询:带注释的生产可用 SQL 代码
- 说明:查询的功能和运行逻辑
- 性能备注:优化建议和注意事项
- 测试脚本(如有需要):示例数据和验证查询
延伸阅读
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 · 87 lines · 73 tokens per session scan A 2635dfeeb3e8
sql-queries is a skill published in the GitHub repository killvxk/pm-skills-zh (189 stars, last pushed 8mo ago), licensed MIT. It adds 73 tokens to every session and 885 once invoked, about $0.0003 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-30.
sql-queries compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| sql-querieskillvxk/pm-skills-zh | Skill | 189 | 8mo ago | MIT | A | 73 | Claude Code |
| create-prprisma/orm | Skill | 48k | today | Apache-2.0 | A | 47 | Claude Code, Codex |
| schema-explorationlangchain-ai/deepagents | Skill | 32k | today | MIT | A | 57 | Claude Code, Codex |
| atlas-mssqlariga/atlas | Skill | 8.9k | yesterday | Apache-2.0 | A | 163 | Claude Code |
| ha-data-storesshiwenwen/hope-agent | Skill | 1.9k | yesterday | MIT | A | 115 | Claude Code, Codex |
| bex-keyvaluebex-co/bex | Skill | 1.6k | today | Apache-2.0 | A | 117 | Claude Code, Codex |
| pentesting-mysqlxalgorix/xalgorix | Skill | 1.6k | yesterday | Apache-2.0 | A | 65 | Claude Code, Codex |