diff --git a/src/lib/components/chat/Settings/Chats.svelte b/src/lib/components/chat/Settings/Chats.svelte index ecaf587a4..191e64d35 100644 --- a/src/lib/components/chat/Settings/Chats.svelte +++ b/src/lib/components/chat/Settings/Chats.svelte @@ -2,7 +2,6 @@ import fileSaver from 'file-saver'; const { saveAs } = fileSaver; - import { resetVectorDB } from '$lib/apis/rag'; import { chats, user } from '$lib/stores'; import { @@ -330,38 +329,6 @@ {$i18n.t('Export All Chats (All Users)')} - -
- - {/if} diff --git a/src/lib/components/documents/Settings/General.svelte b/src/lib/components/documents/Settings/General.svelte index 3f8020e2a..f00038de4 100644 --- a/src/lib/components/documents/Settings/General.svelte +++ b/src/lib/components/documents/Settings/General.svelte @@ -5,8 +5,10 @@ updateRAGConfig, getQuerySettings, scanDocs, - updateQuerySettings + updateQuerySettings, + resetVectorDB } from '$lib/apis/rag'; + import { documents } from '$lib/stores'; import { onMount, getContext } from 'svelte'; import { toast } from 'svelte-sonner'; @@ -17,6 +19,8 @@ let loading = false; + let showResetConfirm = false; + let chunkSize = 0; let chunkOverlap = 0; let pdfExtractImages = true; @@ -231,6 +235,100 @@ /> + +
+ + {#if showResetConfirm} +
+
+ + + + + {$i18n.t('Are you sure?')} +
+ +
+ + +
+
+ {:else} + + {/if}