CooperBench/cooperdata-bridge-midtrain-blend
Viewer • Updated • 33.2k
How to use CooperBench/Qwen3.5-9B-cooperdata-bridge-midtrain-32k with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("image-text-to-text", model="CooperBench/Qwen3.5-9B-cooperdata-bridge-midtrain-32k")
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("CooperBench/Qwen3.5-9B-cooperdata-bridge-midtrain-32k")
model = AutoModelForMultimodalLM.from_pretrained("CooperBench/Qwen3.5-9B-cooperdata-bridge-midtrain-32k", 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=40)
print(processor.decode(outputs[0][inputs["input_ids"].shape[-1]:]))How to use CooperBench/Qwen3.5-9B-cooperdata-bridge-midtrain-32k with vLLM:
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "CooperBench/Qwen3.5-9B-cooperdata-bridge-midtrain-32k"
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:8000/v1/chat/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "CooperBench/Qwen3.5-9B-cooperdata-bridge-midtrain-32k",
"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 run hf.co/CooperBench/Qwen3.5-9B-cooperdata-bridge-midtrain-32k
How to use CooperBench/Qwen3.5-9B-cooperdata-bridge-midtrain-32k with SGLang:
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
--model-path "CooperBench/Qwen3.5-9B-cooperdata-bridge-midtrain-32k" \
--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": "CooperBench/Qwen3.5-9B-cooperdata-bridge-midtrain-32k",
"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 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 "CooperBench/Qwen3.5-9B-cooperdata-bridge-midtrain-32k" \
--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": "CooperBench/Qwen3.5-9B-cooperdata-bridge-midtrain-32k",
"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"
}
}
]
}
]
}'How to use CooperBench/Qwen3.5-9B-cooperdata-bridge-midtrain-32k with Docker Model Runner:
docker model run hf.co/CooperBench/Qwen3.5-9B-cooperdata-bridge-midtrain-32k
axolotl version: 0.17.0.dev0
base_model: Qwen/Qwen3.5-9B
plugins:
- axolotl.integrations.cut_cross_entropy.CutCrossEntropyPlugin
strict: false
datasets:
- path: CooperBench/cooperdata-bridge-midtrain-blend
type: completion
field: text
split: train
sample_packing: true
dataloader_num_workers: 4
dataloader_prefetch_factor: 4
dataloader_pin_memory: true
unfrozen_parameters:
- model.language_model.*
- lm_head.*
val_set_size: 0.0
output_dir: /vol/midtrain_axolotl_bridge-32k
dataset_prepared_path: /vol/_axolotl_prepared_bridge
sequence_len: 32768
max_steps: -1
micro_batch_size: 1
gradient_accumulation_steps: 1
num_epochs: 1
optimizer: adamw_torch_fused
lr_scheduler: cosine
learning_rate: 1.5e-05
warmup_ratio: 0.1
weight_decay: 0.1
bf16: auto
tf32: true
gradient_checkpointing: false
attn_implementation: flash_attention_2
logging_steps: 1
saves_per_epoch: 1
special_tokens: null
wandb_project: qwen35-9b-cooperdata
wandb_name: bridge-midtrain-axolotl
fsdp_config:
fsdp_version: 2
offload_params: false
cpu_ram_efficient_loading: true
auto_wrap_policy: TRANSFORMER_BASED_WRAP
transformer_layer_cls_to_wrap: Qwen3_5DecoderLayer
state_dict_type: FULL_STATE_DICT
sharding_strategy: FULL_SHARD
reshard_after_forward: true
activation_checkpointing: true
This model is a fine-tuned version of Qwen/Qwen3.5-9B on the CooperBench/cooperdata-bridge-midtrain-blend dataset.
More information needed
More information needed
More information needed
The following hyperparameters were used during training: