refactor: streamline document and FAQ index removal methods and enhance knowledge base deletion logic

This commit is contained in:
mlogclub
2026-06-02 11:25:30 +08:00
parent 5c4d486df0
commit abedafe911
13 changed files with 215 additions and 58 deletions
+1 -1
View File
@@ -45,7 +45,7 @@ func (s *index) buildDocumentChunks(ctx context.Context, document models.Knowled
return chunks, nil
}
func collectExistingVectorIDs(chunks []models.KnowledgeChunk) []string {
func (s *index) collectExistingVectorIDs(chunks []models.KnowledgeChunk) []string {
ret := make([]string, 0, len(chunks))
for _, chunk := range chunks {
if strs.IsNotBlank(chunk.VectorID) {