Infra health
Skill tarangdeep-goel-by/claude-harness/claude/skills/infra-health
Dev-focused Claude Code harness — workflow-engine skills, in-repo memory, session continuity (/recall ↔ /vault-push), local telemetry, + a ready-to-fill vault scaffold. clone + ./install.sh and go.
npx -y skills add tarangdeep-goel-by/claude-harness --skill infra-healthAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
What its author says it does
Copied from the file, not written here
Telemetry on the Claude Code harness itself — how hooks, skills, subagents, and daily jobs are performing. Use for: "infra health", "how is the infra performing", "hook telemetry", "which skills am I using", "are any hooks failing", "infra stats". All telemetry is LOCAL (stays on this machine under ~/vault/logs/). Distinct from /stats (which is cost/token usage).
SKILL.md
5.3 KB, as published. Nobody here has run it
/infra-health — Harness Telemetry
Reports how the infrastructure is performing, so it can be improved. Reads the event sinks
under ~/vault/logs/ — no live cost data (that's /stats). All telemetry is local — nothing
leaves this machine.
Run it
python3 ~/.claude/skills/infra-health/scripts/infra_health.py <days> # default 7
/infra-health→ 7 days ·/infra-health today→1·/infra-health month→30
What it shows
- Hooks — per-hook run count, ok/skip/error split, p50/p95 duration. ⚠ flags any hook with
errors/blocks. Source:
hooks.jsonl. - Skills — quality + cost — per skill: invocations, auto vs explicit (
/slash) split, median output tokens (cost), correction rate (corr%, ⚠ at ≥25% = rework), and in-window errors. Source:skills.jsonl. - Routing adherence —
ok / (ok + missed): are skills firing when a prompt matches their triggers? Lists recentmissed(matched triggers, nothing fired) + misfire candidates. Source:routing.jsonl. - Dead skills — registered (
~/.claude/skills/*/SKILL.md) but never invoked. Source:skills.jsonl∪workflow.jsonl(all-time), minus the registry. - Subagents — Task/agent invocation frequency. Source:
skills.jsonl(kind=agent). - Daily jobs — last run, freshness (hours ago), failures. Source:
daily-jobs.jsonl. - Knowledge drift — the semantic-memory eval KPI: latest counters + trend across recent runs
(ADR hygiene, KBs past
verify_by+ max stale days, metric-drift suspects, memory count/index KB). ⚠ flags any counter climbing off its baseline,suspects_recurring > 0(a flagged item still unactioned a run later — the dead-detector alarm), or a staledate(the weekly--scoreisn't running). Working = counters flat-low + nothing recurring. Source:knowledge-drift-score.jsonl. - Sessions — marker count, live (<45m heartbeat), and unpushed count. Source:
active-sessions/. - Recent errors — warm-start FATAL/ERROR tail.
How telemetry is captured (the data model)
Two capture paths: hooks log themselves on the hot path; skill/routing quality is
computed offline by skill_analyzer.py in the session-export pipeline (a Skill-tool
PostToolUse hook can't measure skills — the tool returns once SKILL.md loads, before the skill
does any work). Full schema: ~/code/claude-harness/vault-scripts/TELEMETRY.md.
| Sink | Written by | Holds |
|---|---|---|
~/vault/logs/hooks.jsonl | every hook (via hooklib.sh) | hook runs + outcome + duration + exit code |
~/vault/logs/skills.jsonl | skill_analyzer.py (session-export, offline) | per-invocation cost + quality: source, output_tokens, tool_calls, errors, correction_next; kind=agent for subagents |
~/vault/logs/routing.jsonl | skill_analyzer.py (session-export, offline) | per trigger-matched user turn: verdict (ok/missed/misfire), matched, fired, prompt |
~/vault/logs/workflow.jsonl | tool-telemetry-hook.sh (PostToolUse Skill|Task) — the merged hook | real-time skill + subagent invocations: kind (skill/agent), name, project, args, outcome. The single invocation log (absorbed skill-log-hook + the old events.jsonl). Dead-skill history + invocation audit; also read by workflow-gate + vault-audit. |
~/vault/logs/daily-jobs.jsonl | run-daily-jobs.sh | daily-job success/failure + timing |
~/vault/logs/knowledge-drift-score.jsonl | discrepancy-scan.py --score (weekly, via /wrap-up) | semantic-memory drift KPI: ADR-hygiene + KB-freshness + metric-drift + memory counters per run (eval trend); baseline = 2026-07-02 audit |
~/vault/logs/active-sessions/*.json | session-marker-hook.sh | per-session liveness + pushed flag |
Using it to improve
- A hook with a high error/block rate or a fat p95 → fix or raise its timeout. (
block/denywithexit=2on a guard hook is working as intended, not a failure —exit_codeflags real crashes.) - A skill with a high
corr%(≥25%) → its output keeps getting reworked next turn; tighten it. - A skill with high median output tokens → cost target to optimize.
- Low routing adherence / recurring missed triggers → a CLAUDE.md routing-rule gap or weak
SKILL.md
descriptiontriggers (matching is heuristic — treat missed/misfire as review candidates). - A skill with 0 invocations over a month → candidate to retire or fix discoverability.
- A daily job stale beyond its freshness → cron/
/start-worknot firing. - A persistent unpushed count → sessions ending without
/vault-push. - Suggest concrete changes based on the numbers; this is the feedback loop for the harness.
Note: skill/routing telemetry is reconstructed from session JSONL by
skill_analyzer.py, so it accumulates from when that analyzer was wired into session-export. The analyzer is idempotent (dedup-keyed), so Stop/PreCompact re-runs over a growing JSONL never double-count.