Skip to main content

QAI AppBuilder

Quick AI Application Builder (QAI AppBuilder) helps developers easily use the Qualcomm® AI Runtime SDK to deploy AI models and design AI applications on Qualcomm® SoC platforms equipped with the Qualcomm® Hexagon™ Processor (NPU). It encapsulates model deployment APIs into a set of simplified interfaces for loading models to the NPU and performing inference. QAI AppBuilder significantly reduces the complexity of model deployment for developers and provides multiple demos as references for designing their own AI applications.

Supports Python API / C++ API

QAI-APPBUILDER architecture

Supported devices

DeviceSoC
Dragon Q6AQCS6490
Dragon Q8BSC8280XP
Fogwise® AIRbox Q900QCS9075

Installation methods

tip

Install with a wheel package is recommended. To build from source, see Build from source.

Clone the repository

Device
git clone https://github.com/qualcomm/qai-appbuilder.git && cd qai-appbuilder

Install with a wheel package

Create a virtual environment
tip

Create a virtual environment before installing Python packages for isolation.

Device
sudo apt install python3-venv
python3 -m venv .venv
source .venv/bin/activate
Install qai_appbuilder

Download the Linux aarch64 wheel that matches your Python version from GitHub Releases. For Python 3.12, for example:

Device
pip3 install https://github.com/qualcomm/qai-appbuilder/releases/download/v2.48.40/qai_appbuilder-2.48.40-cp312-cp312-manylinux_2_39_aarch64.whl
tip

Starting from v2.0.0, the Python wheel bundles the required Qualcomm® AI Runtime libraries (such as libQnnHtp.so and Hexagon skels). You usually do not need a full QAIRT SDK install for Python inference.

Verify the installation:

Device
python3 -c "import qai_appbuilder; print(qai_appbuilder.__file__)"

Build from source

To build from source, install build dependencies and prepare the QAIRT SDK.

Install build dependencies

Device
sudo apt update
sudo apt install -y cmake build-essential python3-dev python3-venv
git clone https://github.com/qualcomm/qai-appbuilder.git --recursive
cd qai-appbuilder
python3 -m venv .venv
source .venv/bin/activate
pip3 install wheel==0.45.1 setuptools==80.9.0 pybind11==2.13.6 build==1.4.0

Configure QAIRT environment variables

Extract the QAIRT SDK first. Replace <path_to_qairt> with the actual SDK path:

Device
export QNN_SDK_ROOT=<path_to_qairt>
export QAI_TOOLCHAINS=aarch64-oe-linux-gcc11.2

Build and install the qai_appbuilder wheel

Device
python3 -m build -w
python3 -m pip install dist/qai_appbuilder-*.whl
tip

The wheel version follows the linked QAIRT SDK version. See the official BUILD.md for details.

Create ADSP environment variables

Before running NPU inference on Linux, set ADSP_LIBRARY_PATH to a directory that contains the Hexagon skel libraries (for example libQnnHtpV68Skel.so / libQnnHtpV73Skel.so).

After installing the wheel, point to the package libs directory:

Device
export ADSP_LIBRARY_PATH=$(python3 -c "import os, qai_appbuilder; print(os.path.join(os.path.dirname(qai_appbuilder.__file__), 'libs'))")

Use system QAIRT packages

System packages such as qairt-libs and qairt-dsp-binaries come from the Qualcomm apt repository (ppa:ubuntu-qcom-iot/qcom-ppa). This repository is not configured by default — add it manually before installing the packages:

Device
sudo apt update && sudo apt install -y software-properties-common
sudo add-apt-repository -y ppa:ubuntu-qcom-iot/qcom-ppa
sudo apt update
sudo apt install -y qairt-libs qairt-dsp-binaries

If packages such as qairt-dsp-binaries are already installed, you can also point ADSP_LIBRARY_PATH to the platform DSP directory. For QCS6490, for example:

Device
export ADSP_LIBRARY_PATH=/usr/share/qcom/qcm6490/Thundercomm/RB3gen2/dsp/cdsp
tip

You can add the export line to ~/.bashrc and run source ~/.bashrc to make it persistent.

Application examples

tip

Upstream samples are reorganized by task type. On Linux, pass --chipset so the script can download the matching model package:

  • QCS6490 / SC8280XP: --chipset 6490
  • QCS9075: --chipset 9075

For more samples, see the upstream samples/README.md. You can also refer to local Demo examples.

Install sample dependencies

Install common sample dependencies in the activated virtual environment:

Device
pip3 install requests tqdm qai-hub py3-wget Pillow torch torchvision opencv-python-headless

Enter the samples directory

Device
cd qai-appbuilder/samples

Run samples

You can run a sample script directly, or use the interactive launcher:

Device
python3 run_inference.py --list
python3 run_inference.py --model inception_v3 --args "--chipset 6490"
tip

Upstream Linux sample scripts currently select model packages with --chipset 6490 / --chipset 9075. SC8280XP and QCS6490 both use Hexagon V68, so use --chipset 6490 when downloading models.

  • Image classification

    ModelHow to run
    googlenetpython3 ComputerVision/Image_Classification/googlenet/googlenet.py --chipset 6490
    inception_v3python3 ComputerVision/Image_Classification/inception_v3/inception_v3.py --chipset 6490
  • Object detection

    ModelHow to run
    yolov8_detpython3 ComputerVision/Object_Detection/yolov8_det/yolov8_det.py --chipset 6490
  • Super resolution

    ModelHow to run
    quicksrnetmediumpython3 ComputerVision/Super_Resolution/quicksrnetmedium/quicksrnetmedium.py --chipset 6490
    real_esrgan_general_x4v3python3 ComputerVision/Super_Resolution/real_esrgan_general_x4v3/real_esrgan_general_x4v3.py --chipset 6490
    real_esrgan_x4pluspython3 ComputerVision/Super_Resolution/real_esrgan_x4plus/real_esrgan_x4plus.py --chipset 6490 --bin --no_show

    You need to be logged into GitHub to post a comment. If you are already logged in, please ignore this message.

    Radxa-docs © 2026 by Radxa Computer (Shenzhen) Co.,Ltd. is licensed under CC BY 4.0