Installing a local instance of an LLM - Post 1 of 3

In this post I will basically mention two LLMs that I am going to install and thereafter comment on them.

Most AI apps seem to use python to run. So once you have installed 

1. Install Ubuntu linux version 22 (Jammy Jellyfish). 

a. Go to https://ubuntu.com/download 

b. Get the iso file

c. Copy it to a flash disk using Etcher (https://etcher.io

d. Insert flash disk, reboot, hit f2 on the keyboard; enter BIOS and tell your PC to boot off the flash disk. Take it from there. 

e. Install PHP 3.10

sudo apt-get install python3.10 


2. Install either or both of GPT4ALL or privateGPT.

GPT4ALLhttps://github.com/nomic-ai/gpt4all

PrivateGPThttps://github.com/imartinez/privateGPT

For example

mkdir git

cd git

git clone https://github.com/imartinez/privateGPT

git clone https://github.com/nomic-ai/gpt4all


3. Once those are downloaded ...

cd git/privateGPT 


or

cd git/gpt4all

then

pip install 'pygpt4all==v1.0.1' --force-reinstall

sudo apt install libxcb-cursor0

python3.10 -m pip install -r requirements.txt

Note that this last step almost always fails with some error or dependency. I find that the following commands usually fix it.

Note also that the dependencies, LLM files and libraries are usually stored in ~/.cache/nomicai/ or similar.

4. Fix its nonsense

sudo apt-get install python3-dev

python3.10 -m pip install --upgrade pip

sudo apt install build-essential

python3.10 -m pip install hnswlib

python3.10 -m pip install chromadb

then

python3.10 -m pip install chroma-migrate

chroma-migrate

python3.10 -m pip install -r requirements.txt

Popular posts from this blog

Testing ChatGPT on coding - a script to make CSV to ICS

Ollama3 works - running a local LLM

What is a "token" , what is "temperature", and what is "n-shot"?