Quickstart
This guide demonstrates building a production-ready video understanding service using a three-step process:
- Create an index
- Upload videos
- Perform downstream tasks.
The following diagram illustrates the steps in this guide:
Each step is composed of a single API call.
Start building
Explore these quickstart notebooks containing complete, executable code that you can customize and extend:
Prerequisites
-
This guide assumes you’re familiar with the concepts that are described on the Platform overview page.
-
To use the platform, you need an API key:
-
The videos you wish to upload must meet the following requirements:
- Video resolution: Must be at least 360x360 and must not exceed 3840x2160.
- Video and audio formats: The video files you wish to upload must be encoded in the video and audio formats listed on the FFmpeg Formats Documentation page. For videos in other formats, contact us at support@twelvelabs.io.
- Duration: For Marengo, it must be between 4 seconds and 2 hours (7,200s). For Pegasus, it must be between 4 seconds and 30 minutes (1800s). In a future release, the maximum duration for Pegasus will be 2 hours (7,200 seconds).
- File size: Must not exceed 2 GB.
If you require different options, contact us at support@twelvelabs.io.
-
Depending on the programming language you are using, install the TwelveLabs SDK by entering one of the following commands:
Procedure
You can interact with the platform using one of the available SDKs or an HTTP client like requests
or axios
.
Follow the steps in one of the sections below, depending on what task you want to complete. Note that the recommended approach for most scenarios is to use the SDKs.