diff --git a/backend/lib/ytdlp.js b/backend/lib/ytdlp.js index a81f2f0..ecffb5e 100644 --- a/backend/lib/ytdlp.js +++ b/backend/lib/ytdlp.js @@ -13,14 +13,10 @@ const { romajiForStorage, isTokenizerReady } = require('./romaji'); const JP_RE = /[ぁ-んァ-ン一-龯]/; function buildTitleKeywords(title) { - // For Japanese titles: \w strips all kana/kanji, leaving nothing useful. - // Instead use the first whitespace-delimited segment as a literal keyword so - // the YTM --match-filter requires the video title to contain it. - if (JP_RE.test(title)) { - const firstWord = (title.split(/[\s ]/)[0] || '').slice(0, 12); - const escaped = firstWord.replace(/[.*+?^${}()|[\]\\]/g, '\\$&'); - return escaped ? [escaped] : []; - } + // For Japanese titles: Art Tracks on YTM/YouTube are often romanized + // ("Souiunatsu" for "そういう夏") — a Japanese keyword filter would always + // reject the correct video. Channel + duration are the quality gates instead. + if (JP_RE.test(title)) return []; const VARIANT_WORDS = new Set(['sped','speedup','slowed','reverb','nightcore','karaoke','parody','remix','cover','acoustic','instrumental']); const STOPWORDS = new Set(['the','a','an','and','or','of','in','on','at','to','for','feat','ft','with','single','ep','album','remaster','remastered','deluxe','edition','version','live','bonus']); const MIX_QUALIFIERS = ['radio', 'extended', 'club', 'vip', 'original', 'edit'];