[CNCF LFX Proposal] OpenTelemetry — Zero-code AI Agent observability for otelc
- Dominant language
- JavaScript
- Stars
- 3.1k
- Forks
- 816
- Avg merge
- 12h 32m
- Merged PRs (30d)
- 8
Description
### CNCF Project
OpenTelemetry
### Term
2026 Term 3 (Sep-Nov)
### Program Name
Zero-code AI Agent observability for otelc
### Program Description
Design and build an **AI provider adapter interface** in `otelc` (`opentelemetry-go-compile-instrumentation`) — OpenTelemetry's compile-time, zero-code instrumentation for Go — that emits the `gen_ai.*` semantic conventions (spans, metrics, events) through a single shared abstraction, so AI providers and libraries plug into a common contract instead of being instrumented ad hoc.
The already-merged OpenAI instrumentation (#604) is migrated onto this interface as the reference implementation, then the adapter is extended to additional providers and libraries: `anthropic-sdk-go`, Gemini, and the MCP / LangChain frameworks. MCP/LangChain require non-HTTP hooks (following the Kafka/Redis instrumentation patterns) rather than the HTTP-based path.
This design-first framing gives the mentee real architecture and problem-solving work — defining the adapter contract, mapping heterogeneous provider APIs onto shared semconv, and validating it across libraries — rather than repetitive per-library instrumentation.
Community demand is concrete and vendor-neutral: the OpenAI instrumentation (#604) closed community issue #327, and the request pipeline is active (#706 for aws-sdk-go-v2, #553 MongoDB shipped).
Deliverables follow a week-by-week plan where each milestone ships a runnable demo + green CI so progress is visible at a glance: adapter interface + OpenAI migration → anthropic-sdk-go → Gemini → MCP → LangChain, each with instrumentation rules, tests under the paired `test/` directory, and an example app emitting `gen_ai.*` spans.
Privacy posture: message bodies are off by default and strictly opt-in via `OTEL_INSTRUMENTATION_GENAI_CAPTURE_MESSAGE_CONTENT` — nothing is captured unless the operator turns it on.
### Technologies
Go, OpenTelemetry, compile-time instrumentation, gen_ai semantic conventions, API/interface design
### Skills same as Technologies?
- [x] Yes, the required skills are the same as the technologies listed above.
### Required/Desirable Skills
_No response_
### Mentors
Haibin Zhang | @NameHaibinZhang | namehaibinzhang@gmail.com | zhanghaibin1990
Xabier Martinez | @txabman42 | x42.martinez@gmail.com | x42.martinez
### Upstream Issue URL
https://github.com/open-telemetry/opentelemetry-go-compile-instrumentation/issues/709
### Application Prerequisites
- [x] Resume
- [x] Cover Letter
- [ ] School Enrollment Verification
- [ ] Participation Permission from school or employer
- [ ] Coding Challenge
- [ ] Custom Prerequisite (fill in details below)
### Coding Challenge URL
_No response_
### Custom Prerequisite Name
_No response_
### Custom Prerequisite Description
_No response_
### Custom Prerequisite — File Upload
- [ ] Yes — completion of this task requires the mentee to submit a file.
---
**LFX program:** [CNCF - OpenTelemetry: Zero-code AI Agent observability for otelc (2026 Term 3)](https://mentorship.lfx.linuxfoundation.org/project/91cab14a-42aa-4e08-9144-3b243309e68c)
Contributor guide
Research direction
Start by reading upstream issue #709 and the already-merged OpenAI instrumentation (#604) in opentelemetry-go-compile-instrumentation. Define the shared adapter contract, then validate each provider or framework in its paired test/ directory and example app. Done means the planned providers emit gen_ai.* telemetry with green CI and message capture remains opt-in.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- ai, backend-api-design, observability-sre
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100