In short.
ktx is a local tool for developers and data teams who want AI agents to reuse approved database knowledge, but they must supply warehouse connections and model access. The README describes automatic context building from databases, business documents and existing analytics definitions, producing Markdown knowledge pages and YAML semantic sources. Agents can search this context and request metrics through CLI and MCP tools. The evidence supports its documented purpose and setup approach, but does not establish query accuracy, connector reliability, read-only enforcement or operating costs. Local execution also includes disclosed telemetry and configured model-provider communication.
Researched and written by an AI model and checked by a second AI model. How it works
Coverage is limited to the complete README.md at the exact source address https://github.com/Kaelio/ktx/blob/main/README.md, captured at revision 49a4ae6f5b28c904da921afc0ee72da6db7ac202, plus the accompanying LICENSE notice. Linked documentation, images, videos, agent-skill files, implementation code and dependency files are excluded. No installation, connector operation, query execution, performance measurement or security testing occurred.
The overview
Identity
ktx is maintained by Kaelio and published as the npm package @kaelio/ktx. It provides a local context layer for agents querying company data: business knowledge, database relationships and reusable metric definitions are made available through CLI and MCP tools.
The source is the repository README at [https://github.com/Kaelio/ktx/blob/main/README.md]. Although the README also links an installable agent skill, the resource described here is the broader ktx tool.
Assessment
ktx is worth considering when agents repeatedly answer questions against the same warehouse and need consistent business definitions. Its useful distinction is combining existing analytics definitions with table inspection and company documentation, then exposing them through one searchable interface.
The claimed improvements in accuracy and automatic join handling are not accompanied by quantitative results in the supplied README. Practical value will depend on the quality of existing definitions, connector behavior and human review of conflicting knowledge.
Users
The intended users are developers and data teams connecting agents such as Claude Code, Codex, Cursor or OpenCode to company data. It is particularly relevant when knowledge is spread across database schemas, dbt projects, BI tools, Notion and team documentation.
Beginners should expect to configure database access and model providers. The README advises against using ktx without an existing SQL warehouse or for a single ad-hoc query, where it suggests psql or a notebook.
Capabilities
The README describes table sampling, metadata and usage-pattern collection, detection of joinable columns, documentation organization, duplicate removal and contradiction flags for human review. It also claims automatic handling of fan and chasm traps, join patterns that can produce incorrect aggregate metrics.
Listed database connections include PostgreSQL, Snowflake, BigQuery, ClickHouse, MySQL, SQL Server, SQLite, DuckDB, Amazon Athena and MongoDB. Listed integrations include dbt, MetricFlow, LookML, Looker, Metabase, Sigma, Notion and Google Drive. Feature coverage and limitations for individual connectors are not established.
Using it
Requirements
The documented installation uses npm. A useful deployment also needs a configured database connection and language-model access; an agent client is needed to use the MCP integration. Minimum runtime versions, hardware requirements and detailed database permissions are not specified.
The README lists Anthropic API, Google Vertex AI, AI Gateway, a local Claude Code session through the Claude Agent SDK, and local Codex authentication through the Codex SDK as model backends. Its status example includes an embedding provider, but does not establish when embeddings are mandatory. pnpm and uv appear in contributor setup instructions.
Mechanism
ktx ingests database information, analytics definitions and documents into a context-building process involving reconciliation and validation. It stores semantic sources as YAML and business knowledge as Markdown wiki pages. A join graph connects tables and metrics so agents can request metrics without repeatedly reconstructing their SQL definitions.
At query time, CLI or MCP tools provide combined full-text and semantic search. The README describes metric requests being compiled into read-only SQL against the warehouse. The developer layout identifies a TypeScript CLI, Python semantic-layer query planning and a Python compute service; implementation details were not supplied.
Setup
The documented sequence is npm install -g @kaelio/ktx, followed by ktx setup and ktx status. The setup command creates or resumes a local project, configures providers and connections, builds context and installs agent integration. If status instructs the user to start the MCP service, the README says to do so before opening the agent client.
Projects contain ktx.yaml, semantic-layer/, wiki/, raw-sources/ and .ktx/. The README recommends committing configuration, semantic sources and wiki content while keeping .ktx/, which contains local state and secrets, local. Scripts can use --project-dir to select a project explicitly. Further instructions are linked at [https://docs.kaelio.com/ktx/docs/getting-started/quickstart]; that page's contents are not included.
Example
For a team answering recurring revenue questions, an illustrative workflow is to configure its warehouse and existing metric sources, build context with ktx ingest, and search for relevant definitions with ktx sl "revenue". The documented ktx wiki "refund policy" command searches business documentation that may affect interpretation.
An agent connected through MCP could then use the available definitions when answering a revenue question. This is an illustrative use of documented capabilities: no revenue query, returned value or successful execution is established by the evidence.
Assessment & evidence
Limitations
Automatic context building does not establish that definitions are correct or contradictions are resolved: the README explicitly calls for human review of conflicts. Read-only connections are a documented design claim; enforcement, failure behavior, large-warehouse performance and query accuracy remain unassessed.
The FAQ says only data sent to the configured LLM leaves the machine, while a separate section discloses usage telemetry and PostHog error tracking. Error reports may contain local paths or usernames. The README describes redaction of sensitive fields from explicit exception payloads, but its effectiveness is unverified. Exact model-request contents and telemetry opt-out steps are not supplied.
Fit considerations
The strongest reason to consider ktx is repeated use of shared definitions across agent sessions. Searchable business documentation and reusable metrics could reduce the need for agents to rediscover relationships and recreate SQL logic, although the evidence does not measure that benefit.
Its fit is weaker when there is little reusable context or nobody can review conflicting definitions. A meaningful adoption decision should depend on agreement with known business metrics and acceptable data handling, rather than the README's comparison table alone.
Alternatives
For one-off queries, the README suggests psql or a notebook. It also discusses general-purpose agents and existing semantic layers such as dbt or MetricFlow. ktx can ingest those layers, so it may complement an existing system.
The practical comparison is whether combining metric definitions, raw-table context and company documentation adds enough value to justify setup and review. The supplied evidence contains no independent comparison of accuracy, maintenance effort, latency or cost.
Evidence
The available evidence comprises the complete README.md and accompanying LICENSE at repository revision 49a4ae6f5b28c904da921afc0ee72da6db7ac202. The README supports the documented features, installation commands and architecture; LICENSE supports the redistribution terms.
Implementation files, dependency manifests, linked documentation, benchmarks and test results are not included. Badges and an illustrative status display do not establish successful execution. No commands were executed, and the tool was not installed, run or tested.
Access & freshness
Costs
The README states that ktx adds no usage billing and can use the user's own API keys or existing local agent authentication. It specifically mentions Claude Pro/Max through Claude Code and local Codex authentication.
Total operating cost is unknown. Model and embedding charges, applicable subscription costs and warehouse query or compute expenses may still apply. The evidence supplies no prices, usage estimates or measurements of context-building cost, and does not establish provider-plan limits.
Rights
The README identifies ktx as Apache-2.0 licensed, and the accompanying LICENSE supplies those terms. They permit use, modification and redistribution subject to conditions including supplying the license, marking modified files, retaining relevant notices and carrying applicable NOTICE attributions when present.
The license includes a conditional contributor patent grant, does not grant general trademark rights and provides the work without warranties. Licenses for dependencies, linked services and external assets are not established by these two files.
Freshness
The source snapshot was captured on 22 November 2026 at revision 49a4ae6f5b28c904da921afc0ee72da6db7ac202. Its fixed README address is [https://raw.githubusercontent.com/Kaelio/ktx/49a4ae6f5b28c904da921afc0ee72da6db7ac202/README.md].
The evidence does not establish the published npm version, release date or subsequent changes. The README's @latest upgrade command does not identify a reproducible package version, and its example model names are not proof of required defaults.
Next steps
Before adoption, confirm support for the intended database and knowledge sources, review model-provider data handling and telemetry settings, and choose database credentials with appropriate read-only permissions. Telemetry information is linked at [https://docs.kaelio.com/ktx/docs/community/telemetry], but the opt-out procedure is unknown from the supplied text.
For a bounded evaluation, follow the documented setup, inspect readiness with ktx status, review generated definitions and contradiction flags, and compare representative metric answers with approved SQL. Measure ingestion cost and warehouse workload before expanding use. These are suggested evaluation steps, not completed results.
