watch

watch is a command for Claude Code from rjwalters/kicad-tools. It costs 0 tokens per session (8,113 once invoked), scanned A, original, MIT.

A long-running fleet-monitoring loop that repeatedly checks system health, performs a small set of pre-approved fixes, and reports a final summary.

In plain words
What is it for?
Use it to watch a fleet for a chosen duration, set check intervals, preview actions with a dry run, limit the number of checks, and review the results.
Why use it?
It avoids making an operator repeat the same health checks and routine responses during an unattended monitoring period.

Command for Claude Code

Written for Claude Code: $ARGUMENTS substitution. Also seen: mentions subagents.

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 commands/rjwalters/kicad-tools/watch
Clone the repo
git clone --depth 1 https://github.com/rjwalters/kicad-tools

Made for: Claude Code.

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 watch

README.md
[![agentmods](https://agentmods.dev/badge/commands/rjwalters/kicad-tools/watch.svg)](https://agentmods.dev/commands/rjwalters/kicad-tools/watch)
Your own site
<a href="https://agentmods.dev/commands/rjwalters/kicad-tools/watch"><img src="https://agentmods.dev/badge/commands/rjwalters/kicad-tools/watch.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 8,113 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.1 $0.00000 $0.08113
Opus 5 $0.00000 $0.04057
Sonnet 5 $0.00000 $0.01623
Haiku 4.5 $0.00000 $0.00811

Measured 6d ago against content hash eec252b436c1, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

watch 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 6d 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.

.claude/commands/loom/watch.md · 586 lines

How it starts

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

Fleet Watch

Keep the fleet running smoothly over a long, unattended window — a tick loop that probes fleet health, applies a small set of pre-authorized remediations, and prints an end-of-window summary.

Arguments: $ARGUMENTS

/loom:watch [--until HH:MM] [--interval 25m] [--dry-run] [--max-ticks N]

This is the skill form of the manual "night watch" an operator otherwise runs by hand: on 2026-07-30→31 that watch ran 21 ticks, re-typed the same five-check battery every time, produced 42 merges, two #4694 false-dead saves, and one #4688 pre-emptive mitigation — and burned ~60 tool calls of pure loop mechanics getting there. Everything hard-won in that night is encoded below.

Naming. Shipped as watch (the alternatives considered on #4762 were sustain and night-shift). watch was chosen because the loop is observe-first: the default posture every tick is look, decide, usually do nothing, and remediation is the exception. night-shift over-narrows it to overnight use (the same loop is useful for a 90-minute lunch window), and sustain implies the skill drives work — it does not; the daemon does. It also matches the verb operators already use ("watch the fleet") and the existing watch_registry.rs / watchdog vocabulary.

What this skill is NOT

  • Not a work generator. It never dispatches sweeps to keep itself busy. The daemon's work finder (or the operator) decides what gets built; the watch only notices when dispatch has stopped and repairs the cause.
  • Not a replacement for the watchdog. loom-daemon-watchdog.sh (#4011) is a host-side, out-of-process detector that survives this session dying. The watch is a supervising reader that can reason and repair; it complements the watchdog, and if the two disagree the watchdog's evidence wins on liveness.
  • Not a merge bot. Champion merges PRs. The watch does not merge, review, or edit code.

Arguments

Flag Default Meaning
--until HH:MM none (runs until --max-ticks, or until the operator stops it) Local wall-clock end of the window. 07:00 means "next occurrence of 07:00" — if it is already past today, it means tomorrow.
--interval <dur> 25m Time between ticks. Accepts 90s, 10m, 1h. Clamp to [5m, 60m]; a value below 5m burns context for no signal, above 60m misses outages long enough to matter.
--dry-run off Exactly one tick, report only, zero mutations. See "Dry-run mode".
--max-ticks N unbounded (or derived from --until) Hard ceiling on tick count. Always honoured, even if --until has not been reached.

Read the full file on GitHub · 586 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. 6d ago First seen · 586 lines · 0 tokens per session scan A eec252b436c1

Subscribe to this mod's changes

watch is a command published in the GitHub repository rjwalters/kicad-tools (55 stars, last pushed today), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 8,113 tokens. 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.