# US 2025/0157197 A1 · Methods and apparatuses for training content understanding model and content generation model

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2025/0157197 A1
- Document ID: US20250157197A1
- Status: Published application
- Kind: A1
- Application number: 18/940,207
- Filed: 2024-11-07
- Published: 2025-05-15
- Earliest claimed: 2023-11-13
- Assignees: Alipay (Hangzhou) Information Technology Co., Ltd.
- Applicants: Alipay (Hangzhou) Information Technology Co., Ltd.
- Inventors: Ziping Ma; Qingpei Guo
- Web page: https://patentgrep.com/patent/US20250157197A1

## CPC

- G06V 10/774: Generating sets of training patterns; Bootstrap methods, e.g. bagging or boosting
- G06V 10/72: Data preparation, e.g. statistical preprocessing of image or video features
- G06V 10/761: {Proximity, similarity or dissimilarity measures}
- G06V 10/82: using neural networks
- Y02D 10/00: Energy efficient computing, e.g. low power processors, power management or thermal management
- G06V: IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- Y02D: CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE

## Abstract

Separately training a content understanding model and a content generation model with an image-text pair formed by an image and a text in a target training set. Sample processing is performed on a noise-containing sample set, including: inputting a first image in any first image-text pair in the noise-containing sample set into the content understanding model to obtain several candidate texts; separately inputting a first text in the first image-text pair and the several candidate texts into the content generation model to obtain multiple candidate images; performing similarity matching between the multiple candidate images and the first image to determine a target text; and continuing to train the content understanding model and the content generation model by forming a second image-text pair by using the first image and the target text and adding the second image-text pair to the target training set.

## Claims

### Claim 1

A computer-implemented method for content understanding model and content generation model training, comprising:
separately training a content understanding model and a content generation model with an image-text pair formed by an image and a text in a target training set, wherein the content understanding model is used to generate an image description text based on an input image, and wherein the content generation model is used to generate a corresponding image based on an input description text; and
performing sample processing on a noise-containing sample set, wherein an image-text matching degree of an image-text pair in the noise-containing sample set is less than that in the target training set, and the sample processing comprises:
inputting a first image in any first image-text pair in the noise-containing sample set into the content understanding model to obtain several candidate texts;
separately inputting a first text in the first image-text pair and the several candidate texts into the content generation model to obtain multiple candidate images;
performing similarity matching between the multiple candidate images and the first image, and determining a target text based on a matching result; and
forming a second image-text pair by using the first image and the target text and adding the second image-text pair to the target training set, as an updated target training set, to continue to train the content understanding model and the content generation model.

### Claim 2 (depends on 1)

The computer-implemented method of claim 1, comprising:
continuing, using the updated target training set, to train the content understanding model and the content generation model; or
continuing to train the content understanding model and the content generation model by using an image-text pair newly added to the target training set.

### Claim 3 (depends on 1)

The computer-implemented method of claim 1, comprising:
obtaining the target training set and the noise-containing sample set, and dividing the noise-containing sample set into a first subset to an Nth subset, wherein image-text matching degrees of image-text pairs in the first subset to the Nth subset decrease sequentially; and
the performing sample processing on a noise-containing sample set comprises:
sequentially performing the sample processing on the first subset to the Nth subset.

### Claim 4 (depends on 3)

The computer-implemented method of claim 3, wherein the obtaining the target training set and the noise-containing sample set, and dividing the noise-containing sample set into a first subset to an Nth subset, comprises:
obtaining a first training set, wherein the first training set comprises several image-text pairs formed by images and texts; and
sorting the several image-text pairs in the first training set in descending order of image-text matching degrees, dividing the first training set into N+1 subsets based on a sorting result, and using an initial subset as the target training set and remaining N subsets as the first subset to the Nth subset sequentially.

### Claim 5 (depends on 4)

The computer-implemented method of claim 4, wherein:
the first training set comprises a third image-text pair;
the third image-text pair comprises a third image and a third text; and
an image-text matching degree of the third image-text pair is determined by:
inputting the third image into an image encoder of a multi-modal model to obtain a third image representation, wherein the multi-modal model comprises a text encoder, and the image encoder and the text encoder are jointly pre-trained, so encoding results of the image encoder and the text encoder are located in a same representation space;
inputting the third text into the text encoder to obtain a third text representation; and
calculating a similarity between the third image representation and the third text representation, and determining the similarity as the image-text matching degree of the third image-text pair.

### Claim 6 (depends on 5)

The computer-implemented method of claim 5, wherein the multi-modal model is a contrastive language-image pre-training (CLIP) model.

### Claim 7 (depends on 1)

The computer-implemented method of claim 1, wherein performing similarity matching between the multiple candidate images and the first image, comprises:
separately inputting the multiple candidate images and the first image into an image encoder to obtain multiple candidate image representations and a first image representation; and
separately performing similarity matching between the multiple candidate image representations and the first image representation.

### Claim 8 (depends on 7)

The computer-implemented method of claim 7, wherein the image encoder is an image encoder of a contrastive language-image pre-training (CLIP) model.

### Claim 9 (depends on 1)

The computer-implemented method of claim 1, wherein determining a target text based on a matching result, comprises:
determining a candidate image having a highest similarity with the first image as a first target image; and
determining, as the target text, a text used when the first target image is generated.

### Claim 10 (depends on 1)

The computer-implemented method of claim 1, wherein:
the multiple candidate images comprise a seed candidate image generated based on the first text; and
determining a target text based on a matching result, comprises:
sorting the multiple candidate images in descending order of similarities with the first image, and determining a ranking position of the seed candidate image in the sorting as a first ranking position; and
if the first ranking position is less than or equal to a predetermined first threshold, determining the first text as the target text;
if the first ranking position is greater than or equal to a predetermined second threshold, determining an image having a highest similarity as a second target image, and determining, as the target text, a text used when the second target image is generated; or
if the first ranking position is greater than the predetermined first threshold and is less than the predetermined second threshold, sending the first text, the first image, and the several candidate texts to a manual labeling platform, and determining a text returned by the manual labeling platform as the target text.

### Claim 11

A non-transitory, computer-readable medium storing one or more instructions executable by a computer system to perform one or more operations, comprising:
separately training a content understanding model and a content generation model with an image-text pair formed by an image and a text in a target training set, wherein the content understanding model is used to generate an image description text based on an input image, and wherein the content generation model is used to generate a corresponding image based on an input description text; and
performing sample processing on a noise-containing sample set, wherein an image-text matching degree of an image-text pair in the noise-containing sample set is less than that in the target training set, and the sample processing comprises:
inputting a first image in any first image-text pair in the noise-containing sample set into the content understanding model to obtain several candidate texts;
separately inputting a first text in the first image-text pair and the several candidate texts into the content generation model to obtain multiple candidate images;
performing similarity matching between the multiple candidate images and the first image, and determining a target text based on a matching result; and
forming a second image-text pair by using the first image and the target text and adding the second image-text pair to the target training set, as an updated target training set, to continue to train the content understanding model and the content generation model.

### Claim 12 (depends on 11)

The non-transitory, computer-readable medium of claim 11, comprising:
continuing, using the updated target training set, to train the content understanding model and the content generation model; or
continuing to train the content understanding model and the content generation model by using an image-text pair newly added to the target training set.

### Claim 13 (depends on 11)

The non-transitory, computer-readable medium of claim 11, comprising:
obtaining the target training set and the noise-containing sample set, and dividing the noise-containing sample set into a first subset to an Nth subset, wherein image-text matching degrees of image-text pairs in the first subset to the Nth subset decrease sequentially; and
the performing sample processing on a noise-containing sample set comprises:
sequentially performing the sample processing on the first subset to the Nth subset.

### Claim 14 (depends on 13)

The non-transitory, computer-readable medium of claim 13, wherein the obtaining the target training set and the noise-containing sample set, and dividing the noise-containing sample set into a first subset to an Nth subset, comprises:
obtaining a first training set, wherein the first training set comprises several image-text pairs formed by images and texts; and
sorting the several image-text pairs in the first training set in descending order of image-text matching degrees, dividing the first training set into N+1 subsets based on a sorting result, and using an initial subset as the target training set and remaining N subsets as the first subset to the Nth subset sequentially.

### Claim 15 (depends on 14)

The non-transitory, computer-readable medium of claim 14, wherein:
the first training set comprises a third image-text pair;
the third image-text pair comprises a third image and a third text; and
an image-text matching degree of the third image-text pair is determined by:
inputting the third image into an image encoder of a multi-modal model to obtain a third image representation, wherein the multi-modal model comprises a text encoder, and the image encoder and the text encoder are jointly pre-trained, so encoding results of the image encoder and the text encoder are located in a same representation space;
inputting the third text into the text encoder to obtain a third text representation; and
calculating a similarity between the third image representation and the third text representation, and determining the similarity as the image-text matching degree of the third image-text pair.

### Claim 16 (depends on 15)

The non-transitory, computer-readable medium of claim 15, wherein the multi-modal model is a contrastive language-image pre-training (CLIP) model.

### Claim 17 (depends on 11)

The non-transitory, computer-readable medium of claim 11, wherein performing similarity matching between the multiple candidate images and the first image, comprises:
separately inputting the multiple candidate images and the first image into an image encoder to obtain multiple candidate image representations and a first image representation; and
separately performing similarity matching between the multiple candidate image representations and the first image representation.

### Claim 18 (depends on 17)

The non-transitory, computer-readable medium of claim 17, wherein the image encoder is an image encoder of a contrastive language-image pre-training (CLIP) model.

### Claim 19 (depends on 11)

The non-transitory, computer-readable medium of claim 11, wherein determining a target text based on a matching result, comprises:
determining a candidate image having a highest similarity with the first image as a first target image; and
determining, as the target text, a text used when the first target image is generated.

### Claim 20

A computer-implemented system, comprising:
one or more computers; and
one or more computer memory devices interoperably coupled with the one or more computers and having tangible, non-transitory, machine-readable media storing one or more instructions that, when executed by the one or more computers, perform one or more operations, comprising:
separately training a content understanding model and a content generation model with an image-text pair formed by an image and a text in a target training set, wherein the content understanding model is used to generate an image description text based on an input image, and wherein the content generation model is used to generate a corresponding image based on an input description text; and
performing sample processing on a noise-containing sample set, wherein an image-text matching degree of an image-text pair in the noise-containing sample set is less than that in the target training set, and the sample processing comprises:
inputting a first image in any first image-text pair in the noise-containing sample set into the content understanding model to obtain several candidate texts;
separately inputting a first text in the first image-text pair and the several candidate texts into the content generation model to obtain multiple candidate images;
performing similarity matching between the multiple candidate images and the first image, and determining a target text based on a matching result; and
forming a second image-text pair by using the first image and the target text and adding the second image-text pair to the target training set, as an updated target training set, to continue to train the content understanding model and the content generation model.
