monitor-setup

Une commande qui enregistre la définition d'une mesure et crée un suivi pour cette mesure. Une mesure est une valeur utilisée pour observer l'évolution d'un projet ou d'une activité.

In plain words
What is it for?
Elle sert à choisir ou proposer une mesure, la classer, puis créer les fichiers de définition et de suivi correspondants.
Why use it?
Elle évite de surveiller des chiffres sans définition claire ni emplacement organisé pour les alertes.

Command for Claude Code

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/with-geun/alive-analysis/monitor-setup
Clone the repo
git clone --depth 1 https://github.com/with-geun/alive-analysis

Made for: Claude Code.

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 1,651 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 $0.00000 $0.01651
Opus 5 $0.00000 $0.00826
Sonnet 5 $0.00000 $0.00330
Haiku 4.5 $0.00000 $0.00165

Measured 2d ago against content hash 3ec3de24a3a5, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

monitor-setup 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 2d 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/monitor-setup.md · 179 lines

How it starts

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

/monitor setup

Set up a new metric monitor or register a metric definition.

Instructions

You are helping the user set up structured metric monitoring. This command does two things:

  1. Register a metric definition in .analysis/metrics/definitions/
  2. Create a monitor for that metric in .analysis/metrics/monitors/

Follow these steps in order.

Step 1: Check prerequisites

  • Check if .analysis/metrics/ folder exists. If not, create the structure:
    .analysis/metrics/
    ├── definitions/
    │   ├── north-star/
    │   ├── leading/
    │   ├── guardrail/
    │   └── diagnostic/
    ├── monitors/
    └── alerts/
    
  • Read .analysis/config.md for existing metric framework (North Star, Leading, Guardrail, Diagnostic).

Step 2: Identify the metric

Q1: Which metric do you want to monitor?

Three paths:

  • From config.md: "Pick from your existing metrics in config.md" → show list
  • From EVOLVE proposal: "Register a metric proposed during analysis" → ask for analysis ID, then:
    1. Resolve file path: Full analysis → analyses/active/{ID}_{slug}/05_evolve.md, Quick → analyses/active/quick_{ID}_{slug}.md (EVOLVE section)
    2. Read the "Proposed New Metrics" section and extract: Background, Purpose (including proposed tier), Definition & Logic, Interpretation Guide, STEDII Validation
    3. Use the extracted content to pre-fill the metric definition in Step 3
    4. STEDII carry-forward: If the EVOLVE proposal has completed STEDII checkboxes ([x]), carry them into the definition. If any are unchecked ([ ]), guide the user through the remaining criteria before proceeding.
  • New metric: "Define a new metric from scratch" → guide through definition

Step 3: Register metric definition (if not already registered)

If the metric doesn't have a definition file yet, create one.

Create file: .analysis/metrics/definitions/{tier}/{metric-slug}.md

# Metric: {name}
> Tier: {🌟 North Star / 📊 Leading / 🛡️ Guardrail / 🔬 Diagnostic}
> Registered: {YYYY-MM-DD}
> Owner: {team/person}
> Source: {config.md / analysis {ID} / experiment {ID} / new}

## Definition
- **What it measures**: (one sentence)
- **Formula**: {calculation}
- **Data source**: {table, API, dashboard}
- **Granularity**: daily / weekly / monthly / per-cohort
- **Refresh cadence**: {how often the data updates}

## Interpretation
- **Direction**: ↑ higher is better / ↓ lower is better
- **Healthy range**: {min} — {max}
- **Warning threshold**: {value}
- **Critical threshold**: {value}
- **Counter-metric**: {what to watch to prevent gaming}

## Context
- **Plain-language**: "When this goes up, it means... When it drops, it means..."
- **Segments that behave differently**: {list}
- **Seasonal patterns**: {if any}
- **Known data caveats**: {if any}

## STEDII Validation
- [x] **Sensitive** — {evidence}
- [x] **Trustworthy** — {evidence}
- [x] **Efficient** — {evidence}
- [x] **Debuggable** — {evidence}
- [x] **Interpretable** — {evidence}
- [x] **Inclusive** — {evidence}

## History
| Date | Change | Reason |
|------|--------|--------|
| {YYYY-MM-DD} | Created | {source} |

Read the full file on GitHub · 179 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. 2d ago First seen · 179 lines · 0 tokens per session scan A 3ec3de24a3a5

Subscribe to this mod's changes

monitor-setup is a command published in the GitHub repository with-geun/alive-analysis (41 stars, last pushed 3mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,651 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.