sl

sl is a skill for Claude Code, Codex from Kaelio/ktx. It costs 87 tokens per session (2,540 once invoked), scanned A, original, Apache-2.0.

A structured catalogue of reusable business data definitions. It can describe tables, SQL views and added measures, calculated fields, joins and named groups so teams share the same meaning for metrics.

In plain words
What is it for?
Use it to document data sources and reusable metrics, and to help research agents read and query defined business data. The input does not describe its querying commands in detail.
Why use it?
It reduces confusion caused by different people rebuilding the same business metrics from raw database data. The catalogue provides a common reference for finding and checking those definitions.

Skill for Claude CodeCodex

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.

agentmods
npx agentmods add skills/kaelio/ktx/sl
Any agent
npx skills add Kaelio/ktx --skill sl
Clone the repo
git clone --depth 1 https://github.com/Kaelio/ktx

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 sl

README.md
[![agentmods](https://agentmods.dev/badge/skills/kaelio/ktx/sl.svg)](https://agentmods.dev/skills/kaelio/ktx/sl)
Your own site
<a href="https://agentmods.dev/skills/kaelio/ktx/sl"><img src="https://agentmods.dev/badge/skills/kaelio/ktx/sl.svg" alt="Measured on agentmods" height="20"></a>
Per session 87 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,540 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00087 $0.02540
Opus 5 $0.00044 $0.01270
Sonnet 5 $0.00017 $0.00508
Haiku 4.5 $0.00009 $0.00254

Measured 4d ago against content hash ab35024574c5, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

sl 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 4d ago.

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.

packages/cli/src/skills/sl/SKILL.md · 248 lines

How it starts

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

Semantic Layer

ktx's semantic layer (SL) is a structured catalog. Each source represents a table, a SQL view, or an overlay that enriches a manifest-backed table with measures, computed columns, joins, and named segments. The catalog is the single source of truth for reusable business metrics.

This skill covers two parts:

  • Part 1 - Schema reference (what an SL source looks like).
  • Part 2 - Querying via sl_query.

Capture (when and how to add new patterns to the SL) is a separate concern handled by the memory-agent - see the sl_capture skill if you are running in capture mode. The research agent reads and queries the SL via the tools described here; it does not write to it.

For capture-time identifier verification, load sl_capture. Synthesis writer skills must verify warehouse identifiers with discover_data, entity_details, and sql_execution before emitting table or column names.


Part 1 - Schema reference

An SL source is a YAML file under semantic-layer/<connectionId>/. The file's name: field is the source's identity — it mirrors the warehouse identifier verbatim (e.g. Snowflake's uppercase SIGNED_UP); the filename is only a derived label. Always address sources by name through the sl_* tools, never by file path. There are three flavors:

Overlay sources

Enrich a manifest-backed table with measures, computed columns, joins, and segments. No table or sql field. The base table's columns and grain are inherited from the manifest.

name: fct_orders           # must match an existing manifest table
descriptions:
  user: "Overlay adding business measures to the orders fact table."
measures:
  - name: total_revenue
    expr: sum(amount)
    description: Total order revenue - filter by status or region at query time
columns:                    # computed dimensions only
  - name: is_large_order
    type: boolean
    expr: "amount > 1000"
column_overrides:           # metadata patches for inherited columns
  - name: status
    descriptions:
      user: "Order lifecycle status."
segments:
  - name: paid_non_refunded
    expr: "is_paid = true AND is_refunded = false"
joins:
  - to: customers
    on: "customer_id = customers.id"
    relationship: many_to_one

Read the full file on GitHub · 248 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. 4d ago First seen · 248 lines · 87 tokens per session scan A ab35024574c5

Subscribe to this mod's changes

sl is a skill published in the GitHub repository Kaelio/ktx (1,571 stars, last pushed today), licensed Apache-2.0. It adds 87 tokens to every session and 2,540 once invoked, about $0.0004 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

retail-govern

Run the Seshat BI governance checker and interpret its findings. Use when someone asks to check, validate, or gate Power BI / DAX / TMDL / PBIR / SQL work in the Seshat BI repo, when seshat check reports a rule violation, or when you need to know what a rule id (D8, C2, S2, G1, …) means and where to fix it.…

Kemetra/Seshat-BI · 129 tokens

source-mapping

Drive a raw retail source table through the source-mapping gate before any silver SQL exists. Use when someone asks to map, model, profile, or onboard a new bronze table toward Power BI in the Seshat BI repo -- profile the source, decide grain/PK, fill the five mapping artifacts into mappings/ /, and stop at the gate.…

Kemetra/Seshat-BI · 122 tokens

pbip-xray

Audit a committed PBIP semantic model as text (unused fields, relationship risks, measure-graph findings) and explain a TMDL change in business terms for PR review. Read-only: it parses committed TMDL/PBIR and git history, opens no database, never launches Power BI, and edits nothing.

Kemetra/Seshat-BI · 69 tokens

capabilities

Show the read-only capability inventory for this kit -- each capability by lifecycle state, authority, requirements and provenance. Use when someone asks what the kit can do or what works without a database. Writes nothing and emits no score.

Kemetra/Seshat-BI · 48 tokens

cross-table-lineage

Trace column- and table-level lineage across bronze/silver/gold in the Seshat BI repo and report the downstream impact of a change. Read-only: it reads committed SQL and mappings, opens no database, and edits nothing.

Kemetra/Seshat-BI · 52 tokens

retail-build-warehouse

Author the silver + gold migration SQL for a mapped retail table from its APPROVED source-map, then STOP before executing. Use after a table's mapping gate is CLEARED in the Seshat BI repo and someone asks to build the silver/gold SQL, write the migration, or fill the retail-orchestrate build seam. Author-and-stop: it…

Kemetra/Seshat-BI · 113 tokens