sveinbjornt / hear

Command line speech recognition and transcription for macOS
https://sveinbjorn.org/hear
BSD 3-Clause "New" or "Revised" License
303 stars 18 forks source link

Integrate with ffmpeg? #7

Closed sagz closed 1 year ago

sagz commented 1 year ago

Hi, great utility! Any way to integrate this with ffmpeg to be able to auto-subtitle videos? Maybe there's a piping command that could make this work today, but I'm not able to figure that out.

sveinbjornt commented 1 year ago

Apple's speech recognition API does not provide any timestamps so this is not gonna work.

sagz commented 1 year ago

Could this be done where in ffmpeg sends cut up snippets of audio and those snippets are sent to hear?

Issue is if it cuts in the middle of a word. Maybe the cutting can be made to be aware of silence. That's likely out of scope.