Token导航 LogoToken导航TokenDH.com
研究检索敏感数据github未标认证来源可访问clear审计异常

agent-observabilityAgent 可观察性

Agent Skill

agent-observability 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

242

周安装

10

GitHub Stars

2

下载量

79
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

3

许可证

MIT

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:agent-observability(Agent 可观察性)
来源仓库:https://github.com/zpankz/mcp-skillset
仓库路径:skills/agent-observability
安装命令:
npx skills add https://github.com/zpankz/mcp-skillset --skill agent-observability
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。不同来源提供的安装方式可能略有差异;本站展示可直接复制的安装命令,安装前请核对来源页面。

skills.shnpx skills
npx skills add https://github.com/zpankz/mcp-skillset --skill agent-observability

简介

agent-observability 提供 Agent 运行时的可观察性仪表板,支持历史输出追踪和性能监控。

  • 适用于 Codex、Claude、Cursor、Gemini CLI 中需要记录任务历史、分析执行路径或调试问题的场景。
  • 通过 GitHub 安装,需配置 Bun 环境和 PAI_DIR 变量,支持 hooks 集成。
  • 安装前需确认权限范围、维护状态,以及是否会触发文件写入或终端操作。
  • 建议在使用时核对历史存储路径和钩子配置,确保数据完整性和隐私保护。

SKILL.md

Agent Observability Skill

Prerequisites

  • Bun runtime installed
  • Claude Code with hooks configured
  • PAI_DIR environment variable set

Installation

See SETUP.md for complete installation instructions.

Quick Setup:

# 1. Set environment variable
export PAI_DIR="$HOME/.claude"  # Add to ~/.zshrc or ~/.bashrc

# 2. Configure hooks (merge into ~/.claude/settings.json)
cat settings.json.example

# 3. Create directory structure
mkdir -p ~/.claude/history/raw-outputs

# 4. Install dependencies
cd apps/server && bun install
cd ../client && bun install

Usage

Start the Observability Dashboard

Terminal 1 - Server:

cd ~/Projects/PAI/skills/agent-observability/apps/server
bun run dev

Terminal 2 - Client:

cd ~/Projects/PAI/skills/agent-observability/apps/client
bun run dev

Open browser: http://localhost:5173

Using Claude Code

Once the dashboard is running, any Claude Code activity will appear in real-time:

  1. Open Claude Code
  2. Use any tool (Read, Write, Bash, etc.)
  3. Launch subagents with Task tool
  4. Watch events appear in the dashboard

Event Types Captured

  • SessionStart - New Claude Code session begins
  • UserPromptSubmit - User sends a message
  • PreToolUse - Before a tool is executed
  • PostToolUse - After a tool completes
  • Stop - Main agent task completes
  • SubagentStop - Subagent task completes
  • SessionEnd - Session ends

Features

Real-Time Visualization

  • Agent Swim Lanes: See multiple agents (kai, designer, engineer, etc.) running in parallel
  • Event Timeline: Chronological view of all events
  • Tool Usage Charts: Visualize which tools are being used most
  • Session Tracking: Track individual sessions and their lifecycles

Filtering & Search

  • Filter by agent name (kai, designer, engineer, pentester, etc.)
  • Filter by event type (PreToolUse, PostToolUse, etc.)
  • Filter by session ID
  • Search event payloads

Data Storage

Events are stored in JSONL (JSON Lines) format:

~/.claude/history/raw-outputs/YYYY-MM/YYYY-MM-DD_all-events.jsonl

Each line is a complete JSON object:

{"source_app":"kai","session_id":"abc123","hook_event_type":"PreToolUse","payload":{...},"timestamp":1234567890,"timestamp_pst":"2025-01-28 14:30:00 PST"}

In-Memory Streaming

  • Server keeps last 1000 events in memory
  • Low memory footprint
  • Fast real-time updates via WebSocket
  • No database overhead

Architecture

┌─────────────────┐
│  Claude Code    │  Executes hooks on events
│   (with hooks)  │
└────────┬────────┘
         │
         ▼
┌─────────────────┐
│ capture-all-    │  Appends events to JSONL
│ events.ts hook  │
└────────┬────────┘
         │
         ▼
┌─────────────────────────────────────┐
│ ~/.claude/history/raw-outputs/      │  Daily JSONL files
│ 2025-01/2025-01-28_all-events.jsonl │
└────────┬────────────────────────────┘
         │
         ▼
┌─────────────────┐
│ file-ingest.ts  │  Watches files, streams to memory
│  (Bun server)   │
└────────┬────────┘
         │
         ▼
┌─────────────────┐
│  Vue 3 Client   │  Real-time dashboard visualization
│  (Vite + Tail)  │
└─────────────────┘

Configuration

Environment Variables

PAI_DIR: Path to your PAI directory (defaults to ~/.claude/)

export PAI_DIR="/Users/yourname/.claude"

Hooks Configuration

Add to ~/.claude/settings.json (see settings.json.example for full template):

{
  "hooks": {
    "PreToolUse": [{
      "matcher": "*",
      "hooks": [{
        "type": "command",
        "command": "${PAI_DIR}/skills/agent-observability/hooks/capture-all-events.ts --event-type PreToolUse"
      }]
    }],
    // ... other hooks
  }
}

Troubleshooting

No events appearing

  1. Check PAI_DIR is set: echo $PAI_DIR
  2. Verify directory exists: ls ~/.claude/history/raw-outputs/
  3. Check hook is executable: ls -l hooks/capture-all-events.ts
  4. Look for today's events file: ls ~/.claude/history/raw-outputs/$(date +%Y-%m)/

Server won't start

  1. Check Bun is installed: bun --version
  2. Verify dependencies: cd apps/server && bun install
  3. Check port 3001 isn't in use: lsof -i:3001

Client won't connect

  1. Ensure server is running first
  2. Check WebSocket connection in browser console
  3. Verify no firewall blocking localhost:3001

Credits

Inspired by @indydevdan's pioneering work on multi-agent observability for Claude Code.

Our implementation differs by using filesystem-based event capture and in-memory streaming instead of SQLite database persistence. Both approaches have their merits! Check out indydevdan's work for a database-backed solution with full historical persistence.

Development

Running in Development

# Server (hot reload)
cd apps/server
bun --watch src/index.ts

# Client (Vite dev server)
cd apps/client
bun run dev

Building for Production

# Client build
cd apps/client
bun run build
bun run preview

Adding New Event Types

  1. Update capture-all-events.ts hook if needed
  2. Add hook configuration to settings.json
  3. Client will automatically display new event types

Documentation

License

Part of the PAI (Personal AI Infrastructure) project.

Contributing

Contributions welcome! Areas for improvement:

  • Historical data persistence options
  • Export functionality (CSV, JSON)
  • Alert/notification system
  • Advanced filtering and search
  • Session replay capability
  • Integration with other PAI skills

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

04

需要参考平台分布和安装热度时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

OpenCode

28.81%
按下载量换算23

Claude Code

23.64%
按下载量换算19

windsurf

15.93%
按下载量换算13

Codex

13.13%
按下载量换算10

kiro-cli

7.1%
按下载量换算6

mcpjam

3.03%
按下载量换算2

安全审计

Gen Agent Trust Hub

未通过

Socket

通过

Snyk

通过

权限和风险

敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。

来源信息

继续浏览同类 Skills