Text Generation
Transformers
Safetensors
Chinese
English
qwen3_5
image-text-to-text
shopping-agent
sft
action-only
shopsimulator
tool-calling
conversational
Instructions to use HOWILLMAKEIT/ShopMaster-4B-SFT with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use HOWILLMAKEIT/ShopMaster-4B-SFT with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="HOWILLMAKEIT/ShopMaster-4B-SFT") 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("HOWILLMAKEIT/ShopMaster-4B-SFT") model = AutoModelForMultimodalLM.from_pretrained("HOWILLMAKEIT/ShopMaster-4B-SFT", 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]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use HOWILLMAKEIT/ShopMaster-4B-SFT with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "HOWILLMAKEIT/ShopMaster-4B-SFT" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "HOWILLMAKEIT/ShopMaster-4B-SFT", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/HOWILLMAKEIT/ShopMaster-4B-SFT
- SGLang
How to use HOWILLMAKEIT/ShopMaster-4B-SFT 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 "HOWILLMAKEIT/ShopMaster-4B-SFT" \ --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": "HOWILLMAKEIT/ShopMaster-4B-SFT", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'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 "HOWILLMAKEIT/ShopMaster-4B-SFT" \ --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": "HOWILLMAKEIT/ShopMaster-4B-SFT", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use HOWILLMAKEIT/ShopMaster-4B-SFT with Docker Model Runner:
docker model run hf.co/HOWILLMAKEIT/ShopMaster-4B-SFT
ShopMaster-4B-SFT
ShopMaster-4B ็ Action-Only SFT๏ผep2๏ผ้ถๆฎตๆจกๅโโๅ
ณ้ญๆ็ปด้พใไป
็็ฃ <tool_call> ๅทฅๅ
ทๅจไฝๆฎต๏ผไฝไธบๅ็ปญ 100 ๆญฅ GiGPO + DAPO ๅผบๅๅญฆไน ็ๅทๅฏๅจ่ตท็นใ
- ๆ็ป RL ๆจกๅ๏ผๆจ่้ป่ฎคไฝฟ็จ๏ผ: HOWILLMAKEIT/ShopMaster-4B๏ผHoldout-915 **65.75%**๏ผ
- GitHub ไปๅบ: HOWILLMAKEIT/ShopMaster-4B
- ไบคไบๅผ้กน็ฎไธป้กต: https://howillmakeit.github.io/ShopMaster-4B/
- ๅบๅบงๆจกๅ: Qwen/Qwen3.5-4B
่ฎญ็ปไธๆ้่ฏดๆ
- ๆฐๆฎ๏ผไป
DeepSeek-V4.1-Flash-1017้้ๅนถ็ป็ฏๅข้่ฝฎๅๆพ 0 ่ฏฏๅทฎๆ ธ้ช็ 1,015 ๆกๆๅ่ฝจ่ฟนไธญๆ้ฟๅบฆๅ 4 ๆกฃๆฝๆ ท 388 ๆก่ฎญ็ป + 40 ๆก้ช่ฏ๏ผๅทฒๆๅ ๅ ็ฝฎไบ GitHub ไปๅบdata/sft/teacher_success_1015.tar.gz๏ผใ - ่ๅผ๏ผ้็จ Action-Only SFT๏ผๆฏ่ฝฎ assistant ็ฝฎ็ฉบ
<think>๏ผไป ๅฏนๅทฅๅ ท่ฐ็จๅจไฝๆฎต่ฎก็ฎไบคๅ็ต๏ผๆๆๅไฝ้ๆณๅทฅๅ ท่ฐ็จๅนถๆไธไธๆ็็ปๅค่ฝฎ็ฏๅข่งๅฏใ - ๆ้ๅฝขๅผ๏ผ็บฏๆๆฌ้ชจๅนฒไธ่ฎญ็ป
LoRA (r=16, alpha=32)2 epoch๏ผๅๅนถๅ็ปๅคๆจกๆๅฃณๅซๆฅๅๅๅๅงQwen/Qwen3.5-4Bๅ็็ปๆ๏ผ่ง่งๅกๅๆ ทไฟ็๏ผ๏ผๅนถ่กฅ้ฝgeneration_config.json๏ผeos_token_id: [248044, 248046]๏ผ๏ผๅฏ็ดๆฅ็จ SGLang / vLLM / Transformers ๅ ่ฝฝๆ็ดๆฅไฝไธบveRLRL ่ฎญ็ป่ตท็นใ
่ฏๆต่กจ็ฐ๏ผHoldout-915๏ผT=0.0๏ผ32K ไธไธๆ๏ผ
| ๆจกๅ | ๆๆ้ข | ไธฅๆ ผๆๅ็ | ๅๅ | ่ดญไนฐ็ | ไธๅ็ฒพๅๅบฆ | repeat_loop |
invalid_tool |
้ขๅๆญฅๆฐ | ้ขๅ็ๆ Token |
|---|---|---|---|---|---|---|---|---|---|
Qwen3.5-4B (Base, ๅ
ณๆ่) |
906/915 | 35.10% (318) | 0.382 | 74.83% | 46.90% | 19 (2.1%) | 182 (19.9%) | 4.5 | 311 |
| ShopMaster-4B-SFT (ๆฌๆจกๅ, ep2) | 905/915 | 58.34% (528) | 0.607 | 84.75% | 68.84% | 124 (13.6%) | 10 (1.1%) | 8.2 | 267 |
| ShopMaster-4B (+100 ๆญฅ GiGPO + DAPO) | 911/915 | 65.75% (599) | 0.675 | 91.11% | 72.17% | 63 (6.9%) | 7 (0.8%) | 6.7 | 226 |
ๅฟซ้ไฝฟ็จ๏ผๆจ็ไธ RL ๅค็ฐๅ้ enable_thinking=False๏ผ
python -m sglang.launch_server \
--model-path HOWILLMAKEIT/ShopMaster-4B-SFT \
--host 127.0.0.1 --port 8000 \
--context-length 32768 \
--tool-call-parser qwen3_coder
่ฎธๅฏ
ๆ้้ตๅพชๅบๅบงๆจกๅ Qwen/Qwen3.5-4B ็ Apache-2.0 ่ฎธๅฏ่ฏใ
- Downloads last month
- 13