Update README.md
Browse files
README.md
CHANGED
@@ -14,11 +14,11 @@ datasets:
|
|
14 |
|
15 |
<center><img src="MobileLLaMa.png" alt="mobillama logo" width="300"/></center>
|
16 |
|
17 |
-
## Model Summary
|
18 |
-
|
19 |
MobiLlama-05B is a Small Language Model with **0.5 billion** parameters. It was trained using the Amber data sources [Amber-Dataset](https://huggingface.co/datasets/LLM360/AmberDatasets).
|
20 |
|
21 |
-
|
|
|
|
|
22 |
|
23 |
## Model Description
|
24 |
|
@@ -26,23 +26,13 @@ MobiLlama-05B is a Small Language Model with **0.5 billion** parameters. It was
|
|
26 |
- **Language(s) (NLP):** English
|
27 |
- **License:** Apache 2.0
|
28 |
- **Resources for more information:**
|
29 |
-
- [Training Code](https://github.com/
|
30 |
- [Data Preparation](https://github.com/LLM360/amber-data-prep)
|
31 |
- [Fully processed Amber pretraining data](https://huggingface.co/datasets/LLM360/AmberDatasets)
|
32 |
|
33 |
|
34 |
## How to Use
|
35 |
|
36 |
-
MobiLlama-05B has been integrated in the development version (4.37.0.dev) of `transformers`. Until the official version is released through `pip`, ensure that you are doing one of the following:
|
37 |
-
|
38 |
-
* When loading the model, ensure that `trust_remote_code=True` is passed as an argument of the `from_pretrained()` function.
|
39 |
-
|
40 |
-
* Update your local `transformers` to the development version: `pip uninstall -y transformers && pip install git+https://github.com/huggingface/transformers`. The previous command is an alternative to cloning and installing from the source.
|
41 |
-
|
42 |
-
The current `transformers` version can be verified with: `pip list | grep transformers`.
|
43 |
-
|
44 |
-
To load a specific checkpoint, simply pass a revision with a value between `"ckpt_000"` and `"ckpt_358"`. If no revision is provided, it will load `"ckpt_359"`, which is the final checkpoint.
|
45 |
-
|
46 |
```python
|
47 |
from transformers import AutoModelForCausalLM, AutoTokenizer
|
48 |
|
@@ -56,22 +46,6 @@ print(tokenizer.batch_decode(outputs[:, input_ids.shape[1]:-1])[0].strip())
|
|
56 |
|
57 |
```
|
58 |
|
59 |
-
## Evaluation
|
60 |
-
|
61 |
-
| Evaluation Benchmark | MobiLlama-0.5B | MobiLlama-0.8B | MobiLlama-1.2B |
|
62 |
-
| ----------- | ----------- | ----------- | ----------- |
|
63 |
-
| HellaSwag | 0.5252 | 0.5409 | 0.6299 |
|
64 |
-
| MMLU | 0.2645 | 0.2692 | 0.2423 |
|
65 |
-
| Arc Challenge | 0.2952 | 0.3020 | 0.3455 |
|
66 |
-
| TruthfulQA | 0.3805 | 0.3848 | 0.3557 |
|
67 |
-
| CrowsPairs | 0.6403 | 0.6482 | 0.6812 |
|
68 |
-
| PIQA | 0.7203 | 0.7317 | 0.7529 |
|
69 |
-
| Race | 0.3368 | 0.3337 | 0.3531 |
|
70 |
-
| SIQA | 0.4022 | 0.4160 | 0.4196 |
|
71 |
-
| Winogrande | 0.5753 | 0.5745 | 0.6108 |
|
72 |
-
|
73 |
-
|
74 |
-
|
75 |
## Hyperparameters
|
76 |
| Hyperparameter | Value |
|
77 |
| ----------- | ----------- |
|
@@ -84,6 +58,22 @@ print(tokenizer.batch_decode(outputs[:, input_ids.shape[1]:-1])[0].strip())
|
|
84 |
| Max Seq Length | 2048 |
|
85 |
| Vocab Size | 32000 |
|
86 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
87 |
## Intended Uses
|
88 |
|
89 |
Given the nature of the training data, the MobiLlama-05B model is best suited for prompts using the QA format, the chat format, and the code format.
|
|
|
14 |
|
15 |
<center><img src="MobileLLaMa.png" alt="mobillama logo" width="300"/></center>
|
16 |
|
|
|
|
|
17 |
MobiLlama-05B is a Small Language Model with **0.5 billion** parameters. It was trained using the Amber data sources [Amber-Dataset](https://huggingface.co/datasets/LLM360/AmberDatasets).
|
18 |
|
19 |
+
## Model Summary
|
20 |
+
|
21 |
+
"Bigger the better" has been the predominant trend in recent Large Language Models (LLMs) development. However, LLMs do not suit well for scenarios that require on-device processing, energy efficiency, low memory footprint, and response efficiency. These requisites are crucial for privacy, security, and sustainable deployment. This paper explores the ‘less is more’ paradigm by addressing the challenge of designing accurate yet efficient Small Language Models (SLMs) for resource-constrained devices. Our primary contribution is the introduction of an accurate and fully transparent open-source 0.5 billion (0.5B) parameter SLM, named MobiLlama, catering to the specific needs of resource-constrained computing with an emphasis on enhanced performance with reduced resource demands. MobiLlama is a SLM design that initiates from a larger model and applies a careful parameter sharing scheme to reduce both the pre-training and the deployment cost. Our work strives to not only bridge the gap in open-source SLMs but also ensures full transparency, where complete training data pipeline, training code, model weights, and over 300 checkpoints along with evaluation codes are available on our [Github](https://github.com/mbzuai-oryx/MobiLlama).
|
22 |
|
23 |
## Model Description
|
24 |
|
|
|
26 |
- **Language(s) (NLP):** English
|
27 |
- **License:** Apache 2.0
|
28 |
- **Resources for more information:**
|
29 |
+
- [Training Code](https://github.com/mbzuai-oryx/MobiLlama)
|
30 |
- [Data Preparation](https://github.com/LLM360/amber-data-prep)
|
31 |
- [Fully processed Amber pretraining data](https://huggingface.co/datasets/LLM360/AmberDatasets)
|
32 |
|
33 |
|
34 |
## How to Use
|
35 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
36 |
```python
|
37 |
from transformers import AutoModelForCausalLM, AutoTokenizer
|
38 |
|
|
|
46 |
|
47 |
```
|
48 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
49 |
## Hyperparameters
|
50 |
| Hyperparameter | Value |
|
51 |
| ----------- | ----------- |
|
|
|
58 |
| Max Seq Length | 2048 |
|
59 |
| Vocab Size | 32000 |
|
60 |
|
61 |
+
|
62 |
+
## Evaluation
|
63 |
+
|
64 |
+
| Evaluation Benchmark | MobiLlama-0.5B | MobiLlama-0.8B | MobiLlama-1.2B |
|
65 |
+
| ----------- | ----------- | ----------- | ----------- |
|
66 |
+
| HellaSwag | 52.52 | 54.09 | 62.99 |
|
67 |
+
| MMLU | 26.45 | 26.92 | 24.23 |
|
68 |
+
| Arc Challenge | 29.52 | 30.20 | 34.55 |
|
69 |
+
| TruthfulQA | 38.05 | 38.48 | 35.57 |
|
70 |
+
| CrowsPairs | 64.03 | 64.82 | 68.12 |
|
71 |
+
| PIQA | 72.03 | 73.17 | 75.29 |
|
72 |
+
| Race | 33.68 | 33.37 | 35.31 |
|
73 |
+
| SIQA | 40.22 | 41.60 | 41.96 |
|
74 |
+
| Winogrande | 57.53 | 57.45 | 61.08 |
|
75 |
+
|
76 |
+
|
77 |
## Intended Uses
|
78 |
|
79 |
Given the nature of the training data, the MobiLlama-05B model is best suited for prompts using the QA format, the chat format, and the code format.
|