Spaces:
Running
Running
Commit History
-
Re-architect: API-based acquisition, no download; ffmpeg -ss screenshots
- Comments via YouTube Data API v3 (key in UI or YOUTUBE_API_KEY secret) instead of yt-dlp scraping; sentiment ranking unchanged - Transcript via youtube-transcript-api (already timestamped) instead of faster-whisper - Screenshots without downloading: yt-dlp resolves a stream URL, ffmpeg -ss grabs one frame per weighted timestamp (sharpest of 3); falls back to text-only if blocked - Remove the whole YouTube-access section (cookies/proxy/PO-token UI) and the browser extension; thin fallback kept via optional YT_COOKIES / YT_PROXY secrets - Drop faster-whisper + full video download; add youtube-transcript-api + numpy - gitignore cookies.txt; README rewritten for the new architecture Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>f07812e -
Broaden PO-token capture (initplayback / any googlevideo request with pot=)
Verified end-to-end by loading the real extension into headless Chromium (Playwright): content_hook captures the gvs pot via the fetch/XHR hook, bridges it to session storage, and fillSpaceFields populates the Space fields with input events. Broaden the URL matcher beyond /videoplayback to also catch /initplayback and any googlevideo.com request carrying a pot param. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>357c3d4 -
Capture PO token via in-page fetch/XHR hook (fix: token not captured)
YouTube fetches media via fetch()/SABR, which the MV3 service-worker webRequest path can miss. Add MAIN-world content_hook.js that patches fetch + XHR to read the gvs `pot` from videoplayback URLs (and visitor_data from ytcfg), bridged to session storage via content_bridge.js. Background now raises session-storage access level for content scripts and keeps a broadened webRequest capture as backup. Popup gives a precise diagnostic (media seen vs. token present). Bump to 1.1.0. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>6b506cb -
Fix extension zip nesting so Load unpacked works
Zip the extension's files at the archive root (manifest.json at top level) instead of under an extension/ subfolder, so the unzipped folder can be selected directly in "Load unpacked". Clarify the install step (select the folder containing manifest.json). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>1ea78e7 -
Add one-click extension .zip download button in the Space UI
Zip the bundled extension/ folder at startup (top-level extension/ dir, ready to "Load unpacked") and expose it via a gr.DownloadButton in the YouTube-access panel; allow the temp dir in launch() so Gradio can serve it. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>e935ba7 -
Extension: auto-fill the Space's PO-token / visitor-data fields
- app.py: stable elem_ids (tm_pot_token, tm_visitor_data) on the Gradio inputs - extension: "Fill the Space tab" injects values into the Space (all frames, so it works at *.hf.space and embedded in huggingface.co/spaces) using the native value setter + input/change events so Gradio's Svelte bindings update; visitor_data cached in session storage so fill works when the Space tab is focused; add *://*.hf.space/* host permission - READMEs updated with the auto-fill flow Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>4b8e533 -
Add PO Token Grabber browser extension (one-click visitor data + gvs PO token)
Chrome/Edge MV3 extension under extension/: a read-only webRequest listener captures the gvs `pot` from googlevideo videoplayback requests, and the popup reads `visitor_data` from the active YouTube tab's ytcfg (MAIN-world scripting). Formats the PO token as `web.gvs+<token>` for one-click copy into the Space's PO-token / visitor-data fields. README points users to it as the easy alternative to manual DevTools extraction. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>29c4ada -
Add PO-token support (manual PO token + visitor data) with README guide
- download + comment-fetch accept po_token/visitor_data and inject them into yt-dlp extractor_args; when a PO token is present, web-family player clients are tried so the token applies - UI: PO token + visitor data fields in the "YouTube access" panel, with a pointer to the README's PO-token guide; operator secrets YT_POT / YT_VISITOR_DATA as shared defaults - README: step-by-step manual PO-token + visitor-data extraction guide, automated (bgutil) note, and a link to the official yt-dlp PO Token Guide - Block-error hint now suggests the PO-token route Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>dc57844 -
Add per-user cookies + proxy for YouTube access (UI fields + operator secrets)
A hosted Space can't read a visitor's browser cookies, so make access explicit and self-serve: - UI: "YouTube access" panel with a cookies box (raw cookies.txt or base64) and a proxy URL box, used only for that run; throwaway-account warning included - Fall back to operator-wide YT_COOKIES / YT_PROXY secrets when the UI fields are empty - Thread proxy through download + comment-fetching; add player-client fallbacks (default/android/tv/web_safari) for best-effort access without cookies - Honest caveat in UI + README: free datacenter proxies (e.g. Webshare free tier) usually do NOT bypass YouTube's block Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>401a193 -
Accept base64-encoded YT_COOKIES and auto-add Netscape header
HF secret fields can convert the Netscape format's required TAB characters into spaces, which makes yt-dlp reject the cookie file. _cookiefile now auto-detects and decodes a base64-encoded cookies.txt (tab-safe), and prepends the Netscape header if missing. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>2f51a0e -
Replace keyword density with primary/secondary keyword placement + AEO structure
- UI: primary keyword + secondary keywords (comma-separated) instead of density inputs - LLM prompt: use primary ~3x in body and place it in title/slug/meta/first-100-words of intro and 1-2 H2 headings; each secondary keyword once - AEO best practices (from GameMaster citation guide): answer-first "Quick answer" block, descriptive title + meta description + URL slug, H2 step headings, FAQ section, and a sources/last-updated trust footer - docx_builder renders the new structure; tutorial JSON gains slug/meta_description/answer/faqs - Add count_keyword() and surface the primary-keyword count in the run status Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>01abd01 -
Fix Gradio 6 Textbox error and add SEO keyword-density controls
- Remove show_copy_button (unsupported by Textbox in Gradio 6.x) that crashed startup - Add three keyword + density% inputs; instruct the tutorial LLM to weave them in at the target keyword density, leaning toward under-use rather than keyword stuffing Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>01fb241 -
Add YouTube -> tutorial .docx pipeline (Gradio Space)
Search top videos, rank by comment sentiment, transcribe the best with faster-whisper, generate tutorial text with DeepSeek-V3, pick screenshots via a weighted LLM/Whisper-timing indicator, caption them with a vision model, and assemble a .docx. Downloaded video is auto-deleted after frame extraction. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>f6a6455 -
initial commit
Verified signature2931418