feat(search): add document_chunks page/source columns + unique idx

migrations 279-281: page_start/end + source_type/chunker_version/source_hash/chunk_content_hash, legacy backfill (30,952 rows), unique (doc_id,source_type,chunker_version,chunk_index). PR-DocSrv-LargeDoc-Split-Markdown-1 commit 1.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
hyungi
2026-05-24 07:01:34 +00:00
parent 329c9eac76
commit 72190cf90a
3 changed files with 23 additions and 0 deletions
@@ -0,0 +1,10 @@
-- PR-DocSrv-LargeDoc-Split-Markdown-1 (commit 1: schema)
-- 통합 schema: LargeDoc(page_start/end) + Phase 3A(source_type/chunker_version/source_hash/chunk_content_hash) 선반영.
-- Phase 3A 세션은 이 컬럼 위에서 동작 (schema 미터치). 분담 plan: brisk-paging-quokka.md
ALTER TABLE document_chunks
ADD COLUMN IF NOT EXISTS page_start integer,
ADD COLUMN IF NOT EXISTS page_end integer,
ADD COLUMN IF NOT EXISTS source_type text,
ADD COLUMN IF NOT EXISTS chunker_version text,
ADD COLUMN IF NOT EXISTS source_hash text,
ADD COLUMN IF NOT EXISTS chunk_content_hash text;