Problem
PEGASUS_SYSTEM_PROMPT asks TwelveLabs Pegasus to return timestamps as decimal seconds, for example [12.5-15.0]. The downstream extract_timestamps() function only accepts SRT timestamps such as [00:00:12,500-00:00:15,000].
As a result, a response that follows the prompt exactly produces no clip ranges.
Reproduction
On current main (2ee37298):
PYTHONPATH=funclip python3 -c 'from utils.trans_utils import extract_timestamps; print(extract_timestamps("1. [12.5-15.0] highlight"))'
Output:
The first line is the function debug print; the second is the returned empty list.
Expected behavior
A Pegasus response in the format requested by the built-in prompt must be converted into millisecond clip ranges. Existing SRT-formatted LLM responses must remain supported.
Acceptance criteria
[12.5-15.0] produces [[12500, 15000]] in the Pegasus clipping path.
- Existing
[00:00:12,500-00:00:15,000] parsing remains unchanged.
- Multiple segments and integer-second values are covered.
- Malformed or reversed ranges do not silently create invalid clips.
- A regression test passes the normalized Pegasus output into the same parser used by the AI clipping pipeline.
This mismatch was also identified during review of #165: #165 (comment)
Problem
PEGASUS_SYSTEM_PROMPTasks TwelveLabs Pegasus to return timestamps as decimal seconds, for example[12.5-15.0]. The downstreamextract_timestamps()function only accepts SRT timestamps such as[00:00:12,500-00:00:15,000].As a result, a response that follows the prompt exactly produces no clip ranges.
Reproduction
On current
main(2ee37298):PYTHONPATH=funclip python3 -c 'from utils.trans_utils import extract_timestamps; print(extract_timestamps("1. [12.5-15.0] highlight"))'Output:
The first line is the function debug print; the second is the returned empty list.
Expected behavior
A Pegasus response in the format requested by the built-in prompt must be converted into millisecond clip ranges. Existing SRT-formatted LLM responses must remain supported.
Acceptance criteria
[12.5-15.0]produces[[12500, 15000]]in the Pegasus clipping path.[00:00:12,500-00:00:15,000]parsing remains unchanged.This mismatch was also identified during review of #165: #165 (comment)