Repository navigation
Add Agents Schema discovery hint to server instructions - #245
joe-clickhouse merged 1 commit into
Conversation
|
@felipempleite I very much prefer this approach! Simpler and sticks with an already set precedent. When it's ready for review, please change from draft to ready and I'll take a proper look. Thanks! |
|
@joe-clickhouse Me too! Thanks for the review and feedback on the original PR, this is definitely a cleaner approach 😅 |
There was a problem hiding this comment.
Looks good. Thanks again!
There was a problem hiding this comment.
Copilot review overview
🟢 Approval recommended
The focused documentation and instruction change is consistent, tested, and introduces no query-execution changes.
Review effort: Balanced
Findings: None
What changed in this PR
Adds Agents Schema discovery guidance to server instructions without changing query behavior.
Changes:
- Directs agents to inspect
AGENTS.ROOTafter database discovery. - Documents the guidance and adds modern/legacy client coverage.
- Records the user-visible addition in the changelog.
| File | Description |
|---|---|
mcp_clickhouse/skills_advisor.py |
Adds the discovery hint. |
tests/test_skills_advisor.py |
Verifies hint content. |
tests/test_startup_contract.py |
Verifies instruction delivery across client modes and startup configurations. |
README.md |
Documents behavior and permissions. |
CHANGELOG.md |
Records the new guidance. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Summary
Small follow-up to #231, following the discovery-first approach suggested in review.
Adds one sentence to the existing server instructions:
The rest of the change documents the hint and tests its delivery through modern and legacy MCP clients, including startup configurations with ClickHouse disabled and without opening a database connection.
Why
Published Agents Schema metadata can help agents understand the data before writing a query. The existing discovery and query tools already provide access; this change points agents toward that path without changing query execution.
This is guidance only: no SQL scanner, automatic metadata queries, extra worker pools, caches, feature flags, or tool-result changes. Model-description enrichment and engine guidance are out of scope. Agents must follow the hint, and existing ClickHouse permissions still apply; missing or inaccessible metadata returns the normal query error.
Validation
AGENTS, missingROOT, successful explicit discovery and metadata reads in modern/legacy modes, and a read-only user with and withoutSELECTonAGENTS.ROOT.These are local validation results; GitHub CI remains to be run.