CtrlK
BlogDocsLog inGet started
Tessl Logo

sql-optimization-patterns

Master SQL query optimization, indexing strategies, and EXPLAIN analysis to dramatically improve database performance and eliminate slow queries. Use when debugging slow queries, designing database schemas, or optimizing application performance.

85

0.98x
Quality

80%

Does it follow best practices?

Impact

93%

0.98x

Average score across 3 eval scenarios

SecuritybySnyk

Passed

No findings from the security scan

The canonical home for this skill is sql-optimization-patterns in wshobson/agents

SKILL.md
Quality
Evals
Security

Quality

Content

61%Weight 40%Scale 1-5

Reviews the quality of instructions and guidance provided to agents. Good implementation is clear, handles edge cases, and produces reliable results.

The content is highly actionable with strong copy-paste SQL examples, but it is a verbose monolithic reference rather than an overview pointing to deeper materials, and it lacks validation checkpoints for its batch/destructive operations. The 'Resources' section advertises bundle files that do not exist, which both misleads navigation and breaks progressive disclosure.

Suggestions

Trim or externalize the foundational exposition (EXPLAIN metric definitions, index-type primer, basic JOIN rewriting) into reference files so SKILL.md stays a lean overview of patterns; assume Claude already knows SQL fundamentals.

Add explicit validation/verification steps for batch and destructive operations — e.g. wrap batch UPDATE/DELETE in BEGIN/ROLLBACK-with-checks, run EXPLAIN ANALYZE before and after, and warn before VACUUM FULL/REINDEX on production tables.

Either ship the seven referenced bundle files (references/*, assets/*, scripts/*) or remove the broken 'Resources' links; currently every listed path points to a non-existent file.

DimensionReasoningScore

Conciseness

The 510-line body extensively catalogs SQL syntax and concepts Claude already knows (EXPLAIN flags, index types, B-Tree vs Hash vs GIN, basic JOIN rewriting), with long inline code blocks that re-teach fundamentals; while accurate it is noticeably padded with material that does not earn its context tokens, fitting the 3-anchor 'mostly efficient but includes some unnecessary explanation'.

3 / 5

Actionability

Every pattern is backed by copy-paste-ready, executable SQL (and Python) examples with bad/good/better variants — e.g. CREATE INDEX statements, EXPLAIN ANALYZE queries, cursor-pagination SQL — covering the common cases concretely, matching the 5-anchor 'fully executable; copy-paste ready'.

5 / 5

Workflow Clarity

The skill is organized as a reference catalog of patterns rather than a sequenced workflow, and critically lacks validation/verification checkpoints for destructive and batch operations (batch UPDATE/DELETE, DROP/REINDEX, VACUUM FULL which 'locks table'); per the rubric's batch/destructive rule this caps workflow_clarity at 3 even though individual patterns are clear.

3 / 5

Progressive Disclosure

The body inlines ~500 lines of API/syntax reference that belongs in separate files, and the 'Resources' section lists 7 bundle paths (references/postgres-optimization-guide.md, assets/index-strategy-checklist.md, scripts/analyze-slow-queries.sql, etc.) none of which actually exist in the bundle — buried, unverified references with content inlined rather than split, matching the 2-anchor.

2 / 5

Total

13

/

20

Passed

Description

100%Weight 40%Scale 1-5

Based on the skill's description, can an agent find and select it at the right time? Clear, specific descriptions lead to better discovery.

The description is exemplary: it states concrete capabilities and pairs them with explicit, natural 'Use when' trigger phrases covering the right scenarios. It is concise, third-person, and highly distinct from other skills. No changes needed.

DimensionReasoningScore

Specificity

Lists multiple concrete actions — 'query optimization, indexing strategies, and EXPLAIN analysis' to 'improve database performance and eliminate slow queries' — giving comprehensive coverage of what the skill does, matching the 5-anchor example that enumerates several specific actions.

5 / 5

Completeness

Explicitly answers both 'what' ('Master SQL query optimization, indexing strategies, and EXPLAIN analysis') and 'when' ('Use when debugging slow queries, designing database schemas, or optimizing application performance') with concrete trigger phrases, exactly matching the 5-anchor pattern.

5 / 5

Trigger Term Quality

Includes natural phrases users actually say — 'debugging slow queries', 'designing database schemas', 'optimizing application performance' — with a clear synonym cluster around slow queries and indexing; matches the comprehensive synonym/extension coverage of the 5-anchor.

5 / 5

Distinctiveness Conflict Risk

Occupies a clear niche — SQL/database query optimization via EXPLAIN and indexing — with distinct triggers unlikely to fire for unrelated skills, matching the 5-anchor's 'clear niche with distinct triggers; minimal conflict risk'.

5 / 5

Total

20

/

20

Passed

Validation

87%

Checks the skill against the spec for correct structure and formatting. All validation checks must pass before discovery and implementation can be scored.

Validation14 / 16 Passed

Validation for skill structure

CriteriaDescriptionResult

skill_md_line_count

SKILL.md is long (510 lines); consider splitting into references/ and linking

Warning

referenced_paths_exist

Referenced path issues: 7 missing

Warning

Total

14

/

16

Passed

Repository
Dicklesworthstone/pi_agent_rust
Reviewed

Table of Contents

Is this your skill?

If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.