DEV Community

Choonho Son
Choonho Son

Posted on • Updated on

Llama 2 in Apple Silicon Macbook (1/3)

This post describe how to use Llama 2 in Apple Silicon Macbook.

Download model

To download Llama 2 model from Meta,

https://ai.meta.com/llama/

Image description

After fill up the form, you will get email from Meta.

Image description

The title of email is "Get Started with Llama 2"

Image description

Clone Git repository

To download Llama 2 model, you need to download git repository first.

git clone https://github.com/facebookresearch/llama.git
Enter fullscreen mode Exit fullscreen mode

In this repository, there is download.sh file.

cd llama
/bin/bash ./download.sh
Enter fullscreen mode Exit fullscreen mode

Put URL link from email. Then model what you want to download.
In my case, I downloaded 7B-chat

Image description

After download finished, there is a folder "llama-2-7b-chat".

Image description

Image description

The file format consolidated.00.pth is PyTorch model file.

This is end of downloading Llama 2 model.

Next Step. Llama 2 in Apple Silicon Macbook (2/3).
https://dev.to/choonho/llama-2-in-apple-silicon-macbook-23-2j51

Reference

https://medium.com/@karankakwani/build-and-run-llama2-llm-locally-a3b393c1570e
https://github.com/rustformers/llm/blob/main/crates/ggml/README.md

Series

Llama 2 in Apple Silicon Bacbook (1/3)
https://dev.to/choonho/llama-2-in-apple-silicon-macbook-13-54h

Llama 2 in Apple Silicon Bacbook (2/3)
https://dev.to/choonho/llama-2-in-apple-silicon-macbook-23-2j51

Llama 2 in Apple Silicon Bacbook (3/3)
https://dev.to/choonho/llama-2-in-apple-silicon-macbook-33-3hb7

Top comments (0)