reels-app/app
Sebastjan Artič 4788a55643 Clean noise patterns more aggressively + clean already-stored values
User feedback: 'Ansambel UNIKAT — PA PA (offiicial video)' shows the
'(offiicial video)' suffix everywhere (titles, downloads, UI). The user
wants only 'Artist - Title' without any video format markers.

Two fixes:

1. EXPANDED _NOISE_PATTERNS to handle:
   - Typos in 'official': 'offiicial', 'offical', 'oficial' (regex Off[a-z]*icial)
   - Variants: '(Official 4K Video)', '(Official HD Video)', '(Official Music Video)'
   - More versions: (Live), (Cover), (Acoustic), (Extended Mix), (Radio Edit), (Clean), (Explicit)
   - Square brackets: [Official...], [HD], [Lyrics...]
   - Bare words without brackets
   - Trailing year markers '(2024)'

2. NEW clean_noise() function applied at READ TIME:
   Even if a job was saved with 'PA PA (offiicial video)' as parsed_title,
   the new code re-cleans it when serving the job to the UI or building
   the download filename. This means existing jobs get fixed too without
   needing re-processing.

3. Applied to:
   - build_download_filename() — clean before formatting
   - list_jobs() — strip noise when serving job list
   - get_job() — strip noise when serving single job

Result: 'Ansambel UNIKAT - PA PA - REEL.mp4' (no more (offiicial video))
2026-04-29 18:47:19 +00:00
..
main.py Clean noise patterns more aggressively + clean already-stored values 2026-04-29 18:47:19 +00:00
telegram.py Multi-upload batch queue + Telegram notifications 2026-04-29 15:12:38 +00:00