Support shorter shots (spec v0.7.6)#64
Conversation
Bumps the API spec submodule to v0.7.6 (cloudglue-api-spec commit 7a89fb0) and regenerates the SDK. Shot-based segmentation now accepts fractional durations with a 0.6s minimum (previously integer-only, 1s minimum), and the API default for minimum shot length is now 0.6s. Client wrapper updates: - Segments.create_shot_config: duration params widened to Union[int, float]; min_duration_seconds default changed 1 -> 0.6 to match the new API default - Segmentations.create_shot_detector_config: docstring range for min_seconds updated to 0.6-600 SDK version bumped to 0.7.13.
|
Important Review skippedToo many files! This PR contains 275 files, which is 125 over the limit of 150. To get a review, narrow the scope: ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (275)
You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
7a89fb0, "Support shorter shots") and regenerates the low-level SDK. Shot-based segmentation now accepts fractional durations with a 0.6s floor (previously integer-only, 1s minimum), and the API default minimum shot length is now 0.6s.Segments.create_shot_configduration params widened frominttoUnion[int, float], andmin_duration_secondsdefault changed from1to0.6to track the new API default (note: behavioral change for callers relying on the old implicit 1s minimum).Segmentations.create_shot_detector_configalready accepted floats — docstring range updated to 0.6–600.Test plan
Segments.create_shot_config()default builds withmin_duration_seconds=0.6create_shot_config(min_duration_seconds=0.75, max_duration_seconds=10.5)andcreate_shot_detector_config(detector="adaptive", min_seconds=0.6)min_duration_seconds=0.5raisesValidationErrorNote
Medium Risk
Changes default minimum shot length and request validation for segmentation jobs; callers using implicit defaults may get shorter segments, and values between 0.6–1s behave differently than before.
Overview
Aligns the Python client with OpenAPI 0.7.6 so shot-based segmentation can use sub-second minimum lengths (floor 0.6s, was 1s) and fractional min/max durations.
The high-level Segments helper updates
create_shot_config: duration args areUnion[int, float], defaultmin_duration_secondsis 0.6 (was 1), and docs reflect 0.6–600.Segmentations.create_shot_detector_configonly updates themin_secondsdoc range to 0.6–600; it already accepted floats.Regenerated
cloudglue.sdkmodels (ShotConfig,SegmentationShotDetectorConfig) match the new validation and defaults. Package version is 0.7.13; most other SDK files only bump the embedded API version string.Reviewed by Cursor Bugbot for commit ba4815f. Bugbot is set up for automated code reviews on this repo. Configure here.