Get Started#
Live Video Captioning processes RTSP streams or USB camera (including webcam) feeds through a DL Streamer pipeline and uses a Vision-Language Model (VLM) to generate real-time captions. It also reports throughput and latency metrics.
This section shows how to:
Set up the sample application: Download the models and use Docker Compose tool to deploy the application in your environment. Compared to quick start guide, this documentation allows the user to personalize the application.
Run the application: Execute the application to see real-time captioning from your video stream.
Modify application parameters: Customize settings like inference models and VLM parameters to adapt the application to your specific requirements.
Prerequisites#
Verify that your system meets the minimum requirements. See System Requirements for details.
Install Docker platform: Installation Guide. Install the Ubuntu platform version.
In case the sample application is used with RTSP streams, setup of the RTSP stream source (live camera or test feed) or simulated RTSP stream source using local video files should be done separately. Reference instructions are provided here.
Run the Application#
1. Clone the suite#
Go to the target directory of your choice and clone the suite.
If you want to clone a specific release branch, replace main with the desired tag.
To learn more on partial cloning, check the Repository Cloning guide.
git clone --filter=blob:none --sparse --branch release-2026.2.0 https://github.com/open-edge-platform/edge-ai-suites.git
cd edge-ai-suites
git sparse-checkout set metro-ai-suite
cd metro-ai-suite/live-video-analysis/live-video-captioning
2. Create .env#
Run the setup helper:
bash scripts/setup_env.sh
The helper creates .env from .env.example, detects HOST_IP, and stores image settings such as REGISTRY and TAG in the file.
Use --force only if you want to overwrite an existing .env:
bash scripts/setup_env.sh --force
This script sets these important values:
Variable |
Default |
Purpose |
|---|---|---|
|
(auto-detected) |
Host address reachable by the browser for WebRTC signaling. |
|
|
Image registry prefix. |
|
|
Docker image tag. |
|
|
Port for the web dashboard. |
|
|
Port for the pipeline management REST API. |
|
|
Port for WebRTC/WHIP signaling (mediamtx). |
|
|
Port for the internal MQTT broker. |
|
|
WebRTC stream bitrate in kbps. Lower values reduce bandwidth. |
|
|
Enables optional object-detection pre-filtering when set to |
|
|
Enables alert-style visual highlighting based on keyword rules when set to |
|
|
Number of previous captions shown in the UI. |
|
(empty) |
Pre-fills the RTSP URL field in the dashboard on load. |
|
(empty) |
Required for downloading gated Hugging Face models. |
3. Download Models (one-time)#
Download a VLM model that is required to generate captions. For default CPU example:
./model_download_scripts/download_models.sh \
--model OpenGVLab/InternVL2-1B \
--type vlm \
--weight-format int8
Gated Hugging Face models#
Some models (for example, Gemma-3) require a Hugging Face access token. Set the token in .env or export it before running the download script:
export HUGGINGFACEHUB_API_TOKEN=<your-token>
Specifying the conversion device#
By default the model is converted on CPU. To explicitly set the device:
./model_download_scripts/download_models.sh \
--model <vlm-model-of-choice-from-huggingface> \
--type vlm \
--weight-format int8 \
--device <CPU|GPU|NPU>
Note: NPU currently requires
int4quantization for VLM conversion. If you pass--device NPUwithint8orfp16, the script automatically overrides it toint4.
See Model Preparation for detailed usage.
4. Customize your deployment (Optional)#
Before starting, edit .env to enable the features you need. The table below summarises the common customizations:
Change exposed ports#
If the default ports conflict with other services on your host, override them in .env:
DASHBOARD_PORT=4200
EVAM_HOST_PORT=8050
WHIP_SERVER_PORT=9000
Pre-fill the RTSP URL#
Set DEFAULT_RTSP_URL to have the dashboard automatically populate the stream field on load:
DEFAULT_RTSP_URL=rtsp://<RTSP_HOST_IP>:<PORT>/<ROUTE>
# For example:
DEFAULT_RTSP_URL=rtsp://192.168.1.10:8554/stream
Enable Alert Mode#
Set ALERT_MODE=true to activate alert-style visual highlighting. After starting the application, define keyword rules directly in the Alert Rules panel on the dashboard. See Enable Alert Mode for full details.
ALERT_MODE=true
Enable Object Detection#
Set ENABLE_DETECTION_PIPELINE=true to pre-filter frames using a YOLO model before sending them to the VLM.
ENABLE_DETECTION_PIPELINE=true
Download a detection model. For example:
./model_download_scripts/download_models.sh --model yolov8s --type vision
This places the model under ov_detection_models/.
See Configure Object Detection Pipeline for full details.
5. Start the application#
docker compose up -d
6. Use the dashboard#
Open:
http://<HOST_IP>:4173
Then:
Enter an RTSP stream URL or select the available USB/webcam camera.
Select the device on which the VLM model will run (e.g., “CPU”, “GPU”, “NPU”), based on the hardware available on your host system.
Select a VLM model.
Set Frame Resolution for frames parsed by the VLM:
Choose
Defaultto keep the input source resolution.Choose a preset resolution to downscale or upscale before VLM inference.
Choose
Customto set a specific width and height.
Adjust the prompt and maximum token settings if needed.
Click Start.
If your network uses a proxy, add your RTSP stream host or IP to no_proxy so the stream connection does not go through the proxy.
7. Stop the application#
docker compose down