phoenix-tracing
它能做什么
这个工具可以帮你追踪并理解 AI 程序的运行方式。它会记录每一个步骤,就像摄像机记录事件一样,让你看清到底发生了什么。
适用场景
- ✓在设置 AI 追踪时。
- ✓在代码中创建自定义的追踪步骤时。
- ✓在为系统投入生产使用做准备时。
技能链接
https://github.com/github/awesome-copilot/blob/main/skills/phoenix-tracing/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“我该如何为 Python 设置追踪?”
每周 5 个新技能,1 分钟读完。
工作原理
它的原理是记录 AI 操作的详细信息,比如使用了哪些模型、耗时多久、处理了什么数据。这些信息会形成一条可供分析的 'trace'。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
Phoenix Tracing
Comprehensive guide for instrumenting LLM applications with OpenInference tracing in Phoenix. Contains reference files covering setup, instrumentation, span types, and production deployment.
When to Apply
Reference these guidelines when:
- Setting up Phoenix tracing (Python or TypeScript)
- Creating custom spans for LLM operations
- Adding attributes following OpenInference conventions
- Deploying tracing to production
- Querying and analyzing trace data
Reference Categories
| Priority | Category | Description | Prefix |
|---|---|---|---|
| 1 | Setup | Installation and configuration | setup-* |
| 2 | Instrumentation | Auto and manual tracing | instrumentation-* |
| 3 | Span Types | 9 span kinds with attributes | span-* |
| 4 | Organization | Projects and sessions | projects-*, sessions-* |
| 5 | Enrichment | Custom metadata | metadata-* |
| 6 | Production | Batch processing, masking | production-* |
| 7 | Feedback | Annotations and evaluation | annotations-* |
Quick Reference
1. Setup (START HERE)
- setup-python - Install arize-phoenix-otel, configure endpoint
- setup-typescript - Install @arizeai/phoenix-otel, configure endpoint
2. Instrumentation
- instrumentation-auto-python - Auto-instrument OpenAI, LangChain, etc.
- instrumentation-auto-typescript - Auto-instrument supported frameworks
- instrumentation-manual-python - Custom spans with decorators
- instrumentation-manual-typescript - Custom spans with wrappers
3. Span Types (with full attribute schemas)
- span-llm - LLM API calls (model, tokens, messages, cost)
- span-chain - Multi-step workflows and pipelines
- span-retriever - Document retrieval (documents, scores)
- span-tool - Function/API calls (name, parameters)
- span-agent - Multi-step reasoning agents
- span-embedding - Vector generation
- span-reranker - Document re-ranking
- span-guardrail - Safety checks
- span-evaluator - LLM evaluation
4. Organization
- projects-python / projects-typescript - Group traces by application
- sessions-python / sessions-typescript - Track conversations
5. Enrichment
- metadata-python / metadata-typescript - Custom attributes
6. Production (CRITICAL)
- production-python / production-typescript - Batch processing, PII masking
7. Feedback
- annotations-overview - Feedback concepts
- annotations-python / annotations-typescript - Add feedback to spans
Reference Files
- fundamentals-overview - Traces, spans, attributes basics
- fundamentals-required-attributes - Required fields per span type
- fundamentals-universal-attributes - Common attributes (user.id, session.id)
- fundamentals-flattening - JSON flattening rules
Common Workflows
- Quick Start: setup-{lang} → instrumentation-auto-{lang} → Check Phoenix
- Custom Spans: setup-{lang} → instrumentation-manual-{lang} → span-{type}
- Session Tracking: sessions-{lang} for conversation grouping patterns
- Production: production-{lang} for batching, masking, and deployment
How to Use This Skill
…
常见问题
什么是 'spans'?
'Spans' 就像 trace 中某个具体操作的单独记录,比如一次 AI 模型调用或一次数据检索。
什么是 'OpenInference'?
OpenInference 是一种标准,能确保不同工具之间的追踪信息保持一致。
使用这个工具需要会编程吗?
要完成设置并使用基础功能,一些编程知识会有帮助。不过分析追踪结果并不需要编程基础。
详情
作者的原始描述
OpenInference semantic conventions and instrumentation for Phoenix AI observability. Use when implementing LLM tracing, creating custom spans, or deploying to production.
repo: github/awesome-copilot
热度
- GitHub 星标
- 40k
- 排名
- #7322
- 许可证
- MIT
- 更新时间
- 2026/10/15
评论
- …
同一仓库的更多技能
acquire-codebase-knowledge
40k帮你的智能体理解并编写现有代码项目的文档。它有助于新成员快速上手,或者快速了解项目架构。
acreadiness-assess
40k让你的智能体评估一个项目对 AI 的准备程度,并生成报告。它有助于了解项目在使用 AI 工具方面的准备情况。
acreadiness-generate-instructions
40k帮你的智能体根据评估结果编写 AI 工具的指令文件。它有助于改善 AI 与代码的交互方式,并弥补已发现的不足。
acreadiness-policy
40k让你的智能体协助制定或应用 AI 项目评估的政策。它有助于规范项目的评估方式,并确保合规。