os-watcher

os-watcher is a command for Claude Code from CronusL-1141/AI-company. It costs 56 tokens per session (923 once invoked), scanned A, original, MIT.

A command for turning reminders and end-of-session blocking on or off when a background watcher is not armed.

In plain words
What is it for?
It checks the current setting or switches it with commands such as on, off, and toggle.
Why use it?
It lets you silence the prompts and stop-blocking behavior without starting or stopping the watcher itself.

Command for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: reads .claude/ paths.

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is bash scripts/os-watch.sh <session_id> <team_id> <你的 reader 标识> # 必须以宿主的后台任务方式起(run_in_background).

Part of the ai-team-os plugin — 5 skills, 8 commands, 9 agents, 16 hooks, 1 MCP server shipped together

Good fit It checks the current setting or switches it with commands such as on, off, and toggle.

Compare 6 commands from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/CronusL-1141/AI-company
agentmods
npx agentmods add commands/cronusl-1141/ai-company/os-watcher

Made for: Claude Code.

Or install ai-team-os, the plugin that ships this one along with the rest of its 5 skills, 8 commands, 9 agents, 16 hooks, 1 MCP server.

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 os-watcher

README.md
[![agentmods](https://agentmods.dev/badge/commands/cronusl-1141/ai-company/os-watcher/github.svg)](https://agentmods.dev/commands/cronusl-1141/ai-company/os-watcher)
Your own site
<a href="https://agentmods.dev/commands/cronusl-1141/ai-company/os-watcher"><img src="https://agentmods.dev/badge/commands/cronusl-1141/ai-company/os-watcher/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for os-watcher

Your own site · 80×15
<a href="https://agentmods.dev/commands/cronusl-1141/ai-company/os-watcher"><img src="https://agentmods.dev/badge/commands/cronusl-1141/ai-company/os-watcher.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 56 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 923 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.00056 $0.00923
Opus 5.5 $0.00022 $0.00369
Sonnet 5.5 $0.00011 $0.00185
Haiku 4.5 $0.00006 $0.00092

Measured 16d ago against content hash 2bb8fbb2ebd2, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

os-watcher 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 16d 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.

plugin/commands/os-watcher.md · 52 lines

What it actually says

!F="$HOME/.claude/data/ai-team-os/arm-hint.off"; mkdir -p "$(dirname "$F")" 2>/dev/null; case "$(printf '%s' "$ARGUMENTS" | tr '[:upper:]' '[:lower:]' | tr -d '[:space:]')" in off|mute|close|关|静默) touch "$F";; on|open|开|恢复) rm -f "$F";; status|state|查|"") if [ -e "$F" ]; then echo "当前:已静默(收工不拦)"; else echo "当前:守卫开着(有活在飞且 watcher 未武装时拦收工)"; fi; exit 0;; *) if [ -e "$F" ]; then rm -f "$F"; else touch "$F"; fi;; esac; if [ -e "$F" ]; then echo "已静默 — 有活在飞时收工也不再拦你"; else echo "已开启 — 有活在飞且 watcher 未武装时会拦一次收工"; fi

上面一行是命令的执行结果。把它原样转述给用户,一句话结束,不要再跑任何工具、不要复查文件、不要解释机制。

(如果上面显示的是 ! 加一段脚本原文而不是执行结果,说明这个环境没开 inline shell execution —— 那就改用 Bash 工具执行同一段逻辑,再转述结果。)

先分清两件事

本命令不启停 watcher 本身。 它管的是「watcher 没武装时拦你收工」这件事。

想做的事 用什么
真的武装一个 watcher bash scripts/os-watch.sh <session_id> <team_id> <reader>,以宿主的后台任务方式起(run_in_background)
让它别再拦我收工 /os-watcher off ← 本命令

/os-watcher off 不会让已武装的 watcher 停掉,也不会替你武装一个。

这个开关管什么

turn_end_guard.py 的待命守卫:Stop 时若「有活在飞 + watcher 未武装」,拦一次逼你先武装 (最多连拦 MAX_BLOCKS 次)。每轮注入的「watcher 未武装」提醒已退役,不再出现。

静默的代价写在明处:关掉之后有活在飞也能直接收工,活干完没人叫醒你。 结果不会丢——任务台账、事件、子 agent 产出照常落库,只是要等你下次开口才看到。

放行时走的是 hint_muted 分支,不与其它 allow 混淆:静默是你的选择,不是系统判定无风险, 两者在日志里必须分得开。

状态存哪

~/.claude/data/ai-team-os/arm-hint.off,文件存在即静默。随时可切,不用重启会话 (用文件而不是环境变量正是为此:改 env 要重启才生效)。

读不到这个文件时一律当作"没关"——开关本身出故障要回到有保护的那一侧。

关了之后想恢复叫醒能力

武装一个 watcher 即可,它和本开关互不影响:

bash scripts/os-watch.sh <session_id> <team_id> <你的 reader 标识>   # 必须以宿主的后台任务方式起(run_in_background)

watcher 武装后,守卫本来也不会拦你(watcher_armed 分支放行)。

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. 16d ago Changed · -5 lines · +5 tokens per session 2bb8fbb2ebd2
  2. 28d ago First seen · 57 lines · 51 tokens per session scan A 847bb982a8fe

Subscribe to this mod's changes

os-watcher is a command published in the GitHub repository CronusL-1141/AI-company (372 stars, last pushed 5d ago), licensed MIT. It adds 56 tokens to every session and 923 once invoked, about $0.0002 per session on Opus 5.5. 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-09-19.