CtrlK
BlogDocsLog inGet started
Tessl Logo
SkillPublic

generating-clickhouse-query-performance-reports

Produce and structure slow-query performance reports for PostHog's production ClickHouse (US and EU). Use when asked for a slow query report, query performance analysis over the last N days, per-team query cost, OOM or timeout investigation, cluster cost/memory regressions, or materialization candidates. Covers the modern `query_log_archive` source (typed `lc_*` columns, multi-day retention), how to categorize and attribute slow queries, root-cause patterns (unmaterialized JSONExtract, high-cardinality breakdowns, heavy joins), and the report structure. Runs queries via the `querying-production-databases-via-metabase` skill.

74

Quality

93%

Does it follow best practices?

Run evals on this skill

Adds up to 20 points to the overall score

View guide
SecuritybySnyk

—

The risk profile of this skill

SKILL.md
Quality
Evals
Security

Quality

Content

87%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.

A well-structured methodology skill: clear sequenced workflow with validation checkpoints, concrete SQL and report-structure guidance, and clean progressive disclosure through a small set of clearly signaled reference files. Minor tightening in the delta step would push conciseness to a 5.

Suggestions

Tighten step 9's delta guidance—consolidate the incident-excluded baseline and window-comparability points into a tighter checklist to reduce token cost.

Inline the most critical single query (e.g. the slow-query predicate or the per-day count) directly in SKILL.md so the core action is executable without opening references/query-patterns.md.

DimensionReasoningScore

Conciseness

The body is largely lean and assumes Claude's competence without explaining what ClickHouse or query logs are, but step 9's delta explanation and some attribution prose could be tightened; minor verbosity prevents a 5.

4 / 5

Actionability

Provides concrete SQL predicates, a full column table, per-step reference pointers, exact report structure, and exact filenames like `<YYYY-MM-DD>-<topic>.md`; most ready-to-run SQL is deferred to references rather than inline, leaving minor gaps.

4 / 5

Workflow Clarity

A clear 9-step coarse-to-specific sequence with explicit validation checkpoints (per-day count to confirm the window, 'Do not read previous reports until step 9') and explicit fallbacks for the missing sibling repo, giving strong feedback loops for a batch/reporting operation.

5 / 5

Progressive Disclosure

SKILL.md is an overview with well-signaled, one-level-deep references (query-patterns.md, materialization-analysis.md, hogql-deep-dive.md, and the sibling skill's playbook) listed in a dedicated References section, with detailed SQL appropriately split out.

5 / 5

Total

18

/

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.

A strong, specific description that clearly states what the skill does and when to use it, with natural trigger terms and a distinct niche. Third-person voice is maintained throughout. It is somewhat long but the density is justified by the concrete triggers and capabilities it enumerates.

DimensionReasoningScore

Specificity

Lists multiple concrete actions—produce and structure reports, categorize and attribute slow queries, root-cause patterns (unmaterialized JSONExtract, high-cardinality breakdowns, heavy joins), and report structure—giving comprehensive coverage of the domain.

5 / 5

Completeness

Explicitly answers both what ('Produce and structure slow-query performance reports... Covers the modern query_log_archive source...') and when ('Use when asked for a slow query report, query performance analysis over the last N days...') with concrete trigger phrases.

5 / 5

Trigger Term Quality

Natural user-facing phrases are well covered—'slow query report', 'query performance analysis over the last N days', 'per-team query cost', 'OOM or timeout investigation', 'cluster cost/memory regressions', 'materialization candidates'—matching what a user would actually say.

5 / 5

Distinctiveness Conflict Risk

The niche is sharply scoped to PostHog production ClickHouse slow-query reporting and explicitly distinguishes itself from the sibling root-causing skill, leaving minimal risk of triggering the wrong skill.

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.

Validation — 14 / 16 Passed

Validation for skill structure

CriteriaDescriptionResult

relative_links

Relative link issues: 6 suspicious

Warning

referenced_paths_exist

Referenced path issues: 16 missing

Warning

Total

14

/

16

Passed

Repository

PostHog/posthog

Path

.agents/skills/generating-clickhouse-query-performance-reports/SKILL.md

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.