├── .gitignore ├── requirements.txt ├── run.bat └── run.sh /.gitignore: -------------------------------------------------------------------------------- 1 | logs 2 | venv 3 | index.html -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/leonvanzyl/langflow-tutorial-2024/630227e335b9219d8e95aa96178ecf1fd2e652a1/requirements.txt -------------------------------------------------------------------------------- /run.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | REM Check if the venv folder exists 3 | IF NOT EXIST "venv\Scripts\activate" ( 4 | echo Creating virtual environment... 5 | python -m venv venv 6 | ) 7 | 8 | REM Activate the virtual environment 9 | call venv\Scripts\activate 10 | 11 | REM Check if langflow is installed 12 | pip show langflow >nul 2>&1 13 | IF %ERRORLEVEL% NEQ 0 ( 14 | echo Installing langflow... 15 | python -m pip install langflow 16 | ) ELSE ( 17 | echo Updating langflow... 18 | python -m pip install langflow --upgrade 19 | ) 20 | 21 | REM Start langflow 22 | langflow run 23 | 24 | REM Keep the window open 25 | pause 26 | -------------------------------------------------------------------------------- /run.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Check if the venv folder exists 4 | if [ ! -d "venv" ]; then 5 | echo "Creating virtual environment..." 6 | python3 -m venv venv 7 | fi 8 | 9 | # Activate the virtual environment 10 | source venv/bin/activate 11 | 12 | # Check if langflow is installed 13 | if ! pip show langflow > /dev/null 2>&1; then 14 | echo "Installing langflow..." 15 | python -m pip install langflow 16 | else 17 | echo "Updating langflow..." 18 | python -m pip install langflow --upgrade 19 | fi 20 | 21 | # Start langflow 22 | langflow run 23 | 24 | # Keep the terminal open (only needed if running from a double-clickable script) 25 | exec $SHELL 26 | --------------------------------------------------------------------------------