‹ 首页

braintrust-analyze

@vibeeval · 收录于 1 周前 · 上游提交 1 个月前

Analyze Claude Code sessions via Braintrust

适合你,如果使用 Claude Code 并想通过数据驱动方式提升代码质量

/ 下载安装
braintrust-analyze.skill双击,或拖进 Claude 桌面版 / Cowork,即完成安装↓ .skill↓ .zip
用别的 agent?下载 .zip 解压,把文件夹放进它的技能目录
Claude Code~/.claude/skills/(项目级 .claude/skills/)
Codex CLI~/.codex/skills/
Cursor自动读取上面两处目录
其他工具见其文档的「skills」目录;两个下载是同一份文件,只是名字不同
/ 通过 npx 安装 校验哈希
npx oh-my-skill add vibeeval/vibecosystem/braintrust-analyze
/ 通过 bash 安装
curl -fsSL https://oh-my-skill.com/install.sh | bash -s -- vibeeval/vibecosystem/braintrust-analyze
/ 已经装过?验证本机副本,不用重装
npx oh-my-skill verify vibeeval/vibecosystem/braintrust-analyze
安装目标可用 --agent / --scope 或 --to 明确指定;省略时只会在唯一已存在的 agent 目录上自动选择,零命中或多命中会停止并提示。content_hash 缺失或不一致均拒装。
515GitHub stars
~546上下文体积 · 单文件
镜像托管

怎么用

技能原文 SKILL.md作者撰写 · MIT · cea9462

Braintrust Analysis

Analyze your Claude Code sessions for patterns, issues, and insights using Braintrust tracing data.

When to Use
  • After completing a complex task (retrospective)
  • When debugging why something failed
  • Weekly review of productivity patterns
  • Finding opportunities to create new skills
  • Understanding token usage trends
Commands

Run from the project directory:

# Analyze last session - summary with tool/agent/skill breakdown
uv run python -m runtime.harness scripts/braintrust_analyze.py --last-session

# List recent sessions
uv run python -m runtime.harness scripts/braintrust_analyze.py --sessions 5

# Agent usage statistics (last 7 days)
uv run python -m runtime.harness scripts/braintrust_analyze.py --agent-stats

# Skill usage statistics (last 7 days)
uv run python -m runtime.harness scripts/braintrust_analyze.py --skill-stats

# Detect loops - find repeated tool patterns (>5 same tool calls)
uv run python -m runtime.harness scripts/braintrust_analyze.py --detect-loops

# Replay specific session - show full sequence of actions
uv run python -m runtime.harness scripts/braintrust_analyze.py --replay <session-id>

# Weekly summary - daily activity breakdown
uv run python -m runtime.harness scripts/braintrust_analyze.py --weekly-summary

# Token trends - usage over time
uv run python -m runtime.harness scripts/braintrust_analyze.py --token-trends
Options
  • --project NAME - Braintrust project name (default: agentica)
What You'll Learn
Session Analysis
  • Tool usage breakdown
  • Agent spawns (plan-agent, debug-agent, etc.)
  • Skill activations (/commit, /research, etc.)
  • Token consumption estimates
Loop Detection

Find sessions where the same tool was called repeatedly, which may indicate:

  • Stuck in a search loop
  • Inefficient approach
  • Opportunity for better tooling
Usage Patterns
  • Which agents you use most
  • Which skills get activated
  • Daily/weekly activity trends
Examples
Quick Retrospective
# What happened in my last session?
uv run python -m runtime.harness scripts/braintrust_analyze.py --last-session

Output:

## Session Analysis
**ID:** `92940b91...`
**Started:** 2025-12-24T01:31:05Z
**Spans:** 14

### Tool Usage
- Read: 4
- Bash: 2
- Edit: 2
...
Find Loops
uv run python -m runtime.harness scripts/braintrust_analyze.py --detect-loops
Weekly Review
uv run python -m runtime.harness scripts/braintrust_analyze.py --weekly-summary
Requirements
  • BRAINTRUST_API_KEY in ~/.claude/.env or project .env
  • Braintrust tracing enabled (via braintrust-claude-plugin)
按 MIT 许可原样转载,未经改动 · 在 GitHub 查看 →

评论

登录即可评论;带「已验证安装」的,是发布者名下有本店的安装或持有记录。