All Products
Search
Document Center

Cloud Monitor:Integrate a QwenPaw application

Last Updated:Jun 16, 2026

You can integrate QwenPaw with CloudMonitor 2.0 using the QwenPaw observability plugin. The plugin enables OpenTelemetry auto-instrumentation in the QwenPaw runtime environment and reports AI Agent traces to CloudMonitor 2.0. After integration, you can view the QwenPaw Agent execution traces, model calls, tool calls, token consumption, and error information.

Limitations

  • Runtime environment: Install the observability plugin in the Python environment where QwenPaw runs. If you use conda or venv, switch to the corresponding environment first. In container scenarios on Container Service for Kubernetes (ACK) or Container Compute Service (ACS), you can use ack-onepilot for automatic integration. If you use a QwenPaw Docker image, we recommend using an image URL that is synced to Alibaba Cloud ACR.

  • Reporting protocol: OpenTelemetry trace data is reported over HTTP/Protobuf.

  • CloudMonitor service: You must activate the CloudMonitor 2.0 service and create a workspace.

  • Startup method: After installing the plugin, you must set the LOONGSUITE_PYTHON_SITE_BOOTSTRAP=true environment variable and restart QwenPaw.

Integration methods

Choose one of the following methods based on your QwenPaw deployment environment: integration through Container Service for Kubernetes (ACK) and Container Compute Service (ACS), manual probe integration, or integration from a personal PC.

ACK and ACS

If you use a custom image, first confirm that the Python environment where QwenPaw runs matches the environment used by pip3. If you cannot confirm the image startup method, runtime user, or Python environment, use manual probe integration.

Step 1: Install ack-onepilot

  1. Log on to the Container Service for Kubernetes (ACK) console and select Clusters from the left-side navigation pane.

  2. Click the name of your target cluster. In the left-side navigation pane, choose Operations & Maintenance > Component Management.

  3. On the ack-onepilot card, click Install. Configure the parameters. We recommend that you use the default values. Then, click Confirm.

    Note

    The ack-onepilot component must be version 5.1.1 or later. If you have an earlier version installed, upgrade ack-onepilot on the Component Management page.

Step 2: Enable AI application monitoring

ack-onepilot automatic integration does not require you to first obtain an integration command from the CloudMonitor 2.0 console. Add the following labels to spec.template.metadata.labels in your Deployment and replace the application name and workspace with your actual values:

apiVersion: apps/v1
kind: Deployment
metadata:
  name: qwenpaw
spec:
  template:
    metadata:
      labels:
        aliyun.com/app-language: python
        armsPilotAutoEnable: "on"
        armsPilotCreateAppName: "qwenpaw-demo"
        armsPilotAppWorkspace: "<Your-Workspace>"
    spec:
      containers:
        - name: qwenpaw
          image: agentscope-registry.ap-southeast-1.cr.aliyuncs.com/agentscope/qwenpaw:latest

After you update the workload, wait for the Pod to be recreated and started. The presence of Aliyun python agent is started in the startup logs indicates that the Python probe has loaded into the application process.

Manual probe integration

This method is for scenarios where you do not use ack-onepilot, cannot confirm the injection conditions for a custom image, or want to include the probe installation process in your image build. During the image build phase or before the container starts, run the installation command generated in the console from the Python environment where QwenPaw runs.

Step 1: Get integration parameters

  1. Log on to the CloudMonitor 2.0 console and select your target workspace.

  2. In the left-side navigation pane, click Integration Center.

  3. In the Observability for AI Applications section, select the QwenPaw integration item.

  4. In the parameter configuration section, enter an application name, select the connection method based on your deployment environment, and then click Click to obtain next to LicenseKey.

  5. Record the generated integration parameters, including Endpoint, LicenseKey, Project, Workspace, and serviceName.

Step 2: Build an image with the probe

FROM agentscope-registry.ap-southeast-1.cr.aliyuncs.com/agentscope/qwenpaw:latest

RUN curl -fsSL https://arms-apm-cn-hangzhou-pre.oss-cn-hangzhou.aliyuncs.com/qwenpaw-cms-plugin/install.sh | bash -s -- \
  --python /app/venv/bin/python \
  --skip-qwenpaw-check \
  --site-bootstrap \
  --x-arms-license-key "<Your-LicenseKey>" \
  --x-arms-project "<Your-Project>" \
  --x-cms-workspace "<Your-Workspace>" \
  --serviceName "qwenpaw-demo" \
  --endpoint "https://<Endpoint>/apm/trace/opentelemetry"

If you run the installation command during container startup, make sure that the installation completes before you start the qwenpaw app. Then, recreate the Pod so that the environment variables and site initialization configuration can take effect.

Personal PC integration

This method is suitable for development, debugging, proof-of-concept (PoC) validation, issue reproduction, or short-term verification on a local machine, such as a macOS, Linux, or Windows Subsystem for Linux (WSL) machine. It uses a lightweight site bootstrap method that loads the observability capabilities when the local Python process starts. If QwenPaw is deployed in ACK, ACS, a container image, or needs to run long-term, we recommend manual probe integration instead.

Step 1: Get the integration command

  1. Log on to the CloudMonitor 2.0 console and select your target workspace.

  2. In the left-side navigation pane, click Integration Center.

  3. In the Observability for AI Applications section, select the QwenPaw integration item.

  4. In the parameter configuration section, enter an application name, select the personal PC integration method, and then copy the generated installation command. The command contains information such as Endpoint, LicenseKey, Project, Workspace, and serviceName.

Step 2: Install the observability plugin

Run the installation command on the machine where QwenPaw is located. If QwenPaw runs in a conda environment, run conda activate qwenpaw to switch to it first.

curl -fsSL https://arms-apm-cn-hangzhou-pre.oss-cn-hangzhou.aliyuncs.com/qwenpaw-cms-plugin/install.sh | bash -s -- \
  --x-arms-license-key "<Your-LicenseKey>" \
  --x-arms-project "<Your-Project>" \
  --x-cms-workspace "<Your-Workspace>" \
  --serviceName "qwenpaw-demo" \
  --endpoint "https://<Endpoint>/apm/trace/opentelemetry"

After the installation succeeds, the terminal prints output similar to the following:

qwenpaw-cms-plugin installed successfully!

Step 3: Start the QwenPaw application

After installing the plugin, set the environment variable, and then start QwenPaw:

export LOONGSUITE_PYTHON_SITE_BOOTSTRAP=true
qwenpaw app

If the application is already running, stop and then restart it. After startup, go to http://127.0.0.1:8088/ to open the QwenPaw Console and initiate a conversation or task.

If the following message appears in the terminal, OpenTelemetry auto-instrumentation is initialized:

loongsuite-site-bootstrap: started successfully (OpenTelemetry auto-instrumentation initialized).

View monitoring details

  1. Log on to the CloudMonitor 2.0 console and select your target workspace.

  2. In the left-side navigation pane, choose Application Observability > Observability for AI Applications.

  3. In the application list, find qwenpaw-demo.

  4. Click the application name to view trace, model calls, token consumption, tool call details, and error information.

Troubleshooting

Slow startup or noisy logs after integration

After setting LOONGSUITE_PYTHON_SITE_BOOTSTRAP=true for personal PC integration, loongsuite-site-bootstrap is enabled. When the Python process starts, it performs a one-time auto-integration initialization, which adds a fixed startup overhead.

If certain temporary Python child processes do not require separate trace collection, you can disable site bootstrap in the child process's environment and compare the overhead:

LOONGSUITE_PYTHON_SITE_BOOTSTRAP=False

If the logs keep printing the site bootstrap initialization success message, make sure loongsuite-site-bootstrap is upgraded to version 0.6.1 or later, and set the following environment variable to disable the message:

pip install -U "loongsuite-site-bootstrap>=0.6.1"
LOONGSUITE_PYTHON_SITE_BOOTSTRAP_LOG_SUCCESS=False

Data delay after integration

After you complete the personal PC integration, the initial data report and console display may be delayed by several minutes. We recommend that you trigger multiple real AI Agent calls from the QwenPaw Console, wait 5 to 10 minutes, and then refresh the console to view the data. If you still do not see any traces, trigger another call and continue troubleshooting by checking the probe logs, application name, workspace, and reporting endpoint configuration.

No initialization message appears at startup

Confirm that you install the plugin and run the startup command from the same Python environment. If you use conda or venv, switch to the correct environment before you install the plugin and start QwenPaw.

Other issues

If you encounter issues after integration, such as Python probe installation failures, missing probe initialization logs after application startup, no trace data in the console, or environment variables not taking effect, see: