Self-hosted video downloader for YouTube and other sites (web UI for yt-dlp)
This report presents the forensic synthetic code analysis of alexta69/metube, a Python project with 14,541 GitHub stars. SynthScan v2.0 examined 26,180 lines of code across 87 source files, recording 484 pattern matches distributed across 8 syntactic categories. The overall adjusted score of 17.6 places this repository in the Moderate AI signal band.
The scanner applied 160+ deterministic lexical heuristics, multi-line block detectors, abstract syntax tree depth profilers, and a cross-file Jaccard similarity matrix to construct a statistically normalised synthetic code estimate. All matches are individually weighted by severity coefficient and contextual multiplier before summation, and the resulting headline score is temporally discounted to account for the repository's development history relative to the commercial emergence of large language model coding tooling (November 2022 onward).
This chart maps the temporal evolution of the adjusted synthetic code score across successive scan runs. An upward trajectory indicates ongoing incorporation of AI-generated code or expanding LLM-assisted scaffolding; a stable or declining trajectory may reflect active human refactoring, code removal, or the adoption of stricter authorship policies. The dashed secondary line (right axis) independently tracks total raw pattern hit count, which can diverge from the normalised score when codebase size changes significantly between scans.
Classifies detected patterns by their diagnostic confidence and structural impact. CRITICAL patterns (coefficient 10) represent definitive synthetic signatures — hallucinated imports, explicit LLM attribution metadata — virtually never produced by human authors. HIGH (5) indicates strong structural tells such as cross-file repetition or cross-linguistic idioms. MEDIUM (2) covers recognisable conversational padding and AI-specific vocabulary. LOW (1) captures subtle indicators like tautological comments and generic boilerplate that require density to carry independent signal.
This horizontal bar chart decomposes the repository's raw synthetic code score by top-level directory, allowing you to pinpoint precisely which modules or components carry the highest AI authorship density. Directories with disproportionately high scores relative to their size warrant targeted manual review: concentrated AI signatures often trace back to mass-generated configuration layers, auto-ported test suites, LLM-scaffolded boilerplate classes, or entire subsystems authored under heavy copilot assistance. Use this view to prioritise your human code-review effort.
The scanner identified 484 distinct pattern matches across 8 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a statistically significant AI authorship indicator. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the diagnostic confidence level (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — comment-context matches receive a ×1.5 weight because LLMs systematically over-annotate. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier as dense clusters constitute far stronger evidence of synthetic authorship than isolated hits.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | app/state_store.py | 192 | def _warn_direct_write_fallback(self, exc: OSError) -> None: | CODE |
| LOW | app/ytdl.py | 356 | def _sanitize_entry_for_pickle(obj, _depth=0): | CODE |
| LOW | app/ytdl.py | 642 | def _short_title_for_failed_url(url: str) -> str: | CODE |
| LOW | app/ytdl.py | 685 | def _download_info_from_record(record: dict[str, Any]) -> DownloadInfo: | CODE |
| LOW | app/ytdl.py | 1388 | def _seconds_until_next_probe(self) -> Optional[float]: | CODE |
| LOW | app/ytdl.py | 1426 | async def _probe_scheduled_download(self, download: Download) -> None: | CODE |
| LOW | app/ytdl.py | 1495 | async def _schedule_upcoming_download(self, download: Download) -> None: | CODE |
| LOW | app/ytdl.py | 1658 | def __write_feed_metadata_sync(self, entry, etype, download_type, folder, | CODE |
| LOW | app/subscriptions.py | 154 | def _is_subscriber_only_entry(entry: dict) -> bool: | CODE |
| LOW | app/subscriptions.py | 262 | def _normalize_subscription_record(rec: dict[str, Any]) -> dict[str, Any]: | CODE |
| LOW | app/subscriptions.py | 280 | def _subscription_from_record(record: Any) -> Optional[SubscriptionInfo]: | CODE |
| LOW | app/subscriptions.py | 293 | def _normalize_title_regex_value(value: Any) -> str: | CODE |
| LOW | app/subscriptions.py | 314 | def validate_subscription_name(value: Any) -> str: | CODE |
| LOW | app/subscriptions.py | 327 | def validate_subscription_folder(value: Any) -> str: | CODE |
| LOW | app/subscriptions.py | 472 | async def _queue_subscription_entries( | CODE |
| LOW | app/dl_formats.py | 34 | def _normalize_subtitle_language(language: str) -> str: | CODE |
| LOW | app/main.py | 37 | def seconds_until_next_daily_time(time_hhmm: str, now: datetime | None = None) -> float: | CODE |
| LOW | app/main.py | 378 | def _parse_ytdl_options_overrides(value, *, enabled: bool) -> dict: | CODE |
| LOW | app/main.py | 442 | def _parse_clip_timestamp_value(value) -> float: | CODE |
| LOW⚡ | app/main.py | 472 | def _clip_field_provided_in_post(raw) -> bool: | CODE |
| LOW⚡ | app/main.py | 480 | def _extract_t_query_from_url(url: str) -> tuple[str, float | None]: | CODE |
| LOW | app/main.py | 514 | def _parse_ytdl_options_presets(post: dict) -> list[str]: | CODE |
| LOW | app/main.py | 615 | async def _shutdown_download_manager(app): | CODE |
| LOW | app/main.py | 650 | async def _subscription_loop_startup(app): | CODE |
| LOW | app/main.py | 671 | async def _start_nightly_update_schedule(app): | CODE |
| LOW | app/main.py | 1096 | def warn_if_cookiefile_shadowed(): | CODE |
| LOW | app/url_guard.py | 132 | def _address_allowed_at_connect(addr: str, is_allowed_endpoint: bool = False) -> bool: | CODE |
| LOW⚡ | app/tests/test_nightly_update.py | 12 | def test_seconds_until_later_today(self): | CODE |
| LOW⚡ | app/tests/test_nightly_update.py | 17 | def test_seconds_until_wraps_to_next_day(self): | CODE |
| LOW⚡ | app/tests/test_nightly_update.py | 22 | def test_seconds_until_same_minute_is_next_day(self): | CODE |
| LOW | app/tests/test_music_metadata.py | 14 | def test_album_uses_existing_order_and_total_when_track_number_is_missing(): | CODE |
| LOW⚡ | app/tests/test_music_metadata.py | 28 | def test_official_track_number_wins_over_album_order(): | CODE |
| LOW⚡ | app/tests/test_music_metadata.py | 38 | def test_inline_official_track_total_is_preserved(): | CODE |
| LOW⚡ | app/tests/test_music_metadata.py | 47 | def test_source_track_number_and_total_are_retained_from_flat_extraction(): | CODE |
| LOW⚡ | app/tests/test_music_metadata.py | 56 | def test_album_title_falls_back_to_source_playlist_title(): | CODE |
| LOW⚡ | app/tests/test_music_metadata.py | 66 | def test_playlist_without_extractor_album_signals_is_not_changed(): | CODE |
| LOW | app/tests/test_music_metadata.py | 80 | def test_regular_video_artwork_is_not_changed(): | CODE |
| LOW | app/tests/test_music_metadata.py | 91 | def test_music_audio_prefers_largest_existing_square_thumbnail(): | CODE |
| LOW | app/tests/test_music_metadata.py | 108 | def test_landscape_only_music_artwork_keeps_existing_order(): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 27 | def test_bare_video_id_allowed(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 30 | def test_ytsearch_prefix_allowed(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 33 | def test_empty_string_allowed(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 52 | def test_localhost_blocked_without_lookup(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 57 | def test_localhost_subdomain_blocked(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 60 | def test_gcp_metadata_name_blocked(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 69 | def test_public_https_allowed(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 75 | def test_link_local_metadata_blocked(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 84 | def test_decimal_ip_form_blocked(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 117 | def test_loopback_blocked_by_default(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 123 | def test_loopback_allowed_only_when_opted_in(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 127 | def test_proxy_opt_in_covers_any_internal_range(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 135 | def test_opt_in_still_rejects_non_addresses(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 138 | def test_link_local_metadata_blocked(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 170 | def test_sixtofour_and_teredo_stay_blocked(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 177 | def test_plain_addresses_unaffected(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 182 | def test_tunnelled_form_blocked_at_ingress(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 221 | def test_internal_only_raises(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 226 | def test_filters_internal_keeps_global(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 232 | def test_loopback_blocked_without_matching_proxy(self): | CODE |
| LOW⚡ | app/tests/test_url_guard.py | 238 | def test_loopback_allowed_at_configured_url_endpoint(self): | CODE |
| 359 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | app/state_store.py | 75 | except Exception as exc: | CODE |
| LOW | app/state_store.py | 113 | except Exception as exc: | CODE |
| LOW | app/state_store.py | 144 | except Exception: | CODE |
| MEDIUM | app/ytdl.py | 1019 | def running(self): | CODE |
| MEDIUM | app/ytdl.py | 1719 | def __write_feed_metadata(self, entry, etype, download_type, folder, | CODE |
| LOW | app/ytdl.py | 380 | except Exception: | CODE |
| LOW | app/ytdl.py | 385 | except Exception: | CODE |
| LOW | app/ytdl.py | 987 | except Exception as e: | CODE |
| LOW | app/ytdl.py | 1258 | except Exception: | CODE |
| LOW | app/ytdl.py | 1272 | except Exception: | CODE |
| LOW | app/ytdl.py | 1418 | except Exception as exc: | CODE |
| LOW | app/ytdl.py | 1443 | except Exception as exc: | CODE |
| LOW | app/ytdl.py | 1729 | except Exception as exc: | CODE |
| LOW | app/subscriptions.py | 552 | except Exception as e: | CODE |
| LOW | app/subscriptions.py | 719 | except Exception: | CODE |
| LOW | app/subscriptions.py | 744 | except Exception: | CODE |
| LOW | app/subscriptions.py | 828 | except Exception: | CODE |
| LOW | app/subscriptions.py | 893 | except Exception: | CODE |
| LOW | app/subscriptions.py | 912 | except Exception: | CODE |
| LOW | app/subscriptions.py | 928 | except Exception: | CODE |
| LOW | app/subscriptions.py | 1058 | except Exception: | CODE |
| LOW | app/main.py | 327 | except Exception: | CODE |
| LOW⚡ | app/main.py | 490 | except Exception: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | app/state_store.py | 1 | CODE | |
| LOW | app/ytdl.py | 2 | CODE | |
| LOW | app/subscriptions.py | 3 | CODE | |
| LOW | app/music_metadata.py | 8 | CODE | |
| LOW | app/tests/conftest.py | 3 | CODE | |
| LOW | app/tests/test_nightly_update.py | 3 | CODE | |
| LOW | app/tests/test_music_metadata.py | 3 | CODE | |
| LOW | app/tests/test_url_guard.py | 3 | CODE | |
| LOW | app/tests/test_state_store.py | 1 | CODE | |
| LOW | app/tests/test_subscriptions.py | 1 | CODE | |
| LOW | app/tests/test_dl_formats.py | 3 | CODE | |
| LOW | app/tests/test_config.py | 3 | CODE | |
| LOW | app/tests/test_main_helpers.py | 3 | CODE | |
| LOW | app/tests/test_api.py | 3 | CODE | |
| LOW | app/tests/test_download_queue.py | 3 | CODE | |
| LOW | app/tests/test_ytdl_utils.py | 3 | CODE | |
| LOW | app/tests/test_bg_tasks.py | 3 | CODE | |
| LOW | app/tests/test_persistent_queue.py | 3 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | app/ytdl.py | 389 | CODE | |
| LOW | app/ytdl.py | 532 | CODE | |
| LOW | app/ytdl.py | 774 | CODE | |
| LOW | app/ytdl.py | 1028 | CODE | |
| LOW | app/ytdl.py | 1394 | CODE | |
| LOW | app/ytdl.py | 1733 | CODE | |
| LOW | app/ytdl.py | 2188 | CODE | |
| LOW | app/ytdl.py | 791 | CODE | |
| LOW | app/subscriptions.py | 97 | CODE | |
| LOW | app/subscriptions.py | 262 | CODE | |
| LOW | app/subscriptions.py | 871 | CODE | |
| LOW | app/dl_formats.py | 96 | CODE | |
| LOW | app/main.py | 531 | CODE | |
| LOW | app/main.py | 741 | CODE | |
| LOW | app/tests/test_state_store.py | 77 | CODE | |
| LOW | app/tests/test_subscriptions.py | 197 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | app/dl_formats.py | 40 | Returns yt-dlp format selector. Args: download_type (str): selected content type (video, audio, captions | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | app/main.py | 679 | # Check if this path matches our YTDL_OPTIONS_FILE | COMMENT |
| LOW | .github/workflows/update-yt-dlp.yml | 28 | # Check if yt-dlp has updates available | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | app/ytdl.py | 81 | return '\n'.join(lines) | COMMENT |
| LOW | app/main.py | 1341 | async def on_prepare(request, response): | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | app/ytdl.py | 462 | CODE | |
| LOW | app/ytdl.py | 1967 | CODE | |
| LOW | app/ytdl.py | 2099 | CODE |