# Running generative models locally

All the big models run on external servers and are usually only available through a (paid) account. There are some alternatives available that you can run locally on your own machine. Installing these usually involves complex installation procedures, but there's a trend for 'one-click-installers' that get you set up relatively painlessly. Below you can find some simple installers for various generative AI's.

<p class="callout danger"><span style="color: rgb(0, 0, 0);">**Note 1 All of these models take up significant amount of space on your computer.** </span>The programs can take up to 3Gb, and the models are even larger. Make sure you have around 30Gb free when you get these models running!</p>

<p class="callout danger"><span style="color: rgb(0, 0, 0);">**Note 2 Most of these models need (recent and beefy) Nvidia graphics cards to run, or an Apple M processor.**</span></p>

<p class="callout success">If you don't have a system that can run these models and you also don't want to use the online services, or need some help with installation, **please [contact us through the HKU en AI page](https://studentportal.hku.nl/over-hku/hku-en-ai/)**. We have some models set up here that you can experiment with. Open for both students and employees (of HKU.)</p>

### <span style="color: rgb(0, 0, 0);">Image generation</span> on your own computer

These models are based on Stable Diffusion. You will not get the latest version, but you can re-train the model, or download variants from the internet. Automatic11111 also allows you to combine models.

Stable Diffusion WebUI by Automatic11111: [https://github.com/AUTOMATIC1111/stable-diffusion-webui](https://github.com/AUTOMATIC1111/stable-diffusion-webui) (Win, Linux, Mac)

Easy Diffusion [https://github.com/easydiffusion/easydiffusion](https://github.com/easydiffusion/easydiffusion) (Win, Linux, Mac)

Both programs above can be downloaded from the Github page directly, resulting in a folder containing a .bat file. Run this and it will start downloading and installing all necessary files. Once it's done, run the .bat again and the program will start in your browser.

DiffusionBee [https://diffusionbee.com/](https://diffusionbee.com/) for Mac. Also runs on older Intel macs, but those will take a very long time to generate images.

### <span style="color: rgb(0, 0, 0);">Text generation</span> ('ChatGPT') on your own computer  


If you want more control over the installation, pick between various models and give the model your own instructions, check the Ollama bookstack [description page here](https://bookstack.hku.nl/books/artificial-intelligence/page/ollama-for-local-llms "Running Large Language Models locally").

If you want a no-fuss installation with a web-style interface, you can try something like oobabooga: [https://github.com/oobabooga/text-generation-webui](https://github.com/oobabooga/text-generation-webui) (Win, Linux, Mac) or Jan.ai: [https://www.jan.ai/](https://www.jan.ai/).