mirror of
https://github.com/ParisNeo/lollms-webui.git
synced 2024-12-19 20:37:51 +00:00
upgraded and added more languages to audio xTTS
This commit is contained in:
parent
d8fb2d6ff7
commit
22c63467c7
@ -816,6 +816,7 @@ class LoLLMsAPI(LollmsApplication):
|
||||
def create_empty_message(data):
|
||||
client_id = request.sid
|
||||
type = data.get("type",0)
|
||||
message = data.get("message","")
|
||||
if type==0:
|
||||
ASCIIColors.info(f"Building empty User message requested by : {client_id}")
|
||||
# send the message to the bot
|
||||
@ -824,7 +825,7 @@ class LoLLMsAPI(LollmsApplication):
|
||||
if not self.model:
|
||||
self.error("No model selected. Please make sure you select a model before starting generation", client_id = client_id)
|
||||
return
|
||||
self.new_message(client_id, self.config.user_name, "", sender_type=SENDER_TYPES.SENDER_TYPES_USER, open=True)
|
||||
self.new_message(client_id, self.config.user_name, message, sender_type=SENDER_TYPES.SENDER_TYPES_USER, open=True)
|
||||
self.socketio.sleep(0.01)
|
||||
else:
|
||||
if self.personality is None:
|
||||
|
@ -9,6 +9,7 @@
|
||||
"version": "0.0.0",
|
||||
"dependencies": {
|
||||
"autoprefixer": "^10.4.16",
|
||||
"axios": "^1.6.3",
|
||||
"flowbite": "^2.2.1",
|
||||
"postcss": "^8.4.32",
|
||||
"tailwind-scrollbar": "^3.0.5",
|
||||
@ -841,6 +842,11 @@
|
||||
"resolved": "https://registry.npmjs.org/arg/-/arg-5.0.2.tgz",
|
||||
"integrity": "sha512-PYjyFOLKQ9y57JvQ6QLo8dAgNqswh8M1RMJYdQduT6xbWSgK36P/Z/v+p888pM69jMMfS8Xd8F6I1kQ/I9HUGg=="
|
||||
},
|
||||
"node_modules/asynckit": {
|
||||
"version": "0.4.0",
|
||||
"resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz",
|
||||
"integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q=="
|
||||
},
|
||||
"node_modules/autoprefixer": {
|
||||
"version": "10.4.16",
|
||||
"resolved": "https://registry.npmjs.org/autoprefixer/-/autoprefixer-10.4.16.tgz",
|
||||
@ -877,6 +883,16 @@
|
||||
"postcss": "^8.1.0"
|
||||
}
|
||||
},
|
||||
"node_modules/axios": {
|
||||
"version": "1.6.3",
|
||||
"resolved": "https://registry.npmjs.org/axios/-/axios-1.6.3.tgz",
|
||||
"integrity": "sha512-fWyNdeawGam70jXSVlKl+SUNVcL6j6W79CuSIPfi6HnDUmSCH6gyUys/HrqHeA/wU0Az41rRgean494d0Jb+ww==",
|
||||
"dependencies": {
|
||||
"follow-redirects": "^1.15.0",
|
||||
"form-data": "^4.0.0",
|
||||
"proxy-from-env": "^1.1.0"
|
||||
}
|
||||
},
|
||||
"node_modules/balanced-match": {
|
||||
"version": "1.0.2",
|
||||
"resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz",
|
||||
@ -1020,6 +1036,17 @@
|
||||
"resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
|
||||
"integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA=="
|
||||
},
|
||||
"node_modules/combined-stream": {
|
||||
"version": "1.0.8",
|
||||
"resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz",
|
||||
"integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==",
|
||||
"dependencies": {
|
||||
"delayed-stream": "~1.0.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">= 0.8"
|
||||
}
|
||||
},
|
||||
"node_modules/commander": {
|
||||
"version": "4.1.1",
|
||||
"resolved": "https://registry.npmjs.org/commander/-/commander-4.1.1.tgz",
|
||||
@ -1057,6 +1084,14 @@
|
||||
"resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.3.tgz",
|
||||
"integrity": "sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw=="
|
||||
},
|
||||
"node_modules/delayed-stream": {
|
||||
"version": "1.0.0",
|
||||
"resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz",
|
||||
"integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==",
|
||||
"engines": {
|
||||
"node": ">=0.4.0"
|
||||
}
|
||||
},
|
||||
"node_modules/didyoumean": {
|
||||
"version": "1.2.2",
|
||||
"resolved": "https://registry.npmjs.org/didyoumean/-/didyoumean-1.2.2.tgz",
|
||||
@ -1198,6 +1233,25 @@
|
||||
"mini-svg-data-uri": "^1.4.3"
|
||||
}
|
||||
},
|
||||
"node_modules/follow-redirects": {
|
||||
"version": "1.15.4",
|
||||
"resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.4.tgz",
|
||||
"integrity": "sha512-Cr4D/5wlrb0z9dgERpUL3LrmPKVDsETIJhaCMeDfuFYcqa5bldGV6wBsAN6X/vxlXQtFBMrXdXxdL8CbDTGniw==",
|
||||
"funding": [
|
||||
{
|
||||
"type": "individual",
|
||||
"url": "https://github.com/sponsors/RubenVerborgh"
|
||||
}
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=4.0"
|
||||
},
|
||||
"peerDependenciesMeta": {
|
||||
"debug": {
|
||||
"optional": true
|
||||
}
|
||||
}
|
||||
},
|
||||
"node_modules/foreground-child": {
|
||||
"version": "3.1.1",
|
||||
"resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.1.1.tgz",
|
||||
@ -1213,6 +1267,19 @@
|
||||
"url": "https://github.com/sponsors/isaacs"
|
||||
}
|
||||
},
|
||||
"node_modules/form-data": {
|
||||
"version": "4.0.0",
|
||||
"resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz",
|
||||
"integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==",
|
||||
"dependencies": {
|
||||
"asynckit": "^0.4.0",
|
||||
"combined-stream": "^1.0.8",
|
||||
"mime-types": "^2.1.12"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">= 6"
|
||||
}
|
||||
},
|
||||
"node_modules/fraction.js": {
|
||||
"version": "4.3.7",
|
||||
"resolved": "https://registry.npmjs.org/fraction.js/-/fraction.js-4.3.7.tgz",
|
||||
@ -1428,6 +1495,25 @@
|
||||
"node": ">=8.6"
|
||||
}
|
||||
},
|
||||
"node_modules/mime-db": {
|
||||
"version": "1.52.0",
|
||||
"resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz",
|
||||
"integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==",
|
||||
"engines": {
|
||||
"node": ">= 0.6"
|
||||
}
|
||||
},
|
||||
"node_modules/mime-types": {
|
||||
"version": "2.1.35",
|
||||
"resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz",
|
||||
"integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==",
|
||||
"dependencies": {
|
||||
"mime-db": "1.52.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">= 0.6"
|
||||
}
|
||||
},
|
||||
"node_modules/mini-svg-data-uri": {
|
||||
"version": "1.4.4",
|
||||
"resolved": "https://registry.npmjs.org/mini-svg-data-uri/-/mini-svg-data-uri-1.4.4.tgz",
|
||||
@ -1720,6 +1806,11 @@
|
||||
"resolved": "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-4.2.0.tgz",
|
||||
"integrity": "sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ=="
|
||||
},
|
||||
"node_modules/proxy-from-env": {
|
||||
"version": "1.1.0",
|
||||
"resolved": "https://registry.npmjs.org/proxy-from-env/-/proxy-from-env-1.1.0.tgz",
|
||||
"integrity": "sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg=="
|
||||
},
|
||||
"node_modules/queue-microtask": {
|
||||
"version": "1.2.3",
|
||||
"resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz",
|
||||
|
@ -10,6 +10,7 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"autoprefixer": "^10.4.16",
|
||||
"axios": "^1.6.3",
|
||||
"flowbite": "^2.2.1",
|
||||
"postcss": "^8.4.32",
|
||||
"tailwind-scrollbar": "^3.0.5",
|
||||
|
@ -1,5 +1,56 @@
|
||||
from fastapi import FastAPI
|
||||
from fastapi.staticfiles import StaticFiles
|
||||
app = FastAPI()
|
||||
from pydantic import BaseModel
|
||||
import uvicorn
|
||||
from lollms.paths import LollmsPaths
|
||||
from lollms.utilities import check_and_install_torch, PackageManager
|
||||
from pathlib import Path
|
||||
from ascii_colors import ASCIIColors
|
||||
import subprocess
|
||||
from pathlib import Path
|
||||
|
||||
app.mount("/", StaticFiles(directory="dist"))
|
||||
from starlette.responses import FileResponse
|
||||
from starlette.requests import Request
|
||||
|
||||
root_path =Path(__file__).parent.parent.parent.parent
|
||||
global_path = root_path/"global_paths_cfg.yaml"
|
||||
ASCIIColors.yellow(f"global_path: {global_path}")
|
||||
lollms_paths = LollmsPaths(global_path)
|
||||
shared_folder = lollms_paths.personal_path/"shared"
|
||||
sd_folder = shared_folder / "auto_sd"
|
||||
output_dir = lollms_paths.personal_path / "outputs/sd"
|
||||
output_dir.mkdir(parents=True, exist_ok=True)
|
||||
script_path = sd_folder / "lollms_sd.bat"
|
||||
output_folder = lollms_paths.personal_outputs_path/"audio_out"
|
||||
|
||||
ASCIIColors.red(" ")
|
||||
ASCIIColors.red(" __ _____ __ __ _____ _____ ")
|
||||
ASCIIColors.red("| | | | | | | | | __|")
|
||||
ASCIIColors.red("| |__| | | |__| |__| | | |__ |")
|
||||
ASCIIColors.red("|_____|_____|_____|_____|_|_|_|_____|")
|
||||
ASCIIColors.red(" Configurator ")
|
||||
ASCIIColors.red(" LoLLMS configuratoin tool")
|
||||
ASCIIColors.yellow(f"Root dir : {root_path}")
|
||||
app = FastAPI(debug=True)
|
||||
|
||||
class Item(BaseModel):
|
||||
name: str
|
||||
price: float
|
||||
|
||||
# Serve the index.html file for all routes
|
||||
@app.get("/{full_path:path}")
|
||||
async def serve_index(request: Request, full_path: Path):
|
||||
if str(full_path).endswith(".js"):
|
||||
return FileResponse(root_path/"scripts/python/lollms_installer/frontend/dist"/full_path, media_type="application/javascript")
|
||||
return FileResponse(root_path/"scripts/python/lollms_installer/frontend/dist/index.html")
|
||||
|
||||
app.mount("/", StaticFiles(directory=root_path/"scripts/python/lollms_installer/frontend/dist"), name="static")
|
||||
|
||||
@app.post("/start_installing")
|
||||
def start_installing(item: Item):
|
||||
|
||||
# Your code here
|
||||
return {"message": "Item created successfully"}
|
||||
|
||||
if __name__ == "__main__":
|
||||
uvicorn.run(app, host="0.0.0.0", port=8000)
|
1
scripts/python/lollms_installer/models_zoo
Submodule
1
scripts/python/lollms_installer/models_zoo
Submodule
@ -0,0 +1 @@
|
||||
Subproject commit 6d78abe11265d37b77f851a442df875f70595263
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
4
web/dist/index.html
vendored
4
web/dist/index.html
vendored
@ -6,8 +6,8 @@
|
||||
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>LoLLMS WebUI - Welcome</title>
|
||||
<script type="module" crossorigin src="/assets/index-c1cddf3b.js"></script>
|
||||
<link rel="stylesheet" href="/assets/index-ba9f58be.css">
|
||||
<script type="module" crossorigin src="/assets/index-5ced427f.js"></script>
|
||||
<link rel="stylesheet" href="/assets/index-1bbab987.css">
|
||||
</head>
|
||||
<body>
|
||||
<div id="app"></div>
|
||||
|
@ -682,7 +682,7 @@ export default {
|
||||
readNextChunk();
|
||||
},
|
||||
makeAnEmptyUserMessage() {
|
||||
this.$emit('createEmptyUserMessage')
|
||||
this.$emit('createEmptyUserMessage',this.message)
|
||||
},
|
||||
makeAnEmptyAIMessage() {
|
||||
this.$emit('createEmptyAIMessage')
|
||||
|
@ -1140,8 +1140,8 @@ export default {
|
||||
console.log("Error: Could not get generation status", error);
|
||||
});
|
||||
},
|
||||
createEmptyUserMessage(){
|
||||
socket.emit('create_empty_message', {"type":0}); // 0 for user and 1 for AI
|
||||
createEmptyUserMessage(message){
|
||||
socket.emit('create_empty_message', {"type":0,"message":message}); // 0 for user and 1 for AI
|
||||
},
|
||||
createEmptyAIMessage(){
|
||||
socket.emit('create_empty_message', {"type":1}); // 0 for user and 1 for AI
|
||||
|
@ -764,8 +764,8 @@
|
||||
<td>
|
||||
<div class="flex flex-row">
|
||||
<select v-model="current_language" @change="settingsChanged=true" :disabled="!enable_voice_service">
|
||||
<option v-for="language in voice_languages" :key="language.key" :value="language.value">
|
||||
{{ language.key }}
|
||||
<option v-for="(value, key) in voice_languages" :key="key" :value="value">
|
||||
{{ key }}
|
||||
</option>
|
||||
</select>
|
||||
</div>
|
||||
|
Loading…
Reference in New Issue
Block a user