Sorry, the response matched public code so it was blocked. Please rephrase your prompt. Learn more.

1 min read Original article ↗

This was triggered by submitting the following prompt

=====
Continue making the system to create subtitles in this format:

Dialogue: 0,0:00:00.00,0:00:05.00,Default,,0,0,0,,Hello, World!

reference code:

                    tokens.forEach((token, index) => {
                        // Construct the subtitle
                        // Create a TTS file and get its length
                        const tempAudioPath = path.join(__dirname, '../', 'temporary', 'editing', 'audio', 'voiceMeasurment.mp3')
                        createTTS(token, 'voiceMeasurment', voice)

                        const ffprobe = spawnSync(path.join(__dirname, '../', 'modules', 'ffprobe.exe'), ['-v', 'error', '-show_entries', 'format=duration', '-of', 'default=noprint_wrappers=1:nokey=1', tempAudioPath])
                        const audioLength = parseFloat(Number(ffprobe.stdout.toString()).toFixed(3))

                        

                        console.log(subtitle)
                    })

=====