LordPatil commited on
Commit
1e20198
·
verified ·
1 Parent(s): 1f1864e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -1
app.py CHANGED
@@ -164,7 +164,11 @@ def create_video_thread(
164
  raise gr.Error("Could not fetch transcript. The video might not have one, or it could be private.")
165
 
166
  transcript_arr = [
167
- f"{chunk.text.strip().replace("\n", " ")} [{ms_to_hhmmss(int(chunk.offset))} - {ms_to_hhmmss(int(chunk.offset) + int(chunk.duration))}]"
 
 
 
 
168
  for chunk in transcript.content
169
  ]
170
 
 
164
  raise gr.Error("Could not fetch transcript. The video might not have one, or it could be private.")
165
 
166
  transcript_arr = [
167
+ "{} [{} - {}]".format(
168
+ chunk.text.strip().replace("\n", " "),
169
+ ms_to_hhmmss(int(chunk.offset)),
170
+ ms_to_hhmmss(int(chunk.offset) + int(chunk.duration))
171
+ )
172
  for chunk in transcript.content
173
  ]
174