Skip to content

hku/portable-llama2

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Portable LLama2

en | 中文

This project loads the LLama2 model into the browser using wasm technology, achieving efficient inference computing on the web. demo online

screenshot:

screenshot

The default model is a mini version of llama2 with 15M parameters trained over 300M Chinese dialogs.

Model Training

Adapted from Karpathy's repository.

(will be opennd soon after cleaning the codes)

WebAssembly Compilation

(will be opennd soon after cleaning the codes)

Installation

  1. install node

  2. install node packages npm install

  3. run the web server npm run start

  4. open the web link: http://localhost:3000/

Resources

Models | Git | Gitee

Acknowledgement

  • Special thanks to Karpathy for open-sourcing the llama2 code in C lang. The model training and inference codes are mainly adapted from this repository.

  • Special Thanks to enscripten, mui, and chatGPT

Others

In lots of specific scenarios, portable models have advantages in terms of computational power savings, response acceleration, and data privacy. If you are interested in portable technology of LLM too, feel free to contact me ~

twitter

wx:

qrcode

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published