new rag api

This commit is contained in:
Saifeddine ALOUI 2024-12-21 01:28:03 +01:00
parent 936c3afc69
commit 4780b3b878
5 changed files with 18 additions and 9 deletions

@ -1 +1 @@
Subproject commit e8ffec9cd022260ea7debe57a85b233ed255f773
Subproject commit 192f57063eb7ad05fcb72cb1931f5ad045a88597

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
View File

@ -6,8 +6,8 @@
<script src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-svg.js"></script>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>LoLLMS WebUI</title>
<script type="module" crossorigin src="/assets/index-BGxqI5br.js"></script>
<link rel="stylesheet" crossorigin href="/assets/index-BCXKQ2R_.css">
<script type="module" crossorigin src="/assets/index-DtQszzNk.js"></script>
<link rel="stylesheet" crossorigin href="/assets/index-CrgoEYSL.css">
</head>
<body>
<div id="app"></div>

View File

@ -484,9 +484,17 @@ export default {
return Array.isArray(this.dataSourceNames) && this.dataSourceNames.length > 0;
},
dataSourceNames() {
console.log("dataSourceNames", this.$store.state.config.rag_databases);
// Extract the names from the rag_databases array and transform them into the desired format
const formattedDataSources = this.$store.state.config.rag_databases.map(dataSource => {
console.log("rag_databases", this.$store.state.config.rag_databases);
console.log("remote_databases", this.$store.state.config.remote_databases);
// Combine both rag_databases and remote_databases
const combinedDatabases = [
...this.$store.state.config.rag_databases,
...this.$store.state.config.remote_databases
];
// Extract the names from the combined array and transform them into the desired format
const formattedDataSources = combinedDatabases.map(dataSource => {
console.log("entry", dataSource);
const parts = dataSource.split('::');
console.log("extracted", parts[0]);
@ -503,9 +511,10 @@ export default {
help: 'mounts the database'
};
});
console.log("formatted data sources", formattedDataSources);
return formattedDataSources;
},
}
},
methods: {
showSendMenu() {