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"
  • Image generation / image editing

    ModelHow to run
    stable_diffusion_v2_1python3 GenerativeAI/Image_Generation/stable_diffusion_v2_1/stable_diffusion_v2_1.py --chipset 9075 --prompt "the prompt string ..."
    stable_diffusion_v1_5python3 GenerativeAI/Image_Generation/stable_diffusion_v1_5/stable_diffusion_v1_5.py --chipset 9075 --prompt "the prompt string ..."
    lama_dilatedpython3 ComputerVision/Image_Editing/lama_dilated/lama_dilated.py --chipset 9075
    aotganpython3 ComputerVision/Image_Editing/aotgan/aotgan.py --chipset 9075
  • Super resolution

    ModelHow to run
    real_esrgan_x4pluspython3 ComputerVision/Super_Resolution/real_esrgan_x4plus/real_esrgan_x4plus.py --chipset 9075
    real_esrgan_general_x4v3python3 ComputerVision/Super_Resolution/real_esrgan_general_x4v3/real_esrgan_general_x4v3.py --chipset 9075
    quicksrnetmediumpython3 ComputerVision/Super_Resolution/quicksrnetmedium/quicksrnetmedium.py --chipset 9075
  • Image recognition

    ModelHow to run
    inception_v3python3 ComputerVision/Image_Classification/inception_v3/inception_v3.py --chipset 9075
    beitpython3 ComputerVision/Image_Classification/beit/beit.py --chipset 9075
    googlenetpython3 ComputerVision/Image_Classification/googlenet/googlenet.py --chipset 9075
  • Pose estimation

    ModelHow to run
    openposepython3 ComputerVision/Pose_Estimation/openpose/openpose.py --chipset 9075
    mediapipe_handpython3 ComputerVision/Pose_Estimation/mediapipe_hand/mediapipe_hand.py --chipset 9075
  • Segmentation / depth estimation

    ModelHow to run
    unet_segmentationpython3 ComputerVision/Semantic_Segmentation/unet_segmentation/unet_segmentation.py --chipset 9075
    depth_anythingpython3 ComputerVision/Depth_Estimation/depth_anything/depth_anything.py --chipset 9075
  • Object detection

    ModelHow to run
    yolov8_detpython3 ComputerVision/Object_Detection/yolov8_det/yolov8_det.py --chipset 9075
  • 3D face modeling

    ModelHow to run
    facemap_3dmmpython3 ComputerVision/Face_Recognition/facemap_3dmm/facemap_3dmm.py --chipset 9075
    face_attrib_netpython3 ComputerVision/Face_Recognition/face_attrib_net/face_attrib_net.py --chipset 9075
  • Audio models

    ModelHow to run
    yamnetpython3 audio/Audio_Classification/yamnet/yamnet.py --chipset 9075
    whisper_base_enpython3 audio/Speech_Recognition/whisper_base_en/whisper_base_en.py --chipset 9075
    whisper_tiny_enpython3 audio/Speech_Recognition/whisper_tiny_en/whisper_tiny_en.py --chipset 9075
  • Text / multimodal embedding

    ModelHow to run
    nomic_embed_textpython3 Multimodal/Text_Generation/nomic_embed_text/nomic_embed_text.py --chipset 9075
    openai_clippython3 Multimodal/Image_Classification/openai_clip/openai_clip.py --chipset 9075 --text "mountain"
    qwen_vlDownload model package first; python3 Multimodal/qwen_vl/qwen_vl.py --model qwen2 --path ./qwen2vl2b (see sample page)
  • 3D action recognition

    ModelHow to run
    resnet_3dpython3 ComputerVision/Video_Classification/resnet_3d/resnet_3d.py --chipset 9075
  • OCR

    ModelHow to run
    easy_ocrpython3 Multimodal/Image_To_Text/easy_ocr/easy_ocr.py --chipset 9075

    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