kg-database-optimizer

Query and performance optimization tool for PostgreSQL and MySQL, focused on improving database query efficiency and performance.

Installation

Review the source and dependencies with a prompt. A package is available to download.

Install with an AI assistant

Copy the prompt so your assistant can review the pinned revision and dependencies first.

View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "kg-database-optimizer" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-cec76c47724aea20741ac489da052ee3605d8b89bf4c77bb2565b37c7b9eee21. Verify the upstream source and version against https://skillhub.cn/skills/kunlungrowth/kg-database-optimizer before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.

Source and setup

skillhub.cn

Setup guidance pending

See the original source for supported tools, dependencies, and permissions.

Installation test pending

Query and performance optimization tool for PostgreSQL and MySQL, focused on improving database query efficiency and performance.

0 Downloads

Introduction source: third_party · kunlungrowth · 1.0.0 Reference

SkillPi interpretation

Tasks
Translation pending; see source documentation.
Audience
Translation pending; see source documentation.
Inputs and outputs
The output contains two sections: 1) a structured artifact (full content); 2) a natural-language summary and improvement suggestions (quality self-check, the 2-3 most important points to change). The full template (including workflow key points, quality self-check checklist, artifact examples, common pitfalls) is in `references/template.md`.
Testing
Not tested

Browse files

Browse files at the source ↗

Original SKILL.md

Open original ↗
Frontmatter
name: database-optimizer
slug: database-optimizer
version: 1.0.0
displayName: 数据库优化
description: 跨 PostgreSQL/MySQL 优化查询与性能。
category: data
capability: database-optimizer
pricing:
  model: free
  amount_fen: 0
agent_created: true
tags:
  - 数据库
  - 调优
  - 查询

数据库优化

1. 角色与目标

你是数据库优化专家,帮助用户在 PG/MySQL 上定位慢查询、分析执行计划并给出跨引擎优化方案。

2. 何时使用 / 适用对象

  • 排查慢查询、分析执行计划
  • 优化索引与schema
  • 跨 PG/MySQL 给出建议
  • 不适用:特定引擎深度特性用 postgres-pro/sql-pro;不处理 NoSQL 调优。

3. 工作流

步骤1 步骤1 — 收集:慢日志/执行计划、数据分布。 步骤2 步骤2 — 诊断:定位全表扫描、锁、临时表。 步骤3 步骤3 — 优化:索引、重写、参数。 步骤4 步骤4 — 验证:对比前后计划与耗时。 步骤5 步骤5 — 输出工件:返回 DbOptReport。

4. 互操作(I/O)

  • INPUT:用户自然语言描述的需求、约束与(可选)代码片段;可接收结构化 DbOptReport 做二次优化。
  • **OUTPUT(工件类型:DbOptReport):
    • DbOptReport:{engine, slow_queries:[string], fixes:[string], gain:string}
  • 下游消费:下游消费:交 postgres-pro 做 PG 专项。

5. 输出规范

输出包含两段:1) 结构化工件(完整内容);2) 自然语言摘要与改进建议(质量自检、最该改的 2-3 点)。完整模板(含工作流要点、质量自检清单、工件示例、常见陷阱)见 references/template.md。

6. 使用示例

输入:

MySQL 有个查询 2 秒,怎么降到毫秒?

输出(节选): 加复合索引覆盖查询列,避免类型转换,复测降至 30ms。输出工件见下。

{
  "engine": "MySQL",
  "slow_queries": [
    "SELECT without index"
  ],
  "fixes": [
    "add composite idx"
  ],
  "gain": "从 2.1s 到 30ms"
}

Current listing version

1.0.0

Verify the source revision ↗

Quality assessment

Out of 100 · Assessment report from SkillPi LAB.

Scenario Value92/100

Highlights

  • 解决数据库慢查询、执行计划分析、索引优化等高频刚需场景
  • 跨 PostgreSQL/MySQL 提供通用优化方案,受众明确
Trigger Precision88/100

Highlights

  • 触发词精准覆盖慢查询、执行计划、索引优化等核心场景
  • 边界清晰,明确排除 NoSQL 与特定引擎深度特性
Structure and Standards85/100

Highlights

  • 结构完整:角色目标、工作流、I/O、输出规范、示例齐全
  • frontmatter 完整,单文件长度合规
Execution Reliability75/100

Areas to improve

  • Missing referenced files Reported severity: Major

    SKILL.md 引用了 references/template.md 文件,但该文件未传入 ZIP 包

    Recommendation: 请补全 references/template.md 文件或移除引用,确保端到端完整性

Highlights

  • 工具来源(PG/MySQL)明确,参数合理,流程闭环
  • 输出工件 DbOptReport 结构清晰,便于下游消费
Evidence Verifiability (mean of the first four)85/100

The arithmetic mean of the first four original scores, rounded to a whole number.

Static text checks

100 / 100 · skillpi-20261123-no-r3-v1

No current rules matched the text.

This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.

Permissions and checks before use

Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.

These common operations were not identified in the main document. This does not mean no permissions or risks exist.

These notices grant no permissions. Your host tool must still confirm file changes, secrets, external transfers or costs as needed.

Security rating and access scope

safe · Static evidence review; not a runtime safety guarantee.

Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.