Installation - altoiddealer/ad_discordbot GitHub Wiki

Installation

  1. OPTIONAL FOR TGWUI INTEGRATION: Install oobabooga's text-generation-webui

  2. Create a Discord bot account, invite it to your server, and note its authentication token.

    !!! IMPORTANT: You must allow your bot to have "Privileged Intents" for "MESSAGE_CONTENT" !!!

    !!! Enabling Privileged Intents !!!

  3. Clone this repository anywhere.

    FOR TGWUI INTEGRATION: clone into /text-generation-webui/

    git clone https://github.com/altoiddealer/ad_discordbot
    
  4. Run the launcher for your OS (ex: start_windows.bat)

  5. Enter your bot token (from Step 2) into the CMD window

    Screenshot 2024-05-25 100216
  6. The bot should now be up and running!

    If a Welcome message does not appear in your main channel, you can use /helpmenu to see it.

    A number of user settings files will appear (copied in from /user_settings/) where you can customize the bot.

    config.yaml , dict_api_settings.yaml, dict_base_settings.yaml , dict_cmdoptions.yaml , dict_imgmodels.yaml , dict_tags.yaml


Running the bot

  1. Run the launcher for your OS (ex: start_windows.bat)
  • Optionally add launch flags to CMD_FLAGS.txt

EXAMPLE CMD Flags:

 --loader exllama --model airoboros-l2-13b-gpt4-2.0-GPTQ
  1. In Discord UI, use command /character to choose a character.

Usage:

Getting responses from the bot:

  • @ mention the bot

  • Use command /main to set a main channel. The bot won't need to be @ mentioned in main channels.

  • If you enclose your text in parenthesis (like this), the bot will not respond.

Getting image responses from the bot

An "ImgGen" API must be configured and enabled - See APIs Configuration

  • By default, starting your request with "draw " or "generate " will trigger an image response via the Tags system (see dict_tags.yaml)

  • Use /image command to use your own prompt with advanced options

Getting TTS responses from the bot

  1. a. A "TTSGen" API can be used if configured and enabled - See APIs Configuration

    b. Alternatively: If bot is TGWUI enabled, TGWUI TTS extensions can also be used (Tested: alltalk_tts, coqui_tts, silero_tts, elevenlabs_tts)

    TGWUI TTS Extension Usage Instructions

    Install your TTS extension.

    Follow the specific instructions for your TTS extension!!

    Example instructions for coqui_tts:

    Run the .cmd file in text-generation-webui directory (ex: cmd_windows.bat), and performing the following commands:

    Linux / Mac:

    pip install -r extensions/coqui_tts/requirements.txt
    

    Windows:

    pip install -r extensions\coqui_tts\requirements.txt
    

    If necessary, model file(s) should download on first launch of the bot. If not, then first launch textgen-webui normally and enable the extension.

  2. Ensure that your bot has sufficient permissions to access the Voice channel and/or upload files (From your bot invite/Discord Developer portal, and your Discord server/channel settings)

  3. Configure the ttsgen section in config.yaml

  4. Your characters can have their own settings including voices! See example character M1nty for usage


Updating

  1. Run the update-wizard for your OS (ex: update_wizard_windows.bat)
Screenshot 2025-04-04 215515
⚠️ **GitHub.com Fallback** ⚠️