agentleFS
kernelkernel/hypeman/skills/monitoring-feature-observability/SKILL.md

monitoring-feature-observability

Skill373 starsChanged 22 days agoMITView on GitHub

Add or adjust monitoring for a Hypeman feature using repository standards for logs, traces, and metrics. Use when a user asks for instrumentation, observability reviews, telemetry consistency changes, metric design, or production-signal improvements.

The file

We split this skill into the rules it gives an agent

6 rules. About 0 are common, 5 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈5

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use WARN and ERROR logs appropriately.

    line 18
  2. Distinctive:

    All API requests should support tracing.

    line 23
  3. Distinctive:

    Use counters where advisable to avoid sampling errors in data.

    line 36
  4. Distinctive:

    All features should have at least one good application-level metric.

    line 39
  5. Distinctive:

    Do not create denormalized metrics (containing information that can be derived from other metrics).

    line 41
  6. Very specific:

    Look in DEVELOPMENT.md (section: Local OpenTelemetry (optional)) for how to collect telemetry from a local server.

    line 43

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Monitoring Feature Observability

Your task is to add monitoring for a specific feature or to perform a specific monitoring-related ask from the user.

Logging

  • Logging uses structured slog JSON with per-subsystem levels (LOG_LEVEL, LOG_LEVEL_<SUBSYSTEM>). Logs are enriched with subsystem, and when trace context exists, trace_id/span_id: lib/logger/logger.go.
  • During normal running of the system without requests or events being sent to the system, there should be minimal to no logging at the INFO level or greater. So ongoing maintenance items should not be logging at INFO or greater.
  • During a request (for example, API call) or interrupt/event (for example, guest program stops), the normal case should have about one informative log at INFO level, usually just one log.
  • Other useful but normal information within a single request/event should be at DEBUG level accordingly. Do not use TRACE level.
  • Logs resulting from a single request or event should not provide much duplicated information.
  • Logs with instance_id are also duplicated into per-instance logs/hypeman.log, and instance log APIs stream them, so be sure to set instance_id or other resourcetype_id accordingly.
  • Use WARN and ERROR logs appropriately.
  • Logs should be associated with traces.

Tracing

  • All API requests should support tracing.
  • Tracing should span down as far as reasonable, ideally all the way down unless there is a good reason not to.
  • For example, trace down into clients calling each hypervisor.
  • Per-instance identifiers (for example, instance_id) are allowed in trace attributes when they materially improve debugging or correlation.
  • Still avoid sensitive or unbounded attributes by default (for example, full guest paths, user identifiers, tokens, arbitrary payload fields).

Metrics

  • Metrics should be created in Prometheus/OpenMetrics format using normal best practices.
  • Metrics are emitted via OTel instruments (counters/histograms/gauges) across subsystems (instances, images, network, and so on).
  • Low-cardinality labels only (for example, no VM name, IP address, or ID labels).
  • Per-VM metric labels are an explicit exception when operationally required (for example instance_id, instance_name) and should be guarded with budget/alerting.
  • Confirm with the user before adding any new high-cardinality metric label.
  • Use counters where advisable to avoid sampling errors in data.
  • Usually include timing histogram metrics.
  • Work with the user to agree on good application-level signals to monitor for a given feature, providing examples in terms of what it would look like on the /metrics endpoint.
  • All features should have at least one good application-level metric.
  • Confirm with the user before removing metrics.
  • Do not create denormalized metrics (containing information that can be derived from other metrics).

Look in DEVELOPMENT.md (section: Local OpenTelemetry (optional)) for how to collect telemetry from a local server.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.