/kdbx-knowledge:kxmeta-authorfrom kdbx-knowledge
Writes qdoc annotations for the aimeta compiler to correctly publish tables and functions in q codebases. Covers mandatory @kind/@name markers, chained @col modifiers, and q-language traps.
Ships in kdbx-knowledge. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
aimeta annotations/ @kind ... blocks above tables or functions in a q codebase that loads aimeta.meta.json (the compiler ran clean but the item didn't surface).The wire model — tag vocabulary, meta.json shape, type-string rules, references[] semantics — lives in reference/agent-guide.md. This skill covers the behaviour of getting annotations correct.
Every annotated item needs these. Without them the parser drops the item from meta.json — no error, no warning.
@kind data for a table, @kind function for a callable. @kind table is a common mistake — it silently drops because qdoc's preprocessor only recognises function/data/readme/file.@name <bindingName> — required on every annotated item. The compiler reads names from @name only, never from qdoc's auto-detection (unreliable for multi-line lambdas). Convention: leaf for top-level (@name trade), fully-qualified for namespaced (@name .gw.vwap)./ @tag at column 0. Indented / lines are code context, not annotations.@desc, @param description, @returns description, @example). Repeatable tags: @param, @col, @example, @uses, @tag, @sampleRow — every other tag appears at most once.@authorize takes exactly two static tokens: / @authorize <action> <resource>. Use read data.<table> for a direct data-read API and exec analytic for a higher-level analytic API. Do not put expressions or caller-specific values in either token.{...} (symbol, symbol[], float, timestamp), not q's single-char codes. The compiler maps to s/f/p/… when emitting kdbType.@col modifiersColumn modifiers pile up on a single @col line after the required name {type} description. prefix:
/ @col sym {symbol} Instrument symbol. @semanticType:instrument @foreignRef:instrument.sym @attr:u
Order doesn't matter. Modifiers: @semanticType:X, @foreignRef:T.C, @cardinality:{low,medium,high}, @attr:{s,u,p,g} (may repeat), @label.
@sampleRow attaches example data — one row per tag (repeatable), comma-separated q literals: / @sampleRow 2026.04.29D14:30:00,`AAPL,175.5.
@col, each matching the column's type — an {int} column needs 100i, not 100."..."-quoted.These are q-tokeniser quirks, not annotation rules. Symptom: compiler runs clean, item is missing from meta.json.
/ at column 0 can open a block comment that swallows subsequent annotations. Use // for non-annotation comments interleaved between bindings.- in symbols — `:foo-bar parses as `:foo minus bar. Use _ or camelCase: `:foo_bar, `:fooBar.if[c; '"err"]; rest inline in a function body silently drops the host function. Use $[c; '"err"; rest] — semantically equivalent, parses cleanly.{...} — dict(a:long;b:long) or fn(long;long)->long may silently drop the item. Stick to bare dict, function, *; put structure into @desc.@desc split across multiple / lines — only the first line is the description; the rest are dropped silently.@private (the binding is omitted from meta.json entirely, including the references[] index).@public. The block parses cleanly without @public but the function won't appear in the published surface.@public functions@kind, @name, @desc, @returns, one @param per declared argument. Recommended: @example (at least one), @uses (table dependencies — drives the cross-process publish graph), and @authorize when the intended grant is known. Optional: @tag.
@uses and @authorize answer different questions. @uses trade records a
dependency; @authorize exec analytic records the capability expected of the
caller. Prefer read data.trade when the function is a direct read facade and
exec analytic when it exposes a higher-level calculation. Do not invent a
grant when the owning policy intent is unknown.
The tag is informative only. aimeta neither checks the caller nor inserts a
guard into the function. A policy-enforcement module or gateway must enforce
the published action/resource pair. Computed or row-specific resources need
explicit enforcement outside this static annotation model.
A @reference X table is the canonical resolver for vocabulary X. It needs at least one @attr:u column (the key) and may carry @label columns (human-readable names). Other tables link to it via @semanticType:X on the joining column. See the worked example in reference/agent-guide.md for the full pattern.
Reference-table rules:
@reference X requires the table to have a @attr:u column.@reference X for the same X is an error.@label outside an @reference table produces a warning but is still published.@reference X ↔ @semanticType X is a vocabulary link; @foreignRef T.C is an edge. Independent — a column can carry both.After substantive edits, restart the host — init[] recompiles on
boot by default:
q host.q
Or run the standalone CLI form (useful in CI, or when iterating without booting):
scripts/kx-meta.sh compile /path/to/your/q/source
Either path writes <srcDir>/.aimeta/meta.json — byte-deterministic; commit it and let CI guard against drift.
The parser doesn't report what it silently dropped. Count what made it through:
m: .aimeta.data[];
expectedFns: `.gw.vwap`.gw.fxConvert; / what you expect
gotFns: key m`functions;
missing: expectedFns except gotFns;
if[count missing;
-1 "MISSING from meta.json: ", "," sv string missing;
-1 " → first check: missing @kind, missing @name, mismatched @name.";
-1 " → then: bare `/` comments, `-` in symbols, if[c;'\"err\"];rest bodies, compound types."];
If items are missing and the compiler reported no errors, the cause is one of the silent-drop traps above.
meta.json shape, references[] semantics).What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
4 skills in this plugin
/kdbxUse when working with KDB-X modules, AI libraries (vector search, HNSW, IVF, BM25, time-series similarity, anomaly detection), GPU acceleration, Parquet, kURL REST client, object storage, or the module framework. Also use when encountering module-not-found errors, vector dimension mismatches, HNSW index issues, GPU setup issues, or `nyi` errors from using `\l` instead of `use`./kdbx-db-serviceUse this skill whenever working with the KDB-X DB Service - a containerised time-series database distributed via Docker Compose. Trigger for any task involving: setting up or resetting the DB Service, ingesting data (CSV, streaming, REST, or third-party sources like OneTick), writing or optimising queries (Python client, q client, or REST/qSQL), or planning an end-to-end ingest pipeline. Also trigger for schema design questions, troubleshooting ingest jobs, or any reference to `dbservice_client`, `session.import_files`, `session.import_data`, `session.query_simple`, `session.query_sql`, `session.query_q`, `session.querySimple`, `session.querySQL`, `session.queryQ`, or the DB Service REST API on port 8080. Also trigger for: "run the FX recipe", "FX ingest recipe", "run the OneTick recipe", "run the OneTick LSE recipe", "run the OneTick LSE runbook", or any request to set up the full OneTick batch pipeline end-to-end from download through to ingest. Do NOT trigger for: KX Dashboards configuration; generic Docker Compose questions unrelated to the DB Service stack; or plain kdb+/q questions that don't reference the DB Service.
npx claudepluginhub kxsystems/kx-skills --plugin kdbx-knowledgeOther plugins' skills for the same job