feat: Enhance chunk management and FAQ import functionality
- Updated chunk repository methods to support deletion of unindexed chunks and listing all FAQ chunks by knowledge ID. - Introduced batch update functionality for chunks in the chunk service. - Enhanced FAQ import logic to handle append and replace operations, improving efficiency and data integrity. - Added content hash calculation for FAQ entries to facilitate quick matching and deduplication. - Refactored related methods to streamline the import process and improve logging for better tracking of import tasks.
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
-- 000013_add_chunk_status_and_hash.down.sql
|
||||
-- Rollback: Remove status and content_hash fields from chunks table
|
||||
|
||||
BEGIN;
|
||||
|
||||
-- Drop index on content_hash
|
||||
DROP INDEX IF EXISTS idx_chunks_content_hash;
|
||||
|
||||
-- Drop content_hash column
|
||||
ALTER TABLE chunks
|
||||
DROP COLUMN IF EXISTS content_hash;
|
||||
|
||||
-- Drop status column
|
||||
ALTER TABLE chunks
|
||||
DROP COLUMN IF EXISTS status;
|
||||
|
||||
COMMIT;
|
||||
Reference in New Issue
Block a user