package top.tqx.demo_1.service;

import top.tqx.demo_1.entity.KnowledgeBasePath;
import top.tqx.demo_1.vo.CollectionVO;
import top.tqx.demo_1.vo.ChunkVO;
import top.tqx.demo_1.vo.DocumentVO;

import java.util.List;
import java.util.Map;

public interface KnowledgeBaseService {

    List<CollectionVO> getCollections(Long userId, Long deptId, String deptCode);

    CollectionVO createCollection(String name, String displayName, String department, String description, Long userId);

    CollectionVO updateCollection(String name, String displayName, String department, String description);

    void deleteCollection(String name);

    List<ChunkVO> getCollectionChunks(String kbName, String documentId, Integer limit, Integer offset);

    Map<String, Object> deprecateDocument(String kbName, String filename, String reason, Long userId);

    Map<String, Object> restoreDocument(String kbName, String filename);

    List<Map<String, Object>> getDocumentVersions(String kbName, String filename, Integer limit);

    DocumentVO uploadDocument(String collection, String filename, byte[] content, Long userId);

    List<DocumentVO> batchUploadDocuments(String collection, List<String> filenames, List<byte[]> contents, Long userId);

    List<DocumentVO> getDocumentList(String collection, Long userId);

    void deleteDocument(String path);

    List<ChunkVO> getDocumentChunks(String path);
}