ktx/docs-site/content/docs/cli-reference
Andrey Avtomonov 911cfdc741 docs: rewrite Semantic Querying concept with imperative-vs-declarative diagram
Reframe semantic-layer-internals.mdx around the contract the semantic
layer offers an agent: declare what you want (a Semantic Query), KTX
figures out how to compute it. Replaces the old "Context-Aware SQL"
framing with a clear imperative-vs-declarative narrative.

Adds a React Flow component (semantic-layer-flow.tsx) that contrasts a
buggy 4-table agent-authored SQL (chasm trap, LEFT-JOIN-in-WHERE,
hardcoded DATE_TRUNC) against the chasm-safe per-fact CTE SQL the
planner actually emits, including the outer GROUP BY over the requested
dimensions. Both lanes converge into a shared warehouse node and each
SQL card now has parallel bullet notes (failures on the left, KTX
behavior on the right).

Side fixes bundled in:
- include the /ktx basePath in the favicon metadata so the icon resolves
  under the production prefix
- migrate docs-site/middleware.ts to docs-site/proxy.ts (Next 16 rename)
- redirect / to /ktx/docs/getting-started/introduction so the apex docs
  URL works
- add tests covering the apex redirect, the favicon basePath, and the
  middleware-to-proxy rename
- propagate the Semantic Query terminology across the ktx-sl CLI
  reference, the context-layer concept page, and the agent-clients /
  primary-sources integration pages
2026-05-19 19:34:04 +02:00
..
ktx-connection.mdx Revise CLI reference docs (#100) 2026-05-14 12:53:55 -04:00
ktx-dev.mdx docs: revamp quickstart and tighten code-block styling (#135) 2026-05-18 19:22:19 +02:00
ktx-ingest.mdx docs: revamp quickstart and tighten code-block styling (#135) 2026-05-18 19:22:19 +02:00
ktx-mcp.mdx Improve README scanability and CLI docs (#112) 2026-05-15 13:25:44 -04:00
ktx-setup.mdx fix: allow agent setup without context (#139) 2026-05-19 12:18:52 +02:00
ktx-sl.mdx docs: rewrite Semantic Querying concept with imperative-vs-declarative diagram 2026-05-19 19:34:04 +02:00
ktx-sql.mdx feat(cli): add read-only sql command (#126) 2026-05-17 10:29:07 +02:00
ktx-status.mdx feat: add claude-code llm backend with runtime port (#115) 2026-05-16 12:06:34 +02:00
ktx-wiki.mdx feat(cli): improve search ranking output (#123) 2026-05-17 02:32:41 +02:00
ktx.mdx docs: remove section overview pages (#130) 2026-05-18 09:49:43 -04:00
meta.json docs: remove section overview pages (#130) 2026-05-18 09:49:43 -04:00