PlugWiki

python-observability Skill for Claude Code: Logging, Metrics and Tracing

Teaches Claude to add structured logging, Prometheus metrics, correlation IDs and tracing to a Python app so you can debug production without redeploying.

Installs
11.8K
on skills.sh
Stars
42.1K
on GitHub
Files
1
besides SKILL.md
Updated
Oct 2026
last repo commit

python-observability gives Claude eight patterns for instrumenting Python code. Four are in the SKILL.md: structured logging with structlog, consistent log fields, log levels, and correlation ID propagation with a FastAPI middleware. Four more are in a details file: the four golden signals with Prometheus, bounded label cardinality, timed operations and OpenTelemetry tracing.

It triggers when you ask for logging, metrics, tracing or help debugging production. The folder holds 2 Markdown files and no scripts. The SKILL.md has no install commands. Its examples import packages such as structlog, FastAPI, httpx and OpenTelemetry, so your project needs the ones you use.

Good for

  • Python developers adding logging or metrics to a service
  • Teams debugging production issues across several services
  • FastAPI users who want request IDs carried through logs and calls

Install python-observability

Claude Code

  1. 1

    Copy this prompt.

    Install the python-observability skill in Claude Code. Run this command:
    
    /plugin marketplace add wshobson/agents
    /plugin install python-development@claude-code-workflows
    
    Then check that it loaded and tell me how to use it.
  2. 2

    Paste it into Claude Code. It shows the change and asks before running it.

Pick one route. The python-development plugin adds 15 more Python skills, 3 agents and a /python-development:python-scaffold command. The skills-only route installs just this skill, without the plugin's agents or commands (README).

From the project README. Source.

What's in the skill

When it loads

Python observability patterns including structured logging, metrics, and distributed tracing. Use when adding logging, implementing metrics collection, setting up tracing, or debugging production systems.

Sections in SKILL.md

  1. When to Use This Skill
  2. Core Concepts
  3. 1. Structured Logging
  4. 2. The Four Golden Signals
  5. 3. Correlation IDs
  6. 4. Bounded Cardinality
  7. Quick Start
  8. Fundamental Patterns
  9. Pattern 1: Structured Logging with Structlog
  10. Pattern 2: Consistent Log Fields
  11. Pattern 3: Semantic Log Levels
  12. Pattern 4: Correlation ID Propagation
  13. Detailed worked examples and patterns
  14. Best Practices Summary

Key facts

License
MIT
Installs on skills.sh
11,805 (Nov 2, 2026)
Files in the skill folder
2 files including SKILL.md

What it includes

  • Configures JSON logs with a timestamp, level and context.

    Pattern 1, with a configure_logging function to call at startup.

    Structured logging with structlog

  • Gives every entry the same fields for filtering.

    Pattern 2: correlation ID, method, path, status code and duration.

    Consistent log fields

  • Defines DEBUG, INFO, WARNING and ERROR use.

    Pattern 3. Expected behavior, such as a wrong password, is INFO, not ERROR.

    Semantic log levels

  • Threads a request ID through logs and outbound calls.

    Pattern 4: a FastAPI middleware plus an httpx call that forwards the header.

    Correlation ID propagation

  • Tracks latency, traffic, errors and saturation with Prometheus.

    Pattern 5, in references/details.md.

    Four golden signals

  • Keeps metric label values to a small set.

    Pattern 6: never use user IDs as labels.

    Bounded cardinality

  • Wraps timing and error handling in a context manager.

    Pattern 7, in references/details.md.

    Timed operations

  • Adds distributed tracing across services.

    Pattern 8. The file notes the OpenTelemetry API is still changing.

    OpenTelemetry tracing

  • A 10-point checklist, from structured logs to alerts.

    Ends the SKILL.md.

    Best practices summary

From the official docs

Questions

What does python-observability do?

It teaches Claude to instrument a Python app with structured logs, metrics and traces. It gives patterns for log fields, levels, correlation IDs, Prometheus signals and OpenTelemetry.

How do I install it?

Use the install box above. The README offers the python-development plugin, which adds 16 Python skills and 3 agents, or a skills-only install of just this skill.

Does it work in Claude.ai, Codex or Cursor?

The README documents Claude Code and Codex plugins, and a Cursor plugin marketplace. For other tools it points to the skills-only installers. It does not describe the Claude app.

Which libraries does it use?

The examples use structlog, FastAPI, httpx, Prometheus and OpenTelemetry. The skill does not tell Claude to install them, so check your dependencies after Claude adds code.

Is it safe?

The skill bundles no scripts and has no install commands. It gives Claude code patterns to write into your project, so review the generated changes as you would any other code, especially what gets logged.

Can it log sensitive data?

The log examples include fields such as user_id and request paths. Decide which fields are safe to log before shipping, and ask Claude to leave out personal data.

Information

updated Nov 2, 2026

Repository
wshobson/agents
Folder
plugins/python-development/skills/python-observability

wshobson/agentsskills.sh

Sources

Docs, issue trackers and discussions this page is built from.

Show all 4
  1. wshobson/agents README · github.com
  2. python-observability SKILL.md · github.com
  3. python-observability details.md · github.com
  4. python-development plugin.json · github.com

Updated Nov 2, 2026.