Skip to content

[Feature Request] Export rate information in JSON format #19

@photkey

Description

@photkey

In actual use, sometimes certain segments are read too quickly, making it difficult to hear clearly. Therefore, it is requested to export the original srt file in JSON format along with the audio file, which includes the actual reading speed for each text segment. With this JSON file, we can achieve better reading effects by re-editing the video or re-editing the srt text.

srt:

1
00:05:00,400 --> 00:05:15,300
If you want to use the edge-tts command, you can simply run it with the following command:

2
00:05:16,400 --> 00:05:25,300
Note the above requires the installation of the mpv command line player.

json:
In the following example snippets, rate represents the actual reading speed.

{
  "subtitles": [
    {
      "id": "1",
      "text": "If you want to use the edge-tts command, you can simply run it with the following command:",
      "start_time": "00:05:00.400",
      "end_time": "00:05:15.300",
      "rate": 1.8
    },
    {
      "id": "2",
      "text": "Note the above requires the installation of the mpv command line player.",
      "start_time": "00:05:16.400",
      "end_time": "00:05:25.300",
      "rate": 1.2
    }
  ]
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions