Multi-modal data processing and synchronization (invitation-only preview)
The multi-modal data processing and synchronization feature reads raw data in multiple modalities, such as text and images, from a specified data source. It uses AI Search Open Platform models to extract and vectorize the multi-modal information, and then synchronizes the processed data to an Elasticsearch Serverless application. In this tutorial, you create a synchronization task that continuously delivers your source data and its generated vector fields to a destination index.
Background information
AI Search Open Platform is a subproduct of OpenSearch. For intelligent search and retrieval-augmented generation (RAG) scenarios, it provides componentized algorithm services used in the AI search process, including document parsing, document chunking, text embedding, query analysis, recall, ranking, evaluation, and large language model (LLM) services. You can select only the component services that your search service requires.
Billing
AI Search Open Platform charges fees for AI model services based on actual model usage. No fees are charged when the services are not used.
After charges are incurred, you can log on to the Expenses and Costs system to view your bills.
Limits
Supported region — The multi-modal data processing and synchronization feature is available only in the China (Shanghai) region. Whether a support ticket is required to add your account to the feature whitelist is to be confirmed.
Supported data source — Currently, only data from ApsaraDB RDS can be synchronized and processed.
Prerequisites
AI models — You have activated and initialized AI models.
Raw data — You have created the raw data to process and synchronize. To prepare the data source, create an ApsaraDB RDS instance in the China (Hangzhou) region, and then create a database, a database account and password, and the corresponding source table in the database.
ApsaraDB RDS includes ApsaraDB RDS for MySQL, ApsaraDB RDS for PostgreSQL, ApsaraDB RDS for SQL Server, and ApsaraDB RDS for MariaDB. Select a database engine as needed. The regions and ApsaraDB RDS product types that this feature supports are to be confirmed.
Step 1: Create a synchronization task
You create the synchronization task in the Elasticsearch Serverless console and then configure it in the steps that follow.
Go to the application details page.
Log on to the Elasticsearch Serverless console. In the top menu bar, switch to the region where your Elasticsearch Serverless application is deployed.
In the left-side navigation pane, click Application Management, and then click the name of the application that you created.
In the left-side navigation pane, click Data Migration and Synchronization.
In the Use AI Search Open Platform - Multi-modal Data Processing and Synchronization Service section, click Use Now.
Click Create to create a data processing and synchronization task.
Step 2: Configure basic information
On the Basic Information Configuration tab, configure the synchronization task name and the data source information.
| Parameter | Description |
| Task name | A custom name for the synchronization task. The name must be unique within the application. |
| API key | Select the required API key from the drop-down list. When you call AI model-related APIs or software development kits (SDKs), use an API key for identity authentication to help ensure secure and reliable calls. |
| Data source | Currently, only ApsaraDB RDS is supported. |
| Instance ID | The ID of the ApsaraDB RDS instance. Log on to the ApsaraDB RDS console and obtain it from the instance list. |
| Database name | The name of the ApsaraDB RDS database. Log on to the ApsaraDB RDS console, go to the instance details page, and obtain it from the database management page. |
| Username and password | The username and password of the ApsaraDB RDS database account. Log on to the ApsaraDB RDS console, go to the instance details page, and obtain them from the account management page. |
| Table name | The name of the ApsaraDB RDS data table. |
Step 3: Process data
On the Data Processing tab, select the source fields to synchronize and specify processing rules, such as the fields whose images or text need to be vectorized, to generate result fields.
Filter the source fields.
In the Source Fields section, view the fields in the source table to synchronize. By default, all source table fields are synchronized. You can delete the fields that do not need to be synchronized to the Elasticsearch Serverless application.
Customize a data processing rule.
In the Data Processing Configuration section, click Create Processing Rule to customize a data processing rule. After a rule is created, you can edit or delete it as needed.
You can define multiple data processing rules for the same source field.
If you edit or delete a data processing rule, the previously generated result fields are changed or deleted accordingly. The restrictions that apply to deleting a data processing rule are to be confirmed.
Configure the following parameters.
Parameter Description Rule name A custom name for the rule. The name must be unique within the current synchronization task. Data type Select the type of data to vectorize. Valid values: Text and Image. Data processing template Select the vectorization method used to process data. The available methods depend on the value of Data type. If Data type is set to Text, you can select Dense vectorization, which converts text into low-dimensional vectors and is suitable for semantic search, question answering, and recommendation scenarios, or Sparse vectorization, which converts text into high-dimensional vectors and is suitable for short-text and keyword searches. If Data type is set to Image, only Image vectorization is supported. It converts images into numerical vectors and extracts image features for retrieval or classification. Source fields Select the fields to process with the current rule. You can select multiple fields. Image format Configure this parameter only when Data type is set to Image. The format of the images to process in the selected fields. The system processes only the images that match this format. Valid values: uri(images are stored externally, and the fields contain publicly accessibleHTTPorOSSURLs),binary(images are stored in binary format inBLOBfields),base64-string(images are stored asBASE64strings inTEXTfields), andbase64-bytes(images are stored asBASE64strings inBLOBfields).Processing pipeline Select the multi-modal embedding AI model required to vectorize the data. After you select a model, you can view the model description and the result fields generated from the model. Result fields use the following naming formats: <RuleName>_<SourceFieldName>_multi-text-embeddingfor dense text vectorization (for example,test2_hobby_text-embedding),<RuleName>_<SourceFieldName>_multi-text-sparse-embeddingfor sparse text vectorization (for example,test2_name_text-sparse-embedding), and<RuleName>_<SourceFieldName>_multi-modal-embeddingfor image vectorization (for example,test2_age_multi-modal-embedding). The field names displayed in the Generated Fields section prevail.Generate the result fields.
After you create a data processing rule, the platform generates the corresponding result fields according to the rule. In the Generated Fields section, view the generated field names and a description of how the fields are generated.
Step 4: Configure field mappings
On the Field Mapping Configuration tab, configure the mappings between the fields to synchronize, which include source fields and generated result fields, and the destination index fields in the Elasticsearch Serverless application. After the synchronization task starts, data in the fields to synchronize is automatically synchronized to the corresponding destination index fields.
Select a destination index.
The number of fields in the destination index must be greater than or equal to the number of fields to synchronize.
If the current application does not contain an index, or if the existing indexes do not meet your business requirements, select the fields to synchronize and click Create Index with One Click. The system automatically infers and generates index fields from the selected fields.
NoteIn the Index Inference Results panel, select the specified code, right-click it, and copy the code to your local device for editing and use. How the copied code is applied and how you return to the field mapping flow are to be confirmed.
Configure the field mappings.
After you select an index, the system automatically matches the fields to synchronize with the destination index fields that have the same names. You can adjust the mappings as needed.
You can add the same field to synchronize multiple times and configure different destination index fields for it. Each destination index field supports only one mapping and can correspond to only one field to synchronize.
Fields to synchronize: the raw data to synchronize. By default, all source table fields and generated result fields are displayed. You can add or delete fields as needed.
Destination index fields: the fields that receive data from the corresponding fields to synchronize.
Primary key: currently, only one primary key can be configured.
After all fields to synchronize are matched with destination index fields, click Next to continue the configuration.
Step 5: Configure a synchronization policy
In the Data Synchronization Configuration section, enter the password that you set when you created the Elasticsearch Serverless application, and then follow the on-screen instructions to complete the synchronization configuration.
What to do next
After the synchronization task is configured, it automatically starts. In the synchronization task list, verify that the task status changes to Running.
After data synchronization is complete, go to Kibana to view details about the synchronized data.
Manage synchronization tasks
In the synchronization task list, you can view basic and detailed task information and start, stop, copy, or delete tasks as needed.
Task status — The possible statuses are Pending, Starting, Running, and Failed. If a task enters the Failed state, follow the on-screen instructions to view the relevant logs and locate the issue.
Multi-modal data processing and synchronization tasks use a combined full and incremental synchronization mode. Therefore, a synchronization task remains in the Running state and does not stop automatically.
NoteA task in the Running state can also encounter issues. Use the logs in the Elasticsearch Serverless console to locate the issue. The information displayed in the console prevails.
Copy and create — Quickly copy an existing task to create a new task with the same configuration. After the task is created, adjust the configuration as needed to facilitate batch task deployment.
Delete a task — If a task is no longer needed, click the
icon and then click Delete, and follow the on-screen instructions to delete the task.ImportantA deleted task cannot be recovered. Proceed with caution. Whether the synchronized data is retained after a task is deleted is to be confirmed.