How to use from
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 "PolicyShiftGuard/PolicyShiftGuard-7B" \
    --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": "PolicyShiftGuard/PolicyShiftGuard-7B",
		"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 "PolicyShiftGuard/PolicyShiftGuard-7B" \
        --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": "PolicyShiftGuard/PolicyShiftGuard-7B",
		"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"
						}
					}
				]
			}
		]
	}'
Quick Links

PolicyShiftGuard-7B

📜 Paper | 💻 Code | 🏠 Project Page

PolicyShiftGuard-7B is a policy-conditioned image guardrail model based on Qwen2.5-VL-7B. It is trained to follow a supplied policy bundle and produce structured image-safety decisions under changing application policies.

Expected Output Format

true | <two-digit risk category id> | <short reason>
false | <short reason>

Training Data

This checkpoint is trained with the PolicyShiftBench public data release:

  • Dataset: PolicyShiftBench/PolicyShiftBench
  • Main evaluation splits: ID/adaptive branch and OOD/shift branch
  • Training stages: randomized policy SFT followed by boundary-pair policy adaptation

Intended Use

Use this model for research on policy-conditioned multimodal safety, adaptive image moderation, and robustness under policy shifts. The model should be evaluated with explicit policy bundles rather than as a fixed universal safety classifier.

Limitations

This is a research checkpoint. It may fail under policies, languages, visual domains, or deployment settings not represented in the benchmark. Outputs should not be treated as legal or compliance advice.

Citation

If you use this model, please cite the paper:

@article{song2026policyshiftguard,
  title   = {PolicyShiftGuard: Benchmarking and Improving Policy-Adaptive Image Guardrails},
  author  = {Song, Mingyang and Xu, Luxin and Sun, Haoyu and Pan, Minzhou and Cheng, Yu and Li, Bo},
  journal = {arXiv preprint arXiv:2607.05910},
  year    = {2026}
}
Downloads last month
44
Safetensors
Model size
8B params
Tensor type
BF16
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for PolicyShiftGuard/PolicyShiftGuard-7B

Finetuned
(1187)
this model
Quantizations
1 model

Dataset used to train PolicyShiftGuard/PolicyShiftGuard-7B

Paper for PolicyShiftGuard/PolicyShiftGuard-7B