Text Generation
Transformers
Safetensors
GGUF
gemma3_text
turkish
türkiye
english
ai
lamapi
gemma3
next
next-x1
efficient
open-source
1b
huggingface
large-language-model
llm
causal
transformer
artificial-intelligence
machine-learning
ai-research
natural-language-processing
nlp
finetuned
lightweight
creative
summarization
question-answering
chat-model
generative-ai
optimized-model
unsloth
trl
sft
chemistry
biology
finance
legal
music
art
code
climate
medical
agent
text-generation-inference
conversational
Instructions to use thelamapi/next-1b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use thelamapi/next-1b with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="thelamapi/next-1b") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("thelamapi/next-1b") model = AutoModelForCausalLM.from_pretrained("thelamapi/next-1b") 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]:])) - llama-cpp-python
How to use thelamapi/next-1b with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="thelamapi/next-1b", filename="next-1b-bf16.gguf", )
llm.create_chat_completion( messages = [ { "role": "user", "content": "What is the capital of France?" } ] ) - Inference
- Local Apps Settings
- llama.cpp
How to use thelamapi/next-1b with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf thelamapi/next-1b:BF16 # Run inference directly in the terminal: llama cli -hf thelamapi/next-1b:BF16
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf thelamapi/next-1b:BF16 # Run inference directly in the terminal: llama cli -hf thelamapi/next-1b:BF16
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 thelamapi/next-1b:BF16 # Run inference directly in the terminal: ./llama-cli -hf thelamapi/next-1b:BF16
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 thelamapi/next-1b:BF16 # Run inference directly in the terminal: ./build/bin/llama-cli -hf thelamapi/next-1b:BF16
Use Docker
docker model run hf.co/thelamapi/next-1b:BF16
- LM Studio
- Jan
- vLLM
How to use thelamapi/next-1b with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "thelamapi/next-1b" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "thelamapi/next-1b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/thelamapi/next-1b:BF16
- SGLang
How to use thelamapi/next-1b 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 "thelamapi/next-1b" \ --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": "thelamapi/next-1b", "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 "thelamapi/next-1b" \ --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": "thelamapi/next-1b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Ollama
How to use thelamapi/next-1b with Ollama:
ollama run hf.co/thelamapi/next-1b:BF16
- Unsloth Studio
How to use thelamapi/next-1b 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 thelamapi/next-1b 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 thelamapi/next-1b to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for thelamapi/next-1b to start chatting
- Atomic Chat new
- Docker Model Runner
How to use thelamapi/next-1b with Docker Model Runner:
docker model run hf.co/thelamapi/next-1b:BF16
- Lemonade
How to use thelamapi/next-1b with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull thelamapi/next-1b:BF16
Run and chat with the model
lemonade run user.next-1b-BF16
List all available models
lemonade list
Update README.md
Browse files
README.md
CHANGED
|
@@ -140,97 +140,6 @@ Ideal for **developers, students, and organizations** needing **fast, reliable,
|
|
| 140 |
|
| 141 |
---
|
| 142 |
|
| 143 |
-
# Our Next 1B and Next 4B models are leading to all of the tiny models in benchmarks.
|
| 144 |
-
|
| 145 |
-
<table>
|
| 146 |
-
<thead>
|
| 147 |
-
<tr>
|
| 148 |
-
<th>Model</th>
|
| 149 |
-
<th>MMLU (5-shot) %</th>
|
| 150 |
-
<th>MMLU-Pro %</th>
|
| 151 |
-
<th>GSM8K %</th>
|
| 152 |
-
<th>MATH %</th>
|
| 153 |
-
</tr>
|
| 154 |
-
</thead>
|
| 155 |
-
<tbody>
|
| 156 |
-
<tr class="next">
|
| 157 |
-
<td data-label="Model">Next 4B preview</td>
|
| 158 |
-
<td data-label="MMLU (5-shot) %">84.6</td>
|
| 159 |
-
<td data-label="MMLU-Pro %">66.9</td>
|
| 160 |
-
<td data-label="GSM8K %">82.7</td>
|
| 161 |
-
<td data-label="MATH %"><strong>70.5</strong></td>
|
| 162 |
-
</tr>
|
| 163 |
-
<tr class="next">
|
| 164 |
-
<td data-label="Model">Next 1B <em>Version t327</em></td>
|
| 165 |
-
<td data-label="MMLU (5-shot) %"><strong>87.3</strong></td>
|
| 166 |
-
<td data-label="MMLU-Pro %"><strong>69.2</strong></td>
|
| 167 |
-
<td data-label="GSM8K %"><strong>90.5</strong></td>
|
| 168 |
-
<td data-label="MATH %">70.1</td>
|
| 169 |
-
</tr>
|
| 170 |
-
<tr>
|
| 171 |
-
<td data-label="Model">Qwen 3 0.6B</td>
|
| 172 |
-
<td data-label="MMLU (5-shot) %">52.81</td>
|
| 173 |
-
<td data-label="MMLU-Pro %">37.6</td>
|
| 174 |
-
<td data-label="GSM8K %">60.7</td>
|
| 175 |
-
<td data-label="MATH %">20.5</td>
|
| 176 |
-
</tr>
|
| 177 |
-
<tr>
|
| 178 |
-
<td data-label="Model">Llama 3.2 1B</td>
|
| 179 |
-
<td data-label="MMLU (5-shot) %">49.3</td>
|
| 180 |
-
<td data-label="MMLU-Pro %">44.4</td>
|
| 181 |
-
<td data-label="GSM8K %">11.9</td>
|
| 182 |
-
<td data-label="MATH %">30.6</td>
|
| 183 |
-
</tr>
|
| 184 |
-
</tbody>
|
| 185 |
-
</table>
|
| 186 |
-
|
| 187 |
-
---
|
| 188 |
-
|
| 189 |
-
# Also, our Next 14b model is leading to state-of-the-art models in some of the Benchmarks.
|
| 190 |
-
<table>
|
| 191 |
-
<thead>
|
| 192 |
-
<tr>
|
| 193 |
-
<th>Model</th>
|
| 194 |
-
<th>MMLU (5-shot) %</th>
|
| 195 |
-
<th>MMLU-Pro %</th>
|
| 196 |
-
<th>GSM8K %</th>
|
| 197 |
-
<th>MATH %</th>
|
| 198 |
-
</tr>
|
| 199 |
-
</thead>
|
| 200 |
-
<tbody>
|
| 201 |
-
<tr class="next">
|
| 202 |
-
<td><strong>Next 14B (Thinking)</strong></td>
|
| 203 |
-
<td><strong>94.6</strong></td>
|
| 204 |
-
<td><strong>93.2</strong></td>
|
| 205 |
-
<td><strong>98.8</strong></td>
|
| 206 |
-
<td>92.7</td>
|
| 207 |
-
</tr>
|
| 208 |
-
<tr>
|
| 209 |
-
<td>Next 12B</td>
|
| 210 |
-
<td>92.7</td>
|
| 211 |
-
<td>84.4</td>
|
| 212 |
-
<td>95.3</td>
|
| 213 |
-
<td>87.2</td>
|
| 214 |
-
</tr>
|
| 215 |
-
<tr>
|
| 216 |
-
<td>GPT-5</td>
|
| 217 |
-
<td>92.5</td>
|
| 218 |
-
<td>87.0</td>
|
| 219 |
-
<td>98.4</td>
|
| 220 |
-
<td><strong>96.0</strong></td>
|
| 221 |
-
</tr>
|
| 222 |
-
<tr>
|
| 223 |
-
<td>Claude Opus 4.1 (Thinking)</td>
|
| 224 |
-
<td>~92.0</td>
|
| 225 |
-
<td>87.8</td>
|
| 226 |
-
<td>84.7</td>
|
| 227 |
-
<td>95.4</td>
|
| 228 |
-
</tr>
|
| 229 |
-
</tbody>
|
| 230 |
-
</table>
|
| 231 |
-
|
| 232 |
-
---
|
| 233 |
-
|
| 234 |
## 🎯 Goals
|
| 235 |
|
| 236 |
1. **Lightweight Efficiency:** Run smoothly on low-resource devices.
|
|
|
|
| 140 |
|
| 141 |
---
|
| 142 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 143 |
## 🎯 Goals
|
| 144 |
|
| 145 |
1. **Lightweight Efficiency:** Run smoothly on low-resource devices.
|