Dev & Engineering ✓ Microsoft · Official open-telemetryotlpspan-instrumentationtelemetry-metricscopilot-chattrace-propagationagent-monitoring

Copilot Chat OpenTelemetry Instrumentation

A repository-specific guide for consistent OpenTelemetry instrumentation in Copilot Chat.

FollowSkills review · FSRS-2.0
Use with care
60/ 100 5-point scale 3.0 / 5
Trust19 / 25 · 3.8/5

The skill specifies use of the IOTelService abstraction, truncation, captureContent gating, hashing of sensitive identifiers, and Debug Panel/OTLP isolation, while documenting process-environment and SDK-internal-access risks. It lacks per-change user confirmation, an explicit rollback procedure, and dependency security verification, so full marks are not justified.

Reliability9 / 20 · 2.3/5

It provides architecture maps, operation conventions, graceful-degradation requirements, configuration-sync checklists, unit-test guidance, and validation commands. However, this review is static, the referenced implementation files and test results are not included, and runtime/error-path reproducibility is unproven; the score remains within the static ceiling.

Adaptability10 / 15 · 3.3/5

The audience, trigger scenarios, four agent paths, and rejected patterns are clearly described. Non-fit boundaries, formal input/output contracts, and Chinese-language support are limited. The core skill is not entirely dependent on overseas services, but referenced external monitoring backends may have reachability differences, warranting a deduction.

Convention10 / 15 · 3.3/5

The document uses progressive sections, tables, code examples, and procedural checklists, with MIT licensing and Microsoft repository provenance available as governance evidence. It lacks a skill-specific version, changelog, explicit maintenance owner, update path, and complete installation/troubleshooting guidance.

Effectiveness7 / 15 · 2.3/5

The skill offers directly usable guidance for core OTel instrumentation work, including architecture, naming, content handling, synchronization, and validation steps. Its usefulness depends on additional source and monitoring documents not supplied here, and no end-to-end output evidence is present, so the static maximum applies.

Verifiability5 / 10 · 2.5/5

Specific source paths, test locations, CI-related validation commands, and known risks make the guidance partially auditable. No executed test results or independent corroboration are included, so static calibration limits this to 5.

Evidence confidence:Low Reviewed Jul 20, 2026 Reviewed revision 5b3e1be7be9e
Before you use it
  • No TypeScript checks, unit tests, or Aspire/Agent Debug Log end-to-end validation were executed.
  • Before adoption, verify that the referenced source paths, exporter filters, content-capture settings, and SDK internal fields match this revision.
  • Telemetry may contain prompts, tool arguments, session identifiers, or model responses; confirm that captureContent, truncation, hashing, and exporter policies meet organizational privacy requirements.
  • If the monitoring backend or dependencies require overseas network access, provide a reachable, proxied, or offline alternative for mainland-China users.
See the full review method →

What it does & when to use it

This skill guides OpenTelemetry work in the Copilot Chat extension within the Visual Studio Code repository. It covers four agent execution paths: the foreground agent, in-process Copilot CLI, terminal Copilot CLI, and Claude Code, along with IOTelService and span, metric, event, and propagation conventions. Implementation changes are expected to stay synchronized with the user monitoring documentation, architecture documentation, and tests. It is best suited to developers maintaining telemetry in this codebase, rather than to users seeking a general-purpose OpenTelemetry tutorial or standalone runtime.

It requires reading agent_monitoring.md and agent_monitoring_arch.md before changing telemetry and updating the relevant documentation in the same change. It specifies how to create invoke_agent, chat, execute_tool, and execute_hook spans through IOTelService, use constants from genAiAttributes.ts, and choose between truncation and captureContent gating for content attributes. It documents the Copilot CLI Bridge SpanProcessor, Claude SDK message-to-GenAI span synthesis, cross-boundary trace propagation, and the separation between OTLP, file, SQLite, and debug-panel outputs. It also requires synchronized updates to settings, environment-variable translation, exportable operation names, and unit tests, with TypeScript, OTel/Bridge test, and manual dashboard/debug-panel checks.

  1. A developer maintaining foreground Copilot Chat agents needs consistent invoke_agent, tool, and hook span names, attributes, and error-status handling.
  2. A maintainer changing the in-process Copilot CLI needs to preserve the Bridge SpanProcessor, span hierarchy, traceparent handling, and hook context.
  3. A developer modifying Claude subprocess telemetry needs to synthesize spans from SDK messages and record chat spans through the local language-model server.
  4. A contributor adding a metric, event, attribute, or OTel setting needs to update the public exports, monitoring documentation, and matching tests.
  5. A maintainer investigating differences between Agent Debug Log and OTLP or SQLite output needs to verify EXPORTABLE_OPERATION_NAMES and the debug-panel isolation rules.

Pros & cons

Pros
  • It is specific to the Copilot Chat extension in the VS Code repository, naming concrete files, classes, attribute namespaces, and test locations.
  • It distinguishes four execution models and their different strategies: direct instrumentation, CLI bridging, environment forwarding, and Claude message synthesis.
  • It accounts for debug-panel, OTLP, file, and SQLite export behavior, including legacy-attribute dual emission and content-capture rules.
  • It provides checklists for configuration changes, cross-boundary propagation, bridge changes, and validation.
Limitations
  • Its scope is tightly limited to the Copilot Chat extension described by `.github/skills/otel/SKILL.md` in microsoft/vscode; it is not presented as a general OpenTelemetry design.
  • It assumes familiarity with the VS Code repository layout and internal services such as IOTelService, NodeOTelService, and the Copilot CLI bridge.
  • The Copilot CLI bridge accesses the OpenTelemetry SDK v2 internal `_spanProcessors` state, creating a risk if the SDK structure changes.
  • The source provides no standalone installation workflow, complete test results, or dedicated adaptation guidance for other platforms.
  • The Claude SDK has no file exporter, while the CLI runtime supports only `otlp-http`; the CLI SDK's single captureContent setting affects both the debug panel and OTLP.

How to install

The source does not document a separate installer or client-registration procedure. You can check out the repository and inspect the skill with:

git clone https://github.com/microsoft/vscode.git
cd vscode
cat .github/skills/otel/SKILL.md

The skill is located at .github/skills/otel/; the source does not explain how to register it with a particular Agent Skills client.

How to use

In an Agent Skills-compatible client, explicitly request a repository task covered by the skill, for example: "Follow .github/skills/otel/SKILL.md to add an execute_tool span for a new tool and update agent_monitoring.md, the architecture document, and tests." Before submitting a change, run npx tsc --noEmit --project tsconfig.json from extensions/copilot/, followed by npm test -- --grep "OTel\|Bridge"; then check the Aspire Dashboard and the VS Code Agent Debug Log. The skill defines no standalone command, script, or argument interface.

FAQ

Will this skill automatically add OpenTelemetry to any project?
No. It is engineering guidance for the Copilot Chat extension in microsoft/vscode. It describes implementation, documentation, configuration, and test changes, but does not claim to be a standalone auto-instrumentation tool.
Must OpenTelemetry be enabled to use the guidance?
No. The documented selection uses NodeOTelService when OTel is enabled and InMemoryOTelService when it is disabled. The in-memory implementation still supports the Agent Debug Log with captured spans, metrics, and logs.
Can a new attribute use a hard-coded string key?
No. The skill requires adding and using constants from genAiAttributes.ts. New Copilot attributes should prefer github.copilot.*, while renamed copilot_chat.* keys must continue to be emitted alongside their preferred replacements.
What is the main known risk when changing the Copilot CLI bridge?
The bridge accesses the SDK's internal `_delegate._activeSpanProcessor._spanProcessors` structure. The skill requires retaining a runtime guard, degrading gracefully if that shape changes, and updating the architecture documentation and bridge unit test.

More skills from this repository

All from microsoft/vscode

Dev & Engineering ✓ Microsoft · Official

Tool Rename Compatibility Check

Protect existing prompts and tool configurations when built-in tools are renamed.

Dev & Engineering ✓ Microsoft · Official

VS Code Configuration Policy Maintainer

Standardize VS Code policy registration, export, and validation.

Design & Frontend ✓ Microsoft · Official

VS Code Design Philosophy

Turn vague UI discomfort into concrete fixes using shared values, principles, and design moves.

Dev & Engineering ✓ Microsoft · Official

Agent Host E2E Test Assistant

Maintain VS Code Agent Host end-to-end tests with strict replay fixtures.

Dev & Engineering ✓ Microsoft · Official

VS Code Integrated Browser Architecture

A practical architecture guide for safely changing VS Code's cross-process integrated browser.

Dev & Engineering ✓ Microsoft · Official

VS Code Agents Window Sessions

Safely implement and repair VS Code Agents window features.

Dev & Engineering ✓ Microsoft · Official

Commit Assistant

Creates repository-style commit messages and safely commits code changes.

Dev & Engineering ✓ Microsoft · Official

Agent Host Log Investigator

Trace session, transport, and host failures in Agent Host debug exports.

Dev & Engineering ✓ Microsoft · Official

VS Code Unit Test Runner

Run VS Code repository unit tests by file, test name, or compiled-output glob.

Dev & Engineering ✓ Microsoft · Official

VS Code Agent Customization Assistant

Create, repair, and troubleshoot VS Code Agent customization files and their loading behavior.

Dev & Engineering ✓ Microsoft · Official

Code OSS Launch & Debug

Launch a built-from-source VS Code with isolated profiles, Playwright control, and multi-process debugging ports.

Dev & Engineering ✓ Microsoft · Official

VS Code Accessibility Development Guide

A practical specification for accessible interactive features in VS Code.

Design & Frontend ✓ Microsoft · Official

VS Code CSS Layout Standards

Build reliable VS Code-style CSS layouts and text truncation behavior

Dev & Engineering ✓ Microsoft · Official

VS Code Chat Performance Lab

Benchmark chat rendering and detect memory growth across VS Code builds.

Dev & Engineering ✓ Microsoft · Official

Component Fixtures for Screenshot Testing

Create stable, theme-aware VS Code component fixtures for isolated screenshot testing.

Dev & Engineering ✓ Microsoft · Official

VS Code Smoke Test Assistant

Run, filter, and debug VS Code end-to-end smoke tests.

Dev & Engineering ✓ Microsoft · Official

VS Code Crash Dump Symbolicator

Turn native VS Code crash dumps into readable backtraces with method names.

Dev & Engineering ✓ Microsoft · Official

Local VS Code Web Workbench

Validate VS Code workbench and Agents window changes in a local vscode.dev instance.

Dev & Engineering ✓ Microsoft · Official

Feedback Action

Reads current-session feedback and applies the requested code changes.

Dev & Engineering ✓ Microsoft · Official

VS Code Chat Customizations Editor Skill

Guides developers through safe changes and testing for VS Code’s chat customization management UI.

Related skills