Skip to content

feat(qwen-agent): add instrumentation for Qwen-Agent#154

Open
sipercai wants to merge 2 commits intoalibaba:mainfrom
sipercai:liuyu/qwen-agent
Open

feat(qwen-agent): add instrumentation for Qwen-Agent#154
sipercai wants to merge 2 commits intoalibaba:mainfrom
sipercai:liuyu/qwen-agent

Conversation

@sipercai
Copy link
Collaborator

@sipercai sipercai commented Mar 24, 2026

Description

This PR adds loongsuite-instrumentation-qwen-agent: OpenTelemetry instrumentation for Qwen-Agent using ExtendedTelemetryHandler from opentelemetry-util-genai. It emits GenAI semantic-convention traces for agent runs, LLM calls, ReAct steps, and tool execution (invoke_agent, chat, react step, execute_tool), registers an opentelemetry_instrumentor entry point, and includes unit tests plus VCR-based integration tests.

Fixes #11

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

pip install -e ".[test]" under instrumentation-loongsuite/loongsuite-instrumentation-qwen-agent, then pytest on that package’s tests/
From repo root: tox -c tox-loongsuite.ini -e py312-test-loongsuite-instrumentation-qwen-agent-oldest, py312-test-loongsuite-instrumentation-qwen-agent-latest, lint-loongsuite-instrumentation-qwen-agent

  • Test A

Does This PR Require a Core Repo Change?

  • Yes. - Link to PR:
  • No.

Checklist:

See contributing.md for styleguide, changelog guidelines, and more.

  • Followed the style guidelines of this project
  • Changelogs have been updated
  • Unit tests have been added
  • Documentation has been updated

Change-Id: I5ab30c79fea5e6f2070ef182da505084092632b2
Co-developed-by: Cursor <noreply@cursor.com>
@sipercai sipercai added enhancement New feature or request instrumentaion The instrumentation label represents issues related to instrumentation. genai The genai label represents issues related to generative AI. labels Mar 24, 2026
Change-Id: I6e70c5771f05d4915546bf6c2d4b96dc50582ce7
Co-developed-by: Cursor <noreply@cursor.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request genai The genai label represents issues related to generative AI. instrumentaion The instrumentation label represents issues related to instrumentation.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[feat]Add support for qwen-agent

4 participants