Skip to content

feat(rag): fix/embeddings-table-lazy-creation and unify schema migration#129

Open
sqhyz55 wants to merge 2 commits intoxorbitsai:mainfrom
sqhyz55:fix/embeddings-table-lazy-creation
Open

feat(rag): fix/embeddings-table-lazy-creation and unify schema migration#129
sqhyz55 wants to merge 2 commits intoxorbitsai:mainfrom
sqhyz55:fix/embeddings-table-lazy-creation

Conversation

@sqhyz55
Copy link
Collaborator

@sqhyz55 sqhyz55 commented Mar 10, 2026

  • schema_manager: add ensure_table_fields, refactor all 7 ensure* to use it (dict-style add_columns)
  • schema_manager: add user_id to main_pointers table and migration
  • vector_manager: improve read_chunks_for_embedding error handling and open_table checks
  • search_engine: raise VectorValidationError when open_table fails
  • document_ingestion: detailed embedding logs, v4 auto-detect, rate limit backoff
  • document_search pipeline: per-stage timing logs
  • document_search tool: fallback_to_sparse, warnings for no results / no embedding
  • kb API: return 500 on ingest error, warn on partial; same for ingest_web
  • frontend: handle IngestionResult error/partial and embedding_count=0
  • tests: update vector_manager and main_pointer_manager mocks for user_id schema

…ify schema migration

- schema_manager: add _ensure_table_fields, refactor all 7 ensure_* to use it (dict-style add_columns)
- schema_manager: add user_id to main_pointers table and migration
- vector_manager: improve read_chunks_for_embedding error handling and open_table checks
- search_engine: raise VectorValidationError when open_table fails
- document_ingestion: detailed embedding logs, v4 auto-detect, rate limit backoff
- document_search pipeline: per-stage timing logs
- document_search tool: fallback_to_sparse, warnings for no results / no embedding
- kb API: return 500 on ingest error, warn on partial; same for ingest_web
- frontend: handle IngestionResult error/partial and embedding_count=0
- tests: update vector_manager and main_pointer_manager mocks for user_id schema

Made-with: Cursor
Update cascade cleaner and register_document tests to include required schema fields
and mock open_table call sequence under lazy table creation.

Made-with: Cursor
@sqhyz55 sqhyz55 force-pushed the fix/embeddings-table-lazy-creation branch from 53307bb to ced52eb Compare March 10, 2026 06:31
@sqhyz55 sqhyz55 marked this pull request as draft March 11, 2026 06:08
@sqhyz55 sqhyz55 marked this pull request as ready for review March 12, 2026 13:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants