/tksfw:verify-integrityfrom TKS Framework
Run the method-level integrity and hygiene sweep for any project — independent of what the deliverables mean. Validates the YAML process logs, checks Mermaid-diagram and JSON integrity, scans outputs for internal-alias leakage, and confirms a clean workspace, per AGENTS.md § Core Acceptance Criteria. Use before hand-off, after edits to logs or generated artifacts, or whenever "is everything structurally sound?" must be answered. Domain-agnostic (no deliverable/ARR/catalog knowledge); a domain conformance sweep can call it for integrity evidence.
Ships in TKS Framework. 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.
Read when SKILL.md points to them.
The policy+method half of QA. It enforces AGENTS.md § Core Acceptance Criteria, which are the
same for every project regardless of domain: logs, diagrams, and data files are structurally
valid; no internal alias leaks into outputs; the workspace is clean. It knows nothing about
D-numbers, ARR, capacity, or catalogs — those belong to a domain conformance sweep (Group B), which
calls this skill for the integrity evidence its conformance record needs.
Validate every .agents/workarea/ log with the yaml-log-entry validator (the PostToolUse hook
also does this on write):
for f in changes lessons handoffs events decisions deliverables; do
python3 ../yaml-log-entry/assets/validate_yaml_log.py .agents/workarea/$f.yaml
done
Per-file validity does not prove the graph is consistent. Resolve the foreign keys across files —
event→task, handoff→event/task + BEGIN/END pairing, decision RelatedTo→targets, and each COMPLETED
task's [ev:<EventID>]→a terminal-positive event. Fails (exit 1) on any dangling reference:
python3 ../yaml-log-entry/assets/cross_check.py
Lint tasks.md grammar, status/checkbox agreement, duplicate IDs, and evidence-of-closing presence
on completed leaf tasks. Advisory — review the WARNs (they also surface as a count in STATE.md);
they do not block the sweep:
python3 ../yaml-log-entry/assets/tasks_lint.py # exit 1 if issues; treat as advisory
Render each Mermaid diagram with @mermaid-js/mermaid-cli (mmdc) — it must parse/render without
error. Capture the result as evidence.
mmdc -i <file-with-mermaid>.md -o "$TMPDIR/mmd-check.svg" && echo "mermaid OK"
Every JSON artifact must parse:
python3 -c "import json,sys; [json.load(open(p)) for p in sys.argv[1:]]; print('json OK')" <file.json> ...
The rule is method; the alias strings are instance data — the caller supplies them (a Group-B sweep reads them from its project's inputs and passes them here). This skill never hardcodes them:
python3 assets/integrity_checks.py --aliases <ALIAS1> <ALIAS2> ... --require-aliases # + clean-folder scan
integrity_checks.py discovers the document deliverables from .agents/workarea/deliverables.yaml
(registry; legacy D*.md/D*.yaml fallback) and confirms none contain any supplied alias, then
walks the tree for __pycache__, .DS_Store, *.pyc, *.tmp, and Office lock files (~$…).
Scan an explicit set instead with --files a b ….
--require-aliases: because the aliases are caller-supplied data, an empty list makes the
leak check a silent no-op. Pass --require-aliases whenever the project is known to have internal
aliases: an empty list then FAILS (exit 1) instead of skipping. Without the flag, an empty list
emits a visible WARN and passes — the lenient default for a genuinely alias-free project.
A pass/fail per check. Return the evidence to the caller (e.g. a Group-B conformance sweep) for its conformance record — this skill produces the evidence, it does not own the conformance deliverable.
AGENTS.md), never to the archetype or
project. The alias list and the deliverable file set are data it receives, not dependencies.mmdc needs @mermaid-js/mermaid-cli.What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
9 skills in this plugin
/define-agentCreate, rename or edit a subagent definition (.agents/agents/<name>.toml) for this method: naming convention <family>-<role> with the role vocabulary from .agents/config.toml, required fields, description prefix, sandbox mode by tier, and the rule that models are never hand-written. Load BEFORE creating, renaming or editing ANY .agents/agents/*.toml — the PostToolUse hook validates every agent file on write (assets/validate_agent.py) and blocks non-conforming definitions; a rename must also be logged in changes.yaml.
/delegate-workMechanics for delegating work to subagents once the decision to delegate has been made (AGENTS.md § Subagents holds the decision rules): isolation (git worktree or agent work area), ownership matrix, handoff BEGIN/END logging, cleanup and pruning of finished worktrees/work areas, and how to change models via .agents/config.toml. Load when parallelising subagents, when a subagent needs an isolated place to write, when cleaning up after a phase, or when the Stop hook reports stale work areas.
/ks-reloadReload the instruction layers (AGENTS.md core, the archetype and the project spec) fresh from disk after the operator has edited them. Use when the operator says the instructions, AGENTS.md, KS_PROJECT.md or KS_SPEC.md changed, or invokes ks-reload.npx claudepluginhub ibm/tksfw --plugin tksfw