loom-prometheus

loom-prometheus is a skill for Claude Code, Codex from cosmix/loom. It costs 16 tokens per session (7,099 once invoked), scanned A, original, MIT.

A guide to Prometheus, a monitoring system that regularly collects numeric measurements called metrics and stores them as time series. It covers PromQL, the language used to query metrics, along with alerts and application instrumentation.

In plain words
What is it for?
Use it to write PromQL queries, configure metric collection, define recording and alerting rules, instrument applications, and set up service discovery or Alertmanager notifications.
Why use it?
It helps you turn service measurements into queries and alerts, while avoiding common mistakes such as treating counters like gauges or using Pushgateway for long-running services.

Skill for Claude CodeCodex

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 skills/cosmix/loom/loom-prometheus
Any agent
npx skills add cosmix/loom --skill loom-prometheus
Clone the repo
git clone --depth 1 https://github.com/cosmix/loom

Made for: Claude Code, Codex.

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 loom-prometheus

README.md
[![agentmods](https://agentmods.dev/badge/skills/cosmix/loom/loom-prometheus.svg)](https://agentmods.dev/skills/cosmix/loom/loom-prometheus)
Your own site
<a href="https://agentmods.dev/skills/cosmix/loom/loom-prometheus"><img src="https://agentmods.dev/badge/skills/cosmix/loom/loom-prometheus.svg" alt="Measured on agentmods" height="20"></a>
Per session 16 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 7,099 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. 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.00016 $0.07099
Opus 5 $0.00008 $0.03549
Sonnet 5 $0.00003 $0.01420
Haiku 4.5 $0.00002 $0.00710

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

Security

Grade A, and why

loom-prometheus scanned grade A with 1 finding 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.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl -s http://localhost:9090/api/v1/targets | jq '.data.activeTargets[] | {job:.labels.job, health}'
skills/loom-prometheus/SKILL.md · 569 lines

How it starts

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

Prometheus Monitoring and Alerting

Pull-based, multi-dimensional time-series monitoring with PromQL. Scope: PromQL, scrape/SD config, recording & alerting rules, instrumentation, Alertmanager. Dashboards/panels → loom-grafana; log queries → loom-logging-observability.

Overview

Component Role
Prometheus server Scrapes targets, stores TSDB locally, evaluates rules
Alertmanager Dedup, group, route, inhibit, silence, notify
Exporters Translate third-party systems to the exposition format (node, blackbox, ...)
Client libraries In-process instrumentation (Go, Python, Rust, Java, ...)
Pushgateway Ephemeral batch jobs push metrics — see gotcha; avoid for services
Operator / Thanos·Mimir·Cortex K8s CRD deploy / long-term + global-view remote storage

Metric types. up is the synthetic per-target health series (1 = scrape ok).

Type Semantics Query with
Counter Monotonic, resets to 0 on restart (_total suffix) rate()/increase()never graph raw
Gauge Up/down (memory, queue depth) raw, avg_over_time, deriv, predict_linear
Histogram Bucketed observations → _bucket{le},_sum,_count histogram_quantile(); buckets are additive
Summary Client-side quantiles → {quantile},_sum,_count not aggregatable — single-process only

Scrape Configuration

# prometheus.yml
global:
  scrape_interval: 15s          # rate() windows must be >= ~4x this
  evaluation_interval: 15s
  external_labels: { cluster: production, region: us-east-1 }

alerting:
  alertmanagers:
    - static_configs: [{ targets: [alertmanager:9093] }]

rule_files: ["rules/*.yml", "alerts/*.yml"]

scrape_configs:
  - job_name: prometheus
    static_configs: [{ targets: [localhost:9090] }]

  - job_name: application
    metrics_path: /metrics
    static_configs:
      - targets: [app-1:8080, app-2:8080]
        labels: { env: production, team: backend }
  # Kubernetes SD → see Service Discovery section (single canonical example)

Read the full file on GitHub · 569 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 Changed · -50 tokens per session 8f4647c7af31
  2. 5d ago First seen · 569 lines · 66 tokens per session scan A a49076858e21

Subscribe to this mod's changes

loom-prometheus is a skill published in the GitHub repository cosmix/loom (54 stars, last pushed today), licensed MIT. It adds 16 tokens to every session and 7,099 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

wrangler

Cloudflare Workers CLI for deploying, developing, and managing Workers, KV, R2, D1, Vectorize, Hyperdrive, Workers AI, Containers, Queues, Workflows, Pipelines, and Secrets Store. Load before running wrangler commands to ensure correct syntax and best practices. Biases towards retrieval from Cloudflare docs over…

cloudflare/skills · 75 tokens

agents-sdk

Build AI agents on Cloudflare Workers using the Agents SDK. Load when creating stateful agents, durable workflows, real-time WebSocket apps, scheduled tasks, MCP servers, chat applications, voice agents, or browser automation. Covers Agent class, state management, callable RPC, Workflows, durable execution, queues…

cloudflare/skills · 87 tokens

cloudflare-one-migrations

Plans migrations from Zscaler ZIA/ZPA, Palo Alto, legacy VPN, SWG, or SASE stacks to Cloudflare One. Use for migration assessments, policy mapping, rollout plans, and parity/gap analysis.

cloudflare/skills · 52 tokens

cloudflare

Comprehensive Cloudflare platform skill covering Workers, Pages, storage (KV, D1, R2), AI (Workers AI, Vectorize, Agents SDK), feature flags (Flagship), networking (Tunnel, Spectrum), security (WAF, DDoS), and infrastructure-as-code (Terraform, Pulumi). Use for any Cloudflare development task. Biases towards retrieval…

cloudflare/skills · 87 tokens

sandbox-migrate-to-next

Use when porting a Cloudflare Sandbox app from stable @cloudflare/sandbox to @cloudflare/sandbox@next (Sandbox SDK 1.0 preview), or when the user asks to migrate or upgrade to Sandbox 1.0 / @next. Not for day-to-day stable work (sandbox-stable) or new @next apps (sandbox-next).

cloudflare/skills · 79 tokens

sandbox-stable

Use when building or changing Cloudflare Sandbox apps on the current stable @cloudflare/sandbox package (default npm tag)—commands, sessions, files, ports, tunnels, terminals, bridge, production, or deprecated-API cleanup while staying on stable. Not for @cloudflare/sandbox@next (use sandbox-next) or for porting to…

cloudflare/skills · 85 tokens