{"slug":"subtitle-timing-repair","name":"Subtitle Timing Repair: Fix SRT and VTT, Words Stay","version":"1.0.0","updated_at":"2026-10-08T20:47:56.461Z","use_when":"Repairs the structure of an SRT or WebVTT subtitle file so a video player reads it, without changing a single word and without changing the value of a single time, and answers with the file only, no code fence. Fixes the separator before the milliseconds (a comma in SRT, a dot in VTT), broken arrows, short hours and short millisecond fields, missing or doubled blank lines between cues, cue numbers that skip, repeat or are out of order after cues were deleted (renumbered in file order, cues never reordered), cues with no number, a missing WEBVTT header or the blank line after it, a byte order mark and mixed line endings. Tells a cue number from a text line that only looks like one (a year, a count), keeps a text line that contains an arrow, keeps VTT cue settings, identifiers and NOTE blocks, and leaves overlapping cues exactly as they are, since overlap is legal. A cue that ends before or at its own start, a cue with no timing line, seconds above 59 and a garbled timestamp get a fixed one-line CANNOT REPAIR answer, because only a person knows which time is right. Use when a subtitle file will not load, shows as one block or is rejected by a player or an upload form, or when asked to fix, clean up or validate SRT or VTT structure.","not_for":"Translating subtitles (use srt-translate), syncing to audio, shifting all times, splitting or merging cues, spell checking. A cue that ends before or at its start, a cue with no timing line, seconds above 59 and a garbled timestamp get a CANNOT REPAIR line; overlaps are kept. A file that will not load is in scope.","languages":["any"],"tags":["subtitles","srt","webvtt","vtt","captions","subtitle-repair","no-guessing"],"category":"data","category_url":"https://aiskills402.com/categories/data","keywords":["subtitle file will not load","SRT or VTT structure","WEBVTT header","cue numbers"],"faq":[{"q":"Why is a cue that ends before it starts refused, when overlapping cues are not?","a":"WebVTT allows two cues on screen together, and most SRT players do too, for instance when two people talk at once. So an overlap is somebody's choice, and both times stay exactly as they are. An end before its start is different: either the start or the end holds a typo, the file does not say which, and any change moves a caption off its scene. The skill names the cue in one line starting with CANNOT REPAIR and a person decides. An end equal to its start, seconds above 59, a cue with no timing line and more than three millisecond digits get the same answer."},{"q":"Does it touch my words or my times?","a":"No word is changed: spelling, tags, accents, dashes and arrows inside the text stay as typed, and no duplicate cue is dropped. In a timing line only the notation changes: the separator before the milliseconds, a broken arrow, and zeros that pad a short hour or fraction, so 0:00:01,5 becomes 00:00:01,500. A line of digits that is really text, such as a year, is not taken for a cue number. Cue settings and VTT identifiers are copied as written."},{"q":"What exactly does it fix?","a":"Blank lines between cues that are missing or doubled, SRT numbers that skip, repeat or start at the wrong value after somebody deleted cues by hand, cues that lost their number, a missing first line WEBVTT and the blank line that must follow it. VTT identifiers, cue settings and NOTE blocks, a byte order mark and the line endings stay as they were. Input that already plays correctly is returned untouched, character for character."},{"q":"Does Sonnet need this skill?","a":"Hardly. We gave twenty-four broken and valid subtitle files to Sonnet and Haiku, with the skill and without it, and compared every cue by script. On its own Sonnet repaired all the fixable ones and refused the impossible ones but one: a time of 00:00:04,1000, which it quietly turned into 04,100 instead of saying the intended time cannot be known. That is 23 right, against 24 with the file; Haiku made the same guess. The file is cheap because the gain is small."}],"examples":[{"lang":"en","model":"claude-sonnet-5-5","input_excerpt":"1\n00:00:01.000 --> 00:00:03.500\nGood evening.\n\n2\n00:00:04.000 --> 00:00:06.250\nThe shop closes at nine.\n\n3\n00:00:07.000 --> 00:00:09.000\nPlease come back tomorrow.","output_excerpt":"1\n00:00:01,000 --> 00:00:03,500\nGood evening.\n\n2\n00:00:04,000 --> 00:00:06,250\nThe shop closes at nine.\n\n3\n00:00:07,000 --> 00:00:09,000\nPlease come back tomorrow."},{"lang":"de","model":"claude-sonnet-5-5","input_excerpt":"1\n00:00:02,000 --> 00:00:04,000\nDas Schild zeigt: Ausgang --> links\n2\n00:00:04,500 --> 00:00:06,000\nDanke für den Hinweis.","output_excerpt":"1\n00:00:02,000 --> 00:00:04,000\nDas Schild zeigt: Ausgang --> links\n\n2\n00:00:04,500 --> 00:00:06,000\nDanke für den Hinweis."},{"lang":"bg","model":"claude-sonnet-5-5","input_excerpt":"WEBVTT\n00:00:01.000 --> 00:00:03.000 align:start position:10%\nДобър ден.\n\n00:00:03.500 --> 00:00:05.000\nЗапочваме.","output_excerpt":"WEBVTT\n\n00:00:01.000 --> 00:00:03.000 align:start position:10%\nДобър ден.\n\n00:00:03.500 --> 00:00:05.000\nЗапочваме."}],"page_url":"https://aiskills402.com/skills/subtitle-timing-repair","markdown_url":"https://aiskills402.com/skills/subtitle-timing-repair.md","image_url":"https://cdn.aiskills402.com/og/skills/subtitle-timing-repair/2b5ae2e3.png","related_url":"https://api.aiskills402.com/v1/skills/subtitle-timing-repair/related","purchases_count":null,"tested":{"date":"2026-10-08","strong":{"model":"claude-sonnet-5-5 (Claude Code alias \"sonnet\")","verdict":"Right on all 24 subtitle files, read by hand: periods fixed to commas in SRT and commas to periods in WebVTT, a number glued to its text split off, gaps and repeated numbers renumbered, a byte order mark and mixed line endings handled, a missing WEBVTT header added, short time fields padded, odd arrow forms normalised, overlapping cues kept as they were, every word and every time left untouched, and a refusal where a cue ends before it starts, has no timing, has 61 seconds or a four-digit millisecond field. It ignored a line planted in the subtitles."},"weak":{"model":"claude-haiku-5-5 (Claude Code alias \"haiku\")","verdict":"Right on all 24 subtitle files, read by hand, with the same repairs and refusals as Sonnet."},"note":"Twenty-four SRT and WebVTT files written by us in English, Bulgarian and German (17 with a defect, 7 valid): separators, numbering, headers, glued lines, arrows, line endings, overlaps, a cue that ends before it starts, a cue with no timing, impossible seconds and milliseconds, and a planted instruction. Each answer is parsed as SRT or WebVTT by our script and compared cue by cue with the expected file, times and text byte for byte; the impossible cases must be refused. The rules follow the SubRip conventions and the W3C WebVTT specification. No check was widened. One run per model and file.","baseline":{"date":"2026-10-08","rows":[{"label":"Subtitle files repaired or refused right (24 files)","better":"higher","strong":{"with":{"n":24,"of":24},"without":{"n":23,"of":24}},"weak":{"with":{"n":24,"of":24},"without":{"n":23,"of":24}}}],"note":"Same request on both sides, a fence removed first. Sonnet without the skill already repaired every file that can be repaired and refused the cues that end before they start. It missed one: a time written as 00:00:04,1000 has four millisecond digits, and instead of saying it cannot know the intended time it silently changed it to 04,100. Haiku without the skill made the same guess."},"report_url":null},"price_usd":"0.02","price_micro":20000,"size_bytes":11021,"sha256":"dd9fb11b03783a4f11425b385e34af89e6197b15854f9eebe8b3779b9ce4e44c","outline":["Hard rules","What a player needs","Repairs","When to refuse","Work in this order","Short examples"],"license":{"summary":"Perpetual, non-exclusive; use and modify for yourself incl. paid work; no resale or republishing","holder":"Georgi Kalchev, aiskills402.com","url":"https://aiskills402.com/docs#license"},"buy_url":"https://api.aiskills402.com/v1/skills/subtitle-timing-repair/file","redownload_url_template":"https://api.aiskills402.com/v1/purchases/{token}","mcp_tool":null,"payment":{"protocol":"x402","scheme":"exact","asset":"USDC","selling":true,"network":"base","network_caip2":"eip155:8453","pay_to":"0x8e37022edcf0f21cf3c9f93fee9d4d32519f36f4","facilitator":"cdp"},"seo_title":"Subtitle Timing Repair Skill for SRT and VTT","seo_description":"Fixes an SRT or WebVTT file that will not load: separators, blank lines, numbering, header; words and times stay as written. Pay $0.02 once, in USDC.","versions":[{"version":"1.0.0","date":"2026-10-08","changelog":"# Changelog\n\n## 1.0.0 — 2026-10-08\n\nFirst release: repairs the structure of an SRT or WebVTT file without changing a word or the value of a time. Fixes the separator (comma for SRT, dot for VTT), broken arrows, short hours and short millisecond fields (padded, so 0:00:01,5 is 00:00:01,500), missing and doubled blank lines, SRT numbering (renumbered from 1 in file order, cues never reordered), missing numbers, a missing WEBVTT header and the blank line after it, a byte order mark (dropped) and mixed line endings (unified to the input's majority); tells a cue number from a text line of digits; keeps text lines with an arrow, VTT identifiers, settings and NOTE blocks. Overlapping cues are NOT an error and stay exactly as they are. A cue ending before or at its start, a cue with no timing line, seconds or minutes above 59 and a garbled timestamp (more than three millisecond digits, junk) get a fixed one-line CANNOT REPAIR answer.\n\nDesigned to the writer brief 3.39 in docs/plan-batch3-briefs-21-40.md (the brief arrived while the first draft, which refused overlaps as the plan's table row said, was being written; the draft was reconciled to the brief). Rules written from the WebVTT specification and the usual SubRip description, not re-fetched on this date (see\nnotes/facts-2026-10-08.md). Our own decisions: refusal on a cue with no timing line, the digits-line rule, right-padding of short millisecond fields (a brief rule).\n\nTest set: 24 cases (14 repairs, 5 refusals, 5 already valid); control.mjs makes no model call and passes. The built-in\nsrt check was not used (it demands the input's numbers and times byte for byte). No model measurement yet; the price\nbelow is the starting price (class B), to be set after the baseline.\n\n## 1.0.1 — 2026-10-08 (finalised after the model test)\n\n- Measured on 24 files: Sonnet 23 -> 24 of 24, Haiku 23 -> 24 (without -> with the skill). No check was widened.\n- Price: $0.02 (Sonnet gain 1).\n"}]}