feat(similarity): add document similarity detection with embeddings and cosine similarity

Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot]
2026-03-01 20:38:52 +00:00
parent 2842b4ac46
commit 9748103782
7 changed files with 858 additions and 0 deletions
+3
View File
@@ -67,6 +67,9 @@ class FileRecord(Base):
# Human-readable document title from AI metadata
document_title = Column(String, nullable=True)
# Pre-computed text embedding vector stored as JSON array of floats
embedding = Column(Text, nullable=True)
# Timestamp when we inserted this record
created_at = Column(DateTime(timezone=True), server_default=func.now(), index=True)