New adapter wikimedia.images: Wikidata P18 for people without an official photo, P154 logos for parties and organisations matched by Wikidata id, Firmenbuch (P5285) or ZVR number (P6279). Licence data from the Commons file page goes into image_credit (keyed by image URL); official Parliament/EP photos are never replaced. Web: logos on party cards, party, organisation and organisation-list pages, credit lines under portraits and logos, image proxy allows upload.wikimedia.org. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
14 lines
946 B
SQL
14 lines
946 B
SQL
-- Portraits and logos from Wikimedia Commons (via Wikidata P18 / P154). The image itself sits in person.photo_url or
|
|
-- organization.logo_url; official photos (Parliament, European Parliament) take precedence and are never replaced.
|
|
-- The licence data is keyed by the image URL, so the credit always belongs to the image that is actually shown.
|
|
CREATE TABLE image_credit (
|
|
url TEXT PRIMARY KEY,
|
|
page_url TEXT, -- file description page on Commons
|
|
credit TEXT, -- author / attribution as plain text
|
|
license TEXT, -- short name, e.g. "CC BY-SA 4.0"
|
|
license_url TEXT,
|
|
source_slug TEXT NOT NULL,
|
|
updated_at TIMESTAMPTZ NOT NULL DEFAULT now()
|
|
);
|
|
COMMENT ON TABLE image_credit IS 'Licence and attribution for third-party images in person.photo_url / organization.logo_url (Wikimedia Commons). No row = official photo of the source (Parliament, EP).';
|