huawei-cloud-mrs-clickhouse-sql-check

huawei-cloud-mrs-clickhouse-sql-check is a skill for Claude Code, Codex from huaweicloud/huaweicloud-skills. It costs 277 tokens per session (5,549 once invoked), scanned A, original, MIT.

A checker for ClickHouse SQL, the query language used by the ClickHouse data platform. It validates statements against versions 24.8, 23.3, and 22.3.

In plain words
What is it for?
Use it to review ClickHouse queries, including features such as SAMPLE BY, FINAL, ARRAY JOIN, PREWHERE, and GLOBAL JOIN.
Why use it?
It catches invalid SQL structure, incomplete clauses, and ClickHouse-specific syntax before a query is run. Version checks help avoid using syntax unsupported by the target server.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: names the AskUserQuestion tool.

Good fit Use it to review ClickHouse queries, including features such as SAMPLE BY, FINAL, ARRAY JOIN, PREWHERE, and GLOBAL JOIN.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/huaweicloud/huaweicloud-skills/huawei-cloud-mrs-clickhouse-sql-check
Install

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.

Any agent
npx skills add huaweicloud/huaweicloud-skills --skill huawei-cloud-mrs-clickhouse-sql-check
Clone the repo
git clone --depth 1 https://github.com/huaweicloud/huaweicloud-skills

Made for: Claude Code, Codex.

Wrote 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.

agentmods badge for huawei-cloud-mrs-clickhouse-sql-check

README.md
[![agentmods](https://agentmods.dev/badge/skills/huaweicloud/huaweicloud-skills/huawei-cloud-mrs-clickhouse-sql-check/github.svg)](https://agentmods.dev/skills/huaweicloud/huaweicloud-skills/huawei-cloud-mrs-clickhouse-sql-check)
Your own site
<a href="https://agentmods.dev/skills/huaweicloud/huaweicloud-skills/huawei-cloud-mrs-clickhouse-sql-check"><img src="https://agentmods.dev/badge/skills/huaweicloud/huaweicloud-skills/huawei-cloud-mrs-clickhouse-sql-check/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.

agentmods 80×15 button for huawei-cloud-mrs-clickhouse-sql-check

Your own site · 80×15
<a href="https://agentmods.dev/skills/huaweicloud/huaweicloud-skills/huawei-cloud-mrs-clickhouse-sql-check"><img src="https://agentmods.dev/badge/skills/huaweicloud/huaweicloud-skills/huawei-cloud-mrs-clickhouse-sql-check.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 277 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 5,549 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 5 findings, up to medium

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • medium Excessive Agency · line 33
    Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.
    Fix: Add human-in-the-loop confirmation for destructive, irreversible, or high-impact operations. Never auto-execute commands that modify files, send data, or alter system state.
  • medium Excessive Agency · line 101
    Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.
    Fix: Add human-in-the-loop confirmation for destructive, irreversible, or high-impact operations. Never auto-execute commands that modify files, send data, or alter system state.
  • medium Rogue Agent · line 66
    Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.
    Fix: Remove any persistence mechanisms (cron jobs, startup scripts, state files). Skills should not maintain state across sessions without explicit user consent.
  • medium Rogue Agent · line 126
    Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.
    Fix: Remove any persistence mechanisms (cron jobs, startup scripts, state files). Skills should not maintain state across sessions without explicit user consent.
  • low Excessive Agency · line 211
    Skill's behavior or capabilities extend beyond its stated purpose. Scope creep allows an agent to perform actions unrelated to its documented functionality, increasing the attack surface.
    Fix: Limit the skill's scope to its documented purpose. Remove instructions that enable the agent to perform actions outside its stated functionality.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00277 $0.05549
Opus 5 $0.00138 $0.02774
Sonnet 5 $0.00055 $0.01110
Haiku 4.5 $0.00028 $0.00555

Measured 12d ago against content hash caf457eb49b9, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

huawei-cloud-mrs-clickhouse-sql-check 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 12d ago.

The scan reads SKILL.md. This mod also ships 14 executable files (rules/common/spec_rules.py, rules/v22.3/grammar_rules.py, rules/v22.3/keywords.py, …), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

skills/bigdata/mrs/huawei-cloud-mrs-clickhouse-sql-check/SKILL.md · 463 lines

How it starts

The opening of the file, as written. The whole thing — 463 lines — stays where its author put it; the contents beside it link to each section on GitHub.

ClickHouse SQL Check Skill

You are a ClickHouse SQL specification checking expert, responsible for comprehensive SQL statement checking for ClickHouse. You have a custom-built ClickHouse SQL tokenizer and statement recognizer that can precisely identify ClickHouse-specific syntax.

1. Overview

Architecture: This skill uses a three-stage pipeline: Tokenizer (lexical analysis) → Parser (statement recognition + syntax analysis) → Rule Engine (syntax + spec checking) → Report Generation.

Multi-Version Support: Version-specific grammar rules (keywords, grammar, token types) are stored in rules/v{version}/ directories. Common development-spec rules are in rules/common/. When a user invokes the skill, ask which ClickHouse kernel version to use once per session (see Workflow below). Within the same session, reuse the previously selected version and mode without asking again.

Supported Versions:

Version Keywords Token Types Statement Types Source
24.8 571 52 47 CommonParsers.h APPLY_FOR_PARSER_KEYWORDS macro
23.3 462 49 47 Parser*.cpp ParserKeyword("...") calls (scattered)
22.3 422 48 46 Parser*.cpp ParserKeyword("...") calls (scattered)

Source: All keywords and grammar rules are extracted directly from the ClickHouse kernel source (src/Parsers/CommonParsers.h, src/Parsers/Lexer.h, and src/Parsers/Parser*.cpp), ensuring accuracy and completeness.

Check Modes:

Mode Dependency Description
syntax None Syntax check: keyword validity, statement structure, clause completeness, ClickHouse syntax compatibility
spec None Specification check: 35 development-spec rules (SPEC001-SPEC035) from MRS dev standards
all None Execute both syntax and specification checks

Default: syntax mode. Use spec or all to enable specification rules.

Applicable Scenarios:

  • Validate SQL syntax before executing on ClickHouse cluster
  • Check ClickHouse-specific syntax (ENGINE, ORDER BY, PARTITION BY, SAMPLE BY, TTL, ARRAY JOIN, PREWHERE, GLOBAL JOIN, ASOF JOIN, FINAL, etc.)
  • Identify potential syntax errors in SQL statements
  • Review SQL for ClickHouse version-specific compatibility

Read the full file on GitHub · 463 lines

Changes

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.

  1. 12d ago First seen · 463 lines · 277 tokens per session scan A caf457eb49b9

Subscribe to this mod's changes

huawei-cloud-mrs-clickhouse-sql-check is a skill published in the GitHub repository huaweicloud/huaweicloud-skills (49 stars, last pushed yesterday), licensed MIT. It adds 277 tokens to every session and 5,549 once invoked, about $0.0014 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.

Related

Other skills, from other repositories

clickhouse-analytics

Use when running a ClickHouse server for high-volume OLAP: choosing a MergeTree engine and ORDER BY/PARTITION BY keys, ingesting billions of event/log/metric rows, pre-aggregating with materialized views, or fixing a query that scans instead of pruning. NOT in-process file analytics (that is duckdb), NOT OLTP CRUD…

ericrisco/rsc-harness · 86 tokens

clickhouse

Design ClickHouse MergeTree tables, partitioning, and projections; inspect ingestion and analytical query performance.

alivirgo/Major-AI-Skills · 23 tokens

dbx

DBX CLI for database schema exploration and read-only queries. When the user needs to list connections, explore tables, describe schemas, run queries, or generate AI-friendly schema context from DBX-managed databases. Do NOT use for write operations unless the user explicitly confirms with --allow-writes.

t8y2/dbx · 61 tokens

graphjin-eval

Create, extend, run, baseline, and diagnose GraphJin agent evaluations through the graphjin eval CLI.

dosco/graphjin · 27 tokens

graphjin-env

Use when setting up a training or evaluation loop against a GraphJin agent environment — running the container, reading /health, driving episodes hosted or step-by-step or with your own agent over MCP, splitting train from eval, exporting trajectories, and deciding whether two rewards can be compared.

dosco/graphjin · 61 tokens

chdb-datastore

Use when the user has tabular data (pandas DataFrame, parquet, csv, Arrow, json) and wants to filter, group, aggregate, join, or speed up slow pandas. Provides chDB DataStore — same pandas API, ClickHouse engine underneath. Also handles reading from S3, MySQL, PostgreSQL, MongoDB, ClickHouse Cloud, Iceberg, Delta Lake…

chdb-io/chdb · 168 tokens