mirror of
https://github.com/tencentmusic/supersonic.git
synced 2025-12-24 10:27:28 +08:00
(improvement)(project) Remove Python module and related Python code. (#1263)
This commit is contained in:
@@ -11,10 +11,6 @@ if "%service%"=="" (
|
||||
set "service=%standalone_service%"
|
||||
)
|
||||
set "model_name=%service%"
|
||||
IF "%service%"=="pyllm" (
|
||||
set "llmProxy=PythonLLMProxy"
|
||||
set "model_name=%standalone_service%"
|
||||
)
|
||||
|
||||
cd %baseDir%
|
||||
|
||||
@@ -36,30 +32,15 @@ if "%command%"=="restart" (
|
||||
goto :EOF
|
||||
)
|
||||
|
||||
|
||||
: start
|
||||
if "%service%"=="%pyllm_service%" (
|
||||
call :runPythonService
|
||||
call :runJavaService
|
||||
goto :EOF
|
||||
)
|
||||
call :runJavaService
|
||||
goto :EOF
|
||||
|
||||
|
||||
: stop
|
||||
call :stopPythonService
|
||||
call :stopJavaService
|
||||
goto :EOF
|
||||
|
||||
|
||||
: reloadExamples
|
||||
set "pythonRunDir=%baseDir%\pyllm"
|
||||
cd "%pythonRunDir%\sql"
|
||||
start %python_path% examples_reload_run.py
|
||||
goto :EOF
|
||||
|
||||
|
||||
: runJavaService
|
||||
echo 'java service starting, see logs in logs/'
|
||||
set "libDir=%baseDir%\lib"
|
||||
@@ -74,24 +55,6 @@ if "%command%"=="restart" (
|
||||
echo 'java service started'
|
||||
goto :EOF
|
||||
|
||||
|
||||
: runPythonService
|
||||
echo 'python service starting, see logs in pyllm\pyllm.log'
|
||||
set "pythonRunDir=%baseDir%\pyllm"
|
||||
start /B %python_path% %pythonRunDir%\supersonic_pyllm.py > %pythonRunDir%\pyllm.log 2>&1
|
||||
timeout /t 10 >nul
|
||||
echo 'python service started'
|
||||
goto :EOF
|
||||
|
||||
|
||||
: stopPythonService
|
||||
for /f "tokens=2" %%i in ('tasklist ^| findstr /i "python"') do (
|
||||
taskkill /PID %%i /F
|
||||
echo "python service (PID = %%i) is killed."
|
||||
)
|
||||
goto :EOF
|
||||
|
||||
|
||||
: stopJavaService
|
||||
for /f "tokens=2" %%i in ('tasklist ^| findstr /i "java"') do (
|
||||
taskkill /PID %%i /F
|
||||
|
||||
Reference in New Issue
Block a user