twelvelabs
What it is and what it does
The TwelveLabs SDK is a Python client library that wraps the TwelveLabs video understanding platform's HTTP API, reducing boilerplate code for common workflows. It provides object-oriented interfaces for creating video indexes, uploading video assets (from URLs or local files), monitoring processing status, and querying videos using natural language text or image-based search across visual and audio modalities.
The SDK is built on httpx for HTTP communication and pydantic for data validation, supporting Python 3.8 through 3.12. Typical workflows involve creating an index configured with specific AI models (such as Marengo for search or Pegasus for text generation), uploading videos, waiting for indexing to complete asynchronously, and then performing downstream tasks like semantic video search or content analysis. The platform handles video understanding internally; the SDK's role is to orchestrate these operations and parse results.
Use it for:
- Build a video search engine that finds clips matching natural language queries across a library of indexed videos.
- Automate video ingestion and indexing workflows by uploading files and monitoring processing status programmatically.
- Generate text summaries or descriptions of video content by indexing with the Pegasus model and calling analysis endpoints.
- Integrate video understanding into a larger application (e.g., a content management or discovery platform) without writing raw HTTP calls.
- Search video archives by visual content (objects, scenes) or audio (spoken words, sounds) using multimodal queries.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Python SDK for the TwelveLabs video understanding platform, providing methods to create indexes, upload videos, and perform search and analysis tasks on video content.
Yes, if you are building on the TwelveLabs platform and want to avoid writing raw HTTP boilerplate. The SDK is actively maintained, has low install friction, and supports current Python versions. However, verify the license terms first—they are not declared in the package metadata. Also confirm that the free tier API key and rate limits suit your use case, as the SDK is a client library and all video processing happens on TwelveLabs' servers.
Install
twelvelabs on PyPI
pip
pip install twelvelabsuv
uv add twelvelabspoetry
poetry add twelvelabsInstalling twelvelabs
Before you install
Low install friction with pure-Python wheels and a small dependency footprint (httpx, pydantic, and typing utilities). Active maintenance as of 22 days ago.
License in practice
License treatment is unclear; no SPDX identifier or raw license text is available in the package metadata. Verify the actual license terms before use in proprietary or copyleft-sensitive projects.
Quickstart
pip install twelvelabs
from twelvelabs import TwelveLabs
client = TwelveLabs(api_key="<YOUR_API_KEY>")
index = client.indexes.create(
index_name="my_index",
models=[{"model_name": "marengo3.0", "model_options": ["visual", "audio"]}]
)
print(f"Created index: id={index.id}")
Requires a TwelveLabs API key and account (free tier available); Python 3.8 or newer.
Verify before relying
- Whether the license is open-source, proprietary, or dual-licensed (metadata is unclear).
- Actual API rate limits and pricing tier constraints for the free account tier.
- Whether video files larger than 4 GB are supported despite the guide mentioning 4 GB as a limit for the guide only.
Package facts
| License | not declared (unclear) |
| Python support | supports the current Python release (<4.0,>=3.8) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 5 — httpx, httpx-sse, pydantic, pydantic-core, typing_extensions |
| Maintenance | actively maintained — 22 days since the last release |
| First released | |
| Downloads | 380,289/month — #7,104 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: twelvelabs-1.3.1-py3-none-any.whl
Tags
More Python Modules packages
Converts domain names between Unicode and…
permissive · top 100 on PyPI
setuptoolsSetuptools is a Python build backend and…
permissive · top 100 on PyPI
PyYAMLPyYAML parses and emits YAML 1.1 data format,…
permissive · top 100 on PyPI
pydanticPydantic validates Python data structures…
permissive · top 100 on PyPI
annotated-typesProvides reusable metadata objects for use with…
permissive · top 100 on PyPI
typing-inspectionProvides runtime tools to inspect and…
permissive · top 100 on PyPI
mux-pythonOfficial Python wrapper for the Mux API,…
permissive · top 5,000 on PyPI
youtube-search-pythonSearch YouTube for videos, channels, and…
permissive · top 15,000 on PyPI
pytubepytube downloads YouTube videos and playlists…
permissive · top 5,000 on PyPI
metal-sdkPython client library for indexing and querying…
permissive · top 15,000 on PyPI
cloudinaryCloudinary Python SDK provides image and video…
permissive · top 5,000 on PyPI
azure-search-documentsClient library for querying, indexing, and…
unclear · top 5,000 on PyPI
zai-sdkOfficial Python SDK for Z.ai's large model…
unclear · top 15,000 on PyPI
firecrawlA Python SDK for web scraping, crawling,…
permissive · top 5,000 on PyPI
google-cloud-videointelligencePython client library for Google Cloud Video…
permissive · top 1,000 on PyPI
contentfulA Python client library for querying and…
permissive · top 15,000 on PyPI