Create README.md
Browse files
README.md
ADDED
@@ -0,0 +1,66 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
tags:
|
3 |
+
- vllm
|
4 |
+
- sparsity
|
5 |
+
- quantization
|
6 |
+
- int4
|
7 |
+
pipeline_tag: text-generation
|
8 |
+
license: llama3.1
|
9 |
+
base_model: neuralmagic/Sparse-Llama-3.1-8B-evolcodealpaca-2of4
|
10 |
+
datasets:
|
11 |
+
- theblackcat102/evol-codealpaca-v1
|
12 |
+
language:
|
13 |
+
- en
|
14 |
+
---
|
15 |
+
|
16 |
+
# Sparse-Llama-3.1-8B-evolcodealpaca-2of4
|
17 |
+
|
18 |
+
## Model Overview
|
19 |
+
- **Model Architecture:** Llama-3.1-8B
|
20 |
+
- **Input:** Text
|
21 |
+
- **Output:** Text
|
22 |
+
- **Model Optimizations:**
|
23 |
+
- **Sparsity:** 2:4
|
24 |
+
- **Release Date:** 11/21/2024
|
25 |
+
- **Version:** 1.0
|
26 |
+
- **License(s):** [llama3.1](https://huggingface.co/meta-llama/Meta-Llama-3.1-8B/blob/main/LICENSE)
|
27 |
+
- **Model Developers:** Neural Magic
|
28 |
+
|
29 |
+
This is a code completion AI model obtained by fine-tuning the 2:4 sparse [Sparse-Llama-3.1-8B-2of4](https://huggingface.co/neuralmagic/Sparse-Llama-3.1-8B-2of4) on the [evol-codealpaca-v1](https://huggingface.co/datasets/theblackcat102/evol-codealpaca-v1) dataset, followed by quantization
|
30 |
+
On the [HumanEval](https://arxiv.org/abs/2107.03374) benchmark, it achieves a pass@1 of 49.1, compared to 48.5 for the fine-tuned dense model [Llama-3.1-8B-evolcodealpaca](https://huggingface.co/neuralmagic/Llama-3.1-8B-evolcodealpaca) — demonstrating over **100% accuracy recovery**.
|
31 |
+
|
32 |
+
|
33 |
+
### Model Optimizations
|
34 |
+
|
35 |
+
This inherits the optimizations from its parent, [Sparse-Llama-3.1-8B-2of4](https://huggingface.co/neuralmagic/Sparse-Llama-3.1-8B-2of4).
|
36 |
+
Namely, all linear operators within transformer blocks were pruned to the 2:4 sparsity pattern: in each group of four weights, two are retained while two are pruned.
|
37 |
+
|
38 |
+
|
39 |
+
## Deployment with vLLM
|
40 |
+
|
41 |
+
This model can be deployed efficiently using the [vLLM](https://docs.vllm.ai/en/latest/) backend. vLLM aslo supports OpenAI-compatible serving. See the [documentation](https://docs.vllm.ai/en/latest/) for more details.
|
42 |
+
|
43 |
+
|
44 |
+
## Evaluation
|
45 |
+
|
46 |
+
This model was evaluated on Neural Magic's fork of [EvalPlus](https://github.com/neuralmagic/evalplus).
|
47 |
+
|
48 |
+
### Accuracy
|
49 |
+
#### Human Benchmark
|
50 |
+
<table>
|
51 |
+
<tr>
|
52 |
+
<td><strong>Metric</strong></td>
|
53 |
+
<td style="text-align: center"><strong>Llama-3.1-8B-evolcodealpaca</strong></td>
|
54 |
+
<td style="text-align: center"><strong>Sparse-Llama-3.1-8B-evolcodealpaca-2of4</strong></td>
|
55 |
+
</tr>
|
56 |
+
<tr>
|
57 |
+
<td>HumanEval pass@1</td>
|
58 |
+
<td style="text-align: center">48.5</td>
|
59 |
+
<td style="text-align: center">49.1</td>
|
60 |
+
</tr>
|
61 |
+
<tr>
|
62 |
+
<td>HumanEval+ pass@1</td>
|
63 |
+
<td style="text-align: center">44.2</td>
|
64 |
+
<td style="text-align: center">46.3</td>
|
65 |
+
</tr>
|
66 |
+
</table>
|