Instructions to use ngqtrung/video-8b-grpo-base with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use ngqtrung/video-8b-grpo-base with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="ngqtrung/video-8b-grpo-base") 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)# Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("ngqtrung/video-8b-grpo-base") model = AutoModelForMultimodalLM.from_pretrained("ngqtrung/video-8b-grpo-base") 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=40) print(processor.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use ngqtrung/video-8b-grpo-base with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "ngqtrung/video-8b-grpo-base" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "ngqtrung/video-8b-grpo-base", "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/ngqtrung/video-8b-grpo-base
- SGLang
How to use ngqtrung/video-8b-grpo-base 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 "ngqtrung/video-8b-grpo-base" \ --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": "ngqtrung/video-8b-grpo-base", "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 "ngqtrung/video-8b-grpo-base" \ --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": "ngqtrung/video-8b-grpo-base", "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 ngqtrung/video-8b-grpo-base with Docker Model Runner:
docker model run hf.co/ngqtrung/video-8b-grpo-base
Qwen3-VL-8B · Video-MC · GRPO baseline (cold-start) — best video keeper
RLVR post-training of Qwen/Qwen3-VL-8B-Instruct on multiple-choice video QA with fully-async GRPO, cold-started from the stock 8B-Instruct. This is experiment_name=grpo_video_4node_full_v3_24f100k_8b_base_perf, global_step_80 (the keeper).
This is the best video checkpoint of the 8B campaign. Cold-start base RL reaches offline full-set val mean_accuracy 0.4918 @ step 80 (full set = 5645 rows: VideoMME-v1 2700 + PerceptionComp 1108 + Video-Holmes 1837). It catches the SFT-770-warmstart sibling by step 80 and tracks it thereafter — confirming SFT warm-start buys no durable video val advantage. RL itself clears the zero-shot base (0.4444) by +4.7 pt, but no lever moves above the ~0.485 ceiling.
Results
Offline full-set eval (VideoMME-v1 2700 + PerceptionComp 1108 + Video-Holmes 1837 = 5645 rows), scored with the repo's vero compute_score (the exact training val metric). mean = macro-mean of the 3 bench accuracies.
Keeper = global_step_80 (peak):
| metric | mean | videomme | holmes | perceptioncomp |
|---|---|---|---|---|
| base RL @80 (keeper) | 0.4918 | 0.6581 | 0.4741 | 0.3430 |
| stock Qwen3-VL-8B ckpt-0 (zero-shot) | 0.4444 | 0.6426 | 0.4143 | 0.2762 |
Trajectory (mean): 0.430 @20 → 0.475 @40 → 0.479 @60 → 0.492 @80 → then oscillates tightly 0.475–0.485 around ~0.484 through step 240 (flat plateau, no upward trend, no collapse). RL's gain concentrates where the base is weakest (pcomp 0.276→0.343); videomme is already strong at base and barely moves.
Training
- Base model: stock
Qwen/Qwen3-VL-8B-Instruct(cold-start RL,resume_mode=auto). - Framework: fork of volcengine/verl —
ngquangtrung57/verl@videorl-mods. Fully-async GRPO: FSDP2 trainer + vLLM rollouter, partial rollout. - Warm start: none (cold-start). This run is the A/B ablation vs the SFT-770-warmstart run.
- Reward: dapo-style
score = 0.8·accuracy + 0.2·format(FORMAT_WEIGHT=0.2,FORMAT_MIN_THINK_CHARS=100). No KL penalty. - Exploration: OFF.
- Topology: 4-node 2+2 — 2 trainer nodes (16-GPU FSDP2, dp=16) + 2 rollout nodes (16 GPU, vLLM TP=2 → 8 replicas). H100×8 per node.
- Batch:
ppo_mini_batch_size=16×require_batches=4×rollout.n=8= 512 trajectories/step. - Data:
GROUP_VIDEO_TRAIN_MC_24F100K(5 video-MC parquets, 105,993 prompts/epoch, 24 frames / 100k pixels). - Optim / seq: lr
1e-6, warmup 25 steps;total_epochs=2; clip_ratio 0.2 / 0.3 (clip_c=10.0);max_prompt_length=17408,max_response_length=16384;enforce_eager=true;gpu_memory_utilization=0.75; staleness 0.4. - Validation: inline val OFF (
test_freq=10000); all video val is offline full-set eval on a dedicated 8×H100 node (vLLM TP1, data-parallel), every 20 fit-steps. - Train metrics: ~215 s/step; final reward 0.854; final response_length ~92 tok; 250 steps trained (stopped at fit-step ~251 by planned cutover to the exploration run). Zero crashes in ~15 h.
W&B
Project verl_fully_async (entity quangtrung5705-nanyang-technological-university-singapore). Main segment (train metrics only — video val is offline, not on W&B):
https://wandb.ai/quangtrung5705-nanyang-technological-university-singapore/verl_fully_async/runs/mwuxsj29
Intended use / limitations
Research checkpoint — the best video keeper of an 8B controlled study, but note the headline finding: 8B video-MC RL is a documented 7-way dead-heat at ~0.485 full-set val. No lever tested (SFT warm-start, cold-base RL, exploration at several τ, larger GRPO groups) beats this ceiling; the bottleneck is outside the exploration/warm-start/RL-duration space (data / reward / task design / model scale). RL does buy a real +4-5 pt over the zero-shot base. Multiple-choice video QA, <think>…</think> then-answer format. No safety/RLHF alignment beyond the base.
Usage
from transformers import AutoModelForImageTextToText, AutoProcessor
model_id = "ngqtrung/video-8b-grpo-base"
model = AutoModelForImageTextToText.from_pretrained(model_id, dtype="auto", device_map="auto")
processor = AutoProcessor.from_pretrained(model_id)
messages = [{
"role": "user",
"content": [
{"type": "video", "video": "clip.mp4"},
{"type": "text", "text": "Answer the multiple-choice question. Reason inside <think>...</think>, then give the final letter."},
],
}]
inputs = processor.apply_chat_template(
messages, add_generation_prompt=True, tokenize=True,
return_dict=True, return_tensors="pt"
).to(model.device)
out = model.generate(**inputs, max_new_tokens=1024)
print(processor.batch_decode(out[:, inputs["input_ids"].shape[1]:], skip_special_tokens=True)[0])
Citation / lineage
- Base model: Qwen3-VL-8B-Instruct (Qwen team). Inherits the Qwen3-VL license — review the base model's terms; the Apache-2.0 tag refers to this repo's RLVR training artifacts.
- Framework: verl (volcengine/verl), fork
ngquangtrung57/verl@videorl-mods; fully-async GRPO (FSDP2 + vLLM). - Study: controlled OMR/Video exploration study on Qwen3-VL-8B; this is the cold-start video baseline arm and the best video keeper (
docs/experiments_summary_8b.md).
- Downloads last month
- 24
Model tree for ngqtrung/video-8b-grpo-base
Base model
Qwen/Qwen3-VL-8B-Instruct