Video to Article & Timecoded Chapters PHP Script — Free Download (VidPulse AI)
VidPulse AI: upload a video, get clickable timecoded chapters, a full SEO blog article, an X thread, a LinkedIn post and a YouTube description — powered by Gemini's native multimodal engine. No FFmpeg, no Whisper, no Composer; pure PHP + MySQL.
What it is
The architectural bet is the interesting part: there is no FFmpeg and no Whisper anywhere in the stack. Instead of extracting audio, transcribing it, and summarizing the text, VidPulse streams the raw MP4/WebM/MOV/MP3/WAV file straight to the Gemini File API using the resumable upload protocol, polls until Google marks the media ACTIVE, and then asks gemini-2.5-flash (or pro) to watch the frames and listen to the audio in one pass. Because the request pins a strict responseSchema with responseMimeType: application/json, the answer comes back as guaranteed-valid structured JSON — no regex parsing, no "the model added prose around my JSON" failures.
The front end is a dark-mode dashboard (Tailwind CDN + vanilla JS): drag-and-drop upload with live status, an HTML5 player where clicking any AI-generated chapter timestamp seeks the video to that exact second, tabbed views for the SEO article and the social media kit, one-click Markdown copy and structured-JSON export, and a MySQL-backed history sidebar so every analysis is stored and reloadable. A one-click web installer checks server dependencies (PHP 8+, PDO, cURL, fileinfo), provisions both tables, and optionally saves your API key.
Everything runs on commodity shared hosting: no root access, no binaries to install, no queue workers. If the host has PHP 8 and MySQL, it runs.
Native multimodal vs the classic Whisper pipeline
The traditional way to turn video into articles chains three systems: FFmpeg rips the audio, Whisper transcribes it, an LLM summarizes the transcript. VidPulse replaces the whole chain with one Gemini File API call that sees the frames and hears the audio together.
| Feature | VidPulse AI (Gemini native) | FFmpeg + Whisper + LLM stack |
|---|---|---|
| Server binaries required | None — pure PHP cURL | FFmpeg install (root access), often a GPU box for Whisper |
| Understands visuals (slides, demos, on-screen text) | ✓ — chapters reference what is shown, not just said | ✗ — transcript-only, everything visual is lost |
| Works on shared hosting (cPanel/Plesk) | ✓ | Rarely — no root, no long-running workers |
| Output reliability | Schema-enforced JSON (responseSchema) — parses every time | Prompt-and-pray JSON, regex cleanup common |
| Pipeline steps to maintain | 1 API (upload → poll → generate) | 3 systems + glue code + temp file management |
| Silent-video support | ✓ — visual-only analysis still works | ✗ — empty transcript, empty article |
| Privacy of processed files | Remote copy auto-deleted from Gemini after analysis; local file stays on your server | Depends on each service in the chain |
Server requirements & dependencies
- PHP 8.0 or newer (8.1 / 8.2 / 8.3 fully compatible)
- PHP extensions: pdo, pdo_mysql, curl, json, fileinfo — standard on virtually every shared/VPS host
- MySQL 5.7+ / 8.0+ or MariaDB 10.3+
- A free Google Gemini API key (aistudio.google.com)
- No Composer, no FFmpeg, no Whisper, no Node — 100% native PHP
- Recommended php.ini for large videos (set via the included .htaccess under Apache mod_php): upload_max_filesize 128M, post_max_size 128M, max_execution_time 300
How to install
2. Open /install.php in your browser. The setup wizard runs a live server dependency check (PHP version, PDO, cURL, fileinfo, writable uploads/) and creates both MySQL tables with one click. You can paste your Gemini API key here or later.
3. Open the dashboard, drop in a video, pick the output language and model (gemini-2.5-flash for speed, gemini-2.5-pro for depth), and hit Analyze. Chapters, the SEO article and the social kit appear in seconds; every run is saved to the MySQL history sidebar.
Tip: delete install.php after setup, and keep the app behind your own access control if you deploy it publicly — it ships as a single-user tool with no login system.
Heads-up on model IDs: Google retires Gemini model names over time — while seeding the live demo (late Sep 2026) gemini-2.5-flash returned "no longer available to new users" for a fresh API key, and gemini-3.8-flash worked. The model field in Settings is free text, so just type the current model ID if the default ever 404s.
The prompt — build it yourself
Paste this into Gemini and you'll get this product. This is the actual spec that produced the code above.
The exact prompt given to Gemini:
Build a complete, zero-dependency PHP 8+ and MySQL web application called "VidPulse AI" that showcases Google Gemini's native multimodal video understanding via the Gemini File API (Resumable Upload protocol) and Structured Outputs (responseSchema).
Requirements:
1. Backend (PHP + PDO MySQL):
- Implement a GeminiVideoService class using native PHP cURL that performs a 3-step pipeline:
a) Resumable binary upload of MP4/WebM/MOV/MP3 files to https://generativelanguage.googleapis.com/upload/v1beta/files
b) State polling until the uploaded media status becomes ACTIVE
c) A generateContent call to gemini-2.5-flash with responseMimeType: "application/json" and a strict responseSchema returning: video title, executive summary, clickable timecoded chapters (MM:SS and total seconds), a full SEO blog article (headline, meta description, markdown body, keywords), social media posts (X/Twitter thread, LinkedIn post, YouTube description), and key action items.
d) Automatic cleanup (DELETE) of the remote file on Gemini servers after processing.
2. Database (MySQL):
- Provide database.sql and a one-click web installer (install.php) with a server dependency checker.
- Store API settings in a
settings table and all past video analyses in a video_analyses table.3. Frontend UI:
- Modern dark-mode dashboard using Tailwind CSS CDN and Vanilla JS.
- Drag-and-drop video uploader, interactive HTML5 video player where clicking any generated chapter timestamp jumps the video player directly to that exact second, tabbed views for SEO blog & social media kits, one-click Markdown/JSON export, and MySQL history sidebar.
Independent verification before publishing (done on this site's server, same bar as every other build): all 9 files read line-by-line and linted clean; the resumable-upload / poll / structured-output pipeline in GeminiVideoService.php matches Google's File API contract; fresh install tested end-to-end — dependency checker reported 6/6 PASS, both tables provisioned, dashboard rendered, and an analyze request without an API key failed with a clean, human error message instead of a stack trace. Code quality held up under review: PDO prepared statements throughout, finfo MIME validation on uploads, sanitized server-side filenames, and HTML escaping on both the PHP and JS sides. Real line count is 1,165 across 9 files.
Live demo seeding found one real-world gotcha: with a freshly created API key, Google returned 404 "gemini-2.5-flash is no longer available to new users" — the sample analysis on the demo was generated with gemini-3.8-flash instead (12.5 s for a 54-second video, and its five chapters landed exactly on the five scene changes). The app survives this class of breakage because the model field is editable at runtime.
Reviews
Used Video to Article & Timecoded Chapters PHP Script — Free Download (VidPulse AI)? A star rating takes two seconds and helps others.
More builds
License: MIT — free for personal and commercial use, no warranty. Software is provided as is; review the code before running it in production (it's short enough to actually read).