Summary
GitHubCopilotAgent currently has no OpenTelemetry instrumentation. This issue tracks adding OTel tracing support following the same pattern used by other agents in the framework (e.g., ClaudeAgent, FoundryAgent).
Proposed Changes
- Split
GitHubCopilotAgent into two classes:
RawGitHubCopilotAgent - core implementation without telemetry layers
GitHubCopilotAgent(AgentTelemetryLayer, RawGitHubCopilotAgent) - OTel-enabled wrapper (recommended for most use cases)
- Add a
default_options property to expose the configured model name in span attributes
- Export
RawGitHubCopilotAgent from all public namespaces (agent_framework.github, agent_framework_github_copilot)
- Add a new sample
github_copilot_with_observability.py showing how to use configure_otel_providers() with GitHubCopilotAgent
- Update the GitHub Copilot samples README with OTel environment variable documentation
Usage After This Change
from agent_framework.github import GitHubCopilotAgent
from agent_framework.observability import configure_otel_providers
# Enable OTel tracing (configure OTEL_EXPORTER_OTLP_ENDPOINT for a collector)
configure_otel_providers()
async with GitHubCopilotAgent(instructions="You are a helpful assistant.") as agent:
response = await agent.run("Hello!")
print(response)
Users who want the agent without any telemetry overhead can use RawGitHubCopilotAgent directly.
Related
- Follows the same
Raw* / Telemetry-enabled pattern as RawClaudeAgent / ClaudeAgent
- Depends on the SDK 0.2.x migration (tracked separately)
Summary
GitHubCopilotAgentcurrently has no OpenTelemetry instrumentation. This issue tracks adding OTel tracing support following the same pattern used by other agents in the framework (e.g.,ClaudeAgent,FoundryAgent).Proposed Changes
GitHubCopilotAgentinto two classes:RawGitHubCopilotAgent- core implementation without telemetry layersGitHubCopilotAgent(AgentTelemetryLayer, RawGitHubCopilotAgent)- OTel-enabled wrapper (recommended for most use cases)default_optionsproperty to expose the configured model name in span attributesRawGitHubCopilotAgentfrom all public namespaces (agent_framework.github,agent_framework_github_copilot)github_copilot_with_observability.pyshowing how to useconfigure_otel_providers()withGitHubCopilotAgentUsage After This Change
Users who want the agent without any telemetry overhead can use
RawGitHubCopilotAgentdirectly.Related
Raw* / Telemetry-enabledpattern asRawClaudeAgent/ClaudeAgent