neuralcrew commited on
Commit
05a4367
·
verified ·
1 Parent(s): 05893d1

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +171 -58
README.md CHANGED
@@ -10,7 +10,6 @@ tags:
10
  - llama.cpp
11
  - ollama
12
  - local-llm
13
- - Neutrino
14
  pipeline_tag: text-generation
15
  datasets:
16
  - HuggingFaceFW/finepdfs
@@ -20,117 +19,231 @@ datasets:
20
  - codeparrot/github-code
21
  - HuggingFaceFW/finewiki
22
  - karpathy/fineweb-edu-100b-shuffle
23
- metrics:
24
- - accuracy
25
- - bertscore
26
- - bleu
27
- - bleurt
28
- - brier_score
29
- - cer
30
- library_name: transformers
31
  base_model:
32
- - neuralcrew/neutrino-instruct
33
  ---
34
 
35
- # 🧠 Neutrino-Instruct (7B)
36
- ![Alt text](https://ollama.com/assets/fardeen0424/neutrino/742305f0-8c9e-4ae8-acff-a7c2b133d3d8)
37
- Neutrino-Instruct is a **7B parameter instruction-tuned LLM** developed by **Fardeen NB**.
38
- It is designed for **conversational AI**, **multi-step reasoning**, and **instruction-following** tasks, fine-tuned to maintain coherent and contextual dialogue across multiple turns.
39
 
40
- ## ✨ Model Details
41
 
42
- - **Model Name:** Neutrino-Instruct
43
- - **Developer:** Fardeen NB
44
- - **License:** Apache-2.0
45
- - **Language(s):** English
46
- - **Format:** GGUF (optimized for `llama.cpp` and `Ollama`)
47
- - **Base Model:** Neutrino
48
- - **Version:** 2.0
49
- - **Task:** Text Generation (chat, Q&A, instruction-following)
50
 
51
- ## 🚀 Quick Start
52
 
53
- ### Run with [llama.cpp](https://github.com/ggerganov/llama.cpp)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
54
 
55
  ```bash
56
- # Clone and build llama.cpp
57
  git clone https://github.com/ggerganov/llama.cpp
58
  cd llama.cpp && make
59
 
60
- # Run a single prompt
61
  ./main -m ./neutrino-instruct.gguf -p "Hello, who are you?"
62
 
63
- # Run in interactive mode
64
  ./main -m ./neutrino-instruct.gguf -i -p "Let's chat."
65
 
66
  # Control output length
67
  ./main -m ./neutrino-instruct.gguf -n 256 -p "Write a poem about stars."
68
 
69
- # Change creativity (temperature)
70
  ./main -m ./neutrino-instruct.gguf --temp 0.7 -p "Explain quantum computing simply."
71
 
72
- # Enable GPU acceleration (if compiled with CUDA/Metal)
73
  ./main -m ./neutrino-instruct.gguf --gpu-layers 50 -p "Summarize this article."
74
  ```
75
 
76
- ### Run with [Ollama](https://ollama.com/fardeen0424/neutrino)
77
 
78
  ```bash
79
  ollama run fardeen0424/neutrino
80
  ```
81
 
82
- ### Run in Python (`llama-cpp-python`)
83
 
84
  ```python
85
  from llama_cpp import Llama
86
 
87
- # Load the Neutrino-Instruct model
88
  llm = Llama(model_path="./neutrino-instruct.gguf")
89
 
90
- # Run inference
91
  response = llm("Who are you?")
92
  print(response["choices"][0]["text"])
93
 
94
- # Stream output tokens
95
  for token in llm("Tell me a story about Neutrino:", stream=True):
96
  print(token["choices"][0]["text"], end="", flush=True)
97
  ```
98
 
99
- ## 📊 System Requirements
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
100
 
101
- * **CPU-only:** 32–64GB RAM recommended (runs on modern laptops, slower inference).
102
- * **GPU acceleration:**
 
 
 
 
 
 
 
 
 
 
 
103
 
104
- * 4GB VRAM → 4-bit quantized (Q4) models
105
- * 8GB VRAM → 5-bit/8-bit models
106
- * 12GB+ VRAM → FP16 full precision
107
 
 
108
 
109
- ## 🧩 Potential Use Cases
110
 
111
- * Conversational AI assistants
112
- * Research prototypes
113
- * Instruction-following agents
114
- * Chatbots with identity-awareness
115
 
116
- ⚠️ **Out of Scope:** Use in critical decision-making, legal, or medical contexts.
117
 
118
- ## 🛠️ Development Notes
119
 
120
- * Model uploaded in **GGUF format** for portability & performance.
121
- * Compatible with **llama.cpp**, **Ollama**, and **llama-cpp-python**.
122
- * Supports quantization levels (Q4, Q5, Q8) for deployment on resource-constrained devices.
123
 
124
- ## 📖 Citation
125
 
126
- If you use Neutrino in your research or projects, please cite:
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
127
 
128
  ```bibtex
129
  @misc{fardeennb2025neutrino,
130
- title = {Neutrino-Instruct: A 7B Instruction-Tuned Conversational Model},
131
- author = {Fardeen NB},
132
- year = {2025},
133
  howpublished = {Hugging Face},
134
- url = {https://huggingface.co/neuralcrew/neutrino-instruct}
135
  }
136
- ```
 
 
 
 
 
10
  - llama.cpp
11
  - ollama
12
  - local-llm
 
13
  pipeline_tag: text-generation
14
  datasets:
15
  - HuggingFaceFW/finepdfs
 
19
  - codeparrot/github-code
20
  - HuggingFaceFW/finewiki
21
  - karpathy/fineweb-edu-100b-shuffle
22
+ library_name: gguf
 
 
 
 
 
 
 
23
  base_model:
24
+ - neuralcrew/neutrino
25
  ---
26
 
27
+ <div align="center" style="text-align: center;">
 
 
 
28
 
29
+ # Neutrino-Instruct
30
 
31
+ ![Neutrino](https://ollama.com/assets/fardeen0424/neutrino/742305f0-8c9e-4ae8-acff-a7c2b133d3d8)
 
 
 
 
 
 
 
32
 
33
+ **A 7B-parameter instruction-tuned language model for conversational AI**
34
 
35
+ <p align="center">
36
+ <a href="#model-card">Model card</a> · <a href="#quickstart">Quickstart</a> · <a href="#architecture">Architecture</a> · <a href="#limitations--risks">Limitations</a> · <a href="#license">License</a>
37
+ </p>
38
+
39
+ </div>
40
+
41
+ ---
42
+
43
+ ## Model Card
44
+
45
+ | Field | Value |
46
+ |---|---|
47
+ | **Developer** | Fardeen NB |
48
+ | **Model type** | Autoregressive transformer, decoder-only |
49
+ | **Parameters** | 7B |
50
+ | **Base model** | [neuralcrew/neutrino](https://huggingface.co/neuralcrew/neutrino) |
51
+ | **Fine-tuning** | Instruction tuning for multi-turn dialogue |
52
+ | **Language(s)** | English |
53
+ | **Format** | GGUF (quantized for `llama.cpp`, `Ollama`, `llama-cpp-python`) |
54
+ | **License** | Apache 2.0 |
55
+ | **Version** | 2.0 |
56
+
57
+ ---
58
+
59
+ ## Overview
60
+
61
+ Neutrino-Instruct is a 7B-parameter language model fine-tuned from the Neutrino base model for conversational and instruction-following tasks. It is distributed in GGUF format for efficient local inference on consumer hardware via `llama.cpp`, `Ollama`, and `llama-cpp-python`.
62
+
63
+ The model is designed to hold coherent, contextual dialogue across multiple turns and to follow natural-language instructions reliably at chat scale, while remaining light enough to run on a single consumer GPU or CPU-only machine.
64
+
65
+ ---
66
+
67
+ ## Intended Use
68
+
69
+ **Primary use cases**
70
+ - Conversational assistants and chatbots
71
+ - Instruction-following agents (task completion, Q&A, summarization)
72
+ - Local/offline research prototypes where data cannot leave the device
73
+ - Educational and hobbyist LLM experimentation
74
+
75
+ **Out of scope**
76
+ - Medical, legal, or financial advice, or any use where model error could cause real-world harm
77
+ - Autonomous decision-making without human review
78
+ - Generation of content intended to deceive, impersonate, or manipulate
79
+ - High-stakes classification (e.g., hiring, credit, law enforcement)
80
+
81
+ Neutrino-Instruct is a general-purpose research and hobbyist model. It has **not** been evaluated for production or safety-critical deployment, and Fardeen NB makes no warranty as to its factual accuracy, safety, or fitness for any particular purpose.
82
+
83
+ ---
84
+
85
+ ## Quickstart
86
+
87
+ ### llama.cpp
88
 
89
  ```bash
 
90
  git clone https://github.com/ggerganov/llama.cpp
91
  cd llama.cpp && make
92
 
93
+ # Single prompt
94
  ./main -m ./neutrino-instruct.gguf -p "Hello, who are you?"
95
 
96
+ # Interactive chat
97
  ./main -m ./neutrino-instruct.gguf -i -p "Let's chat."
98
 
99
  # Control output length
100
  ./main -m ./neutrino-instruct.gguf -n 256 -p "Write a poem about stars."
101
 
102
+ # Adjust temperature
103
  ./main -m ./neutrino-instruct.gguf --temp 0.7 -p "Explain quantum computing simply."
104
 
105
+ # GPU offload (if built with CUDA/Metal)
106
  ./main -m ./neutrino-instruct.gguf --gpu-layers 50 -p "Summarize this article."
107
  ```
108
 
109
+ ### Ollama
110
 
111
  ```bash
112
  ollama run fardeen0424/neutrino
113
  ```
114
 
115
+ ### Python (llama-cpp-python)
116
 
117
  ```python
118
  from llama_cpp import Llama
119
 
 
120
  llm = Llama(model_path="./neutrino-instruct.gguf")
121
 
 
122
  response = llm("Who are you?")
123
  print(response["choices"][0]["text"])
124
 
125
+ # Streaming
126
  for token in llm("Tell me a story about Neutrino:", stream=True):
127
  print(token["choices"][0]["text"], end="", flush=True)
128
  ```
129
 
130
+ ---
131
+
132
+ ## Training Data
133
+
134
+ Neutrino-Instruct's base model was pretrained on a mixture of web, encyclopedic, code, and long-document text, and instruction-tuned on conversational data. Component sources include:
135
+
136
+ | Dataset | Type | Role |
137
+ |---|---|---|
138
+ | finepdfs | Long-form documents | Pretraining |
139
+ | finewiki | Encyclopedic text | Pretraining |
140
+ | fineweb-edu-100b-shuffle | Educational web text | Pretraining |
141
+ | wikipedia | Encyclopedic text | Pretraining |
142
+ | github-code | Source code | Pretraining |
143
+ | TinyStories | Short narrative text | Fine-tuning / eval |
144
+ | awesome-chatgpt-prompts | Instruction/persona prompts | Instruction tuning |
145
+
146
+ *Full dataset links are available in the metadata panel on the right side of this page.*
147
+
148
+ ### Training procedure
149
+
150
+ | Field | Value |
151
+ |---|---|
152
+ | **Context length** | 32,768 tokens |
153
+ | **Precision** | bfloat16 |
154
 
155
+ ---
156
+
157
+ ## Architecture
158
+
159
+ Neutrino-Instruct is built on a standard decoder-only Transformer stack. The core computations are as follows.
160
+
161
+ **Scaled dot-product self-attention**, applied per head:
162
+
163
+ $$\text{Attention}(Q, K, V) = \text{softmax}\!\left(\frac{QK^\top}{\sqrt{d_k}}\right)V$$
164
+
165
+ with multi-head attention combining $h$ heads via a learned output projection:
166
+
167
+ $$\text{MultiHead}(Q,K,V) = \text{Concat}(\text{head}_1, \dots, \text{head}_h)\,W^O, \qquad \text{head}_i = \text{Attention}(QW_i^Q, KW_i^K, VW_i^V)$$
168
 
169
+ Neutrino-Instruct uses **grouped-query attention (GQA)**: the 32 query heads are partitioned into $g=8$ groups, each group sharing a single key/value projection ($KW^K_g, VW^V_g$) instead of every query head having its own — trading a small amount of expressivity for a much smaller KV cache at inference time.
 
 
170
 
171
+ **Position encoding** — rotary position embeddings (RoPE), applied to query/key vectors by rotating consecutive coordinate pairs as a function of token position $m$ and frequency $\theta_i$:
172
 
173
+ $$f(x_m, m) = \big[x_m^{(1)}\cos m\theta_i - x_m^{(2)}\sin m\theta_i,\ \ x_m^{(1)}\sin m\theta_i + x_m^{(2)}\cos m\theta_i\big]$$
174
 
175
+ **Feed-forward block** (SwiGLU-style gating):
 
 
 
176
 
177
+ $$\text{FFN}(x) = \big(\text{Swish}(xW_1)\otimes xW_3\big)W_2$$
178
 
179
+ **Pre-normalization** (RMSNorm) around each sub-block:
180
 
181
+ $$\text{RMSNorm}(x) = \frac{x}{\sqrt{\frac{1}{n}\sum_{i=1}^n x_i^2 + \epsilon}} \odot g$$
 
 
182
 
183
+ **Training objective** — standard next-token cross-entropy over the vocabulary:
184
 
185
+ $$\mathcal{L} = -\sum_{t=1}^{T} \log P_\theta(x_t \mid x_{<t})$$
186
+
187
+ | Hyperparameter | Value |
188
+ |---|---|
189
+ | Layers | 32 |
190
+ | Hidden size | 4096 |
191
+ | Intermediate (FFN) size | 14336 |
192
+ | Attention heads | 32 |
193
+ | KV heads (GQA) | 8 |
194
+ | Vocabulary size | 32,768 |
195
+ | Max context length | 32,768 |
196
+ | Activation | SiLU (SwiGLU gating) |
197
+ | Normalization | RMSNorm (pre-norm, $\epsilon=1\text{e-}5$) |
198
+ | Position encoding | RoPE ($\theta=1{,}000{,}000$) |
199
+ | Sliding window | None (full attention) |
200
+ | Precision | bfloat16 |
201
+ | Tied embeddings | No |
202
+
203
+ ---
204
+
205
+ ## Quantization & System Requirements
206
+
207
+ | Setup | VRAM / RAM | Recommended quantization |
208
+ |---|---|---|
209
+ | CPU-only | 32–64 GB RAM | Q4_K_M / Q5_K_M |
210
+ | GPU (entry) | 4 GB VRAM | Q4 |
211
+ | GPU (mid) | 8 GB VRAM | Q5 / Q8 |
212
+ | GPU (high) | 12 GB+ VRAM | FP16 (full precision) |
213
+
214
+ ---
215
+
216
+ ## Limitations & Risks
217
+
218
+ - **Hallucination**: Like all LLMs, Neutrino-Instruct can generate plausible-sounding but incorrect or fabricated information. Outputs should be verified before use in any consequential context.
219
+ - **Bias**: Training data drawn from web and code sources may encode social, cultural, or representational biases present in that data. The model has not undergone a formal bias audit.
220
+ - **Safety tuning**: No dedicated safety alignment (red-teaming, RLHF/DPO refusal training, etc.) has been performed beyond the base instruction tuning. The model may comply with harmful, unsafe, or policy-violating requests.
221
+ - **Language coverage**: English only; behavior on other languages is unevaluated and likely degraded.
222
+ - **Context length**: Supports up to 32,768 tokens; quality may degrade toward the upper end of that window, as is typical for RoPE-based models — this has not been separately verified for Neutrino-Instruct.
223
+ - **No factual grounding**: The model has no live access to external tools, retrieval, or the internet; all knowledge is frozen at training time.
224
+
225
+ This model has not been evaluated by a third party or independent safety team. Users deploying it in any user-facing product are responsible for their own safety evaluation, content filtering, and monitoring.
226
+
227
+ ---
228
+
229
+ ## License
230
+
231
+ Released under the **Apache License 2.0**. See [LICENSE](https://www.apache.org/licenses/LICENSE-2.0) for full terms.
232
+
233
+ ---
234
+
235
+ ## Citation
236
 
237
  ```bibtex
238
  @misc{fardeennb2025neutrino,
239
+ title = {Neutrino-Instruct: A 7B Instruction-Tuned Conversational Model},
240
+ author = {Fardeen NB},
241
+ year = {2025},
242
  howpublished = {Hugging Face},
243
+ url = {https://huggingface.co/neuralcrew/neutrino-instruct}
244
  }
245
+ ```
246
+
247
+ ## Acknowledgements
248
+
249
+ Built on top of the Neutrino base model. Thanks to the maintainers of the open datasets listed above, and to the `llama.cpp`, `Ollama`, and `llama-cpp-python` projects for inference tooling.