Data & Analysis semantic-layermcpsqldata-warehousemetricsbi-integrationdata-context

ktx — Context layer for data agents

A context layer that teaches agents to query your data warehouse accurately, with approved metrics and full business context.

FollowAgents review · FARS-2.1
Use with care
64/ 100 5-point scale 3.2 / 5
1 2 3 4 5 6
1Trust17 / 29 · 2.9/5

Evidence shows: README explicitly states read-only connections, local running, no hosted service, and telemetry has privacy protections. However, lacks user confirmation mechanisms (e.g., confirmation before execution) and detailed rollback mechanisms. Dependency security has lock files and CI checks, but no evidence of vulnerability scanning. External effects: read-only design is good, but no explanation of potential impact on databases. Source attribution: clear maintainer info. Deductions: insufficient evidence for user confirmation and rollback.

2Reliability9 / 14 · 3.2/5

Evidence shows: CI workflows, test scripts, and multiple tests indicate good internal consistency. Dependency availability: lock files and explicit package manager versions. Failure messages: tests check error outputs. Deductions: static review cannot verify runtime reliability.

3Adaptability12 / 18 · 3.3/5

Evidence shows: README defines target users and scenarios, and lists non-applicable cases. Capability boundaries clear, e.g., read-only, supports multiple databases. Trigger precision: CLI commands and MCP tools documented. Environment fit: supports multiple databases and LLM backends. Deductions: no detailed configuration options and limitations.

4Convention13 / 18 · 3.6/5

Evidence shows: Clear information architecture with project layout and docs links. Install notes simple. Naming stability: version numbers and semantic release. Examples and FAQ provide basic usage. Known limitations mentioned in README. License Apache-2.0 complete. Versioning changelog not directly provided, but semantic release implies. Maintenance responsibility clear as Kaelio. Deductions: missing explicit changelog file.

5Effectiveness9 / 13 · 3.5/5

Evidence shows: Output usability: CLI provides multiple output formats (e.g., JSON, plain). Marginal value: solves data agent context problem. Cost-benefit: no extra billing, uses own LLM. Deductions: static review cannot assess actual effectiveness.

6Verifiability4 / 8 · 2.5/5

Evidence shows: README claims supported by docs links, but no independent verification. Cross-source corroboration insufficient, mainly single source. Fact-inference separation: README distinguishes feature descriptions and comparisons. Deductions: lack of third-party verification.

Evidence confidence: Low Reviewed Aug 12, 2026 Reviewed revision 49a4ae6f5b28
Before you use it
  • Static review cannot verify runtime security and reliability.
  • Insufficient evidence for user confirmation and rollback mechanisms.
  • No evidence of dependency vulnerability scanning.
  • Publisher identity unverified; proceed with caution.
See the full review method →

What does this agent do, and when should you use it?

ktx is an executable context layer built by Kaelio that gives AI agents like Claude Code and Codex the context they need to query your warehouse accurately. It automatically ingests knowledge from sources like dbt, Looker, Metabase, and Notion, builds a semantic layer, and serves agents via CLI and MCP tools. It supports multiple databases including PostgreSQL, Snowflake, BigQuery, and ClickHouse, and is read-only by design, never writing to your database. It offers commands like `ktx setup`, `ktx ingest`, and `ktx mcp start` for configuration, context ingestion, and starting the MCP server. The tool is Apache-2.0 licensed and self-hosted, with no hosted service. It is positioned as a superior alternative to traditional semantic layers by automatically building and maintaining context with minimal manual effort.

ktx ingests database schemas, metadata, and usage patterns, along with semantic layers from dbt, Looker, and MetricFlow, and combines them with business knowledge from wikis and Notion. It builds a local wiki and semantic-layer YAML through its context engine, detects joinable columns, and automatically resolves fan and chasm traps. It provides CLI commands like ktx sl "revenue" to search semantic sources, ktx wiki "refund policy" to search wiki pages, and ktx mcp start to start an MCP server for agent clients. Agents can use MCP to fetch approved metric definitions and joinable columns, which are compiled into read-only SQL executed against the warehouse. It also provides ktx status to check project readiness, including LLM and embedding provider configuration.

  1. A data engineer wants Claude Code or Codex agents to query the warehouse using approved metrics instead of inventing new logic each time.
  2. A team with business knowledge scattered across dbt, Looker, Metabase, and Notion wants to provide a unified context layer for AI agents.
  3. An analytics engineer needs a semantic layer that resolves fan and chasm traps automatically, reducing manual intervention.
  4. A data platform team wants to give agents read-only access to the warehouse without compromising security or managing a hosted service.
  5. A solo developer wants to leverage AI agents for data analysis using their own LLM API keys or local agent sessions, with no additional hosting costs.

What are this agent's strengths and limitations?

Pros
  • Automatically builds and maintains a semantic layer without manual upkeep, resolving common issues like fan and chasm traps.
  • Ingests and combines business knowledge from multiple sources (dbt, Looker, Metabase, Notion, Google Drive) for comprehensive context.
  • Provides both CLI and MCP interfaces for agents like Claude Code, Codex, and Cursor, making integration straightforward.
  • Read-only by design, ensuring no writes to the database, thus safe for production use.
Limitations
  • Requires an SQL warehouse; not useful for non-SQL data sources.
  • Requires configuration of an LLM provider (Anthropic, Vertex AI, or local agent login), which may incur costs or dependencies.
  • Needs a Node.js and Python environment, adding setup complexity.
  • Self-hosted with no hosted service; users must manage their own infrastructure.
  • As a relatively new project, it may lack mature community support or long-term stability.

How do you install or deploy this agent?

Install globally via npm: npm install -g @kaelio/ktx. Development requires Node.js and Python (managed via uv). The project requires a SQL warehouse and an LLM provider (e.g., Anthropic API, Google Vertex AI, or local Claude Code/Codex authentication).

How do you use this agent?

Run ktx setup in your project directory, follow the prompts to configure providers, connections, and build context. Then run ktx status to verify readiness. If prompted, run ktx mcp start --project-dir ... to start the MCP server, then open your agent client. Agents can use MCP tools to query the semantic layer and wiki.

How does this agent compare with similar options?

Unlike general-purpose agents that struggle with data tasks, ktx provides a context layer specifically for data agents. Compared to traditional semantic layers like dbt or MetricFlow, ktx ingests those layers and adds wiki content, providing a single searchable surface. The README explicitly mentions that ktx ingests dbt or MetricFlow semantic layers and combines them with raw-table introspection and wiki content, rather than replacing them.

FAQ

Does ktx send my data to a hosted service?
No. ktx runs locally; the only data leaving your machine is what you send to the LLM provider you configured.
Which LLM backends are supported?
Anthropic API, Google Vertex AI, AI Gateway, the local Claude Code session, and local Codex authentication via the Codex SDK.
How safe is my warehouse with ktx?
Connections are read-only; ktx never writes to your database.
Does ktx need a running server?
There is no hosted service. The local MCP daemon runs on demand via ktx mcp start when an agent client needs it.

Compare agents like this one

The same FARS review applied across the shortlist this agent qualifies for.

Related agents