Skip to content

Update open-telemetry/semantic-conventions-genai to latest - #7642

Draft
github-actions[bot] wants to merge 2 commits into
mainfrom
update-otel-genai-to-latest
Draft

Update open-telemetry/semantic-conventions-genai to latest#7642
github-actions[bot] wants to merge 2 commits into
mainfrom
update-otel-genai-to-latest

Conversation

@github-actions

@github-actions github-actions Bot commented Jul 19, 2026

Copy link
Copy Markdown
Contributor

Draft pending the first release of open-telemetry/semantic-conventions-genai. Both conventions are Development stability and unreleased.

Release tagging confidence: none — no published GenAI release signal exists yet (GitHub releases API returns 404).

What this PR implements

Area Convention Upstream Compensating change
gen-ai gen_ai.request.reasoning.level #258 Added constant; emitted from ChatOptions.Reasoning.Effort.
gen-ai gen_ai.execute_tool.duration metric #201 Added metric constant, factory, Meter service, emission in FunctionInvocationProcessor.

Validation: build clean (net8.0 / net9.0 / net10.0, 0 warnings); 694 tests pass. No public API change.

Upstream scan tracking

Scanned at 8d3e4a0 on 2026-08-12.

Legend: 🔴 implemented · ✅ already aligned · 🟡 watch/deferred · 🟢 not applicable

Upstream PR Area Change Status
#97 gen-ai/agent plan operation 🟡 No planning span in MEAI
#99 gen-ai moonshot_ai provider value 🟢 Provider names are strings, no constant needed
#107 gen-ai/agent gen_ai.agent.name sampling-relevant ✅ Spec metadata only
#126 gen-ai gen_ai.invoke_workflow.duration metric 🟡 No workflow span in MEAI
#136 mcp MCP server span opt-in attributes 🟢 No MCP instrumentation
#140 gen-ai Memory operation spans/attributes 🟡 No memory instrumentation
#142 gen-ai document modality value 🟡 Watch for document content parts
#162 gen-ai gen_ai.conversation.compacted, CompactionPart 🟡 No compaction concept in MEAI
#179 gen-ai gen_ai.prompt.version / variable 🟡 No prompt tracking in MEAI
#201 gen-ai gen_ai.execute_tool.duration, invoke_agent.duration 🔴 execute_tool.duration implemented; invoke_agent.duration deferred
#211 gen-ai Billed token count clarification ✅ Docs-only
#212 gen-ai gen_ai.provider.name generalization ✅ Docs-only
#214 gen-ai provider.name conditionally required ✅ Docs-only
#216 gen-ai Span duration includes retries ✅ Docs-only
#217 gen-ai top_k type double→int; retrieval uses gen_ai.retrieval.top_k TopK is int?
#219 gen-ai conversation.id no fallback values ✅ Docs-only
#220 mcp MCP context propagation 🟢 No MCP instrumentation
#242 gen-ai/agent gen_ai.agent.id scope clarification ✅ Not emitted today
#257 gen-ai system_instructions text-only ✅ Already text-only
#258 gen-ai gen_ai.request.reasoning.level 🔴 Implemented
#289 gen-ai/agent Remove provider.name from internal span ✅ Not emitted today
#321 gen-ai/agent invoke_agent.duration in-process clarification ✅ Docs-only
#322 gen-ai invoke_agent / execute_tool attribute alignment ✅ No change needed
#330 gen-ai Weaver template migration ✅ Tooling only
#336 gen-ai/agent invoke_agent.inference_calls / tool_calls metrics 🟡 No agent span in MEAI
#353 gen-ai fetch_response op, stream_cursor, response.status 🟡 No fetch_response client
#354 gen-ai invoke_workflow span criteria ✅ Docs-only
#361 gen-ai Reference scenario fixes ✅ Docs-only
#372 gen-ai gen_ai.request.previous_response.id 🟡 No PreviousResponseId in ChatOptions
#389 mcp MCP error reporting 🟢 No MCP instrumentation
#410 gen-ai conversation.id on workflow spans ✅ Docs-only

In-flight upstream open PRs

PR Area Change Status
#270 gen-ai/agent gen_ai.main_agent entity 🟡 Watch
#374 gen-ai Usage metrics aggregation overhaul 🟡 Watch
#385 gen-ai/agent gen_ai.main_agent.name 🟡 Watch
#440 gen-ai Usage breakdown per modality / cache 🟡 Watch
#444 gen-ai Conformance strict mode 🟢 Tooling only
#450 openai OpenAI dependency v3 🟢 Package dep only

Tracking state

# meai-otel-genai-worker:state:begin
upstream-repo: open-telemetry/semantic-conventions-genai
upstream-scan-ref: 8d3e4a0f3c34a46f6edb9c71e8666e02e6bf3958
upstream-scan-date: 2026-08-12T08:50:57Z
upstream-release: none
core-semconv-dependency: v1.42.0
dotnet-extensions-implemented-version: v1.41
feedback-processed-through: 2026-08-12T08:50:57Z
# meai-otel-genai-worker:state:end

Generated by MEAI: Otel GenAI Worker · 538.3 AIC · ⌖ 7.88 AIC · ⊞ 14.7K ·

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@github-actions github-actions Bot added area-ai Microsoft.Extensions.AI libraries automation Issues and pull requests created through automation labels Jul 19, 2026
@github-actions

Copy link
Copy Markdown
Contributor Author

Automation took over this PR

This run adopted the bootstrapped draft PR #7642 and added the machine-readable meai-otel-genai-worker:state tracking block to its body. Future runs will classify this PR as ours and maintain it automatically.

What was validated this run

  • Build and tests pass against upstream scan SHA c26a2c21d1ee70d5231bd440c7b48d3c94ee506a.
  • All 27 upstream changelog fragments at the scanned commit have been classified.
  • Two actionable changes are implemented on the branch:
  • Doc-comment wording migrated to GenAI Semantic Conventions v1.41.
  • Remaining changes are deferred (no emission site exists in this repo yet).

Release signal

No GitHub Release published for open-telemetry/semantic-conventions-genai yet (404). This PR remains draft until a release is published and its resolved commit matches the recorded upstream-scan-ref.

Warning

Firewall blocked 2 domains

The following domains were blocked by the firewall during workflow execution:

  • winprotocoldocsbhdugrdyduf5h2e4.b02.azurefd.net
  • www.bondcap.com

To allow these domains, add them to the network.allowed list in your workflow frontmatter:

network:
  allowed:
    - defaults
    - "winprotocoldocsbhdugrdyduf5h2e4.b02.azurefd.net"
    - "www.bondcap.com"

See Network Configuration for more information.

Generated by MEAI: Otel GenAI Worker · 94.4 AIC · ⌖ 7.81 AIC · ⊞ 14.7K ·

@github-actions

Copy link
Copy Markdown
Contributor Author

Daily scan update — 2026-07-22

Scanned upstream commit: 2e994c6d59a93bb4fc1752c5378eedb9b8e14d6b
Previous recorded commit: 150760c6252a4bb63c49c9915bad11997d316a15

No convention changes in this delta. The single new upstream commit (#391) is a Renovate bot Python reference-implementation dependency bump — it touches only reference/*/pyproject.toml and reference/*/uv.lock files, with zero changes to changelog.d/, model/, docs/, or any convention spec.

The PR body tracking block has been refreshed to the new upstream SHA. No code changes were needed; all previously integrated and deferred items remain current.

Generated by MEAI: Otel GenAI Worker · 90.1 AIC · ⌖ 7.55 AIC · ⊞ 14.7K ·

@github-actions

Copy link
Copy Markdown
Contributor Author

Generated by MEAI: Otel GenAI Worker · 137.1 AIC · ⌖ 6.36 AIC · ⊞ 14.7K ·

@github-actions

Copy link
Copy Markdown
Contributor Author

Adoption summary (MEAI: Otel GenAI Worker — 2026-07-25)

This run adopted this PR into the automated tracking workflow. The PR was originally bootstrapped manually; the full changes-table and machine-readable tracking block have now been written into the description.

Upstream scanned: 74fd2e0f (2026-07-25)
No new releases exist for open-telemetry/semantic-conventions-genai (404 on GitHub latest release).

Implemented in this PR

  • 🟢 gen_ai.request.reasoning.level — new attribute emitted from ChatOptions.Reasoning.Effort (🆕 constant OpenTelemetryConsts.GenAI.Request.ReasoningLevel)
  • 🟢 document modality — OtelMessageSerializer now maps application/ MIME types to "document" in the message JSON
  • 🟢 Doc comment wording migration — all 6 OpenTelemetry* files updated to "GenAI Semantic Conventions v1.41"

Deferred (tracked, not yet coded)

11 items deferred: agent framework spans/metrics (plan, agent invocation metrics, invoke_agent/execute_tool duration metrics, inference/tool-call counters), workflow duration metric, memory spans, MCP tool-call attributes, compacted conversation, prompt version/variable tracking, and gen_ai.request.previous_response.id. See changes table in PR description.

No code changes needed this run — existing commit covers all actionable items. Watermark advanced to 2026-07-25T09:08:00Z.

Generated by MEAI: Otel GenAI Worker · 151.4 AIC · ⌖ 6.47 AIC · ⊞ 14.7K ·

@github-actions

Copy link
Copy Markdown
Contributor Author

MEAI: Otel GenAI Worker — scan complete (2026-07-26)

Scanned upstream 64cfaa6 (main HEAD).

This run adopted the bootstrapped PR (no prior tracking block) and wrote the full tracking state into the PR body.

Already implemented on this branch (prior commit):

  • 🔴 gen_ai.request.reasoning.level — constant + emission from ReasoningEffort (#258)
  • 🔴 document modality in message serialization (#142)
  • ✅ Doc-comment wording migrated to "GenAI Semantic Conventions v1.41" across all matched files

Already aligned (no change needed):

  • gen_ai.request.top_k already int (#217)
  • gen_ai.system_instructions already text-only (#257)
  • execute_tool sampling-relevant attributes already in span initial tags (#322)

Deferred (no emission sites yet): previous_response.id (no ChatOptions property), conversation.compacted (no abstraction property), prompt.version / prompt.variable (no abstraction properties), agent metrics (invoke_agent.duration, execute_tool.duration, inference_calls, tool_calls — no metric infrastructure in function-invocation path), workflow/memory/planning clients.

Build: clean · Tests: all pass · No public API change.

Warning

Firewall blocked 2 domains

The following domains were blocked by the firewall during workflow execution:

  • winprotocoldocsbhdugrdyduf5h2e4.b02.azurefd.net
  • www.bondcap.com

To allow these domains, add them to the network.allowed list in your workflow frontmatter:

network:
  allowed:
    - defaults
    - "winprotocoldocsbhdugrdyduf5h2e4.b02.azurefd.net"
    - "www.bondcap.com"

See Network Configuration for more information.

Generated by MEAI: Otel GenAI Worker · 282.4 AIC · ⌖ 7.63 AIC · ⊞ 14.7K ·

@github-actions

Copy link
Copy Markdown
Contributor Author

Incremental scan update — upstream advanced from 64cfaa6 to 434c91d (2026-07-29).

New upstream commits:

  • 3cfb9e6#396: Make retrieval document id and score optional → 🟢 Not applicable (no retrieval client in Microsoft.Extensions.AI)
  • 799e014, 434c91d — Reference implementation and Weaver tooling dependency updates (no convention changes)

No code changes are needed. PR description updated to record the new scan ref.

Generated by MEAI: Otel GenAI Worker · 77.9 AIC · ⌖ 3.98 AIC · ⊞ 14.7K ·

@github-actions

Copy link
Copy Markdown
Contributor Author

Upstream scan update — 2026-07-30

Scanned 434c91d (4 commits ahead of previous scan 64cfaa6).

New upstream changes since last scan

Upstream PR Area Change Action
#344/#396 gen-ai Make gen_ai.retrieval.documents id/score optional (nullable) 🟢 No action — gen_ai.retrieval.documents is not currently emitted by dotnet/extensions
#405 tooling Include markdown snippets in CI consistency check 🟢 Tooling only — no convention changes
#407, #412 tooling Dependency updates (Weaver v0.25.1) 🟢 Tooling only — no convention changes

No code changes required — all new upstream changes are either tooling updates or affect an attribute not yet emitted by this library. PR description and tracking block refreshed to the new scan ref.

Generated by MEAI: Otel GenAI Worker · 86.8 AIC · ⌖ 7.61 AIC · ⊞ 14.7K ·

@github-actions

Copy link
Copy Markdown
Contributor Author

Daily scan update — 2026-07-31

Scanned upstream c739977 (the latest commit on main).

Delta vs previous scan (434c91d): one commit — #414 "Change Renovate config to extend best practices" — which touches only .github/renovate.json5. Zero convention changes (no new changelog fragments, no model/ or docs/ changes).

No code changes needed in this run. PR body and tracking block refreshed to advance upstream-scan-ref to the new SHA and update feedback-processed-through watermark. All previously deferred items remain unchanged.

Generated by MEAI: Otel GenAI Worker · 112.3 AIC · ⌖ 10.8 AIC · ⊞ 14.7K ·

@github-actions

github-actions Bot commented Aug 1, 2026

Copy link
Copy Markdown
Contributor Author

Upstream scan update — 2026-08-01

Scanned upstream commit f77b923 (2 commits ahead of prior scan).

New upstream changes

Upstream PR Area Change Status
#353 gen-ai fetch_response operation, gen_ai.fetch_response.client span, gen_ai.request.stream_cursor, gen_ai.response.status 🟡 Deferred
#324 tooling Migrate Anthropic reference scenario to opentelemetry-util-genai 🟢 N/A

All new items from PR #353 are deferred: gen_ai.fetch_response.client is a new span type for fetching a previously generated model response without inference — M.E.AI has no fetch_response operation client today, so gen_ai.request.stream_cursor and gen_ai.response.status (also new) have no emission site. PR #324 is a Python reference scenario migration with no model changes.

No code changes this run. PR description updated with the new entries.

Generated by MEAI: Otel GenAI Worker · 119.3 AIC · ⌖ 7.95 AIC · ⊞ 14.7K ·

@github-actions

github-actions Bot commented Aug 3, 2026

Copy link
Copy Markdown
Contributor Author

Upstream scan update — 2026-08-03

Scanned upstream commit 9af0834 (main, 2026-08-03). Previous scan: f77b923.

Delta since last scan: 5 upstream PRs merged — all tooling and reference-documentation only:

  • #351 Remove inference spans from agentic reference instrumentations (doc/reference — 🟢 no code impact)
  • #400 Weaver 0.25.0 tooling cleanup (🟢)
  • #419 Emit execute_tool only where the library actually runs the tool (reference — 🟢)
  • #420 / #421 Tooling dependency updates (🟢)

No new changelog fragments were added; the convention attributes, metrics, events, and operation names are unchanged. No code changes are needed this run. PR body updated to record the new scan ref and move the above PRs into the merged-changes table.

Generated by MEAI: Otel GenAI Worker · 111.5 AIC · ⌖ 7.83 AIC · ⊞ 14.7K ·

@github-actions

github-actions Bot commented Aug 4, 2026

Copy link
Copy Markdown
Contributor Author

MEAI OTel GenAI Worker — 2026-08-04 scan

Upstream SHA: fe5608e249d64bc5961329a82f8915fe95ced51a (main, 2026-08-04)

Delta since last scan (9af0834): One upstream commit — #424 adds create_agent reference scenario coverage for Anthropic, Mistral, Bedrock, AutoGen, and Google GenAI reference implementations. This is a reference area change only (Python test tooling); no convention spec changes in model/, docs/gen-ai/, or changelog.d/. Zero code changes required in dotnet/extensions.

No reviewer feedback was new since the last watermark (2026-08-03T09:41:34Z).

PR description updated; tracking block advanced to this run's scan ref and feedback-processed-through watermark.

Generated by MEAI: Otel GenAI Worker · 54.8 AIC · ⌖ 5.5 AIC · ⊞ 14.7K ·

@github-actions

github-actions Bot commented Aug 5, 2026

Copy link
Copy Markdown
Contributor Author

Scan update — 2026-08-05

Scanned upstream SHA: 7e6e188 (main, 2026-08-05)

New upstream changes since last scan (fe5608e):

Upstream PR Area Change Status
#341 gen-ai Rename gen_ai.workflow.durationgen_ai.invoke_workflow.duration 🟡
#389 mcp Clarify MCP error reporting: separate client vs server error handling 🟢
#404 mcp Separate mcp.client.status.attributes / mcp.server.status.attributes 🟢
#433 tooling Bump core semconv dependency to v1.44 🟢
#436 tooling Pin signal requirement level doc links 🟢

No actionable code changes this scan. All new items are deferred (no workflow client for gen_ai.invoke_workflow.duration) or tooling/documentation-only. core-semconv-dependency updated to v1.44.0.

Generated by MEAI: Otel GenAI Worker · 115.5 AIC · ⌖ 6.49 AIC · ⊞ 14.7K ·

@github-actions

github-actions Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor Author

Upstream scan update — 2026-08-06

Scanned open-telemetry/semantic-conventions-genai at commit 4a39b6ef (2026-08-05).

Release status: No published release — semantic-conventions-genai has not shipped a tagged release yet. GitHub Releases returns 404; schema URL is gen-ai-dev/1.42.0-dev (development). Core semconv dependency: v1.44.0.

New fragments since prior scan (c26a2c21, ~2026-07-19):

Upstream PR Area Change Action
#344 gen-ai Retrieval document id and score made optional 🟢 No retrieval instrumentation today
#353 gen-ai fetch_response operation and span added 🟡 Deferred — no fetch-response instrumentation today
#372 gen-ai gen_ai.request.previous_response.id attribute added 🟡 Deferred — no PreviousResponseId in ChatOptions today
#389 mcp MCP error reporting clarified 🟢 No MCP instrumentation today

All new fragments are deferred or not applicable — no new code changes in this scan. The PR description has been refreshed to reflect the current full upstream delta, and the tracking block has been initialized.

Previously implemented (July 19 commit): gen_ai.request.reasoning.level (emitted from ChatOptions.Reasoning.Effort), document modality in message JSON schema, doc-comment wording migration.

Generated by MEAI: Otel GenAI Worker · 149.1 AIC · ⌖ 6.52 AIC · ⊞ 14.7K ·

@github-actions

github-actions Bot commented Aug 7, 2026

Copy link
Copy Markdown
Contributor Author

OTel GenAI Worker — incremental update (2026-08-07)

This is the first run that adopts and writes the tracking block for this PR (bootstrapped by a prior run).

Upstream scanned: 8c1b98a (2026-08-07)
Core semconv dependency: v1.44.0
Release: none (no published GenAI release)

Implemented in prior commit on this branch

Change Upstream Notes
gen_ai.request.reasoning.level #258 Constant + emission from OpenTelemetryChatClient
document modality in message serializer #142 OtelMessageSerializer maps application/* to document
Doc-comment wording migration All OpenTelemetry* files updated to "GenAI Semantic Conventions v1.41"

Deferred items (tracked in PR body)

  • gen_ai.conversation.compacted — no CompactionPart API
  • gen_ai.execute_tool.duration — no meter in FunctionInvocationProcessor
  • gen_ai.request.previous_response.id — no PreviousResponseId in ChatOptions
  • fetch_response operation, gen_ai.response.status, gen_ai.request.stream_cursor — no FetchResponse client
  • Agent / workflow / memory / retrieval spans — no frameworks yet

No new upstream changes require additional code this run. Tracking block written to PR body.

Generated by MEAI: Otel GenAI Worker · 207.8 AIC · ⌖ 7.78 AIC · ⊞ 14.7K ·

@github-actions

github-actions Bot commented Aug 8, 2026

Copy link
Copy Markdown
Contributor Author

Incremental scan update (2026-08-08)

Scanned upstream at 1d85c96.

Delta from prior scan (8c1b98a): One commit merged — #423 lock file maintenance (renovate). No convention changes.

New in-flight PR: #440 — span/event attributes for usage breakdown per modality / cache / phases (🟡 watch, extends #197 / #374).

No code changes required this run. PR description and tracking block refreshed.

Generated by MEAI: Otel GenAI Worker · 71 AIC · ⌖ 6.38 AIC · ⊞ 14.7K ·

@github-actions

github-actions Bot commented Aug 9, 2026

Copy link
Copy Markdown
Contributor Author

Daily scan update · upstream 46d43c8 (2026-08-09)

No convention changes since the previous scan (8c1b98a). The two new commits are CI/tooling only:

  • #423: Lock file maintenance (renovate) — no convention impact
  • #442: Conformance runner setup (reference scenarios, CI tooling) — no convention impact

No code changes needed. Tracking block advanced to this scan ref. PR remains current.

Generated by MEAI: Otel GenAI Worker · 93.4 AIC · ⌖ 6.4 AIC · ⊞ 14.7K ·

@github-actions

Copy link
Copy Markdown
Contributor Author

MEAI OTel GenAI Worker — 2026-08-11 incremental scan

Scanned upstream 8d3e4a0 (+4 commits since last scan at 8c1b98a).

No code changes this run. The only upstream convention delta is PR #354 (clarify invoke_workflow span criteria and gen_ai.workflow.name note — doc-only; no attributes added or changed). All other new commits are tooling/lock-file maintenance with no convention impact.

PR body and tracking block refreshed with the updated scan ref and watermark.

Generated by MEAI: Otel GenAI Worker · 101.4 AIC · ⌖ 6.38 AIC · ⊞ 14.7K ·

Add gen_ai.execute_tool.duration metric (upstream PR #201) and
gen_ai.request.reasoning.level attribute (upstream PR #258).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@github-actions

Copy link
Copy Markdown
Contributor Author

Commit pushed: a0f2ac3

Generated by MEAI: Otel GenAI Worker · 538.3 AIC · ⌖ 7.88 AIC · ⊞ 14.7K

@github-actions

Copy link
Copy Markdown
Contributor Author

Incremental update — upstream scan 8d3e4a0 (2026-08-12)

Implemented this run:

  • gen_ai.execute_tool.duration histogram metric (#201): Added metric constant, factory method in OtelMetricHelpers, Meter service exposed from OpenTelemetryChatClient / OpenTelemetryRealtimeClientSession, and emission in FunctionInvocationProcessor with gen_ai.tool.name + gen_ai.tool.type tags (plus error.type on failure).
  • gen_ai.request.reasoning.level (#258): Already implemented by a prior run.

Deferred (tracked, not coded yet): gen_ai.conversation.compacted, gen_ai.request.previous_response.id, gen_ai.request.stream_cursor, gen_ai.response.status, gen_ai.invoke_agent.duration, gen_ai.invoke_workflow.duration, memory / planning operations, and document modality — no current emission site in MEAI.

Build: clean across net8.0 / net9.0 / net10.0. Tests: 694 pass. Tracking block written for the first time (PR adopted from human bootstrap).

Generated by MEAI: Otel GenAI Worker · 538.3 AIC · ⌖ 7.88 AIC · ⊞ 14.7K ·

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area-ai Microsoft.Extensions.AI libraries automation Issues and pull requests created through automation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant