Installation Guide - Starlii10/vivia GitHub Wiki
Installation Guide
Want to run your own Vivia? This guide will show you how to do it.
Preparing a Discord Application
Discord applications define a bot's account: its name, avatar, banner, About Me, etc. They also provide a bot token, which will be used by Vivia to connect to the bot account.
- Go to the Discord Developer Portal. Log in with your Discord account if not already done.
- Click "New Application".
- Give your application a name and accept the ToS.
- Go to the "Bot" section and create a bot.
- (Optional) Customize your bot with an About Me, icon, and banner.
- Click on "Reset Token" and confirm. Copy this into Notepad for now.
- Enable all privileged gateway intents. You don't usually need all of them by default, but some extensions may require them.
Pulling Vivia
You'll want to pull this repository next.
- Go to a directory where you want to place Vivia's files. Note that the repository will go into a "vivia" folder in this directory.
- Open a terminal here and run
git clone https://github.com/Starlii10/vivia
.
Setting Up Vivia
Don't worry, the setup is fairly easy.
- Go to the Vivia directory.
- Create a file named "token.env" in this directory.
- Paste your bot token into token.env, like this:
token="YOUR_TOKEN_HERE"
- Save and close token.env.
- Open a new terminal in the Vivia directory.
- Run
pip install -r requirements.txt
. (This may not work, in which case trypython -m pip install -r requirements.txt
.)
Running Vivia
Here comes the fun part: turning your Vivia on!
- Open a new terminal in the Vivia directory.
- Run
python bot.py
. (This may not work, in which case trypython3 bot.py
.)
If everything goes well, Vivia will start up. Once you see a "Vivia is all ready!" message, you're good to go!
Inviting Vivia to a Discord Server
Vivia currently isn't in any server and can't do much. Let's fix that!
- Go to the Discord Developer Portal. Open the application you just made.
- Go to the "Installation" section. Turn on "Guild Install", if not already done.
- Under "Default Install Settings", turn on the
applications.commands
andbot
scopes. - Copy your bot's install link and paste it into your browser.
- Select the server you want to add Vivia to.
- Click "Authorize".
Vivia will be added to the server and you'll be able to use her!
(Optional) AI Functionality
Giving Vivia AI will allow her to talk when you ping her!
- Install llama-cpp-python. Pay close attention to the Installation Configuration section! Depending on the hardware you're running Vivia on, you may want to change settings; for example, those with NVIDIA GPUs may benefit from installing with CUDA support.
- (Optional) Install pytesseract for OCR (image reading) support. This requires Google Tesseract OCR to also be installed on your computer.
- Find a LLaMa-compatible model and download it. Many are available on Hugging Face.
- Paste the model's .gguf file into
(Vivia directory)/extras/models
. Rename it to "llama-model.gguf". - Run Vivia and ensure AI functionality is working by pinging her.