Instructions to use second-state/Qwen2.5-Math-7B-Instruct-GGUF with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use second-state/Qwen2.5-Math-7B-Instruct-GGUF with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="second-state/Qwen2.5-Math-7B-Instruct-GGUF") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("second-state/Qwen2.5-Math-7B-Instruct-GGUF") model = AutoModelForCausalLM.from_pretrained("second-state/Qwen2.5-Math-7B-Instruct-GGUF") - llama-cpp-python
How to use second-state/Qwen2.5-Math-7B-Instruct-GGUF with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="second-state/Qwen2.5-Math-7B-Instruct-GGUF", filename="Qwen2.5-Math-7B-Instruct-Q2_K.gguf", )
llm.create_chat_completion( messages = [ { "role": "user", "content": "What is the capital of France?" } ] ) - Notebooks
- Google Colab
- Kaggle
- Local Apps
- llama.cpp
How to use second-state/Qwen2.5-Math-7B-Instruct-GGUF with llama.cpp:
Install from brew
brew install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M # Run inference directly in the terminal: llama-cli -hf second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M # Run inference directly in the terminal: llama-cli -hf second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M # Run inference directly in the terminal: ./llama-cli -hf second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama-cli -hf second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M
Use Docker
docker model run hf.co/second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M
- LM Studio
- Jan
- vLLM
How to use second-state/Qwen2.5-Math-7B-Instruct-GGUF with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "second-state/Qwen2.5-Math-7B-Instruct-GGUF" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "second-state/Qwen2.5-Math-7B-Instruct-GGUF", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M
- SGLang
How to use second-state/Qwen2.5-Math-7B-Instruct-GGUF 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 "second-state/Qwen2.5-Math-7B-Instruct-GGUF" \ --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": "second-state/Qwen2.5-Math-7B-Instruct-GGUF", "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 "second-state/Qwen2.5-Math-7B-Instruct-GGUF" \ --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": "second-state/Qwen2.5-Math-7B-Instruct-GGUF", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Ollama
How to use second-state/Qwen2.5-Math-7B-Instruct-GGUF with Ollama:
ollama run hf.co/second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M
- Unsloth Studio new
How to use second-state/Qwen2.5-Math-7B-Instruct-GGUF with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for second-state/Qwen2.5-Math-7B-Instruct-GGUF to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for second-state/Qwen2.5-Math-7B-Instruct-GGUF to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for second-state/Qwen2.5-Math-7B-Instruct-GGUF to start chatting
- Pi new
How to use second-state/Qwen2.5-Math-7B-Instruct-GGUF with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama-server -hf second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M
Configure the model in Pi
# Install Pi: npm install -g @mariozechner/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Hermes Agent new
How to use second-state/Qwen2.5-Math-7B-Instruct-GGUF with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama-server -hf second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M
Run Hermes
hermes
- Docker Model Runner
How to use second-state/Qwen2.5-Math-7B-Instruct-GGUF with Docker Model Runner:
docker model run hf.co/second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M
- Lemonade
How to use second-state/Qwen2.5-Math-7B-Instruct-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull second-state/Qwen2.5-Math-7B-Instruct-GGUF:Q4_K_M
Run and chat with the model
lemonade run user.Qwen2.5-Math-7B-Instruct-GGUF-Q4_K_M
List all available models
lemonade list
Update models
Browse files- .gitattributes +13 -0
- Qwen2.5-Math-7B-Instruct-Q2_K.gguf +3 -0
- Qwen2.5-Math-7B-Instruct-Q3_K_L.gguf +3 -0
- Qwen2.5-Math-7B-Instruct-Q3_K_M.gguf +3 -0
- Qwen2.5-Math-7B-Instruct-Q3_K_S.gguf +3 -0
- Qwen2.5-Math-7B-Instruct-Q4_0.gguf +3 -0
- Qwen2.5-Math-7B-Instruct-Q4_K_M.gguf +3 -0
- Qwen2.5-Math-7B-Instruct-Q4_K_S.gguf +3 -0
- Qwen2.5-Math-7B-Instruct-Q5_0.gguf +3 -0
- Qwen2.5-Math-7B-Instruct-Q5_K_M.gguf +3 -0
- Qwen2.5-Math-7B-Instruct-Q5_K_S.gguf +3 -0
- Qwen2.5-Math-7B-Instruct-Q6_K.gguf +3 -0
- Qwen2.5-Math-7B-Instruct-Q8_0.gguf +3 -0
- Qwen2.5-Math-7B-Instruct-f16.gguf +3 -0
- config.json +27 -0
|
@@ -33,3 +33,16 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
Qwen2.5-Math-7B-Instruct-Q2_K.gguf filter=lfs diff=lfs merge=lfs -text
|
| 37 |
+
Qwen2.5-Math-7B-Instruct-Q3_K_L.gguf filter=lfs diff=lfs merge=lfs -text
|
| 38 |
+
Qwen2.5-Math-7B-Instruct-Q3_K_M.gguf filter=lfs diff=lfs merge=lfs -text
|
| 39 |
+
Qwen2.5-Math-7B-Instruct-Q3_K_S.gguf filter=lfs diff=lfs merge=lfs -text
|
| 40 |
+
Qwen2.5-Math-7B-Instruct-Q4_0.gguf filter=lfs diff=lfs merge=lfs -text
|
| 41 |
+
Qwen2.5-Math-7B-Instruct-Q4_K_M.gguf filter=lfs diff=lfs merge=lfs -text
|
| 42 |
+
Qwen2.5-Math-7B-Instruct-Q4_K_S.gguf filter=lfs diff=lfs merge=lfs -text
|
| 43 |
+
Qwen2.5-Math-7B-Instruct-Q5_0.gguf filter=lfs diff=lfs merge=lfs -text
|
| 44 |
+
Qwen2.5-Math-7B-Instruct-Q5_K_M.gguf filter=lfs diff=lfs merge=lfs -text
|
| 45 |
+
Qwen2.5-Math-7B-Instruct-Q5_K_S.gguf filter=lfs diff=lfs merge=lfs -text
|
| 46 |
+
Qwen2.5-Math-7B-Instruct-Q6_K.gguf filter=lfs diff=lfs merge=lfs -text
|
| 47 |
+
Qwen2.5-Math-7B-Instruct-Q8_0.gguf filter=lfs diff=lfs merge=lfs -text
|
| 48 |
+
Qwen2.5-Math-7B-Instruct-f16.gguf filter=lfs diff=lfs merge=lfs -text
|
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:2d4a9e72e7cda9caf429036a25b09d67329f59502ac71c5ca1bd925c1089c0c0
|
| 3 |
+
size 3015940544
|
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:391c20971ca5fe1e31beb0327ecd4e9294afa8bab8c0b3fed73b889b383a389f
|
| 3 |
+
size 4088459712
|
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:edcb68501ab9dc84ad239912f49a73917fd3e1d7ee8f332e2bcdc1a1391f6f8b
|
| 3 |
+
size 3808391616
|
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:cd934e6279204b16aebfbc51447592abc6fa8cd0b7a82d51eea332ca0925575b
|
| 3 |
+
size 3492368832
|
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:ee6887ebc58cbb91c6aade767d70c9b15283a619693a2d6bcae73cd9d406e4ba
|
| 3 |
+
size 4431391168
|
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:fafe6e14252a94d92dbf56408568f79bde5dd7f3d8e7bc0eb6275195c6214d31
|
| 3 |
+
size 4683073984
|
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:9d23d98e6516df4e515d12659a41cc4e027e55da91f4ab8390ceba3294bec1fa
|
| 3 |
+
size 4457769408
|
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:0820feeb41f8ee15d54c91c472354fe13c8133cdc1587a21327ce19b8f792425
|
| 3 |
+
size 5315176896
|
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:1e593ebd3c758443a7d908882015c6a60ecdb4a965b9d4ac9595712ee7ff28f2
|
| 3 |
+
size 5444831680
|
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:cb6359fa7c9a0eb2a1911f3c2d829904a4f3313f7c710860c65daf5b7fc6a6ca
|
| 3 |
+
size 5315176896
|
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:f9f8946fb899e3572bd75b6bdd42315a24afc89ac1068323870a0280925baf53
|
| 3 |
+
size 6254199232
|
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:007b389083750842fc9316a64f54344a9399699305130e735e717a1928d01eeb
|
| 3 |
+
size 8098525632
|
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:ff22aaf39c7ac46f5d47dccbcc284ca1036c84aeb121d1e64444137888cedacb
|
| 3 |
+
size 15237853632
|
|
@@ -0,0 +1,27 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"architectures": [
|
| 3 |
+
"Qwen2ForCausalLM"
|
| 4 |
+
],
|
| 5 |
+
"attention_dropout": 0.0,
|
| 6 |
+
"bos_token_id": 151643,
|
| 7 |
+
"eos_token_id": 151645,
|
| 8 |
+
"hidden_act": "silu",
|
| 9 |
+
"hidden_size": 3584,
|
| 10 |
+
"initializer_range": 0.02,
|
| 11 |
+
"intermediate_size": 18944,
|
| 12 |
+
"max_position_embeddings": 4096,
|
| 13 |
+
"max_window_layers": 28,
|
| 14 |
+
"model_type": "qwen2",
|
| 15 |
+
"num_attention_heads": 28,
|
| 16 |
+
"num_hidden_layers": 28,
|
| 17 |
+
"num_key_value_heads": 4,
|
| 18 |
+
"rms_norm_eps": 1e-06,
|
| 19 |
+
"rope_theta": 10000.0,
|
| 20 |
+
"sliding_window": 4096,
|
| 21 |
+
"tie_word_embeddings": false,
|
| 22 |
+
"torch_dtype": "bfloat16",
|
| 23 |
+
"transformers_version": "4.43.1",
|
| 24 |
+
"use_cache": true,
|
| 25 |
+
"use_sliding_window": false,
|
| 26 |
+
"vocab_size": 152064
|
| 27 |
+
}
|