Instructions to use grimjim/HuatuoSkywork-o1-Llama-3.1-8B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use grimjim/HuatuoSkywork-o1-Llama-3.1-8B with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="grimjim/HuatuoSkywork-o1-Llama-3.1-8B") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("grimjim/HuatuoSkywork-o1-Llama-3.1-8B") model = AutoModelForCausalLM.from_pretrained("grimjim/HuatuoSkywork-o1-Llama-3.1-8B") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.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(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Inference
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use grimjim/HuatuoSkywork-o1-Llama-3.1-8B with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "grimjim/HuatuoSkywork-o1-Llama-3.1-8B" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "grimjim/HuatuoSkywork-o1-Llama-3.1-8B", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/grimjim/HuatuoSkywork-o1-Llama-3.1-8B
- SGLang
How to use grimjim/HuatuoSkywork-o1-Llama-3.1-8B 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 "grimjim/HuatuoSkywork-o1-Llama-3.1-8B" \ --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": "grimjim/HuatuoSkywork-o1-Llama-3.1-8B", "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 "grimjim/HuatuoSkywork-o1-Llama-3.1-8B" \ --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": "grimjim/HuatuoSkywork-o1-Llama-3.1-8B", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use grimjim/HuatuoSkywork-o1-Llama-3.1-8B with Docker Model Runner:
docker model run hf.co/grimjim/HuatuoSkywork-o1-Llama-3.1-8B
HuatuoSkywork-o1-Llama-3.1-8B
This is a merge of pre-trained language models created using mergekit.
This is an experiment to see what happens when two o1-inspired models are merged. The result achieves an unexpectedly high MATH Lvl 5 benchmark of 33.99%.
This model is capable of roleplay text completion, but it will tend to drive narrative along chain-of-thought lines. Technically, an assistant persona is a role-play, so this model could be an interesting or good fit, depending on one's taste.
Built with Llama.
Merge Details
Merge Method
This model was merged using the SLERP merge method.
Models Merged
The following models were included in the merge:
Configuration
The following YAML configuration was used to produce this model:
models:
- model: Skywork/Skywork-o1-Open-Llama-3.1-8B
- model: FreedomIntelligence/HuatuoGPT-o1-8B
merge_method: slerp
base_model: Skywork/Skywork-o1-Open-Llama-3.1-8B
parameters:
t:
- value: 0.5
dtype: bfloat16
Open LLM Leaderboard Evaluation Results
Detailed results can be found here! Summarized results can be found here!
| Metric | Value (%) |
|---|---|
| Average | 23.67 |
| IFEval (0-Shot) | 39.61 |
| BBH (3-Shot) | 28.33 |
| MATH Lvl 5 (4-Shot) | 33.99 |
| GPQA (0-shot) | 5.70 |
| MuSR (0-shot) | 11.12 |
| MMLU-PRO (5-shot) | 23.28 |
- Downloads last month
- 3
Model tree for grimjim/HuatuoSkywork-o1-Llama-3.1-8B
Collection including grimjim/HuatuoSkywork-o1-Llama-3.1-8B
Evaluation results
- averaged accuracy on IFEval (0-Shot)Open LLM Leaderboard39.610
- normalized accuracy on BBH (3-Shot)test set Open LLM Leaderboard28.330
- exact match on MATH Lvl 5 (4-Shot)test set Open LLM Leaderboard33.990
- acc_norm on GPQA (0-shot)Open LLM Leaderboard5.700
- acc_norm on MuSR (0-shot)Open LLM Leaderboard11.120
- accuracy on MMLU-PRO (5-shot)test set Open LLM Leaderboard23.280