The all-in-one local AI studio for your desktop: chat, image and video generation and a coding agent in one free, open source app. Windows and Linux. No Docker, no terminal, no cloud required.
TypeScript agentai-chatai-studioall-in-onecoding-agentdesktop-appfluximage-generationlinuxllmlocal-ailocal-llmopen-sourceprivacyself-hostedstable-diffusionuncensoreduncensored-aivideo-generationwindows
Fix setup.bat: remove ANSI codes, works in all terminals
PurpleDoubleD8fd7b736c555
diff --git a/setup.bat b/setup.batindex 2ff2c581..7cbdc2d2 100644--- a/setup.bat+++ b/setup.bat@@ -1,80 +1,76 @@@echo offtitle Locally Uncensored - Setup--:: Enable ANSI/VT100 in CMD-for /f %%a in ('echo prompt $E^| cmd') do set "ESC=%%a"-echo.echo.-echo %ESC%[95m ## ####### ###### ### ## ## ## ##%ESC%[0m-echo %ESC%[95m ## ## ## ## ## ## ## ## ## ## ##%ESC%[0m-echo %ESC%[35m ## ## ## ## ## ## ## ## ####%ESC%[0m-echo %ESC%[35m ## ## ## ## ## ## ## ## ##%ESC%[0m-echo %ESC%[35m ## ## ## ## ######### ## ## ##%ESC%[0m-echo %ESC%[95m ## ## ## ## ## ## ## ## ## ##%ESC%[0m-echo %ESC%[95m ######## ####### ###### ## ## ######## ######## ##%ESC%[0m+echo ## ####### ###### ### ## ## ## ##+echo ## ## ## ## ## ## ## ## ## ## ##+echo ## ## ## ## ## ## ## ## ####+echo ## ## ## ## ## ## ## ## ##+echo ## ## ## ## ######### ## ## ##+echo ## ## ## ## ## ## ## ## ## ##+echo ######## ####### ###### ## ## ######## ######## ##echo.-echo %ESC%[95m ## ## ## ## ###### ######## ## ## ###### ####### ######## ######## ########%ESC%[0m-echo %ESC%[95m ## ## ### ## ## ## ## ### ## ## ## ## ## ## ## ## ## ##%ESC%[0m-echo %ESC%[35m ## ## #### ## ## ## #### ## ## ## ## ## ## ## ## ##%ESC%[0m-echo %ESC%[35m ## ## ## ## ## ## ###### ## ## ## ###### ## ## ######## ###### ## ##%ESC%[0m-echo %ESC%[35m ## ## ## #### ## ## ## #### ## ## ## ## ## ## ## ##%ESC%[0m-echo %ESC%[95m ## ## ## ### ## ## ## ## ### ## ## ## ## ## ## ## ## ##%ESC%[0m-echo %ESC%[95m ####### ## ## ###### ######## ## ## ###### ####### ## ## ######## ########%ESC%[0m+echo ## ## ## ## ###### ######## ## ## ###### ####### ######## ######## ########+echo ## ## ### ## ## ## ## ### ## ## ## ## ## ## ## ## ## ##+echo ## ## #### ## ## #### ## ## ## ## ## ## ## ##+echo ## ## ## ## ## ###### ## ## ###### ## ## ######## ###### ## ##+echo ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ##+echo ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ##+echo #### ## ## ###### ######## ## ## ###### ####### ## ## ######## ########echo.-echo %ESC%[90m Private, local AI. No cloud. No censorship. No data collection.%ESC%[0m-echo %ESC%[95m =================================================================%ESC%[0m+echo Private, local AI. No cloud. No censorship. No data collection.+echo =================================================================echo.-echo %ESC%[97m Automatic Setup%ESC%[0m+echo Automatic Setupecho.:: --- Step 1: Check Node.js ---where node >nul 2>nulif %errorlevel% neq 0 (- echo %ESC%[93m[1/5]%ESC%[0m Installing Node.js...- winget install OpenJS.NodeJS.LTS --accept-package-agreements --accept-source-agreements >nul 2>nul+ echo [1/5] Installing Node.js...+ winget install OpenJS.NodeJS.LTS --accept-package-agreements --accept-source-agreementsif %errorlevel% neq 0 (- echo %ESC%[91m[!]%ESC%[0m Could not install Node.js. Get it from https://nodejs.org/- timeout /t 10+ echo [!] Could not install Node.js. Get it from https://nodejs.org/+ pauseexit /b 1)- echo %ESC%[92m[+]%ESC%[0m Node.js installed. Restarting...+ echo [OK] Node.js installed. Restarting...start "" cmd /c "cd /d "%~dp0" && setup.bat"exit /b 0) else (- for /f "tokens=*" %%i in ('node --version') do echo %ESC%[92m[+]%ESC%[0m Node.js %%i+ for /f "tokens=*" %%i in ('node --version') do echo [+] Node.js %%i):: --- Step 2: Check Git ---where git >nul 2>nulif %errorlevel% neq 0 (- echo %ESC%[93m[2/5]%ESC%[0m Installing Git...- winget install Git.Git --accept-package-agreements --accept-source-agreements >nul 2>nul+ echo [2/5] Installing Git...+ winget install Git.Git --accept-package-agreements --accept-source-agreementsif %errorlevel% neq 0 (- echo %ESC%[91m[!]%ESC%[0m Could not install Git. Get it from https://git-scm.com/- timeout /t 10+ echo [!] Could not install Git. Get it from https://git-scm.com/+ pauseexit /b 1)- echo %ESC%[92m[+]%ESC%[0m Git installed. Restarting...+ echo [OK] Git installed. Restarting...start "" cmd /c "cd /d "%~dp0" && setup.bat"exit /b 0) else (- echo %ESC%[92m[+]%ESC%[0m Git+ echo [+] Git):: --- Step 3: Check Ollama ---where ollama >nul 2>nulif %errorlevel% neq 0 (- echo %ESC%[93m[3/5]%ESC%[0m Installing Ollama...- winget install Ollama.Ollama --accept-package-agreements --accept-source-agreements >nul 2>nul+ echo [3/5] Installing Ollama...+ winget install Ollama.Ollama --accept-package-agreements --accept-source-agreementsif %errorlevel% neq 0 (- echo %ESC%[91m[!]%ESC%[0m Could not install Ollama. Get it from https://ollama.com/- timeout /t 10+ echo [!] Could not install Ollama. Get it from https://ollama.com/+ pauseexit /b 1)- echo %ESC%[92m[+]%ESC%[0m Ollama+ echo [+] Ollama installed) else (- echo %ESC%[92m[+]%ESC%[0m Ollama+ echo [+] Ollama):: Start Ollama silently@@ -86,42 +82,42 @@ if %errorlevel% neq 0 (:: --- Step 4: Install dependencies ---echo.-echo %ESC%[93m[4/5]%ESC%[0m Installing dependencies...+echo [4/5] Installing dependencies...cd /d "%~dp0"-call npm install --loglevel=error >nul 2>nul+call npm install --loglevel=errorif %errorlevel% neq 0 (- echo %ESC%[91m[!]%ESC%[0m npm install failed.- timeout /t 10+ echo [!] npm install failed.+ pauseexit /b 1)-echo %ESC%[92m[+]%ESC%[0m Dependencies installed+echo [+] Dependencies installed:: --- Step 5: Check AI models ---echo.ollama list 2>nul | findstr /v "NAME" | findstr "." >nul 2>nulif %errorlevel% neq 0 (- echo %ESC%[93m[5/5]%ESC%[0m No AI model found.- echo %ESC%[93m Downloading Llama 3.1 8B Uncensored (~5.7 GB)...%ESC%[0m- echo %ESC%[90m This is a one-time download. Grab a coffee.%ESC%[0m+ echo [5/5] No AI model found.+ echo Downloading Llama 3.1 8B Uncensored (~5.7 GB)...+ echo This is a one-time download. Grab a coffee.echo.ollama pull mannix/llama3.1-8b-abliterated:q5_K_Mecho.- echo %ESC%[92m[+]%ESC%[0m AI model installed+ echo [+] AI model installed) else (- echo %ESC%[92m[+]%ESC%[0m AI models found+ echo [+] AI models found):: --- Create desktop shortcut ---powershell -NoProfile -Command "$ws = New-Object -ComObject WScript.Shell; $s = $ws.CreateShortcut([System.IO.Path]::Combine([Environment]::GetFolderPath('Desktop'), 'Locally Uncensored.lnk')); $s.TargetPath = '%~dp0start.bat'; $s.WorkingDirectory = '%~dp0'; $s.Description = 'Locally Uncensored - Private AI Chat'; $s.WindowStyle = 7; $s.Save()" >nul 2>nulecho.-echo %ESC%[92m =================================================================%ESC%[0m-echo.-echo %ESC%[97m Setup complete!%ESC%[0m %ESC%[90mOpening in your browser...%ESC%[0m+echo =================================================================+echo Setup complete! Opening in your browser...+echo =================================================================echo.:: Start dev server in background, open browser, close terminalstart "" /b cmd /c "cd /d "%~dp0" && npm run dev >nul 2>nul"-timeout /t 3 /nobreak >nul+timeout /t 4 /nobreak >nulstart "" http://localhost:5173exit