From b0afc5e2ee852a38c42bf43d3cb7c66e8f8a4943 Mon Sep 17 00:00:00 2001 From: Worph Date: Wed, 16 Sep 2026 14:55:28 +0200 Subject: [PATCH] add origin --- src/plugin.ts | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/plugin.ts b/src/plugin.ts index b9e73d5..b240050 100644 --- a/src/plugin.ts +++ b/src/plugin.ts @@ -451,10 +451,19 @@ async function registerSubtitle( opts: SubtitleOpts, ): Promise { // 1. Companion subtitle-file record (fileType=subtitle, lang, video backref). + // + // `source/gateway:opensubtitles` is the SAME label meta-feeder-opensubtitles + // stamps on the records it mints (METADATA_KEYS.md §5), deliberately: a + // subtitle's provenance must not depend on which of the two paths fetched + // it, and meta-watch already reads that one prefix to name the provider. + // It belongs on the subtitle's own record rather than on the video's, + // because a subtitle fetched over the swarm by CID arrives without the + // video record — anything stored there does not travel with the file. const companion: Record = { fileType: 'subtitle', extension: opts.extension, subtitleLanguage: lang3, + 'source/gateway:opensubtitles': 'true', [`videos/${videoCid}`]: 'true', }; if (opts.fileName) companion.fileName = opts.fileName;