heal_subtitle_timecodes
Repair subtitle timecode drift and framerate mismatches, apply millisecond offsets, enforce minimum cue durations, fix overlaps, and audit reading-speed CPS for SRT/VTT output.
Instructions
Repair NLE framerate drift (23.976 <-> 24 <-> 25 <-> 29.97 <-> 30 fps), apply global millisecond offset shifts, enforce minimum cue duration floors, clamp overlapping cues for Premiere / Final Cut Pro / DaVinci Resolve, and audit reading-speed CPS violations.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"input": "<input>"
},
"name": "heal_subtitle_timecodes"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| gapMs | No | Minimum millisecond gap enforced between consecutive cues to guarantee zero overlaps. | |
| input | Yes | Raw .srt, .vtt, or Whisper .json subtitle track to repair and audit. | |
| offsetMs | No | Global millisecond shift applied to every cue (+ delays, - advances). | |
| sourceFps | No | Source camera/transcription framerate when stretching drifted timecodes. | |
| targetFps | No | Target NLE timeline framerate when stretching drifted timecodes. | |
| enCpsLimit | No | Maximum English reading speed threshold in characters per second (CPS). | |
| zhCpsLimit | No | Maximum Chinese reading speed threshold in CJK units per second (CPS). | |
| outputFormat | No | Output subtitle serialization format (.srt or .vtt). | srt |
| minDurationMs | No | Minimum cue duration floor in milliseconds when adjacent timeline space allows. |