Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bigsk1/696f8a10c9d1b9a45100961d141b096f to your computer and use it in GitHub Desktop.
Save bigsk1/696f8a10c9d1b9a45100961d141b096f to your computer and use it in GitHub Desktop.
SillyTavern one click launcher for windows - read bottom of file - add your paths as needed
@echo off
REM Replace with the path to your oogabooga web UI installation
set OOGABOOGA_PATH=PATH_TO_OOGABOOGA
echo Starting oogabooga web UI...
start cmd /k "%OOGABOOGA_PATH%\start_windows.bat"
timeout /t 5
REM Replace with the path to your Stable Diffusion Automatic1111 web UI installation
set STABLE_DIFFUSION_PATH=PATH_TO_STABLE_DIFFUSION
echo Starting Stable Diffusion Automatic1111 web UI...
cd %STABLE_DIFFUSION_PATH%
start cmd /k "webui-user.bat"
timeout /t 30
REM Replace with the path to your SillyTavern installation
set SILLY_TAVERN_PATH=PATH_TO_SILLYTAVERN
echo Starting SillyTavern server...
pushd %SILLY_TAVERN_PATH%
start powershell -Command "npm install --no-audit; node server.js"
timeout /t 10
echo Starting SillyTavern Extras server...
cd %SILLY_TAVERN_PATH%\SillyTavern-extras
start cmd /k "call PATH_TO_MINICONDA\Scripts\activate.bat && conda activate YOUR_ENV_NAME && python server.py --enable-modules=caption,summarize,classify,sd --sd-remote-port 7861"
timeout /t 10
echo Starting Silero API server...
cd %SILLY_TAVERN_PATH%\SillyTavern-extras\silero-api-server
start cmd /k "call PATH_TO_MINICONDA\Scripts\activate.bat && conda activate YOUR_ENV_NAME && python -m silero_api_server"
exit
--------------------------------------
Users will need to replace:
PATH_TO_OOGABOOGA with their oogabooga installation path.
PATH_TO_STABLE_DIFFUSION with their Stable Diffusion installation path.
PATH_TO_SILLYTAVERN with their SillyTavern installation path.
PATH_TO_MINICONDA with the path to their Miniconda or Anaconda installation.
YOUR_ENV_NAME with the name of their Conda environment.
with the above .bat file and your .bat located in your SillyTavern home directory you can start all these with one click, modify as needed. This file will be in the same home folder as start.bat in SillyTavern
@echo off
REM Replace with the path to your oogabooga web UI installation
set OOGABOOGA_PATH=PATH_TO_OOGABOOGA
echo Starting oogabooga web UI...
start cmd /k "%OOGABOOGA_PATH%\start_windows.bat"
timeout /t 5
REM Replace with the path to your Stable Diffusion Automatic1111 web UI installation
set STABLE_DIFFUSION_PATH=PATH_TO_STABLE_DIFFUSION
echo Starting Stable Diffusion Automatic1111 web UI...
cd %STABLE_DIFFUSION_PATH%
start cmd /k "webui-user.bat"
timeout /t 30
REM Replace with the path to your SillyTavern installation
set SILLY_TAVERN_PATH=PATH_TO_SILLYTAVERN
echo Starting SillyTavern server...
pushd %SILLY_TAVERN_PATH%
start powershell -Command "npm install --no-audit; node server.js"
timeout /t 10
echo Starting SillyTavern Extras server...
cd %SILLY_TAVERN_PATH%\SillyTavern-extras
start cmd /k "call PATH_TO_MINICONDA\Scripts\activate.bat && conda activate YOUR_ENV_NAME && python server.py --enable-modules=caption,summarize,classify,sd --sd-remote-port 7861"
timeout /t 10
echo Starting Silero API server...
cd %SILLY_TAVERN_PATH%\SillyTavern-extras\silero-api-server
start cmd /k "call PATH_TO_MINICONDA\Scripts\activate.bat && conda activate YOUR_ENV_NAME && python -m silero_api_server"
exit
@bigsk1
Copy link
Author

bigsk1 commented Aug 21, 2023

This is my working .bat file as an example

@echo off

echo Starting oogabooga web UI...
start cmd /k "X:\oobabooga\oobabooga_windows\start_windows.bat"
timeout /t 5

echo Starting Stable Diffusion Automatic1111 web UI...
cd X:\SD\stable-diffusion-webui
start cmd /k "webui-user.bat"
timeout /t 30

echo Starting SillyTavern server...
pushd %~dp0
start powershell -Command "npm install --no-audit; node server.js"
timeout /t 10

echo Starting SillyTavern Extras server...
cd X:\SillyTavern\SillyTavern-extras
start cmd /k "call C:\Users\dude\miniconda3\Scripts\activate.bat && conda activate sillyextras && python server.py --enable-modules=caption,summarize,classify,sd --sd-remote-port 7861"
timeout /t 10

echo Starting Silero API server...
cd X:\SillyTavern\SillyTavern-extras\silero-api-server
start cmd /k "call C:\Users\dude\miniconda3\Scripts\activate.bat && conda activate sillyextras && python -m silero_api_server"

exit

make sure python and conda are added to path already and in windows you might have to allow execution policy by using this in admin powershell

Set-ExecutionPolicy RemoteSigned -Scope CurrentUser

If you don't want the .bat file in SillyTavern home folder, which I just make a shortcut once it's there as that is easy and then put on desktop, you could modify, replace your path location as needed.

pushd %~dp0
start powershell -Command "npm install --no-audit; node server.js"

to

cd X:\SillyTavern
start powershell -Command "npm install --no-audit; node server.js"

@bigsk1
Copy link
Author

bigsk1 commented Aug 23, 2023

If you are using windows terminal and don't want each window sperate in the windows terminal settings change to "Attach to the most recent used window"

Instead of new windows being opened you will have just tabs opened in one window!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment