Skills DirectorySkills Directory
SkillsLearnSecurityCategoriesDocsBlogPro
Sign InSubmit Skill
Skills Directory

Security-tested agent skills for Claude, coding agents, and AI workflows.

Directory

  • Browse Skills
  • All Skills A–Z
  • Claude Skills
  • Claude Code Skills
  • Agent Skills
  • Categories
  • Authors
  • Submit a Skill

Learn

  • Learn Hub
  • Install Claude Skills
  • Write SKILL.md
  • Skills vs MCP
  • Directories Compared

Security

  • Security
  • Methodology
  • Secure Claude Skills
  • Security Badges
  • Chrome Extension
  • Skill Manager

Company

  • About
  • Community
  • Blog
  • API Docs
  • Advertise

2026 Skills Directory. All rights reserved.

ProTermsPrivacyRefunds
Back to skills

Continuum Observability

ASecurity

Trace agent runs with Langfuse, decorate functions with @observe, collect latency/token/error metrics, and report errors. Invoke when the user asks about "see what the LLM was prompted with", "Langfuse traces", "track latency", "metrics dashboard", "error reporting", or "instrument my function".

85 stars
0 votes
0 copies
2 views
Added 6/5/2026
ai-agentspythongobashdockerdebuggingdatabase

Works with

cli

Security Analysis

A100/100

Scanned 6/5/2026

$npx -y skills add shyftlabs/continuum --skill continuum-observability --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Continuum Observability?

Add the live security badge to your README — it updates automatically with every re-scan.

Security grade badge for Continuum Observability
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/shyftlabs-continuum-observability/badge)](https://www.skillsdirectory.com/skills/shyftlabs-continuum-observability)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
Files
SKILL.md
---
name: continuum-observability
description: Trace agent runs with Langfuse, decorate functions with @observe, collect latency/token/error metrics, and report errors. Invoke when the user asks about "see what the LLM was prompted with", "Langfuse traces", "track latency", "metrics dashboard", "error reporting", or "instrument my function".
---

# Continuum Observability Skill

Authoritative source: [`docs/observability.md`](../../../docs/observability.md).

---

## Quick start

Tracing is on by default if Langfuse is configured.

```bash
docker compose --profile observability up -d              # brings up Langfuse on :3000
```

```env
LANGFUSE_ENABLED=true
LANGFUSE_HOST=http://localhost:3000
LANGFUSE_PUBLIC_KEY=…                                      # from Langfuse UI
LANGFUSE_SECRET_KEY=…
```

Open http://localhost:3000 — every agent run, LLM call, and tool call
shows up automatically.

To disable: `LANGFUSE_ENABLED=false`.

---

## Trace your own functions

```python
from orchestrator.observability import observe, SpanLevel

@observe(name="my-pipeline", capture_input=True, capture_output=True,
         metadata={"version": "v2"}, level=SpanLevel.DEFAULT)
async def run_pipeline(data):
    ...
```

Specialized variants:

```python
from orchestrator.observability import trace_tool, trace_agent

@trace_tool(name="search_db", tool_type="database")
def search_db(query): ...

@trace_agent
async def my_custom_agent_runner(...): ...
```

---

## Manual spans

```python
from orchestrator.core.container import get_container

mgr = get_container().tracing_manager

with mgr.trace(name="onboarding", user_id="u1", session_id="s1",
               metadata={"tier": "pro"}, tags=["beta"]) as trace:
    with mgr.span(name="step-1", input={"foo": 1}) as span:
        span.event(name="cache-hit")
        span.score(name="quality", value=0.92)
```

Generation spans (LLM calls):

```python
with mgr.span(name="step") as span:
    gen = span.generation(name="llm-call", model="gpt-4o-mini",
                          input=messages)
    # … call the LLM …
    gen.end(output=response_text,
            usage_prompt_tokens=120, usage_completion_tokens=80, usage_total_tokens=200)
```

---

## Async-safe trace context

```python
from orchestrator.observability import (
    set_trace_context, restore_trace_context,
    get_current_trace_id, get_current_session_id, get_current_user_id,
)

token = set_trace_context(trace_id="abc", user_id="u1", session_id="s1")
try:
    await client.chat(messages)                # inherits the trace context
finally:
    restore_trace_context(token)
```

---

## Metrics

```python
from orchestrator.observability import (
    get_metrics_collector, get_metrics_summary, reset_metrics,
)

mc = get_metrics_collector()

# Latency
with mc.track_latency("rag.retrieve") as m:
    docs = await retrieve(query)
print(m.duration_ms)

# Or record directly
mc.record_latency("db.query", 12.4, metadata={"table": "users"})

summary = get_metrics_summary()      # {latency: {...}, tokens: {...}, errors: {...}}
```

---

## Error reporting

```python
from orchestrator.observability import (
    report_error, report_exception, flush_errors,
    enable_error_reporting, disable_error_reporting,
)

try:
    ...
except SomeError as e:
    # `context` is a short label string; structured data goes in `metadata=`.
    report_error(e, context="db_query", user_id="u1", metadata={"table": "users"})
```

Every `OrchestratorError` with `should_report=True` is reported
automatically. The reporter has a thread-safe queue (max 1000 entries)
and an auto-flush every 5 seconds.

---

## Debug tip: log the assembled prompt

```env
LOG_FULL_PROMPT=true
```

The runner prints the entire message list it sends to the LLM —
indispensable for debugging memory / RAG / handoff flows.

---

## ObservabilityConfig (when wiring providers manually)

```python
from orchestrator.observability import ObservabilityConfig, initialize_observability

cfg = ObservabilityConfig(
    providers=["langfuse"],
    enabled=True,
    public_key="pk-…", secret_key="sk-…",
    host="http://localhost:3000",
    sample_rate=1.0, flush_interval=1, flush_at=15,
    environment="production", default_tags=["app:billing"],
)
mgr = initialize_observability(cfg)
```

The lifecycle manager normally calls this for you.

---

## Custom provider

```python
from orchestrator.observability import (
    ObservabilityProvider, ProviderCapabilities, register_provider,
)

class MyProvider(ObservabilityProvider):
    def __init__(self): super().__init__(name="my", config={})
    def supports_feature(self, feat): return feat == ProviderCapabilities.TRACE
    def trace(self, name, **kw): ...
    def span(self, *, trace_id, name, **kw): ...
    # …generation, event, score, flush, shutdown

register_provider("my", MyProvider())
```

---

## Don't

- Don't expect to see traces if `LANGFUSE_ENABLED=false` or the keys
  are missing.
- Don't rely on `@observe` to capture huge payloads — `truncate_data`
  caps each field at 10 KB by default.
- Don't make `@observe`-decorated functions sync if the rest of your
  code is async — the contextvars magic works best in fully-async code.
- Don't `flush_langfuse()` in the middle of a request loop — it's
  expensive. Lifecycle shutdown handles it.
- Don't forget to set `SHARED_SERVICES_ENABLED=false` if your process
  is the sole owner of Langfuse — otherwise traces don't flush on
  shutdown.

Attribution

shyftlabsshyftlabs
View sourceSee grades on GitHubMore from shyftlabs →
SSkills DirectorySkills Directory

Ship a skill? Prove it's safe.

Free 120-pattern security scan, letter grade, and an embeddable README badge.

Submit a skill

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments (0)

No comments yet. Be the first to comment!

SSkills DirectorySkills Directory

Ship a skill? Prove it's safe.

Free 120-pattern security scan, letter grade, and an embeddable README badge.

Submit a skill

Related Skills

Caveman

Terse caveman voice: answer first, fluff gone, every technical fact kept. Use for /caveman, "caveman mode", "talk like caveman", "be brief", "less tokens". Stays on until "stop caveman" or "normal mode".

1100021 votes

Hyperplan

Adversarial multi-agent planning skill. Self-orchestrates 5 hostile category members (unspecified-low, unspecified-high, deep, ultrabrain, artistry) via team-mode for ruthless cross-critique debate, distills only the defensible insights, then MANDATORILY hands the distilled insight bundle to the `plan` agent for executable plan formalization. Use when planning needs maximum rigor and surfacing of weak assumptions, blind spots, and over-engineering. Triggers: 'hyperplan', 'hpp', '/hyperplan', ...

698621 votes

Writing Skills

Create and manage Claude Code skills in HASH repository following Anthropic best practices. Use when creating new skills, modifying skill-rules.json, understanding trigger patterns, working with hooks, debugging skill activation, or implementing progressive disclosure. Covers skill structure, YAML frontmatter, trigger types (keywords, intent patterns), UserPromptSubmit hook, and the 500-line rule. Includes validation and debugging with SKILL_DEBUG. Examples include rust-error-stack, cargo-dep...

3931 votes

Mcp Code Execution

Routes multi-tool workflows through MCP servers for large datasets and pipelines. Use when Bash tool overhead is limiting throughput on data-heavy tasks.

3421 votes

catchup

Recovers the conversation and failed tool calls of a previous Codex, Amp, Claude Code, Antigravity, Cline, Copilot CLI, Cursor, DeepSeek Harness, Grok Build, Kimi, OpenCode, Pi Agent, or ZCode session. Use when the user says "catch up", "what did the last session do", "get me up to speed", "I switched agents", asks to recover/summarize a previous session before continuing, or asks to diagnose or report a catchup failure. Do NOT use for the current conversation, git history, or any non-agent log.

741 votes
View all in ai-agents →