Update README.md
Browse files
README.md
CHANGED
@@ -40,7 +40,84 @@ You will need:
|
|
40 |
- Together.AI API Key
|
41 |
- Unsloth package
|
42 |
|
43 |
-
## How to Use Model
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
44 |
|
45 |
You can load this model with `transformers`:
|
46 |
|
|
|
40 |
- Together.AI API Key
|
41 |
- Unsloth package
|
42 |
|
43 |
+
## How to Use Model via Terminal (Mac)
|
44 |
+
|
45 |
+
**Goal** Run Qwen-2.5-3B Instruct on Your Mac Using `llama.cpp`
|
46 |
+
|
47 |
+
Yes! You can run **Qwen-2.5-3B Instruct** on your Mac using `llama.cpp`. Here’s a step-by-step guide assuming you are starting from a clean macOS installation with only `pyenv` installed.
|
48 |
+
|
49 |
+
### **Step 1: Install Homebrew (if not installed)**
|
50 |
+
Homebrew is required to install `llama.cpp`.
|
51 |
+
|
52 |
+
1. Open **Terminal** (`Cmd + Space`, type `Terminal`, and press **Enter**).
|
53 |
+
2. Run:
|
54 |
+
```sh
|
55 |
+
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
|
56 |
+
```
|
57 |
+
3. After installation, add Homebrew to your PATH:
|
58 |
+
```sh
|
59 |
+
echo 'eval "$(/opt/homebrew/bin/brew shellenv)"' >> ~/.zprofile
|
60 |
+
eval "$(/opt/homebrew/bin/brew shellenv)"
|
61 |
+
```
|
62 |
+
|
63 |
+
---
|
64 |
+
|
65 |
+
### **Step 2: Install `llama.cpp` via Homebrew**
|
66 |
+
Run:
|
67 |
+
```sh
|
68 |
+
brew install llama.cpp
|
69 |
+
```
|
70 |
+
|
71 |
+
Once installed, you should be able to use `llama-cli`.
|
72 |
+
|
73 |
+
---
|
74 |
+
|
75 |
+
### **Step 3: Run Qwen-2.5-3B Instruct with `llama-cli`**
|
76 |
+
To run the model, execute:
|
77 |
+
```sh
|
78 |
+
llama-cli -hf eagle0504/qwen-2-5-3b-instruct-using-openai-gsm8k-gguf-data-enhanced-with-deepseek-v3-small:Q8_0
|
79 |
+
```
|
80 |
+
|
81 |
+
---
|
82 |
+
|
83 |
+
### **Step 4: Additional Configurations (If Needed)**
|
84 |
+
If you encounter issues or need finer control, you may want to:
|
85 |
+
|
86 |
+
#### **A. Verify Installation**
|
87 |
+
Check if `llama-cli` is installed:
|
88 |
+
```sh
|
89 |
+
llama-cli --version
|
90 |
+
```
|
91 |
+
If you see a version output, it’s installed correctly.
|
92 |
+
|
93 |
+
#### **B. Run with Explicit Model Path**
|
94 |
+
If the default Hugging Face loader doesn't work, you can manually download the model:
|
95 |
+
1. **Create a models directory:**
|
96 |
+
```sh
|
97 |
+
mkdir -p ~/llama_models && cd ~/llama_models
|
98 |
+
```
|
99 |
+
2. **Download the GGUF model file** from [Hugging Face](https://huggingface.co/eagle0504/qwen-2-5-3b-instruct-using-openai-gsm8k-gguf-data-enhanced-with-deepseek-v3-small):
|
100 |
+
```sh
|
101 |
+
wget https://huggingface.co/eagle0504/qwen-2-5-3b-instruct-using-openai-gsm8k-gguf-data-enhanced-with-deepseek-v3-small/resolve/main/Q8_0.gguf
|
102 |
+
```
|
103 |
+
3. **Run the model manually**:
|
104 |
+
```sh
|
105 |
+
llama-cli -m ~/llama_models/Q8_0.gguf
|
106 |
+
```
|
107 |
+
|
108 |
+
---
|
109 |
+
|
110 |
+
### **Step 5: Test the Model**
|
111 |
+
Try prompting it:
|
112 |
+
```sh
|
113 |
+
llama-cli -m ~/llama_models/Q8_0.gguf -p "Explain quantum computing in simple terms."
|
114 |
+
```
|
115 |
+
or interactively:
|
116 |
+
```sh
|
117 |
+
llama-cli -m ~/llama_models/Q8_0.gguf --interactive
|
118 |
+
```
|
119 |
+
|
120 |
+
## How to Use Model via Python
|
121 |
|
122 |
You can load this model with `transformers`:
|
123 |
|