feat: embedding dimension validation + migration system
- Add /api/admin/embeddings/dimension (GET column dim, POST test model dim) - Add /api/admin/embeddings/migrate (alter column, clear, re-index) - Admin form warns on dimension mismatch after save, offers migrate button - Remove hardcoded 1536 from validate endpoint and embedding service - Add validateDimension() utility to EmbeddingService - Fix health route: import prisma correctly, use router instead of missing registry - i18n keys for dimension warning (EN/FR)
This commit is contained in:
@@ -1137,7 +1137,12 @@
|
||||
"languageDetection": "Language detection",
|
||||
"languageDetectionDesc": "Automatically detects the language of each note",
|
||||
"autoLabeling": "Auto labeling",
|
||||
"autoLabelingDesc": "Suggests and applies labels automatically"
|
||||
"autoLabelingDesc": "Suggests and applies labels automatically",
|
||||
"dimensionMismatch": "Embedding dimension mismatch detected",
|
||||
"dimensionMismatchDetail": "Database column: vector({{dbDimension}}) — Model outputs: {{modelDimension}} dimensions",
|
||||
"dimensionMismatchAction": "Embeddings will not work until you migrate the column. This will clear all existing embeddings and re-index them.",
|
||||
"migrateButton": "Migrate & Re-index",
|
||||
"migrating": "Migrating..."
|
||||
},
|
||||
"resend": {
|
||||
"title": "Resend (Recommended)",
|
||||
|
||||
@@ -1143,7 +1143,12 @@
|
||||
"languageDetection": "Détection de langue",
|
||||
"languageDetectionDesc": "Détecte automatiquement la langue de chaque note",
|
||||
"autoLabeling": "Étiquetage automatique",
|
||||
"autoLabelingDesc": "Suggère et applique des étiquettes automatiquement"
|
||||
"autoLabelingDesc": "Suggère et applique des étiquettes automatiquement",
|
||||
"dimensionMismatch": "Incompatibilité de dimensions d'embedding détectée",
|
||||
"dimensionMismatchDetail": "Colonne base de données : vector({{dbDimension}}) — Le modèle produit : {{modelDimension}} dimensions",
|
||||
"dimensionMismatchAction": "Les embeddings ne fonctionneront pas tant que vous ne migrez pas la colonne. Cela effacera tous les embeddings existants et les ré-indexera.",
|
||||
"migrateButton": "Migrer & Ré-indexer",
|
||||
"migrating": "Migration en cours..."
|
||||
},
|
||||
"resend": {
|
||||
"title": "Resend (Recommandé)",
|
||||
|
||||
Reference in New Issue
Block a user