You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
motief/migrations/2026-03-19-add-embeddings.sql

11 lines
546 B

-- Add a separate embeddings table for semantic search and storage of vectors (DuckDB-compatible)
CREATE TABLE IF NOT EXISTS embeddings (
id INTEGER,
motion_id INTEGER NOT NULL,
model TEXT NOT NULL,
vector JSON NOT NULL,
created_at TIMESTAMP DEFAULT current_timestamp
);
-- DuckDB does not support AUTOINCREMENT; emulate id via a sequence if needed elsewhere
CREATE SEQUENCE IF NOT EXISTS embeddings_id_seq START 1;
-- Populate id via trigger-like insert pattern is handled by application code (select nextval when inserting)