-- S5: onboarding → minne + smaksignaler
-- Användarens onboarding-svar speglas som user_stated memory_items och taste_signals.

ALTER TYPE "public"."taste_axis" ADD VALUE IF NOT EXISTS 'cuisine';
ALTER TYPE "public"."taste_axis" ADD VALUE IF NOT EXISTS 'ingredient_avoid';

ALTER TABLE "public"."taste_signals" ADD COLUMN IF NOT EXISTS "target" text;

CREATE UNIQUE INDEX IF NOT EXISTS "memory_items_user_key_unique" ON "public"."memory_items" USING btree ("user_id","key");
CREATE UNIQUE INDEX IF NOT EXISTS "taste_signals_user_axis_target_unique" ON "public"."taste_signals" USING btree ("user_id","axis","target");
