Correlation model training method, device, storage medium and program product
By selecting a target multimedia resource set from the multimedia resource set and generating training samples to train the relevance model, the problems of low efficiency and low accuracy of manual annotation are solved, and more efficient and accurate relevance model training is achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- GUANGZHOU KUGOU COMP TECH CO LTD
- Filing Date
- 2026-02-28
- Publication Date
- 2026-06-09
AI Technical Summary
In existing technologies, the training method of relevance models that rely on manual annotation is inefficient and inaccurate, resulting in unsatisfactory relevance results output by the model.
By selecting a target multimedia resource set from the multimedia resource set, training samples are generated based on the descriptive text and multimedia resources. These samples are then used to train the relevance model, utilizing the relevance between the descriptive text and multimedia resources for model training.
It improves the efficiency and accuracy of training sample annotation for the relevance model, enabling it to better capture the relevance between descriptive text and multimedia resources, reducing annotation costs and improving the model's generalization ability.
Smart Images

Figure CN122173945A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the fields of computer and internet technology, and in particular to a training method, device, storage medium, and program product for a correlation model. Background Technology
[0002] With the development of the Internet and mobile devices, users search for various information through mobile phones, computers and other terminal devices. Related search engines provide search services for users. Users enter query terms into the search engine and the search engine will return multimedia resources related to the query terms.
[0003] In related technologies, search engines use relevance models to calculate the relevance scores between recalled multimedia resources and query terms. The training samples for relevance models are usually manually labeled, and the labels of multimedia resources are determined by the labelers' understanding and knowledge of the multimedia resources.
[0004] However, relying on manually labeled samples has the problem of low efficiency, and the accuracy of the correlation results output by the trained model is not ideal. Summary of the Invention
[0005] This application provides a training method, device, storage medium, and program product for a correlation model. The technical solution provided by this application includes the following aspects.
[0006] According to one aspect of the embodiments of this application, a method for training a correlation model is provided, the method comprising: From a plurality of multimedia resource collections, at least one target multimedia resource collection is selected; wherein each multimedia resource collection includes at least one multimedia resource; Based on the description text of the target multimedia resource collection and the multimedia resources included in the target multimedia resource collection, at least one training sample is generated; wherein each training sample includes a corresponding set of description text and multimedia resources; The relevance model is trained using the training samples, and the relevance model is used to determine the relevance between the descriptive text and the multimedia resource.
[0007] According to one aspect of the embodiments of this application, a training apparatus for a correlation model is provided, the apparatus comprising: The selection module is used to select at least one target multimedia resource collection from multiple multimedia resource collections; wherein each multimedia resource collection includes at least one multimedia resource. The generation module is further configured to generate at least one training sample based on the description text of the target multimedia resource collection and the multimedia resources included in the target multimedia resource collection; wherein each training sample includes a set of corresponding description text and multimedia resources; The training module is also used to train a relevance model using the training samples, the relevance model being used to determine the relevance between the descriptive text and the multimedia resource.
[0008] According to one aspect of the embodiments of this application, a computer device is provided, the computer device including a processor and a memory, the memory storing a computer program, the computer program being loaded and executed by the processor to implement the above-described training method for the correlation model.
[0009] According to one aspect of the embodiments of this application, a computer-readable storage medium is provided, wherein a computer program is stored in the computer-readable storage medium, the computer program being loaded and executed by a processor to implement the above-described training method for the correlation model.
[0010] According to one aspect of the embodiments of this application, a computer program product is provided, the computer program product including a computer program, the computer program being executed by a processor to implement the above-described training method for the correlation model.
[0011] The technical solution provided in this application can bring the following beneficial effects: By selecting at least one target multimedia resource set from multiple multimedia resource sets, and generating training samples based on the descriptive text and multimedia resources included in the target multimedia resource set, a relevance model can be trained. On one hand, obtaining training samples based on the descriptive text and multimedia resources of the target multimedia resource set improves the annotation efficiency of the relevance model's training samples compared to manually annotated training samples. On the other hand, using descriptive text and multimedia resources as training samples enables the relevance model to learn the relevance between the descriptive text and multimedia resources, thereby improving the accuracy of the relevance model. Attached Figure Description
[0012] Figure 1 This is a schematic diagram of a computer system provided in one embodiment of this application; Figure 2 This is a flowchart of a training method for a correlation model provided in one embodiment of this application; Figure 3 This is a flowchart illustrating a multimedia resource search method provided in one embodiment of this application; Figure 4 This is a flowchart of a training method for a correlation model provided in one embodiment of this application; Figure 5 This is a flowchart illustrating the construction of training data according to one embodiment of this application; Figure 6 This is a flowchart of a training method for a correlation model provided in one embodiment of this application; Figure 7 This is a flowchart of a training method for a correlation model provided in one embodiment of this application; Figure 8 This is a block diagram of a training apparatus for a relational model provided in one embodiment of this application; Figure 9 This is a structural block diagram of a computer device provided in one embodiment of this application. Detailed Implementation
[0013] To make the objectives, technical solutions, and advantages of this application clearer, the embodiments of this application will be described in further detail below with reference to the accompanying drawings.
[0014] Please refer to Figure 1 This illustration shows a schematic diagram of a computer system provided in one embodiment of this application. The computer system may include: a terminal device 10 and a server 20.
[0015] Terminal device 10 includes, but is not limited to, mobile phones, tablets, smart voice interaction devices, game consoles, wearable devices, multimedia playback devices, PCs (Personal Computers), in-vehicle terminals, smart home appliances, and other electronic devices. A client application for the target application can be installed on terminal device 10. Optionally, the target application can be an application that needs to be downloaded and installed, or it can be a webpage or a mini-program; this embodiment does not limit the specific application.
[0016] In this application embodiment, the target application can be any application capable of providing multimedia resource search functionality. For example, the target application is a browser application, which can provide multimedia resource search, multimedia resource display, and other functions. In some embodiments, the target application can be a music player application, a video player application, a news or information application, a social networking application, an instant messaging application, etc., and this application does not limit this to any particular application.
[0017] In the embodiments of this application, the forms of multimedia resources include, but are not limited to, at least one of the following: songs, videos, text, images, interactive resources, etc.
[0018] Server 20 is used to provide backend services for the client of the target application in terminal device 10. For example, server 20 can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN (Content Delivery Network), and big data and artificial intelligence platforms, but it is not limited to these.
[0019] Terminal device 10 and server 20 can communicate with each other via a network. This network can be a wired network or a wireless network.
[0020] In one embodiment, the training process of the correlation model is performed on a computer device, i.e., the method provided in this application, where the execution entity for each step can be a computer device, which can be any electronic device with data storage and processing capabilities. For example, the computer device can be... Figure 1 Server 20 in the middle can be Figure 1 The terminal device 10 can also be another device besides the terminal device 10 and the server 20. The trained relevance model can be deployed on the terminal device 10 or on the server 20, so that after receiving a query term, the trained relevance model can be invoked to determine the multimedia resources related to the keyword. In one embodiment, the trained relevance model is deployed on the server 20. The terminal device 10 obtains the keyword and sends the keyword to the server 20. The server 20 determines the multimedia resources related to the keyword using the trained relevance model.
[0021] In some embodiments, the trained relevance model is deployed on the terminal device 10. After obtaining the keywords, the terminal device 10 directly calls the trained relevance model to determine the multimedia resources related to the keywords.
[0022] In one embodiment, during the training of the relevance model, data uploaded by the terminal device 10 to the server 20 is used as training samples in the relevance model training process, enabling the trained relevance model to better process the input text. Optionally, the trained relevance model can determine the similarity between the input text and at least one multimedia resource. The computer device returns the multimedia resource with a high similarity to the terminal device 10, which then displays it to the user.
[0023] In the related art, when training a correlation model, it mainly relies on manual annotation to construct a dataset. For example, by manually annotating the correspondence between "text label - song", such as manually annotating the correspondence between "soothing - 《x Nong》". The constructed dataset is a static annotation dataset. Then, a language model, such as the BERT (Bidirectional Encoder Representation from Transformers) model, is used to convert the text label into a text vector. At the same time, through the audio features of the song, such as rhythm, melody, decibel, etc., a song vector generation model is trained. Finally, the cosine similarity between the text vector and the song vector is calculated and used as the scoring basis for the correlation between the text and the song, which is used for sorting music search results.
[0024] However, relying on manual annotation to construct a dataset, on the one hand, the annotation cost is high, and it requires professional personnel to match "text - single song" one by one, which is difficult to cover a large single song library; on the other hand, the manual annotation results are relatively subjective, and there may be significant differences in the understanding of text semantics and song styles among different annotators, which will lead to poor consistency and easy errors in the constructed dataset, and further lead to weak generalization ability of the trained correlation model.
[0025] In addition, in the related art, the correlation matching between "text description - song" is also considered. For example, a long music scene description (such as "soft music suitable for playing in the coffee shop in the afternoon") is used as the input text, and then the semantic features of the input text are extracted through the HAN (Hierarchical Attention Network). Song features are constructed based on audio signals (such as MFCC (Mel-Frequency Cepstral Coefficients), spectral band energy), and then a two-tower network structure is used to calculate the similarity between the semantic features of the input text and the song features, and the correlation result is output.
[0026] Only relying on audio signals to extract song features and not combining user behavior data will have the problem of semantic disconnection. For example, for the same piano version of 《x Nong》, the audio features are the same, but in the two text search scenarios of "coffee shop background" and "sleep aid", the user's needs are different. Without considering user behavior data, it will lead to the inability to distinguish subtle differences and inaccurate correlation judgment.
[0027] In addition, related technologies also utilize text tags that users individually label for individual songs, and filter tags that have been labeled at least five times to construct a "tag-song" association library. For example, a user might label the song "Qing x Ci" as "Chinese style, lyrical". When a search text is input, the tags of the text are first extracted through keyword matching. For example, if the search text is "Chinese style song", then "Chinese style" is extracted. Then, the songs are recalled based on the "tag-song" association library. Finally, the relevance result is calculated based on the tag matching degree. For example, the relevance result can be obtained by calculating the ratio of the number of matched tags to the total number of tags in the text.
[0028] Relying on user-generated tags for individual songs can lead to issues of tag sparsity and tag lag. On the one hand, most less popular songs lack user tags and cannot participate in relevance calculations; on the other hand, after a new song is released, it needs to wait for user tags before it can be included in the search, resulting in a significant lag. Furthermore, the relevance results rely solely on tag matching, failing to capture the complex semantic relationships between the text and the song (e.g., "songs suitable for nighttime running" cannot be accurately matched using a single tag).
[0029] Based on the problems existing in related technologies, the technical solutions provided in the embodiments of this application are as follows: Figure 2 As shown. During the training process of the relevance model, at least one target multimedia resource set is selected from multiple multimedia resource sets. Based on the descriptive text of the target multimedia resource set and the multimedia resources in the target multimedia resource set, at least one training sample is generated. The training sample is then used to train the relevance model, enabling the trained relevance model to capture the relevance between the descriptive text and the multimedia resources, thereby better handling the user's search terms.
[0030] like Figure 3 As shown, during the multimedia resource search process, the user inputs search terms, and the trained relevance model converts the search terms into text vectors, which are feature representations of the search terms. The model also converts the multimedia resources recalled by the platform into multimedia vectors, with each multimedia vector corresponding to a recalled multimedia resource. The multimedia vector is a feature representation of the multimedia resource.
[0031] The text vector corresponding to the search term and the multimedia vector corresponding to the recalled multimedia resources are input into the relevance model. The relevance model outputs the relevance score between the search term and each recalled multimedia resource. Optionally, after obtaining the relevance scores between the recalled multimedia resources and the search term, the multimedia resources with higher relevance scores are displayed to the user. Optionally, the multimedia resources are displayed to the user in descending order of relevance scores.
[0032] Please refer to Figure 4The diagram illustrates a flowchart of a training method for a correlation model provided in one embodiment of this application. The execution subject of this method may be the computer device described above. The method may include at least one of the following steps (410-430).
[0033] Step 410: Select at least one target multimedia resource collection from multiple multimedia resource collections; wherein each multimedia resource collection includes at least one multimedia resource.
[0034] In some embodiments, a multimedia resource collection refers to a collection that includes at least one multimedia resource. The type of multimedia resource can be flexibly adjusted according to the application scenario. For example, multimedia resources can be audio, video, images, text, etc.
[0035] Optionally, the multimedia resource collection is a song collection or playlist, which includes at least one song; or, the multimedia resource collection is a video collection, which includes at least one video; or, the multimedia resource collection is an image collection, which includes at least one image; or, the multimedia resource collection is a text and image collection, which includes at least one image and / or text resource; or, the multimedia resource collection is a text collection, which includes at least one text document; or, the multimedia resource collection is an interactive resource collection, which includes at least one interactive resource.
[0036] Optionally, interactive resources include games, courseware, etc.
[0037] Alternatively, multimedia resource collections can be obtained through relevant platforms.
[0038] For example, a collection of multimedia resources is a playlist, and multimedia resources are songs. Multiple playlists can be obtained from relevant platforms.
[0039] Using user-created playlists to construct subsequent training samples can reduce costs, and playlists can usually reflect the collective cognition of users, which can reduce individual subjective bias and improve the consistency and generalization of training samples.
[0040] Obtaining multimedia resource collections from relevant platforms can increase the number of collected multimedia resource collections, providing a rich sample for the selection of target multimedia resource collections.
[0041] In some embodiments, at least one target multimedia resource set that meets the filtering criteria is selected from multiple multimedia resource sets.
[0042] The filtering criteria can be flexibly adjusted according to the application scenario. For example, if the multimedia resource collection is a text collection, the filtering criteria can be the number of clicks on the texts in the text collection, the reading time of the texts, etc. For example, if the multimedia resource collection is a playlist, the filtering criteria can be the number of plays of the songs in the playlist, the song playback time, etc., or the number of plays and favorites of the playlist, etc.
[0043] By setting filtering criteria, at least one target multimedia resource set can be selected from multiple multimedia resource sets. On the one hand, this improves the data quality of subsequent training samples, avoiding the impact of poor training sample data quality on the accuracy of the correlation model. On the other hand, selecting at least one target multimedia resource set that meets the filtering criteria from multiple multimedia resource sets to perform the subsequent step of generating training samples can reduce the number of training samples and improve the training efficiency of the correlation model.
[0044] Step 420: Generate at least one training sample based on the description text of the target multimedia resource collection and the multimedia resources included in the target multimedia resource collection; wherein each training sample includes a set of corresponding description text and multimedia resources.
[0045] In some embodiments, the descriptive text refers to text that describes a target multimedia resource collection. It can be obtained by summarizing the target multimedia resource collection, the content of the multimedia resources within the collection, etc. For example, if the target multimedia resource collection is a playlist, and the multimedia resources within it are upbeat tracks (i.e., songs with a strong rhythm), then the descriptive text for that target multimedia resource collection would be "upbeat tracks."
[0046] In some embodiments, training samples are used to train the relevance model. Each training sample includes a set of corresponding descriptive text and multimedia resources.
[0047] Alternatively, training samples can be represented as (descriptive text, multimedia resources); or, <descriptive text, multimedia resources>, etc.
[0048] In some embodiments, the training samples include positive samples and negative samples. Positive samples consist of a set of corresponding descriptive texts and multimedia resources that are correlated, while negative samples consist of a set of corresponding descriptive texts and multimedia resources that are not correlated.
[0049] Optionally, a positive sample is obtained from the descriptive text of the target multimedia resource collection and at least one multimedia resource included in the target multimedia resource collection.
[0050] Alternatively, negative samples can be obtained through non-intersection sampling.
[0051] For example, there are two target multimedia resource sets, which are playlists, denoted as playlist A and playlist B respectively. The description text of playlist A is "energetic songs", and the description text of playlist B is "folk songs". The multimedia resources included in playlist A include song #1 and song #2, and the multimedia resources included in playlist B include song #3. If the training sample is (energetic songs, song #1), then the training sample is a positive sample. If the training sample is (energetic songs, song #3), then the training sample is a negative sample.
[0052] Training samples are generated by using descriptive text and multimedia resources from a target multimedia resource collection, which can improve the efficiency of data annotation compared to manual annotation.
[0053] Step 430: The relevance model is trained using training samples. The relevance model is used to determine the relevance between the descriptive text and the multimedia resources.
[0054] In some embodiments, the relevance model is used to determine whether there is a relevance between the descriptive text and the multimedia resource. Relevance between the descriptive text and the multimedia resource means that the multimedia resource conforms to the semantics of the descriptive text, or in other words, matches the semantics of the descriptive text.
[0055] For example, if the description text is a popular background music track in a coffee shop, and the multimedia resource is a single track with a soothing rhythm and primarily piano or guitar instruments, then the description text and the multimedia resource are considered relevant. If the multimedia resource is a single track with a fast rhythm and an upbeat melody, then the description text and the multimedia resource are considered unrelated.
[0056] For details regarding the training process of the correlation model, please refer to the following example.
[0057] The technical solution provided in this application selects at least one target multimedia resource set from multiple multimedia resource sets, and generates training samples based on the descriptive text of the target multimedia resource set and the multimedia resources included in the target multimedia resource set to train a relevance model. On the one hand, obtaining training samples based on the descriptive text and multimedia resources of the target multimedia resource set improves the annotation efficiency of the relevance model's training samples compared to manually annotating them. On the other hand, using descriptive text and multimedia resources as training samples enables the relevance model to learn the relevance between the descriptive text and the multimedia resources, thereby improving the accuracy of the relevance model.
[0058] The following examples illustrate the method for generating training samples.
[0059] In some embodiments, at least one training sample includes at least one positive sample, each positive sample including a set of relevant descriptive text and multimedia resources.
[0060] Based on the description text of the target multimedia resource collection and the multimedia resources included in the target multimedia resource collection, generate at least one training sample, including: selecting N multimedia resources from the target multimedia resource collection, where N is a positive integer; for each of the N multimedia resources, take the description text of the target multimedia resource collection and the multimedia resource as a set of related description text and multimedia resources to obtain a positive sample.
[0061] Optionally, a set of relevant descriptive texts and multimedia resources refers to the semantic matching between the content of the multimedia resources and the descriptive texts.
[0062] In some embodiments, N is determined based on the actual application scenario. Optionally, when training the correlation model using a small number of samples, the value of N can be appropriately reduced to meet the needs of small-sample training. Optionally, when a large number of training samples are required to train the correlation model, the value of N can be appropriately increased.
[0063] For example, N is the number of multimedia resources included in the target multimedia resource collection, that is, each multimedia resource in the target multimedia resource collection is combined with the description text of the target multimedia resource collection as a positive sample.
[0064] Optionally, positive samples can be represented as “description text - multimedia resource”; or, “(description text, multimedia resource)”; or, <description text, multimedia resource>, etc.
[0065] For example, the target multimedia resource collection is a playlist, and the description text of the target multimedia resource collection is the title text of the playlist. For each song included in the playlist of the target multimedia resource collection, the title text of the playlist and the songs are treated as a set of related title text and songs to obtain a positive sample. The title of the target multimedia resource collection is "High-energy music suitable for night running", which contains 3 songs. The names of the 3 songs are song #1, song #2 and song #3. The generated positive samples include: ("High-energy music suitable for night running", song #1), ("High-energy music suitable for night running", song #1), ("High-energy music suitable for night running", song #1).
[0066] By generating corresponding positive samples for each song in each playlist, the number of positive samples can be increased, and less popular songs and new songs can be taken into account. In subsequent model training, more training samples can also increase the generalization ability of the model.
[0067] By selecting N multimedia resources from the target multimedia resource set and generating corresponding positive samples for each of the N resources, two advantages are achieved. First, the value of N can be determined based on the actual situation, thereby generating a number of positive samples that match the reality, making the sample distribution in the training samples more closely resemble the real-world scenario. Second, compared to manually annotating training samples, this reduces the annotation cost of training samples for the relevance model.
[0068] In some embodiments, at least one training sample includes at least one negative sample, each negative sample including a set of unrelated descriptive text and multimedia resources; Based on the description text of the target multimedia resource collection and the multimedia resources included in the target multimedia resource collection, generate at least one training sample, including: selecting M multimedia resources from the target set, where the target set is a set of other multimedia resources besides those included in the target multimedia resource collection, and M is a positive integer; for each of the M multimedia resources, treat the description text of the target multimedia resource collection and the multimedia resource as a set of unrelated description text and multimedia resources to obtain a negative sample.
[0069] Optionally, a set of unrelated descriptive texts and multimedia resources refers to a set of multimedia resources whose content does not match the semantics of the descriptive texts.
[0070] In some embodiments, M is determined based on the actual application scenario. Optionally, when training the correlation model using a small number of samples, the value of M can be appropriately reduced to meet the needs of small-sample training. Optionally, when a large number of training samples are required to train the correlation model, the value of M can be appropriately increased.
[0071] Optionally, the target set is a collection of multimedia resources other than those included in the target multimedia resource collection.
[0072] Optionally, different target multimedia resources correspond to different target sets.
[0073] Optionally, other multimedia resources may be extracted from other target multimedia resource collections, or from other multimedia resource collections other than the target multimedia resource collection.
[0074] For example, the target multimedia resource collection is a playlist, including playlist A and playlist B, wherein the description text of playlist A is "energetic tracks" and the description text of playlist B is "lullaby tracks". Playlist A includes song #1, song #2 and song #3, and playlist B includes song #4 and song #5.
[0075] Taking the generation of negative samples for playlist A as an example, M multimedia resources are selected from the target set. The target set consists of song #4 and song #5. When M is 2, two multimedia resources are selected from the target set, and the description text of playlist A, "Burning Song", and the selected songs #4 and #5 are combined to obtain two negative samples, namely "Burning Song, Song #4" and "Burning Song, Song #5".
[0076] For example, a multimedia resource collection is a playlist, wherein multiple multimedia resource collections include playlist A, playlist B, and playlist C. Playlist A and playlist B are selected as target multimedia resource collections. The description text of playlist A is "energetic music," the description text of playlist B is "lullaby music," and playlist B includes song #1 and song #2. The description text of playlist C is "folk music," and playlist C includes song #3 and song #4.
[0077] Taking the generation of negative samples for playlist A as an example, the target set includes songs #1 and #2 from playlist B, and songs #3 and #4 from playlist C. When M is 1, the negative sample can be one of "High-energy song, #1", "High-energy song, #2", "High-energy song, #3", or "High-energy song, #4".
[0078] Optionally, the description text for the playlist is the title text.
[0079] The correlation between playlist titles and songs within the playlist has been collectively verified by users. Songs not included in the playlist have low semantic matching with the playlist title text, resulting in a low negative sample noise rate. For example, analysis of the experimental results shows that the negative sample noise rate can reach less than 0.1%.
[0080] In some embodiments, the selection of M multimedia resources from the target set can be done by random sampling or by sampling multimedia resources that have some of the same characteristics as the multimedia resources in the target multimedia resource set.
[0081] Optionally, the multimedia resource collection is a playlist, and the multimedia resources are songs. Songs are randomly selected from songs in the non-target playlist to obtain at least one negative sample.
[0082] Optionally, the multimedia resource collection is a playlist, and the multimedia resources are songs. Songs with the same style as the songs in the target playlist are extracted. The description text of the target song and the songs with the same style as the songs in the target playlist are taken as a group of unrelated description text and songs to obtain a negative sample.
[0083] For example, a multimedia resource collection is a playlist, and multimedia resources are songs. The descriptive text of the target multimedia resource collection is "energetic music for nighttime running," meaning the playlist's style tag is "energetic music." The target set of this playlist can include at least one song with the style tag "energetic music." Then, the descriptive text of the target multimedia resource collection and the songs with the style tag "energetic music" extracted from the target set are treated as a set of unrelated descriptive text and songs, resulting in a negative sample.
[0084] Optionally, the target set includes: songs with the style tag "energetic" from all singles on the platform, excluding the songs included in this playlist.
[0085] By extracting multimedia resources that share some characteristics with the target multimedia resource set, negative samples can be obtained, which can further reduce the noise rate of negative samples and improve the training accuracy of the correlation model.
[0086] By selecting multimedia resources from the target set and treating the descriptive text and multimedia resources of the target multimedia resource set as a group of unrelated descriptive text and multimedia resources, negative samples are obtained. This method can automatically generate negative samples, reducing the annotation cost of training samples for relevance models.
[0087] In some embodiments, the multimedia resource collection is a playlist, and the flowchart of the training sample generation method is as follows: Figure 5 As shown, first, a playlist pool is input, containing several playlists. Then, the playlists in the playlist pool are input to the filtering module. The filtering module filters the playlists in the playlist pool based on the number of plays and / or favorites. The filtered playlists are then input to the positive sample generation module and the negative sample generation module to generate positive and negative samples, respectively. The positive and negative samples are combined to output as a data sample library.
[0088] The execution steps for the positive sample generation module to generate positive samples and the negative sample generation module to generate negative samples are as described above, and will not be repeated here.
[0089] The following examples illustrate the method for selecting a target multimedia resource collection.
[0090] In some embodiments, selecting at least one target multimedia resource set from a plurality of multimedia resource sets includes: selecting at least one multimedia resource set that meets the filtering criteria from a plurality of multimedia resource sets as at least one target multimedia resource set.
[0091] Optionally, the filtering criteria can be determined based on the application scenario.
[0092] By setting filtering criteria, multimedia resource sets that meet the criteria can be selected from multiple sets of multimedia resources as at least one target multimedia resource set. This can improve the sample quality of the training samples.
[0093] In some embodiments, the filtering criteria include one or more of the following: the number of plays of the multimedia resource collection is greater than or equal to the number of plays; the number of favorites of the multimedia resource collection is greater than or equal to the number of favorites; the number of interactions of the multimedia resource collection is greater than or equal to the number of interactions.
[0094] Optionally, the play count refers to the sum of the play counts of the multimedia resources in the multimedia resource collection. For example, if the multimedia resource collection is a playlist containing 5 songs, then the play count of the multimedia resource collection is the sum of the play counts of the 5 songs.
[0095] Optionally, play count refers to the sum of the number of times a multimedia resource collection is played.
[0096] Optionally, the number of times a multimedia resource collection is played refers to the number of times at least one multimedia resource in the collection is played. For example, if the multimedia resource collection is a playlist, and a playlist is played once, then if at least one song in the playlist is played, then one play count is recorded.
[0097] Optionally, the number of favorites refers to the total number of times a multimedia resource collection has been marked as "favorited" by a user.
[0098] Optionally, interaction volume refers to the cumulative sum of various interactive behaviors initiated by users on the multimedia resource collection. Optionally, interactive behaviors include forwarding, commenting, liking, etc.
[0099] Optionally, interaction volume refers to the statistical value of a certain type of interaction initiated by users on a multimedia resource collection. For example, interaction volume refers to the statistical value of users liking a multimedia resource collection.
[0100] For example, a multimedia resource collection is a playlist collected from the platform, and the filtering criteria include: the multimedia resource collection has been played more than or equal to 100 times and / or the multimedia resource collection has been favorited more than or equal to 10 times.
[0101] The filtering criteria include ensuring that the number of views for a multimedia resource collection is greater than or equal to a certain threshold, thus excluding collections with no practical value. Another filtering criterion is that the number of favorites for a multimedia resource collection is greater than or equal to a certain threshold, ensuring that the multimedia resources included in the collection align with the aesthetic and semantic understanding of some users.
[0102] By setting filtering criteria, including one or more of the following: number of views, number of favorites, and number of interactions, the data quality of the target multimedia resource collection can be improved, thereby enhancing the quality of subsequent training samples.
[0103] The following explains the method for training the correlation model using training samples. Please refer to [link / reference needed]. Figure 6 The diagram illustrates a flowchart of a method for training a correlation model using training samples, according to another embodiment of this application. The method can be executed by the computer device described above. The method may include at least one of the following steps (610-630).
[0104] Step 610: Input the descriptive text and multimedia resources included in the training samples into the relevance model, and have the relevance model output the relevance score corresponding to the training samples; wherein, the relevance score corresponding to the training samples is used to indicate the relevance between the descriptive text and multimedia resources included in the training samples.
[0105] Optionally, the relevance model receives training samples and processes the descriptive text and multimedia resources included in the training samples in a unified manner, that is, it directly calculates the relevance score corresponding to the training samples.
[0106] By directly processing descriptive text and multimedia resources through a relevance model to obtain corresponding relevance scores, the relevance model can directly learn the relevance between descriptive text and multimedia resources.
[0107] Optionally, the relevance model receives training samples and processes the descriptive text and multimedia resources included in the training samples separately to obtain the relevance score corresponding to the training samples.
[0108] After processing the descriptive text and multimedia resources separately, the relevance model obtains the relevance scores corresponding to the training samples, which enables the relevance model to better learn the features of the descriptive text and multimedia resources.
[0109] In some embodiments, step 610 above includes: Step 611: Input the descriptive text and multimedia resources into the relevance model, and extract the text vector and multimedia vector from the relevance model; wherein, the text vector is the feature representation of the descriptive text, and the multimedia vector is the feature representation of the multimedia resources.
[0110] Optionally, the relevance model uses a language processing module to transform the descriptive text into text vectors. The language processing module is the module capable of converting natural language into feature vectors.
[0111] Optionally, the language processing module is an LLM (Large Language Model).
[0112] For example, the language processing module uses the 7B parameter version of the Qwen3 model, inputting descriptive text into the Qwen3 model and extracting the output of the last hidden layer of the Qwen3 model as a text vector. The Qwen3 model is an LLM model, possessing excellent text understanding and vector generation capabilities, capable of transforming natural language text into high-dimensional semantic vectors.
[0113] For example, the language processing model uses the 7B parameter version of the Llama3 model.
[0114] By processing the descriptive text through the language processing module, the relevance model can better capture the semantic features of the descriptive text.
[0115] Optionally, the text vector has a dimension of 1024.
[0116] Optionally, the relevance model converts multimedia resources into feature vectors based on their type.
[0117] For example, the multimedia resource is a song, and a unique identifier is assigned to each song. The multimedia vector is initialized as a random vector, and the multimedia vector is iteratively optimized during the training of the relevance model.
[0118] Optionally, the initialized multimedia vector is a 1024-dimensional random vector.
[0119] Optionally, the random vector has a mean of 0 and a standard deviation of 0.01.
[0120] Step 612: Concatenate the text vector and the multimedia vector to obtain the concatenated vector.
[0121] Alternatively, the text vector and multimedia vector can be directly concatenated to obtain the concatenated vector.
[0122] For example, the text vector has a dimension of 1024, and the multimedia vector also has a dimension of 1024. They are directly concatenated to obtain a concatenated vector with a dimension of 2048.
[0123] Optionally, the text vector and multimedia vector can be ordered as follows: text vector first, multimedia vector second; or multimedia vector first, text vector second.
[0124] Step 613: Perform feature crossing on the concatenated vectors to obtain the feature crossing result.
[0125] Optionally, feature crossing can be performed on the concatenated vectors using a neural network.
[0126] For example, the concatenated vector is input into a DCN (Deep & Cross Network) for feature crossing. A DCN is a deep learning architecture for feature crossing that effectively captures the complex interactions between input features.
[0127] Optionally, the DCN includes two layers of cross-networks, each of which is calculated using the following formula:
[0128] Where, x L+1 The output of the (L+1)th layer cross-connection is given, where x0 is the initial concatenation vector. L For the output of the Lth layer cross-connect network, w L and b L These are trainable parameters.
[0129] For example, the concatenated vector is input into an FM (Factorization Machine) for feature crossing.
[0130] The concatenated vectors are crossed through FM, which can capture the feature cross relationships through matrix factorization. Compared with DCN, FM has a more lightweight structure, which can improve the training speed of the correlation model and is suitable for scenarios with limited computing power.
[0131] By performing feature crossing on the concatenated vectors, the complex interactive relationships between features can be effectively captured.
[0132] Step 614: Based on the feature cross-results, obtain the relevance scores corresponding to the training samples.
[0133] Optionally, the feature cross-processing result is input into an MLP (Multi-Layer Perceptron), and the output of the MLP is then fed into an activation function. The output of the activation function is the relevance score corresponding to the training sample.
[0134] MLP is a neural network consisting of an input layer, a hidden layer, and an output layer, used for nonlinear feature fitting and classification tasks.
[0135] Optionally, the feature cross-processing result is input into a two-layer MLP, the output of the second-layer MLP is connected to an activation function, and the output of the activation function is the relevance score corresponding to the training sample.
[0136] For example, the first MLP layer includes 512 neurons and the activation function of the first MLP layer is the ReLU function, and the second MLP layer includes 256 neurons and the activation function of the second MLP layer is also the ReLU function.
[0137] For example, the activation function used for the output of the MLP is the Sigmoid activation function, with an output value ranging from 0 to 1. That is, the relevance score ranges from [0,1], where 0 represents no relevance and 1 represents relevance. The closer the relevance score is to 0, the weaker the relevance; the closer the relevance score is to 1, the stronger the relevance.
[0138] Step 620: Determine the loss function value of the correlation model based on the correlation score and correlation label corresponding to the training sample; wherein the loss function value is used to indicate the difference between the correlation score and the correlation label.
[0139] Optionally, the relevance label refers to a label that can describe the relevance between the descriptive text and multimedia resources included in the training samples.
[0140] Optionally, relevance labels can be indicated by the numbers 1 and 0; or the English words “True” and “False”; or the words “Yes” and “No”.
[0141] Optionally, a relevance label of 1 for a training sample indicates that the descriptive text and multimedia resources included in the training sample are related. A relevance label of 0 for a training sample indicates that the descriptive text and multimedia resources included in the training sample are not related.
[0142] Optionally, when the training sample is a positive sample, the correlation label of the training sample is 1, and when the training sample is a negative sample, the correlation label of the training sample is 0.
[0143] Alternatively, when the relevance label is represented by the numbers 1 and 0, the loss function value can be obtained by directly calculating the absolute value of the difference between the relevance label and the relevance score.
[0144] Optionally, when the relevance label is represented in other forms, it is first converted into the form of numbers 0 or 1, and then the absolute value of the difference between the relevance label and the relevance score is calculated to obtain the loss function value.
[0145] Optionally, the loss function value is calculated using the binary cross-entropy loss.
[0146] Step 630: Adjust the parameters of the correlation model with the goal of minimizing the loss function value to obtain the trained correlation model.
[0147] By reducing the loss function value and adjusting the parameters of the relevance model, the accuracy of the trained relevance model can be improved. This, in turn, enhances the accuracy of retrieving multimedia resources based on user-provided search terms.
[0148] For example, a collection of multimedia resources is a playlist, and the multimedia resources are songs, such as... Figure 7 As shown, the natural language text, i.e., the descriptive text of the multimedia resource collection, is input into the Qwen-LLM model to obtain the vector form of the textual semantic features of the descriptive text and to obtain the song features. Both the textual semantic features and the song features are then input into a deep cross-network, which captures the complex interaction between the textual semantic features and the song features, such as the interaction between the text "night running" and the song's features of "fast tempo and strong drumbeats". The output of the deep cross-network is then input into the MLP, and the output of the MLP is input into the Sigmoid activation function. The output value of the Sigmoid activation function is the relevance score between the descriptive text and the song.
[0149] Optionally, the description text of the playlist is the title text of the playlist.
[0150] For example, the training parameters of the correlation model include: (1) Optimizer: AdamW, with an initial learning rate of 5e-5 and a linear decay strategy.
[0151] (2) Batch Size: 1024.
[0152] (3) Training epochs: 10 epochs, with an early stop strategy (if the validation set loss does not decrease for 3 consecutive epochs, training is stopped).
[0153] (4) Data partitioning: The ratio of training set, validation set and test set is 8:1:1.
[0154] In some embodiments, incremental training of the correlation model is initiated when the newly added multimedia resource collection reaches a first quantity or the usage time of the correlation model exceeds a first duration.
[0155] Optionally, the value of the first quantity is determined based on the source of the multimedia resource collection. For example, if the multimedia resource collection has many sources, the first quantity will be larger. If the multimedia resource collection has only one source, the first quantity will be smaller.
[0156] Determining the initial quantity based on the sources of the multimedia resource collection can prevent newly added multimedia resource collections from reaching the initial quantity too quickly due to abundant sources, thus avoiding frequent training of the relevance model. It can also alleviate the problem of newly added multimedia resource collections struggling to reach the initial quantity due to a single source, preventing the relevance model from being updated in a timely manner.
[0157] Optionally, the value of the first duration is determined based on the application scenario of the relevance model. For example, if the multimedia resource collection is a collection of historical artifact images, the first duration will be relatively large. Alternatively, if the multimedia resource collection is a collection of songs, the first duration will be relatively small.
[0158] Determining the value of the first duration based on the application scenario of the relevance model can alleviate the problem of the relevance model failing to match the user's semantic cognition due to an excessively long first duration, and can also alleviate the problem of the training cost of the relevance model increasing due to an excessively short first duration.
[0159] Optionally, incremental training of the correlation model can be performed using newly added training samples.
[0160] Optionally, incremental training of the correlation model can reuse the parameters of an existing correlation model as initial values.
[0161] Optionally, the number of training rounds for incremental training of the correlation model can be reduced.
[0162] For example, a multimedia resource collection is a playlist, and the multimedia resources are songs. When the platform adds a certain number of new playlists, incremental training of the relevance model is initiated. From the newly added playlists, at least one target playlist is selected, and at least one training sample is generated based on the description text of the target playlist and the songs included in the target playlist. The parameters of the existing relevance model are reused as initial values for incremental training of the relevance model. The incremental training consists of three rounds.
[0163] By incrementally training the model, it can be ensured that the relevance model can adapt to new user semantic cognition in real time.
[0164] The following examples illustrate the method for obtaining descriptive text.
[0165] In some embodiments, the title text of the target multimedia resource collection is determined as the description text of the target multimedia resource collection.
[0166] Optionally, the title text of the target multimedia resource collection can be directly used as the description text of the target multimedia resource collection.
[0167] Using the title text of the target multimedia resource collection directly as the description text can improve the efficiency of description text retrieval.
[0168] Optionally, a language processing model can be used to extract text related to the features of the multimedia resources in the target multimedia resource collection from the title text of the target multimedia resource collection as descriptive text.
[0169] By linking the features between text semantics and multimedia resources through group behavior data, it is possible to directly capture users' semantic contextual understanding of multimedia resources, thereby alleviating the problem of semantic disconnect. Group behavior refers to the collective actions of several users on the platform in creating, using, and interacting with each other. The correlation between the titles of the resulting multimedia resource collections and the multimedia resources themselves implicitly reflects the public's understanding of the matching between text semantics and multimedia resources.
[0170] In addition, from the title text of the target multimedia resource collection, text related to the features of the multimedia resources in the target multimedia resource collection is extracted as descriptive text. On the one hand, extracting from the title text can improve the efficiency of obtaining descriptive text compared to identifying the features of a large number of multimedia resources.
[0171] In some embodiments, relevant information of the target multimedia resource collection is identified to obtain a descriptive text of the target multimedia resource collection; wherein, the relevant information includes one or more of the following: the title text of the target multimedia resource collection, the content of the target multimedia resource collection, the comment information of the target multimedia resource collection, the introduction information of the target multimedia resource collection, and the tag information of the target multimedia resource collection.
[0172] Optionally, a language processing model can be used to identify relevant information about the target multimedia resource collection and obtain a descriptive text of the media resource collection.
[0173] Optionally, the content of the target multimedia resource collection refers to the content of the multimedia resources included in the target multimedia resource collection. For example, if the target multimedia resource collection is a text collection, the content of the target multimedia resource collection refers to the text content included in the text collection.
[0174] Optionally, the comment information of the target multimedia resource collection refers to the comment information of users on the target multimedia resource collection.
[0175] Optionally, the introductory information of the target multimedia resource collection refers to information that introduces the multimedia resources in the target multimedia resource collection. For example, the introductory information of the target multimedia resource collection may be a brief description or recommendation of the target multimedia resource collection.
[0176] Optionally, the tag information of the target multimedia resource collection refers to tags that can represent the characteristics of the multimedia resources in the target multimedia resource collection. For example, if the target multimedia resource collection is a playlist, and the multimedia resources included are upbeat tracks, then the tag information of the target multimedia resource collection is upbeat tracks.
[0177] The following examples illustrate the application scenarios of the correlation model.
[0178] For example, the relevance model is applied in a music semantic search scenario. A user enters the text "songs suitable for nighttime running" into the search box of a music app. The system calls a language processing model (such as the Qwen3 model) to convert the input text into a 1024-dimensional text vector. Then, it loads the trained relevance model, inputting the text vector and the song vectors of the songs retrieved by the platform one by one into the relevance model. The relevance model outputs a relevance score for each song, and then returns songs with a relevance score greater than 0.8 as search results, in descending order of score. The returned songs are mostly of the "fast-paced, upbeat melody" type, which matches the user's need for a "nighttime running" scenario.
[0179] For example, the relevance model is applied in a music semantic search scenario. A user enters the text "popular background music for coffee shops" into the search box of a music app. The system calls a language processing model (such as the Qwen3 model) to convert the input text into a 1024-dimensional text vector. Then, it loads the trained relevance model, inputting the text vector and the song vectors of the songs retrieved by the platform one by one into the relevance model. The relevance model outputs a relevance score for each song, and then returns songs with a relevance score greater than 0.8 as search results, in descending order of score. The returned songs are mostly of the "slow tempo, with piano or guitar as the main instruments," which matches the atmosphere required for a coffee shop.
[0180] The above description of model selection and vector dimension is merely exemplary and explanatory. For example, in addition to the 1024 dimensions mentioned above, the vector dimension can also be 512 dimensions, 256 dimensions, etc. In practical applications, appropriate models and vector dimensions can be selected according to actual needs. This application does not limit this.
[0181] The following are embodiments of the apparatus described in this application, which can be used to execute the embodiments of the method described in this application. For details not disclosed in the apparatus embodiments of this application, please refer to the embodiments of the method described in this application.
[0182] Please refer to Figure 8 This diagram illustrates a block diagram of a training apparatus for a correlation model according to an embodiment of this application. The apparatus has the functionality to implement the method example described above, and can be implemented in hardware or by hardware executing corresponding software. Optionally, the apparatus can be a computer device or can be housed within a computer device. Figure 8 As shown, the device 800 may include: a selection module 810, a generation module 820, and a training module 830.
[0183] Selection module 810 is used to select at least one target multimedia resource collection from multiple multimedia resource collections; wherein each multimedia resource collection includes at least one multimedia resource.
[0184] The generation module 820 is used to generate at least one training sample based on the description text of the target multimedia resource collection and the multimedia resources included in the target multimedia resource collection; wherein each training sample includes a set of corresponding description text and multimedia resources.
[0185] Training module 830 is used to train the relevance model using training samples. The relevance model is used to determine the relevance between descriptive text and multimedia resources.
[0186] In some embodiments, at least one training sample includes at least one positive sample, each positive sample including a set of related descriptive text and multimedia resources; the generation module 820 is used to select N multimedia resources from the target multimedia resource set, where N is a positive integer; for each of the N multimedia resources, the descriptive text and multimedia resources of the target multimedia resource set are used as a set of related descriptive text and multimedia resources to obtain a positive sample.
[0187] In some embodiments, at least one training sample includes at least one negative sample, each negative sample including a set of unrelated descriptive text and multimedia resources; the generation module 820 is used to select M multimedia resources from the target set, the target set being a set of other multimedia resources besides those included in the target multimedia resource set, where M is a positive integer; for each of the M multimedia resources, the descriptive text and multimedia resources of the target multimedia resource set are used as a set of unrelated descriptive text and multimedia resources to obtain a negative sample.
[0188] In some embodiments, the selection module 810 is configured to select at least one multimedia resource set that meets the filtering criteria from a plurality of multimedia resource sets as at least one target multimedia resource set.
[0189] In some embodiments, the filtering criteria include one or more of the following: the number of plays of the multimedia resource collection is greater than or equal to the number of plays; the number of favorites of the multimedia resource collection is greater than or equal to the number of favorites; the number of interactions of the multimedia resource collection is greater than or equal to the number of interactions.
[0190] In some embodiments, the training module 830 is configured to input the descriptive text and multimedia resources included in the training samples into the relevance model, and the relevance model outputs the relevance score corresponding to the training samples; wherein the relevance score corresponding to the training samples is used to indicate the relevance between the descriptive text and multimedia resources included in the training samples; determine the loss function value of the relevance model based on the relevance score and relevance label corresponding to the training samples; wherein the loss function value is used to indicate the difference between the relevance score and the relevance label; and adjust the parameters of the relevance model with the goal of minimizing the loss function value to obtain the trained relevance model.
[0191] In some embodiments, the training module 830 is used to input descriptive text and multimedia resources into a relevance model, and the relevance model extracts text vectors and multimedia vectors; wherein, the text vector is a feature representation of the descriptive text, and the multimedia vector is a feature representation of the multimedia resources; the text vector and the multimedia vector are concatenated to obtain a concatenated vector; feature crossing is performed on the concatenated vector to obtain a feature crossing result; and the relevance score corresponding to the training sample is obtained based on the feature crossing result.
[0192] In some embodiments, the apparatus 800 further includes: a determining module ( Figure 8 (Not shown in the image).
[0193] The determination module is used to determine the title text of the target multimedia resource collection as the description text of the target multimedia resource collection; or, to identify relevant information of the target multimedia resource collection to obtain the description text of the target multimedia resource collection; wherein, the relevant information includes one or more of the following: the title text of the target multimedia resource collection, the content of the target multimedia resource collection, the comment information of the target multimedia resource collection, the introduction information of the target multimedia resource collection, and the tag information of the target multimedia resource collection.
[0194] In some embodiments, the multimedia resource collection is a song collection or playlist, which includes at least one song; or, the multimedia resource collection is a video collection, which includes at least one video; or, the multimedia resource collection is an image collection, which includes at least one image; or, the multimedia resource collection is a text and image collection, which includes at least one image and / or text resource; or, the multimedia resource collection is a text collection, which includes at least one text document; or, the multimedia resource collection is an interactive resource collection, which includes at least one interactive resource.
[0195] It should be noted that the apparatus provided in the above embodiments is only illustrated by the division of the above functional modules when implementing its functions. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. In addition, the apparatus and method embodiments provided in the above embodiments belong to the same concept, and the specific implementation process can be found in the method embodiments, which will not be repeated here.
[0196] Please refer to Figure 9 The diagram shows a structural block diagram of a computer device 900 provided in one embodiment of this application.
[0197] Typically, computer device 900 includes a processor 910 and a memory 920.
[0198] Processor 910 may include one or more processing cores, such as a quad-core processor or an octa-core processor. Processor 910 may be implemented using at least one hardware form selected from DSP (Digital Signal Processing), FPGA (Field Programmable Gate Array), and PLA (Programmable Logic Array). Processor 910 may also include a main processor and a coprocessor. The main processor, also known as a CPU (Central Processing Unit), is used to process data in the wake-up state; the coprocessor is a low-power processor used to process data in the standby state. In some embodiments, processor 910 may integrate a GPU (Graphics Processing Unit), which is responsible for rendering and drawing the content to be displayed on the screen. In some embodiments, processor 910 may also include an AI processor for handling computational operations related to machine learning.
[0199] The memory 920 may include one or more computer-readable storage media, which may be non-transitory. The memory 920 may also include high-speed random access memory and non-volatile memory, such as one or more disk storage devices or flash memory devices. In some embodiments, the non-transitory computer-readable storage media in the memory 920 are used to store a computer program configured to be executed by one or more processors to implement the above-described training method for the correlation model.
[0200] Those skilled in the art will understand that Figure 9The structure shown does not constitute a limitation on the computer device 900, and may include more or fewer components than shown, or combine certain components, or use different component arrangements.
[0201] In an exemplary embodiment, a computer-readable storage medium is also provided, wherein a computer program is stored in the storage medium, and the computer program, when executed by a processor, implements the training method of the aforementioned correlation model. Optionally, the computer-readable storage medium may include: ROM (Read-Only Memory), RAM (Random Access Memory), SSD (Solid State Drives), or optical disc, etc. The random access memory may include ReRAM (Resistance Random Access Memory) and DRAM (Dynamic Random Access Memory).
[0202] In an exemplary embodiment, a computer program product is also provided, the computer program product including a computer program executed by a processor, causing the computer device to perform the training method of the above-described correlation model.
[0203] It should be noted that the collection and processing of relevant data in this application (including but not limited to the multimedia resources, multimedia resource collections, interactive data, etc. mentioned above) should strictly comply with the requirements of relevant national laws and regulations, obtain the informed consent or separate consent of the personal information subject, and carry out subsequent data use and processing within the scope of laws and regulations and the authorization of the personal information subject.
[0204] It should be understood that "multiple" as used herein refers to two or more. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A alone, A and B simultaneously, or B alone. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. Furthermore, the step numbers described herein are merely illustrative of one possible execution order. In some other embodiments, the steps may not be executed in numerical order, such as two steps with different numbers being executed simultaneously, or two steps with different numbers being executed in the reverse order of the illustration. This application does not limit this.
[0205] The above description is merely an exemplary embodiment of this application and is not intended to limit this application. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the protection scope of this application.
Claims
1. A training method for a correlation model, characterized in that, The method includes: From a plurality of multimedia resource collections, at least one target multimedia resource collection is selected; wherein each multimedia resource collection includes at least one multimedia resource; Based on the description text of the target multimedia resource collection and the multimedia resources included in the target multimedia resource collection, at least one training sample is generated; wherein each training sample includes a corresponding set of description text and multimedia resources; The relevance model is trained using the training samples, and the relevance model is used to determine the relevance between the descriptive text and the multimedia resource.
2. The method of claim 1, wherein, The at least one training sample includes at least one positive sample, and each positive sample includes a set of relevant descriptive text and multimedia resources; The step of generating at least one training sample based on the description text of the target multimedia resource collection and the multimedia resources included in the target multimedia resource collection includes: Select N multimedia resources from the target multimedia resource set, where N is a positive integer; For each of the N multimedia resources, the description text of the target multimedia resource set and the multimedia resource are taken as a group of related description text and multimedia resources to obtain a positive sample.
3. The method of claim 1, wherein, The at least one training sample includes at least one negative sample, and each negative sample includes a set of unrelated descriptive text and multimedia resources; The step of generating at least one training sample based on the description text of the target multimedia resource collection and the multimedia resources included in the target multimedia resource collection includes: Select M multimedia resources from the target set, where the target set is a set of other multimedia resources besides those included in the target multimedia resource collection, and M is a positive integer; For each of the M multimedia resources, the description text of the target multimedia resource set and the multimedia resource are treated as a set of unrelated description text and multimedia resources to obtain a negative sample.
4. The method of claim 1, wherein, Selecting at least one target multimedia resource set from multiple multimedia resource sets includes: From the plurality of multimedia resource collections, at least one multimedia resource collection that meets the filtering criteria is selected as the at least one target multimedia resource collection.
5. The method according to claim 4, characterized in that, The filtering criteria include one or more of the following: The number of plays for the multimedia resource collection is greater than or equal to the play count threshold. The collection size of the multimedia resource collection is greater than or equal to the collection size threshold. The interaction volume of the multimedia resource collection is greater than or equal to the interaction volume threshold.
6. The method according to claim 1, characterized in that, The step of training the correlation model using the training samples includes: The training samples, including descriptive text and multimedia resources, are input into the relevance model, which outputs a relevance score corresponding to the training samples. The relevance score corresponding to the training samples is used to indicate the relevance between the descriptive text and multimedia resources included in the training samples. Based on the relevance scores and relevance labels corresponding to the training samples, the loss function value of the relevance model is determined; wherein, the loss function value is used to indicate the difference between the relevance scores and the relevance labels; With the goal of minimizing the loss function value, the parameters of the correlation model are adjusted to obtain the trained correlation model.
7. The method according to claim 6, characterized in that, The step of inputting the descriptive text and multimedia resources included in the training samples into the relevance model, and having the relevance model output the relevance score corresponding to the training samples, includes: The descriptive text and the multimedia resources are input into the relevance model, and the relevance model extracts text vectors and multimedia vectors; wherein, the text vector is the feature representation of the descriptive text, and the multimedia vector is the feature representation of the multimedia resources; The text vector and the multimedia vector are concatenated to obtain a concatenated vector; Perform feature crossing on the concatenated vectors to obtain the feature crossing result; Based on the feature crossover results, the relevance score corresponding to the training sample is obtained.
8. The method according to claim 1, characterized in that, The method further includes: The title text of the target multimedia resource collection is determined as the description text of the target multimedia resource collection; or, Identify relevant information about the target multimedia resource collection to obtain a descriptive text for the target multimedia resource collection; wherein, the relevant information includes one or more of the following: the title text of the target multimedia resource collection, the content of the target multimedia resource collection, the comment information of the target multimedia resource collection, the introduction information of the target multimedia resource collection, and the tag information of the target multimedia resource collection.
9. The method according to any one of claims 1 to 8, characterized in that, The multimedia resource collection is a song collection or playlist, which includes at least one song; or... The multimedia resource collection is a video collection, and the video collection includes at least one video; or... The multimedia resource collection is an image collection, which includes at least one image; or... The multimedia resource collection is a text and image collection, which includes at least one image and / or text resource; or, The multimedia resource collection is a text collection, which includes at least one text; or... The multimedia resource collection is an interactive resource collection, which includes at least one interactive resource.
10. A computer device, characterized in that, The computer device includes a processor and a memory, the memory storing a computer program that is loaded and executed by the processor to implement the training method of the correlation model as described in any one of claims 1 to 9.
11. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program, which is loaded and executed by a processor to implement the training method of the correlation model as described in any one of claims 1 to 9.
12. A computer program product, characterized in that, The computer program product includes a computer program executed by a processor to implement the training method of the correlation model as described in any one of claims 1 to 9.