mirror of
https://github.com/ParisNeo/lollms-webui.git
synced 2024-12-18 20:17:50 +00:00
upgraded code
This commit is contained in:
parent
7df7e44d07
commit
1dc85118ef
1
app.py
1
app.py
@ -664,6 +664,7 @@ class LoLLMsWebUI(LoLLMsAPPI):
|
||||
def list_models(self):
|
||||
if self.binding is not None:
|
||||
models = self.binding.list_models(self.config)
|
||||
ASCIIColors.yellow("Listing models")
|
||||
return jsonify(models)
|
||||
else:
|
||||
return jsonify([])
|
||||
|
8
web/dist/assets/index-8884f14a.css
vendored
8
web/dist/assets/index-8884f14a.css
vendored
File diff suppressed because one or more lines are too long
8
web/dist/assets/index-8e2ea812.css
vendored
Normal file
8
web/dist/assets/index-8e2ea812.css
vendored
Normal file
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-60e3fd61.js"></script>
|
||||
<link rel="stylesheet" href="/assets/index-8884f14a.css">
|
||||
<script type="module" crossorigin src="/assets/index-a6852352.js"></script>
|
||||
<link rel="stylesheet" href="/assets/index-8e2ea812.css">
|
||||
</head>
|
||||
<body>
|
||||
<div id="app"></div>
|
||||
|
@ -290,7 +290,7 @@ export default {
|
||||
};
|
||||
},
|
||||
async mounted() {
|
||||
this.fileSize = await this.getFileSize(this.model.path)
|
||||
//this.fileSize = await this.getFileSize(this.model.path)
|
||||
//console.log('model path', this.model.path)
|
||||
nextTick(() => {
|
||||
feather.replace()
|
||||
@ -367,6 +367,10 @@ export default {
|
||||
event.target.src = defaultImgPlaceholder
|
||||
},
|
||||
toggleInstall() {
|
||||
this.getFileSize(this.model.path).then(data=>{
|
||||
this.fileSize = data
|
||||
})
|
||||
|
||||
if (this.isInstalled) {
|
||||
this.uninstalling = true;
|
||||
// Simulate uninstallation delay (replace this with your WebSocket logic)
|
||||
@ -378,6 +382,9 @@ export default {
|
||||
}
|
||||
},
|
||||
toggleSelected() {
|
||||
this.getFileSize(this.model.path).then(data=>{
|
||||
this.fileSize = data
|
||||
})
|
||||
this.onSelected(this)
|
||||
},
|
||||
toggleCopy() {
|
||||
|
@ -713,12 +713,12 @@
|
||||
<!-- EXPAND / COLLAPSE BUTTON -->
|
||||
<button v-if="mzl_collapsed"
|
||||
class="text-2xl hover:text-secondary duration-75 flex justify-center hover:bg-bg-light-tone hover:dark:bg-bg-dark-tone rounded-lg "
|
||||
title="Collapse" type="button" @click="mzl_collapsed = !mzl_collapsed">
|
||||
title="Collapse" type="button" @click="open_mzl">
|
||||
<i data-feather="chevron-up"></i>
|
||||
</button>
|
||||
<button v-else
|
||||
class="text-2xl hover:text-secondary duration-75 flex justify-center hover:bg-bg-light-tone hover:dark:bg-bg-dark-tone rounded-lg "
|
||||
title="Expand" type="button" @click="mzl_collapsed = !mzl_collapsed">
|
||||
title="Expand" type="button" @click="open_mzl">
|
||||
<i data-feather="chevron-down"></i>
|
||||
</button>
|
||||
</div>
|
||||
@ -1426,6 +1426,11 @@ export default {
|
||||
|
||||
|
||||
},
|
||||
async open_mzl(){
|
||||
this.mzl_collapsed = !this.mzl_collapsed;
|
||||
console.log("Fetching models")
|
||||
//this.fetchModels();
|
||||
},
|
||||
async getVramUsage() {
|
||||
const resp = await this.api_get_req("vram_usage")
|
||||
// {
|
||||
@ -1584,7 +1589,6 @@ export default {
|
||||
|
||||
},
|
||||
fetchModels() {
|
||||
|
||||
axios.get('/get_available_models')
|
||||
.then(response => {
|
||||
|
||||
@ -2129,12 +2133,6 @@ export default {
|
||||
refresh() {
|
||||
|
||||
|
||||
|
||||
this.api_get_req("list_models").then(response => {
|
||||
this.modelsArr = response
|
||||
this.modelsArr.sort()
|
||||
})
|
||||
|
||||
this.api_get_req("list_personalities_categories").then(response => {
|
||||
this.persCatgArr = response
|
||||
this.persCatgArr.sort()
|
||||
@ -2186,7 +2184,7 @@ export default {
|
||||
})
|
||||
|
||||
|
||||
this.fetchModels();
|
||||
//this.fetchModels();
|
||||
this.api_get_req("list_bindings")
|
||||
then(response => {
|
||||
this.bindings = response
|
||||
|
Loading…
Reference in New Issue
Block a user