daven3 commited on
Commit
7380afd
·
verified ·
1 Parent(s): 3deb6e1

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +66 -3
README.md CHANGED
@@ -1,3 +1,66 @@
1
- ---
2
- license: apache-2.0
3
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ base_model: PLM-Team/PLM-1.8B-Base
3
+ language:
4
+ - en
5
+ library_name: transformers
6
+ license: mit
7
+ quantized_by: PLM-Team
8
+ ---
9
+ <center>
10
+ <img src="https://www.cdeng.net/plm/plm_logo.png" alt="k2-logo" width="200"/>
11
+ <h2>🖲️ PLM: Efficient Peripheral Language Models Hardware-Co-Designed for Ubiquitous Computing</h2>
12
+ <a href='https://sites.google.com/view/project-plm'>👉 Project PLM Website</a>
13
+ </center>
14
+
15
+ <center>
16
+
17
+ ||||||||
18
+ |:-:|:-:|:-:|:-:|:-:|:-:|:-:|
19
+ |<a href='https://arxiv.org/abs/2503.12167'><img src='https://img.shields.io/badge/Paper-ArXiv-C71585'></a>|<a href='https://huggingface.co/PLM-Team/PLM-1.8B-Base'><img src='https://img.shields.io/badge/%F0%9F%A4%97%20Hugging Face-Base-red'></a>|<a href='https://huggingface.co/PLM-Team/PLM-1.8B-Instruct'><img src='https://img.shields.io/badge/%F0%9F%A4%97%20Hugging Face-Instruct-red'></a>|<a href='https://huggingface.co/PLM-Team/PLM-1.8B-Instruct-gguf'><img src='https://img.shields.io/badge/%F0%9F%A4%97%20Hugging Face-gguf-red'></a>|<a href='https://huggingface.co/datasets/plm-team/scots'><img src='https://img.shields.io/badge/Data-plm%20mix-4169E1'></img></a>|<a><img src="https://img.shields.io/github/stars/plm-team/PLM"></a>|
20
+
21
+ </center>
22
+
23
+ ---
24
+
25
+ The PLM (Peripheral Language Model) series introduces a novel model architecture to peripheral computing by delivering powerful language capabilities within the constraints of resource-limited devices. Through modeling and system co-design strategy, PLM optimizes model performance and fits edge system requirements, PLM employs **Multi-head Latent Attention** and **squared ReLU** activation to achieve sparsity, significantly reducing memory footprint and computational demands. Coupled with a meticulously crafted training regimen using curated datasets and a Warmup-Stable-Decay-Constant learning rate scheduler, PLM demonstrates superior performance compared to existing small language models, all while maintaining the lowest activated parameters, making it ideally suited for deployment on diverse peripheral platforms like mobile phones and Raspberry Pis.
26
+
27
+
28
+ **Here we present the static quants for identified model of PLM-1.8B-Instruct**
29
+
30
+ ## Usage (llama.cpp)
31
+
32
+ The original contribution to the llama.cpp framwork is [Si1w/llama.cpp](https://github.com/Si1w/llama.cpp). Here is the usage:
33
+
34
+ ```bash
35
+ git clone https://github.com/Si1w/llama.cpp.git
36
+ cd llama.cpp
37
+ pip install -r requirements.txt
38
+ ```
39
+
40
+ Then, we can build with CPU of GPU (e.g. Orin). The build is based on `cmake`.
41
+
42
+ - For CPU
43
+
44
+ ```bash
45
+ cmake -B build
46
+ cmake --build build --config Release
47
+ ```
48
+
49
+ - For GPU
50
+
51
+ ```bash
52
+ cmake -B build -DGGML_CUDA=ON
53
+ cmake --build build --config Release
54
+ ```
55
+
56
+ Don't forget to download the GGUF files of the PLM. We use the quantization methods in `llama.cpp` to generate the quantized PLM.
57
+
58
+ ```bash
59
+ huggingface-cli download --resume-download PLM-Team/PLM-1.8B-Instruct-gguf --local-dir PLM-Team/PLM-1.8B-Instruct-gguf
60
+ ```
61
+
62
+ After build the `llama.cpp`, we can use `llama-cli` script to launch the PLM.
63
+
64
+ ```bash
65
+ ./build/bin/llama-cli -m ./PLM-Team/PLM-1.8B-Instruct-gguf/PLM-1.8B-Instruct-Q8_0.gguf -cnv -p "hello!" -n 128
66
+ ```