mirror of
https://github.com/ParisNeo/lollms-webui.git
synced 2025-02-06 10:59:23 +00:00
added reboot
This commit is contained in:
parent
13ce4a069f
commit
bd56719618
4
app.py
4
app.py
@ -13,7 +13,7 @@ __github__ = "https://github.com/ParisNeo/lollms-webui"
|
|||||||
__copyright__ = "Copyright 2023, "
|
__copyright__ = "Copyright 2023, "
|
||||||
__license__ = "Apache 2.0"
|
__license__ = "Apache 2.0"
|
||||||
|
|
||||||
__version__ ="8.0 (Beta)"
|
__version__ ="8.0"
|
||||||
|
|
||||||
main_repo = "https://github.com/ParisNeo/lollms-webui.git"
|
main_repo = "https://github.com/ParisNeo/lollms-webui.git"
|
||||||
import os
|
import os
|
||||||
@ -1649,7 +1649,7 @@ try:
|
|||||||
per.model = self.model
|
per.model = self.model
|
||||||
return jsonify({"status": True})
|
return jsonify({"status": True})
|
||||||
except Exception as ex:
|
except Exception as ex:
|
||||||
ASCIIColors.error(f"Couldn't build binding: [{ex}]")
|
self.error(f"Couldn't build binding: [{ex}]")
|
||||||
trace_exception(ex)
|
trace_exception(ex)
|
||||||
return jsonify({"status":False, 'error':str(ex)})
|
return jsonify({"status":False, 'error':str(ex)})
|
||||||
|
|
||||||
|
19
docs/youtube/lollms_v8.0_install_gpu.md
Normal file
19
docs/youtube/lollms_v8.0_install_gpu.md
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
Hi there,
|
||||||
|
|
||||||
|
In this short I'm going to show you how to install lollms in GPU mode and use the hugging face binding to run inference.
|
||||||
|
|
||||||
|
The steps to aceive this are simple:
|
||||||
|
download the installer from the github of the project to an empty folder with a path that does not contain spaces.
|
||||||
|
double click the installer and validate.
|
||||||
|
select the install mode (Cuda, rocm or cpu)
|
||||||
|
wait
|
||||||
|
Run the app
|
||||||
|
Choose the personal data folder
|
||||||
|
Install a binding
|
||||||
|
Reboot the app
|
||||||
|
Select the binding
|
||||||
|
Install a model
|
||||||
|
Select a model
|
||||||
|
|
||||||
|
|
||||||
|
Start by opening the lollms web user interface link that you can find in the description. Then go to the latest release page and download the
|
@ -98,13 +98,6 @@ source "$MINICONDA_DIR/bin/activate" || ( echo "Miniconda hook not found." && ex
|
|||||||
if [ ! -d "$INSTALL_ENV_DIR" ]; then
|
if [ ! -d "$INSTALL_ENV_DIR" ]; then
|
||||||
echo "Packages to install: $PACKAGES_TO_INSTALL"
|
echo "Packages to install: $PACKAGES_TO_INSTALL"
|
||||||
conda create -y -k -p "$INSTALL_ENV_DIR" $CHANNEL $PACKAGES_TO_INSTALL || ( echo && echo "Conda environment creation failed." && exit 1 )
|
conda create -y -k -p "$INSTALL_ENV_DIR" $CHANNEL $PACKAGES_TO_INSTALL || ( echo && echo "Conda environment creation failed." && exit 1 )
|
||||||
if [[ "${gpuchoice^^}" == "A" ]]; then
|
|
||||||
conda run --live-stream -p "$INSTALL_ENV_DIR" python -m pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu121 || ( echo && echo "Pytorch installation failed." && exit 1 )
|
|
||||||
elif [[ "${gpuchoice^^}" == "B" ]]; then
|
|
||||||
conda run --live-stream -p "$INSTALL_ENV_DIR" python -m pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/rocm5.4.2 || ( echo && echo "Pytorch installation failed." && exit 1 )
|
|
||||||
elif [[ "${gpuchoice^^}" == "C" ]]; then
|
|
||||||
conda run --live-stream -p "$INSTALL_ENV_DIR" python -m pip install torch torchvision torchaudio || ( echo && echo "Pytorch installation failed." && exit 1 )
|
|
||||||
fi
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Check if conda environment was actually created
|
# Check if conda environment was actually created
|
||||||
|
@ -95,12 +95,6 @@ if [ ! -d "$INSTALL_ENV_DIR" ]; then
|
|||||||
echo "Packages to install: $PACKAGES_TO_INSTALL"
|
echo "Packages to install: $PACKAGES_TO_INSTALL"
|
||||||
conda create -y -k -n "$ENV_NAME" $CHANNEL $PACKAGES_TO_INSTALL || ( echo && echo "Conda environment creation failed." && exit 1 )
|
conda create -y -k -n "$ENV_NAME" $CHANNEL $PACKAGES_TO_INSTALL || ( echo && echo "Conda environment creation failed." && exit 1 )
|
||||||
echo "Conda created and using packages: $PACKAGES_TO_INSTALL"
|
echo "Conda created and using packages: $PACKAGES_TO_INSTALL"
|
||||||
echo "Installing tools"
|
|
||||||
if [[ "$(echo $gpuchoice | tr '[:lower:]' '[:upper:]')" == "A" ]]; then
|
|
||||||
conda run --live-stream -n "$ENV_NAME" python -m pip install torch torchvision torchaudio --channel pytorch --channel conda-forge || ( echo && echo "Pytorch installation failed." && exit 1 )
|
|
||||||
elif [[ "$(echo $gpuchoice | tr '[:lower:]' '[:upper:]')" == "B" ]]; then
|
|
||||||
conda run --live-stream -n "$ENV_NAME" python -m pip install torch torchvision torchaudio --channel pytorch --channel conda-forge || ( echo && echo "Pytorch installation failed." && exit 1 )
|
|
||||||
fi
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Activate installer environment
|
# Activate installer environment
|
||||||
|
@ -107,9 +107,6 @@ if /I "%gpuchoice%" == "B" (
|
|||||||
if not exist "%INSTALL_ENV_DIR%" (
|
if not exist "%INSTALL_ENV_DIR%" (
|
||||||
echo Packages to install: %PACKAGES_TO_INSTALL%
|
echo Packages to install: %PACKAGES_TO_INSTALL%
|
||||||
call conda create --no-shortcuts -y -k -p "%INSTALL_ENV_DIR%" %CHANNEL% %PACKAGES_TO_INSTALL% || ( echo. && echo Conda environment creation failed. && goto end )
|
call conda create --no-shortcuts -y -k -p "%INSTALL_ENV_DIR%" %CHANNEL% %PACKAGES_TO_INSTALL% || ( echo. && echo Conda environment creation failed. && goto end )
|
||||||
if /I "%gpuchoice%" == "A" call conda run --live-stream -p "%INSTALL_ENV_DIR%" python -m pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu121|| ( echo. && echo Pytorch installation failed.&& goto end )
|
|
||||||
if /I "%gpuchoice%" == "B" call conda run --live-stream -p "%INSTALL_ENV_DIR%" python -m pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/rocm5.4.2|| ( echo. && echo Pytorch installation failed.&& goto end )
|
|
||||||
if /I "%gpuchoice%" == "C" call conda run --live-stream -p "%INSTALL_ENV_DIR%" python -m pip install torch torchvision torchaudio|| ( echo. && echo Pytorch installation failed.&& goto end )
|
|
||||||
)
|
)
|
||||||
|
|
||||||
@rem check if conda environment was actually created
|
@rem check if conda environment was actually created
|
||||||
|
File diff suppressed because one or more lines are too long
2
web/dist/index.html
vendored
2
web/dist/index.html
vendored
@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<title>LoLLMS WebUI - Welcome</title>
|
<title>LoLLMS WebUI - Welcome</title>
|
||||||
<script type="module" crossorigin src="/assets/index-4179aa9a.js"></script>
|
<script type="module" crossorigin src="/assets/index-24f00053.js"></script>
|
||||||
<link rel="stylesheet" href="/assets/index-80a485ca.css">
|
<link rel="stylesheet" href="/assets/index-80a485ca.css">
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
@ -176,9 +176,11 @@ export default {
|
|||||||
this.systemTheme = window.matchMedia("prefers-color-scheme: dark").matches;
|
this.systemTheme = window.matchMedia("prefers-color-scheme: dark").matches;
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
refreshPage(event) {
|
async refreshPage(event) {
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
window.location.reload();
|
console.log("this.$store.state.api_get_req",this.$store.state.api_get_req)
|
||||||
|
await this.$store.state.api_get_req('restart_program')
|
||||||
|
window.close();
|
||||||
},
|
},
|
||||||
handleOk(inputText) {
|
handleOk(inputText) {
|
||||||
console.log("Input text:", inputText);
|
console.log("Input text:", inputText);
|
||||||
|
@ -24,6 +24,7 @@ export const store = createStore({
|
|||||||
state () {
|
state () {
|
||||||
return {
|
return {
|
||||||
// count: 0,
|
// count: 0,
|
||||||
|
api_get_req:null,
|
||||||
startSpeechRecognition:null,
|
startSpeechRecognition:null,
|
||||||
ready:false,
|
ready:false,
|
||||||
loading_infos: "",
|
loading_infos: "",
|
||||||
@ -499,6 +500,7 @@ let actionsExecuted = false;
|
|||||||
app.mixin({
|
app.mixin({
|
||||||
async created() {
|
async created() {
|
||||||
if (!actionsExecuted) {
|
if (!actionsExecuted) {
|
||||||
|
this.$store.state.api_get_req = api_get_req
|
||||||
actionsExecuted = true;
|
actionsExecuted = true;
|
||||||
console.log("Calling")
|
console.log("Calling")
|
||||||
this.$store.state.loading_infos = "Loading Configuration"
|
this.$store.state.loading_infos = "Loading Configuration"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user