feat: regenerate/alternatives grouped by source (variant_of)

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XNQ8ghPfzAfsyVYd6HgFb6
This commit is contained in:
2026-07-23 19:39:04 +00:00
parent 34aa45b292
commit e59d26fadd
3 changed files with 36 additions and 3 deletions
+4
View File
@@ -0,0 +1,4 @@
-- Alternativen/Regenerierung: mehrere Ergebnisse zum selben Ursprung gruppieren.
-- variant_of zeigt auf das „Wurzel"-Item (die erste Fassung); Alternativen teilen es.
ALTER TABLE items ADD COLUMN IF NOT EXISTS variant_of uuid REFERENCES items(id) ON DELETE SET NULL;
CREATE INDEX IF NOT EXISTS items_variant_idx ON items(variant_of);