Add V006__incremental_ingest.sql to persist last_chunker_version and last_embedding_version on the documents table. Wire both columns into upsert_document (INSERT + ON CONFLICT UPDATE) and get_document (SELECT + row mapper), replacing the previous hardcoded None. Add two round-trip tests in tests/incremental_ingest.rs covering the set and None cases. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
7 lines
387 B
SQL
7 lines
387 B
SQL
-- p9-fb-23: incremental ingest needs to know which chunker / embedding
|
|
-- versions were used to populate this document so a re-ingest can
|
|
-- decide whether to skip (versions match) or re-process (any mismatch).
|
|
-- parser_version is already on documents from V001.
|
|
ALTER TABLE documents ADD COLUMN last_chunker_version TEXT;
|
|
ALTER TABLE documents ADD COLUMN last_embedding_version TEXT;
|