note: last working ooba commit: 19f7868
A Discord Bot for chatting with LLaMA, Vicuna, Alpaca, or any other LLaMA-based model. It's not as good as ChatGPT but LLaMA and its derivatives are pretty impressive on their own. Tag the bot with it's @username
or mention it by name to talk to it. Give it a channel of its own to avoid having to tag it every time. Use /character
to change to other characters in your character folder.
Use regen
to make the bot forget and regenerate the previous response. Useful to guide it in a direction. Use /cont
if you're too lazy to type "continue".
To clear chat history with LLaMA or change the initial prompt, use /reset
. Sometimes LLaMA will get stuck or you will want to change the initial prompt to something more interesting so /reset
is well used.
Can use A1111 if it is in api mode with /pics
command:
Can also just ask directly to take a selfie
or take a picture
:
Note the additions to the Llayla character in the characters folder, showing how to provide optional SD prompts the bot can use when taking pictures or selfies, if you're after a particular style or look. It will use whatever model is loaded in the webgui of Automatic 1111.
-
Setup text-generation-webui with their one-click installer and download the model you want (for example
decapoda-research/llama-7b-hf
). Make sure it's working. -
Edit
config.py
with your Discord bot's token -
Place
bot.py
andconfig.py
inside the text-generation-webui directory -
Place your character file(s) in the
characters
folder. One of them should have the same name as your bot. -
Open the
cmd
file that came with the one-click installer -
Install discord.py with
pip install discord
-
Run the bot with
python bot.py
- For ease of use
bot.py
supports allserver.py
model-related command line arguments. For example,python bot.py --model llama-7b-hf
is a valid way to start the bot. - If you experience problems, it might be because the webui updated. Try
git checkout a5d5bb9
before running the bot withpython bot.py