Instructions to use chestnutlzj/MoE-Qwen-4x1.8B-pretrain-50000-ckpt with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use chestnutlzj/MoE-Qwen-4x1.8B-pretrain-50000-ckpt with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="chestnutlzj/MoE-Qwen-4x1.8B-pretrain-50000-ckpt")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("chestnutlzj/MoE-Qwen-4x1.8B-pretrain-50000-ckpt") model = AutoModelForCausalLM.from_pretrained("chestnutlzj/MoE-Qwen-4x1.8B-pretrain-50000-ckpt", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use chestnutlzj/MoE-Qwen-4x1.8B-pretrain-50000-ckpt with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "chestnutlzj/MoE-Qwen-4x1.8B-pretrain-50000-ckpt" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "chestnutlzj/MoE-Qwen-4x1.8B-pretrain-50000-ckpt", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/chestnutlzj/MoE-Qwen-4x1.8B-pretrain-50000-ckpt
- SGLang
How to use chestnutlzj/MoE-Qwen-4x1.8B-pretrain-50000-ckpt 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 "chestnutlzj/MoE-Qwen-4x1.8B-pretrain-50000-ckpt" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "chestnutlzj/MoE-Qwen-4x1.8B-pretrain-50000-ckpt", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'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 "chestnutlzj/MoE-Qwen-4x1.8B-pretrain-50000-ckpt" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "chestnutlzj/MoE-Qwen-4x1.8B-pretrain-50000-ckpt", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use chestnutlzj/MoE-Qwen-4x1.8B-pretrain-50000-ckpt with Docker Model Runner:
docker model run hf.co/chestnutlzj/MoE-Qwen-4x1.8B-pretrain-50000-ckpt
4x1.8B MoE Qwen Ckpt 50000
This is a MoE model project constructed based on the Qwen 1.8B model. In this project, we concatenated 4 original models and trained them using special training methods.
This model is a checkpoint model for the continue pretraining stage.
Evaluations
| Groups | n-shot | Metric | Value | Stderr | |
|---|---|---|---|---|---|
| boolq | 0 | acc | 0.6508 | ± | 0.0083 |
| ceval-valid | 0 | acc | 0.5290 | ± | 0.1912 |
| 0 | acc_norm | 0.5290 | ± | 0.1912 | |
| cmmlu | 0 | acc | 0.5087 | ± | 0.1237 |
| 0 | acc_norm | 0.5087 | ± | 0.1237 | |
| mathqa | 0 | acc | 0.2647 | ± | 0.0081 |
| 0 | acc_norm | 0.2693 | ± | 0.0081 | |
| mmlu | 0 | acc | 0.4353 | ± | 0.0830 |
| - stem | 0 | acc | 0.3809 | ± | 0.0659 |
| - social_sciences | 0 | acc | 0.4959 | ± | 0.0708 |
| - other | 0 | acc | 0.4844 | ± | 0.0744 |
| - humanities | 0 | acc | 0.3998 | ± | 0.0849 |
Acknowledgements
License Agreement
This project is open source under the Tongyi Qianwen Research License Agreement. You can view the complete license agreement in this link: [https://github.com/QwenLM/Qwen/blob/main/Tongyi%20Qianwen%20RESEARCH%20LICENSE%20AGREEMENT].
During the use of this project, please ensure that your usage behavior complies with the terms and conditions of the license agreement.
- Downloads last month
- 14
