feat(controls): control_pendants table - license-pendant mapping

Maps self-written controls to commercially-usable source controls expressing the same obligation (Phase-2 reconcile, embedding-kNN + Haiku 2026-06-15). Additive, idempotent. Salvaged from uncommitted WIP. [migration-approved]

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
Benjamin Admin
2026-06-21 12:40:43 +02:00
parent 6b9c7984b4
commit 28798a3ef6
@@ -0,0 +1,18 @@
-- Migration 154: control_pendants — self-written (license_rule=3) -> sourced
-- (license_rule 1/2) Pendant-Mapping aus dem Phase-2-Reconcile (Embedding-kNN +
-- Haiku-Adjudikation, 2026-06-15). Ein hier gelistetes self-written Atom hat ein
-- kommerziell nutzbares Quell-Control, das DIESELBE Pflicht ausdrueckt -> das
-- Retrieval soll das lizenzierte Quell-Control bevorzugen. Additiv, idempotent.
-- [migration-approved]
SET search_path TO compliance, public;
CREATE TABLE IF NOT EXISTS control_pendants (
control_uuid uuid PRIMARY KEY,
pendant_control_uuid uuid NOT NULL,
cosine numeric,
method varchar(40) NOT NULL DEFAULT 'embed_haiku',
created_at timestamptz NOT NULL DEFAULT now()
);
CREATE INDEX IF NOT EXISTS idx_control_pendants_pendant
ON control_pendants (pendant_control_uuid);