File size: 4,167 Bytes
a97c07b
 
 
 
 
 
 
 
 
 
 
 
 
a7d38cc
 
a97c07b
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
24bb2d1
 
a97c07b
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
---
license: apache-2.0
---
# Lite-Oute-1-65M-Instruct

Lite-Oute-1-65M-Instruct is an experimental ultra-compact model in the Lite series, based on the LLaMA architecture and comprising approximately 65 million parameters. <br>
The primary goal of this model was to explore the lower limits of model size while still maintaining basic language understanding capabilities. <br>
Due to its extremely small size, this model demonstrates basic text generation abilities but may struggle with instructions or maintaining topic coherence. <br>
Users should be aware of its significant limitations compared to larger models and expect inconsistent or potentially inaccurate responses.

## Available versions:
<a href="https://huggingface.co/OuteAI/Lite-Oute-1-65M-Instruct">Lite-Oute-1-65M-Instruct</a> <br>
<a href="https://huggingface.co/OuteAI/Lite-Oute-1-65M-Instruct-GGUF">Lite-Oute-1-65M-Instruct-GGUF</a> <br>
<a href="https://huggingface.co/OuteAI/Lite-Oute-1-65M">Lite-Oute-1-65M</a> <br>
<a href="https://huggingface.co/OuteAI/Lite-Oute-1-65M-GGUF">Lite-Oute-1-65M-GGUF</a> <br>

## Chat format
> [!IMPORTANT]
> This model uses **ChatML** template. Ensure you use the correct template:

```
<|im_start|>system
[System message]<|im_end|>
<|im_start|>user
[Your question or message]<|im_end|>
<|im_start|>assistant
[The model's response]<|im_end|>
```

<table style="text-align: left;">
  <tr>
    <th>Benchmark</th>
    <th>5-shot</th>
    <th>0-shot</th>
  </tr>
  <tr>
    <td>ARC Challenge</td>
    <td>22.61</td>
    <td>23.63</td>
  </tr>
  <tr>
    <td>ARC Easy</td>
    <td>37.16</td>
    <td>40.49</td>
  </tr>
  <tr>
    <td>CommonsenseQA</td>
    <td>19.41</td>
    <td>20.64</td>
  </tr>
  <tr>
    <td>HellaSWAG</td>
    <td>28.74</td>
    <td>28.41</td>
  </tr>
  <tr>
    <td>MMLU</td>
    <td>25.20</td>
    <td>23.45</td>
  </tr>
  <tr>
    <td>OpenBookQA</td>
    <td>27.40</td>
    <td>28.60</td>
  </tr>
  <tr>
    <td>PIQA</td>
    <td>60.88</td>
    <td>60.77</td>
  </tr>
  <tr>
    <td>Winogrande</td>
    <td>50.59</td>
    <td>50.04</td>
  </tr>
</table>

## Usage with HuggingFace transformers 
The model can be used with HuggingFace's `transformers` library:
```python
import torch
from transformers import AutoModelForCausalLM, AutoTokenizer
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
model = AutoModelForCausalLM.from_pretrained("OuteAI/Lite-Oute-1-65M-Instruct").to(device)
tokenizer = AutoTokenizer.from_pretrained("OuteAI/Lite-Oute-1-65M-Instruct")
def generate_response(message: str, temperature: float = 0.4, repetition_penalty: float = 1.12) -> str:
    # Apply the chat template and convert to PyTorch tensors
    messages = [
        {"role": "system", "content": "You are a helpful assistant."},
        {"role": "user", "content": message}
    ]
    input_ids = tokenizer.apply_chat_template(
        messages, add_generation_prompt=True, return_tensors="pt"
    ).to(device)
    # Generate the response
    output = model.generate(
        input_ids,
        max_length=512,
        temperature=temperature,
        repetition_penalty=repetition_penalty,
        do_sample=True
    ) 
    # Decode the generated output
    generated_text = tokenizer.decode(output[0], skip_special_tokens=True)
    return generated_text
message = "I'd like to learn about language models. Can you break down the concept for me?"
response = generate_response(message)
print(response)
```

## Risk Disclaimer

By using this model, you acknowledge that you understand and assume the risks associated with its use. You are solely responsible for ensuring compliance with all applicable laws and regulations. We disclaim any liability for problems arising from the use of this open-source model, including but not limited to direct, indirect, incidental, consequential, or punitive damages. We make no warranties, express or implied, regarding the model's performance, accuracy, or fitness for a particular purpose. Your use of this model is at your own risk, and you agree to hold harmless and indemnify us, our affiliates, and our contributors from any claims, damages, or expenses arising from your use of the model.