Tooluck logoTooluck
SKILL.md

ingest_triage

Agent skill fromKaelio/ktx

Classify and resolve conflicts detected during bundle ingest (structural duplicates, definitional contradictions, near-duplicate clusters, re-ingest changes, evictions).

How to install ingest_triage

install ingest_triage
# install the ktx pack with the skills CLI
npx skills add Kaelio/ktx

# or add only this skill to Claude Code: copy the folder

packages/cli/src/skills/ingest_triage/

# into

~/.claude/skills/ingest_triage/ (all projects)

.claude/skills/ingest_triage/ (one project)

packages/cli/src/skills/ingest_triage/SKILL.md

Apache-2.0Full file
1# Ingest Triage - conflict classification and resolution
2
3This skill is loaded in two contexts:
4- By a Stage 3 WorkUnit agent when `sl_discover`, deterministic projection
5 output, existing project memory, or prior provenance overlaps with what the
6 current WorkUnit is about to write.
7- By the Stage 4 reconciliation agent for cross-WorkUnit sweeps, accepted patch
8 overlap, and eviction decisions.
9
10Apply the rules below before every write that could collide with an existing artifact.
11
12## Decision tree
13
141. **Is this the same artifact I'm producing now, or a different one with the same name?**
15 Read both. If names match and content matches (modulo whitespace): no conflict - skip the write, the prior one stands.
16
172. **If content differs, is it an expression-only change (e.g. a different `sql:` body for the same measure name, same grain, same columns)?**
18 Re-ingest change (expression-only): silently replace via `sl_edit_source`. No flag.
19
203. **If the difference is structural - grain, columns, filter, join shape - is the current bundle the re-ingest of a previously-ingested bundle (i.e. `priorProvenance` has a row for this raw file and artifact)?**
21 Re-ingest change (semantic break): replace + flag. Record in the IngestReport's `conflicts_resolved` list with `flagged_for_human: true`.
22
234. **If reconciliation sees accepted patches from this same job with no
24prior-sync row, check for same-ingest contradictions:**
25
26 | Kind | Detection | Resolution |
27 |---|---|---|
28…

Excerpt shown under the repository's Apache-2.0 license.

More skills in ktx

Newsletter

Join the Community

Subscribe to our newsletter for the latest news and updates