mirror of
https://github.com/danswer-ai/danswer.git
synced 2025-10-11 05:36:03 +02:00
Adding Document Sets (#477)
Adds: - name for connector credential pairs + frontend changes to start populating this field - document set table migration - during indexing, document sets are now checked and inserted into Vespa - background job to check if document sets need to be synced - document set management APIs - document set management dashboard in the UI
This commit is contained in:
13
web/src/app/admin/documents/sets/hooks.tsx
Normal file
13
web/src/app/admin/documents/sets/hooks.tsx
Normal file
@@ -0,0 +1,13 @@
|
||||
import { fetcher } from "@/lib/fetcher";
|
||||
import { DocumentSet } from "@/lib/types";
|
||||
import useSWR, { mutate } from "swr";
|
||||
|
||||
export const useDocumentSets = () => {
|
||||
const url = "/api/manage/document-set";
|
||||
const swrResponse = useSWR<DocumentSet<any, any>[]>(url, fetcher);
|
||||
|
||||
return {
|
||||
...swrResponse,
|
||||
refreshDocumentSets: () => mutate(url),
|
||||
};
|
||||
};
|
Reference in New Issue
Block a user