Zhichao Li
90d · built 2026-07-24
90-day totals
- Commits
- 66
- Grow
- 8.5
- Maintenance
- 3.3
- Fixes
- 0.8
- Total ETV
- 12.6
30-day trajectory
Last 30 days vs. the 30 days before. Up arrows on Growth and ETV mean improvement; up arrow on Fixes share means more time on fixes (worse).
↑+262.5 %
vs 8 prior
↑+28.1 pp
recent vs prior
↓-16.0 pp
recent vs prior
Daily performance
Daily ETV, stacked by Growth, Maintenance and Fixes.
Work-mix over time
Share of Growth / Maintenance / Fixes over a rolling 7-day window. Reads as 'where is effort flowing right now'.
Repository spread
Where this developer's commits land. Concentrated work (top1 > 80%) vs polymath spread (top1 < 30%).
Most impactful commits
Top 20 by ETV in the 90-day window.
- 2.2ETVagent host: native-SDK OTel + local SQLite eval sink Wire the agent host into the native OTel telemetry config exposed by @github/copilot-sdk and add an optional loopback OTLP receiver that persists agent spans to a local SQLite store. The store is opt-in via chat.agentHost.otel.dbSpanExporter.enabled and lives at <userData>/agent-host/otel/agent-host-traces.db. Pass-through mode forwards the user's chat.agentHost.otel.* settings (or OTEL_* env vars) directly to the SDK. DB mode runs an in-process OTLP HTTP receiver on 127.0.0.1, decodes spans, writes them to SQLite, and optionally forwards to a user-configured outer exporter so external endpoints / files keep receiving traces. Six settings (chat.agentHost.otel.{enabled, exporterType, otlpEndpoint, captureContent, outfile, dbSpanExporter.enabled}) are registered, gated to non-stable builds, and translated to env vars by buildAgentHostOTelEnv with env winning over settings. The workbench.action.chat.agentHost.otel.exportAgentTracesDB command lets users save a copy of the SQLite DB. Tests: 9 new agentHostOTelService integration cases plus 27 OTLP JSON / receiver / forwarder / SQLite store unit tests; existing copilotAgent suite updated to inject the new dependency. Refs PR 313921.github.com-microsoft-vscode · b75d8e6d · 2026-05-13
- 2.2ETVfeat(agentHost): emit restricted repository info telemetry Capture immutable begin/end repository snapshots for root Copilot turns and emit the legacy request.repoInfo schema to enhanced GitHub and internal Microsoft telemetry. Reuse Agent Host Git baselines and tree snapshots so committed, working-tree, rename, delete, and untracked changes are represented without mutating the user's index. Bind every event to the session launch token's immutable telemetry context, suppress source diffs when content exclusion may be enabled, and detect account, abort, and mid-capture tree changes before sending. Match the legacy safety and payload limits, multiplex large diffs, support GitHub/GHE/Azure DevOps remotes, and forward the existing repo-info debug kill switch into Agent Host config. Refs microsoft/vscode-internalbacklog#8247github.com-microsoft-vscode · 011a0bba · 2026-07-18
- 1.9ETVagentHost: forward restricted model telemetrygithub.com-microsoft-vscode · eef8a649 · 2026-07-13
- 0.5ETVfeat(otel): make attribute truncation configurable Adds `github.copilot.chat.otel.maxAttributeSizeChars` setting and `COPILOT_OTEL_MAX_ATTRIBUTE_SIZE_CHARS` env var to control truncation of free-form OTel content attributes (prompts, responses, tool arguments/results, hook input/output). Default is `0` (unlimited), matching the OTel spec's `AttributeValueLengthLimit` default of `Infinity`. Users on backends with per-attribute size limits can set a positive value to keep OTLP batches under the backend cap. Plumbs the resolved limit through every call site that previously hit a hardcoded 64KB fallback. Drops the `DEFAULT_MAX_OTEL_ATTRIBUTE_LENGTH` constant; `truncateForOTel`'s default arg is now `0` (unlimited). Refs #299952github.com-microsoft-vscode · 6fef3dff · 2026-05-02
- 0.4ETVfix(agentHost): gate enhanced GH telemetry on the token rt=1 opt-in The enhanced request.options.tools event was sent for every USAGE-level user. Route the enhanced GH send path through the Copilot token's rt claim so only opted-in (internal) users emit it, matching the Copilot extension. copilotAgent pushes the authoritative, refresh-aware rt gate and copilot_trackingId (tid) to the telemetry service; enhanced telemetry defaults off until an authenticated rt=1 token confirms the opt-in.github.com-microsoft-vscode · da062131 · 2026-07-02
- 0.4ETVfeat(agentHost): source restricted telemetry endpoint from CAPI token Align with the Copilot extension and CLI, which target the user's CAPI endpoints.telemetry (dotcom, GHE, or proxy) rather than a hardcoded host. copilotApiService now exposes the discovered telemetry endpoint; copilotAgent resolves it for rt=1 users and pushes it (with the /telemetry path) to the restricted sender, falling back to the dotcom default until it resolves.github.com-microsoft-vscode · bbf01149 · 2026-07-02
- 0.3ETVOTel: replace string literals with typed constants - Add GenAiProviderName.GEMINI; switch geminiNativeProvider, anthropicProvider, copilotcliSession to use GenAiProviderName.* constants - Add CopilotChatAttr.HOOK_TYPE/HOOK_INPUT/HOOK_OUTPUT/HOOK_RESULT_KIND, MODE_NAME, TOTAL_COST_USD; switch chatHookService, claudeMessageDispatch, copilotCliBridgeSpanProcessor, chatDebugFileLoggerService, otelSpanToChatDebugEvent, toolCallingLoop, claudeOTelTracker to use the new constants - Add CopilotCliSdkAttr group for SDK-emitted hook attribute keys (github.copilot.hook.*); switch consumers in copilotCliBridgeSpanProcessor and otelSpanToChatDebugEvent - Replace magic-number SpanStatusCode casts in copilotCliBridgeSpanProcessor with the enum members - Expand otel barrel index.ts to re-export CopilotCliSdkAttr and previously-missing event helpers (emitEditFeedbackEvent, emitEditHunkActionEvent, emitInlineDoneEvent, emitEditSurvivalEvent, emitUserFeedbackEvent, emitCloudSessionInvokeEvent) No behavior change.github.com-microsoft-vscode · 52947bbc · 2026-04-29
- 0.3ETVotel: address PR review feedback on session-id correlation - Rewrite BYOK session-id tests to exercise the real Anthropic/Gemini providers with a capturing OTel service and a correlated CapturingToken, instead of reproducing the attribute spread (which could not catch a production regression). Removes the synthetic tests from byokProviderSpans.spec.ts. - agent_monitoring.md: add copilot_chat.session_id rows to the foreground execute_tool, Claude execute_tool and execute_hook span tables (the code emits it); mark chat-span gen_ai.conversation.id as conditional rather than required. - agent_monitoring_arch.md: narrow the Session Correlation claim — the bridge only enriches the debug-panel copy, not the SDK's own OTLP export; document that CLI SDK-native OTLP correlation depends on the runtime (execute_tool covered once copilot-agent-runtime#12383 lands). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>github.com-microsoft-vscode · a4a3e6c1 · 2026-07-09
- 0.3ETVfeat(agentHost): emit enhanced GH request.options.tools per model call Bring agent-host restricted telemetry to parity with the Copilot extension's request.options.tools event. Emitted per assistant.message (the per-model-call boundary): headerRequestId carries the call's x-copilot-service-request-id (the runtime does not surface the client x-request-id), conversationId is the session id, and the tool definitions ride in messagesJson (routed to the code-snippet table like the extension). Each event gets a fresh unique_id, and copilot_trackingId (the token tid claim) is set as a restricted-telemetry common property.github.com-microsoft-vscode · 5026c10a · 2026-07-01
- 0.3ETVEmit gen_ai streaming OTel signals for chat responses Adds GenAI semantic-convention streaming signals alongside the legacy copilot_chat.time_to_first_token, tagged with gen_ai.response.model for per-model slicing (microsoft/vscode#320651): - gen_ai.request.stream (span attr, bool) - gen_ai.response.time_to_first_chunk (span attr, seconds) - gen_ai.client.operation.time_to_first_chunk (histogram metric) - gen_ai.client.operation.time_per_output_chunk (histogram metric) The main GitHub streaming path (chatMLFetcher) carries the full set including per-output-chunk latency, computed from inter-chunk gaps in FetchStreamRecorder. BYOK providers (Anthropic, Gemini) emit the stream attr + time_to_first_chunk only, as they lack per-chunk arrival timing. The Claude agent path inherits all signals via the shared chatMLFetcher proxy; the Copilot CLI path emits them natively from the runtime. Updates agent_monitoring.md and adds unit tests.github.com-microsoft-vscode · 136b39f3 · 2026-06-10
- 0.3ETVrefactor(otel): share BYOK OTel capture, harden chatMLFetcher system collection - Add buildOTelInputFromChatMessages helper consumed by Anthropic and Gemini BYOK providers, removing duplicated role mapping + parts construction. - Add collectSystemTextsFromRequestBody used by chatMLFetcher; prefer messages-level system entries over top-level system/instructions to avoid double-emitting the prompt when a request carries both shapes. - Tighten JSDoc on OTel formatter helpers and add unit tests.github.com-microsoft-vscode · 5760dcd7 · 2026-05-21
- 0.3ETVfix: include tool parameters and emit tool definitions on chat spans - toolCallingLoop emits tool definitions with parameters (tool inputSchema) on the agent span and tools_available event, per OTel GenAI semantic conventions (fixes #300318). - chatMLFetcher and BYOK providers (anthropic, gemini) now also set gen_ai.tool.definitions on each chat {model} child span so trace viewers can render the tool catalog per LLM call (fixes #299934). - toToolDefinitions normalizer extended to handle OpenAI Responses API, Anthropic input_schema, and VS Code inputSchema shapes.github.com-microsoft-vscode · b1206355 · 2026-04-28
- 0.2ETVfeat(agentHost): enforce rt gate at the restricted telemetry sender (defense in depth) The sole writer to the restricted table now refuses to emit enhanced GH telemetry unless the token opted in (rt=1), independent of the service-level gate — matching the Copilot extension, which only creates the restricted reporter for opted-in users. Makes fetch injectable to unit-test the gate without a live POST. Adds tests: sender drops enhanced until rt=1 (then routes to the enhanced iKey), and enhanced stays suppressed below USAGE even with rt=1.github.com-microsoft-vscode · bc8fda61 · 2026-07-02
- 0.2ETVotel: normalize gen_ai.response.model to match request format Anthropic responses echo the same logical model with a different separator (e.g. request 'claude-opus-4.6' resolves to 'claude-opus-4-6'), causing GROUP BY / DISTINCT on gen_ai.response.model to produce duplicate rows. Add normalizeResponseModel(requestModel, responseModel) that echoes the request value when the two strings only differ in '.' vs '-', and returns the resolved value unchanged when it adds real specificity (e.g. 'gpt-5.4-mini' -> 'gpt-5.4-mini-2026-03-17'). Wire into the three call sites that set gen_ai.response.model: chatMLFetcher (chat spans), toolCallingLoop (foreground invoke_agent), and claudeOTelTracker (Claude invoke_agent). Fixes #318805github.com-microsoft-vscode · a09e44ba · 2026-05-28
- 0.2ETVForward W3C traceparent to MCP servers via _meta (SEP-414) Plumb the active execute_tool span's W3C traceparent through LanguageModelToolInvocationOptions and IMcpToolCallContext, then inject it into the JSON-RPC tools/call payload's _meta so MCP server-side spans can be parented to the client trace. Refs #302301github.com-microsoft-vscode · 1810e63d · 2026-04-27
- 0.2ETVResponses API: translate terminal events into typed completions When CAPI ends a stream with `response.incomplete` or `response.failed`, the parser previously returned undefined and the downstream chatMLFetcher saw zero completions and fell to `ChatFetchResponseType.Unknown` ("Sorry, no response was returned."). Map terminal events into ChatCompletions with the right FinishedCompletionReason so the existing chatMLFetcher switch handles them: - response.incomplete + content_filter -> ContentFilter (+ FilterReason from CAPI content_filters labels, e.g. TextCopyright -> Copyright) - response.incomplete + max_output_tokens -> Length - response.failed -> ServerErrorgithub.com-microsoft-vscode · 10a499bf · 2026-05-11
- 0.2ETVfeat(agentHost): add MSFT-internal + GH restricted telemetry API Adds AgentHostRestrictedTelemetrySender (posts App Insights envelopes to the Copilot telemetry endpoint) and wires sendGHTelemetryEvent / sendEnhancedGHTelemetryEvent / sendInternalMSFTTelemetryEvent onto AgentHostTelemetryService with the same telemetry-level gating as publicLog2.github.com-microsoft-vscode · 3610e9ff · 2026-07-01
- 0.1ETVfix(agentHost): restricted telemetry parity for turnIndex and toolCallDetails cardinality Two parity gaps found while auditing the AHP restricted telemetry against the extension (`sendToolCallingTelemetry` and the `conversation.messageText` emitters) and the CTS column mapping: - `conversation.messageText` sent the SDK turn UUID in `turnIndex`, but the extension emits a numeric turn ordinal (`conversation.turns.length`) and CTS parses `turn_index` with `parseInt`, so our UUID landed empty. Plumb a monotonic 0-based turn ordinal through the session and emit it (stringified) so `turn_index` populates like the extension's. - `toolCallDetails` no-op'd when the turn made no tool calls, but the extension emits it for every turn that had tools available (empty `toolCounts`). Gate on `availableTools.length` to match its row cardinality.github.com-microsoft-vscode · f067a2ee · 2026-07-08
- 0.1ETVfeat(agentHost): emit restricted toolCallDetails per-turn aggregate Mirror the Copilot extension's restricted `toolCallDetailsExternal` / `toolCallDetailsInternal` events from the agent-host process. The per-turn tool-call aggregate (toolCounts, totalToolCalls, parallel-round counts, availableTools, model, responseType, numRequests, turnIndex) is accumulated across the turn's `assistant.message` rounds and emitted on turn completion, main-agent only, via the rt-gated restricted telemetry surface. Fields not surfaced at the agent-host turn boundary (tool-definition token count, per-round token/char counts, invalid-round count, session/turn durations) are omitted. Continues the "entire trajectory" restricted telemetry migration (microsoft/vscode-internalbacklog#8247).github.com-microsoft-vscode · 8bed62b7 · 2026-07-08
- 0.1ETVrefactor: address PR review — policy precedence docs, grpc transport inference, prototype-pollution hardeninggithub.com-microsoft-vscode · e9a25536 · 2026-06-27