Instructions to use codefuse-ai/CodeFuse-Mixtral-8x7B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use codefuse-ai/CodeFuse-Mixtral-8x7B with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="codefuse-ai/CodeFuse-Mixtral-8x7B")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("codefuse-ai/CodeFuse-Mixtral-8x7B") model = AutoModelForCausalLM.from_pretrained("codefuse-ai/CodeFuse-Mixtral-8x7B") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use codefuse-ai/CodeFuse-Mixtral-8x7B with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "codefuse-ai/CodeFuse-Mixtral-8x7B" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "codefuse-ai/CodeFuse-Mixtral-8x7B", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/codefuse-ai/CodeFuse-Mixtral-8x7B
- SGLang
How to use codefuse-ai/CodeFuse-Mixtral-8x7B 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 "codefuse-ai/CodeFuse-Mixtral-8x7B" \ --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": "codefuse-ai/CodeFuse-Mixtral-8x7B", "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 "codefuse-ai/CodeFuse-Mixtral-8x7B" \ --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": "codefuse-ai/CodeFuse-Mixtral-8x7B", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use codefuse-ai/CodeFuse-Mixtral-8x7B with Docker Model Runner:
docker model run hf.co/codefuse-ai/CodeFuse-Mixtral-8x7B
Update README.md
Browse files
README.md
CHANGED
|
@@ -248,8 +248,13 @@ CodeFuse-DeepSeek-33B 是一个通过QLoRA对基座模型DeepSeek-Coder-33B进
|
|
| 248 |
|
| 249 |
| 模型 | HumanEval(pass@1) | 日期 |
|
| 250 |
|:----------------------------|:-----------------:|:-------:|
|
|
|
|
|
|
|
| 251 |
| **CodeFuse-CodeLlama-34B** | 74.4% | 2023.9 |
|
| 252 |
|**CodeFuse-CodeLlama-34B-4bits** | 73.8% | 2023.9 |
|
|
|
|
|
|
|
|
|
|
| 253 |
| WizardCoder-Python-34B-V1.0 | 73.2% | 2023.8 |
|
| 254 |
| GPT-4(zero-shot) | 67.0% | 2023.3 |
|
| 255 |
| PanGu-Coder2 15B | 61.6% | 2023.8 |
|
|
@@ -258,11 +263,7 @@ CodeFuse-DeepSeek-33B 是一个通过QLoRA对基座模型DeepSeek-Coder-33B进
|
|
| 258 |
| GPT-3.5(zero-shot) | 48.1% | 2022.11 |
|
| 259 |
| OctoCoder | 46.2% | 2023.8 |
|
| 260 |
| StarCoder-15B | 33.6% | 2023.5 |
|
| 261 |
-
| Qwen-14b
|
| 262 |
-
| **CodeFuse-StarCoder-15B** | 54.9% | 2023.9 |
|
| 263 |
-
| **CodeFuse-QWen-14B** | 48.78% | 2023.8 |
|
| 264 |
-
| **CodeFuse-CodeGeeX2-6B** | 45.12% | 2023.11 |
|
| 265 |
-
| **CodeFuse-DeepSeek-33B**. | **78.65%** | 2024.01 |
|
| 266 |
|
| 267 |
|
| 268 |
|
|
@@ -287,11 +288,11 @@ System instruction
|
|
| 287 |
<s>human
|
| 288 |
Human 1st round input
|
| 289 |
<s>bot
|
| 290 |
-
Bot 1st round output<
|
| 291 |
<s>human
|
| 292 |
Human 2nd round input
|
| 293 |
<s>bot
|
| 294 |
-
Bot 2nd round output<
|
| 295 |
...
|
| 296 |
...
|
| 297 |
...
|
|
|
|
| 248 |
|
| 249 |
| 模型 | HumanEval(pass@1) | 日期 |
|
| 250 |
|:----------------------------|:-----------------:|:-------:|
|
| 251 |
+
| **CodeFuse-DeepSeek-33B** | **78.65%** | 2024.01 |
|
| 252 |
+
| **CodeFuse-Mixtral-8x7B** | **56.10%** | 2024.01 |
|
| 253 |
| **CodeFuse-CodeLlama-34B** | 74.4% | 2023.9 |
|
| 254 |
|**CodeFuse-CodeLlama-34B-4bits** | 73.8% | 2023.9 |
|
| 255 |
+
| **CodeFuse-StarCoder-15B** | 54.9% | 2023.9 |
|
| 256 |
+
| **CodeFuse-QWen-14B** | 48.78% | 2023.10 |
|
| 257 |
+
| **CodeFuse-CodeGeeX2-6B** | 45.12% | 2023.11 |
|
| 258 |
| WizardCoder-Python-34B-V1.0 | 73.2% | 2023.8 |
|
| 259 |
| GPT-4(zero-shot) | 67.0% | 2023.3 |
|
| 260 |
| PanGu-Coder2 15B | 61.6% | 2023.8 |
|
|
|
|
| 263 |
| GPT-3.5(zero-shot) | 48.1% | 2022.11 |
|
| 264 |
| OctoCoder | 46.2% | 2023.8 |
|
| 265 |
| StarCoder-15B | 33.6% | 2023.5 |
|
| 266 |
+
| Qwen-14b | 32.3% | 2023.10 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 267 |
|
| 268 |
|
| 269 |
|
|
|
|
| 288 |
<s>human
|
| 289 |
Human 1st round input
|
| 290 |
<s>bot
|
| 291 |
+
Bot 1st round output</s>
|
| 292 |
<s>human
|
| 293 |
Human 2nd round input
|
| 294 |
<s>bot
|
| 295 |
+
Bot 2nd round output</s>
|
| 296 |
...
|
| 297 |
...
|
| 298 |
...
|