Skip to main content

Kaltura eSearch Loader

pip install llama-index-readers-kaltura-esearch

This loader reads Kaltura Entries from Kaltura based on a Kaltura eSearch API call. Search queries can be passed as a pre-defined object of KalturaESearchEntryParams, or through a simple free text query. The result is a list of documents containing the Kaltura Entries and Captions json.

Parameters

KalturaESearchEntryParams

This is a Kaltura class used for performing search operations in Kaltura. You can use this class to define various search criteria, such as search phrases, operators, and objects to be searched.

For example, you can search for entries with specific tags, created within a specific time frame, or containing specific metadata.

Kaltura Configuration

To use the Kaltura eSearch Loader, you need to provide the following configuration credentials:

Parameter Description Default Value
partnerId Your Kaltura partner ID. Mandatory (no default)
apiSecret Your Kaltura API secret key (aka Admin Secret). Mandatory (no default)
userId Your Kaltura user ID. Mandatory (no default)
ksType The Kaltura session type. KalturaSessionType.ADMIN
ksExpiry The Kaltura session expiry time. 86400 seconds
ksPrivileges The Kaltura session privileges. "disableentitlement"
kalturaApiEndpoint The Kaltura API endpoint URL. "https://cdnapi-ev.kaltura.com/"
requestTimeout The request timeout duration in seconds. 500 seconds
shouldLogApiCalls If passed True, all the Kaltura API calls will also be printed to log (only use during debug). False

load_data

This method run the search in Kaltura and load Kaltura entries in a list of dictionaries.

Method inputs

  • search_params: search parameters of type KalturaESearchEntryParams with pre-set search queries. If not provided, the other parameters will be used to construct the search query.
  • search_operator_and: if True, the constructed search query will have AND operator between query filters, if False, the operator will be OR.
  • free_text: if provided, will be used as the free text query of the search in Kaltura.
  • category_ids: if provided, will only search for entries that are found inside these category ids.
  • withCaptions: determines whether or not to also download captions/transcript contents from Kaltura.
  • maxEntries: sets the maximum number of entries to pull from Kaltura, between 0 to 500 (max pageSize in Kaltura).

Method output

Each dictionary in the response represents a Kaltura media entry, where the keys are strings (field names) and the values can be of any type:

Column Name Data Type Description
entry_id str Unique identifier of the entry
entry_name str Name of the entry
entry_description str Description of the entry
entry_captions JSON Captions of the entry
entry_media_type int Type of the media (KalturaMediaType)
entry_media_date int Date of the media Unix timestamp
entry_ms_duration int Duration of the entry in ms
entry_last_played_at int Last played date of the entry Unix timestamp
entry_application str The app that created this entry (KalturaEntryApplication)
entry_tags str Tags of the entry (comma separated)
entry_reference_id str Reference ID of the entry

Usage

First, instantiate the KalturaReader (aka Kaltura Loader) with your Kaltura configuration credentials:

from llama_index.readers.kaltura_esearch import KalturaESearchReader

loader = KalturaESearchReader(
    partnerId="INSERT_YOUR_PARTNER_ID",
    apiSecret="INSERT_YOUR_ADMIN_SECRET",
    userId="INSERT_YOUR_USER_ID",
)

Using an instance of KalturaESearchEntryParams

Then, create an instance of KalturaESearchEntryParams and set your desired search parameters:

from KalturaClient.Plugins.ElasticSearch import (
    KalturaESearchEntryParams,
    KalturaESearchEntryOperator,
    KalturaESearchOperatorType,
    KalturaESearchUnifiedItem,
)

# instantiate the params object
search_params = KalturaESearchEntryParams()

# define search parameters (for example, search for entries with a certain tag)
search_params.searchOperator = KalturaESearchEntryOperator()
search_params.searchOperator.operator = KalturaESearchOperatorType.AND_OP
search_params.searchOperator.searchItems = [KalturaESearchUnifiedItem()]
search_params.searchOperator.searchItems[0].searchTerm = "my_tag"

Once you have your KalturaESearchEntryParams ready, you can pass it to the Kaltura Loader:

# Using search params
entry_docs = loader.load_data(search_params)
# Simple pass the search params into the load_data method without setting search_params
entry_docs = loader.load_data(
    search_operator_and=True,
    free_text="education",
    category_ids=None,
    with_captions=True,
    max_entries=5,
)

For a more elaborate example, see: llamaindex_kaltura_esearch_reader_example.py

This loader is designed to be used as a way to load data into LlamaIndex.

About Kaltura

Kaltura Video Cloud is a Digital Experience Platform enabling streamlined creation, management, and distribution of media content (video, audio, image, doc, live stream, real-time video). It powers many applications across industries with collaboration, interactivity, virtual events, and deep video analytics capabilities.

Metadata

Release files for llama-index-readers-kaltura-esearch 0.7.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for llama-index-readers-kaltura-esearch 0.7.0
File Size Uploaded Provenance Actions
llama_index_readers_kaltura_esearch-0.7.0.tar.gz 19.5 kB Without provenance Details for llama_index_readers_kaltura_esearch-0.7.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for llama-index-readers-kaltura-esearch 0.7.0
File Interpreter ABI Platform Actions
llama_index_readers_kaltura_esearch-0.7.0-py3-none-any.whl Python 3 none any Details for llama_index_readers_kaltura_esearch-0.7.0-py3-none-any.whl

Total release size: 38.7 kB

Release files / llama_index_readers_kaltura_esearch-0.7.0.tar.gz

Download URL llama_index_readers_kaltura_esearch-0.7.0.tar.gz
Size 19.5 kB
Tags Source
SHA-256 checksum
How to use checksums
e894c5ae23ad2ea7f98d0481900596db1bce1079063d80880b808a3aa9d74c21
BLAKE2b-256 checksum
How to use checksums
1e586b605b51c462afd9477934b6ecf1c97158b1a2f52f17b96c56e50345db75
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.13.8 {"installer":{"name":"uv","version":"0.13.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / llama_index_readers_kaltura_esearch-0.7.0-py3-none-any.whl

Download URL llama_index_readers_kaltura_esearch-0.7.0-py3-none-any.whl
Size 19.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
fc22f48d669862925487b60cabbbe8dfe4533cd6c6d7424ec2e431e1e3d05be9
BLAKE2b-256 checksum
How to use checksums
b430a2c8da47b1f261e69493a02b1196cf5d55ffd52ea4edc682a700fc15d0cd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.13.8 {"installer":{"name":"uv","version":"0.13.8","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for llama-index-readers-kaltura-esearch 0.7.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page