Instructions to use Qwen/Qwen3.8-27B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Qwen/Qwen3.8-27B with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="Qwen/Qwen3.8-27B") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] pipe(text=messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("Qwen/Qwen3.8-27B") model = AutoModelForMultimodalLM.from_pretrained("Qwen/Qwen3.8-27B", device_map="auto") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] inputs = processor.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=256) print(processor.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Inference
- HuggingChat
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Qwen/Qwen3.8-27B with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Qwen/Qwen3.8-27B" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Qwen/Qwen3.8-27B", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker
docker model run hf.co/Qwen/Qwen3.8-27B
- SGLang
How to use Qwen/Qwen3.8-27B with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "Qwen/Qwen3.8-27B" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Qwen/Qwen3.8-27B", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "Qwen/Qwen3.8-27B" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Qwen/Qwen3.8-27B", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }' - Docker Model Runner
How to use Qwen/Qwen3.8-27B with Docker Model Runner:
docker model run hf.co/Qwen/Qwen3.8-27B
Qwen in production: auto-generating 79 baseball highlight clips for a Korean broadcaster at the 2026 Asian Games
Qwen in production: auto-generating 79 baseball highlight clips for a Korean broadcaster at the 2026 Asian Games
We used Qwen models end to end to build an automatic highlight-clip system for SBS, a Korean broadcaster, and ran it on live operations during the 20th Asian Games (Aichi-Nagoya 2026). Sharing what worked, what broke, and two questions we'd love input on.
Results (baseball, 5 Team Korea games)
| Metric | Value |
|---|---|
| Clips generated automatically | 79, published on SBS play "AI PICK" |
| Operator edits needed (first game, KOR vs TPE, Sep 21) | ~10% (missing segments, boundary fine-tuning) |
| Manual baseline |
The system does not replace editors: AI drafts the clips, operators review and publish. Full quantitative evaluation (tIoU-based precision/recall/F1) over all 79 clips is in progress.
Service page: https://programs.sbs.co.kr/sports/ag2026/clips/90399
Pipeline
- Preprocess - FFmpeg (NVENC/NVDEC) splits video and audio; pyannote handles diarization.
- Speech - Qwen3-ASR-1.7B transcribes, Qwen3-ForcedAligner-0.6B adds word-level timestamps.
- Transcript cleanup - a Qwen LLM [Qwen3.8-27B-FP8] corrects context errors and hallucinations per dialogue segment.
- Scenes - PySceneDetect finds cuts; one representative frame per scene plus STT/OCR/subtitles go to a Qwen VLM for a scene description.
- Index - scene summaries embedded with Qwen3-Embedding-4B into Milvus (1024-d, HNSW, cosine); broadcast metadata (game, inning, matchup) kept as filter fields.
- Clip - RAG over the top-k chunks lets the LLM propose titles and IN/OUT points; only segments with 0 <= IN < OUT <= source duration go to FFmpeg; operators review.
Lessons learned
- Skip ASR when subtitles exist. Where broadcast subtitles are available we bypass speech recognition entirely: cheaper and fewer errors.
- Don't trust first-pass ASR on sports audio. Crowd noise and commentary overlap, so every segment goes through hallucination gates and LLM correction before it counts as dialogue.
- Fewer frames, same understanding. In our PoC on 6-second Korean broadcast clips, sampling at 0.5 fps instead of 30 fps was 2.4x faster and used 6.89x fewer tokens. In production we send one representative frame per scene.
- Visual cuts are not event boundaries. We merge adjacent scenes by dialogue continuity and game context (scoreboard OCR: inning, outs, count, score) before retrieval.
Question for the community
- Frames for scene description: for Qwen3.8 as a VLM, is there guidance on how many frames per scene (or which resolution) gives the best accuracy/cost trade-off for short broadcast scenes?
Any pointers, or experiences from similar media workloads, are very welcome.
Links
- GitHub: https://github.com/SceneMakerAI (Apache 2.0)
- Docs (setup notes, PoC benchmarks): https://doc.scenemaker.solbox.com
- Earlier note on serving Qwen3-Omni on Blackwell: https://github.com/QwenLM/Qwen3-Omni/discussions/182
Built by Solbox and SBSi under the 2026 NIPA Open-Source AI/SW Development and Utilization Support Program (PJT-26-040089). Thanks to the Qwen team for the open weights.