CN114860988A - Video media asset recommendation and sorting method and device and electronic equipment - Google Patents

Video media asset recommendation and sorting method and device and electronic equipment Download PDF

Info

Publication number
CN114860988A
CN114860988A CN202110151110.8A CN202110151110A CN114860988A CN 114860988 A CN114860988 A CN 114860988A CN 202110151110 A CN202110151110 A CN 202110151110A CN 114860988 A CN114860988 A CN 114860988A
Authority
CN
China
Prior art keywords
video
model
user
feature
sequencing
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202110151110.8A
Other languages
Chinese (zh)
Inventor
钱钧
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Mobile Communications Group Co Ltd
China Mobile Communications Ltd Research Institute
Original Assignee
China Mobile Communications Group Co Ltd
China Mobile Communications Ltd Research Institute
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Mobile Communications Group Co Ltd, China Mobile Communications Ltd Research Institute filed Critical China Mobile Communications Group Co Ltd
Priority to CN202110151110.8A priority Critical patent/CN114860988A/en
Publication of CN114860988A publication Critical patent/CN114860988A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/70Information retrieval; Database structures therefor; File system structures therefor of video data
    • G06F16/73Querying
    • G06F16/735Filtering based on additional data, e.g. user or group profiles
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/70Information retrieval; Database structures therefor; File system structures therefor of video data
    • G06F16/73Querying
    • G06F16/738Presentation of query results
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/06Buying, selling or leasing transactions
    • G06Q30/0601Electronic shopping [e-shopping]
    • G06Q30/0631Item recommendations
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/47End-user applications
    • H04N21/482End-user interface for program selection
    • H04N21/4826End-user interface for program selection using recommendation lists, e.g. of programs or channels sorted out according to their score

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Business, Economics & Management (AREA)
  • Multimedia (AREA)
  • General Physics & Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Accounting & Taxation (AREA)
  • Data Mining & Analysis (AREA)
  • Finance (AREA)
  • Computational Linguistics (AREA)
  • Development Economics (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • General Business, Economics & Management (AREA)
  • Strategic Management (AREA)
  • Software Systems (AREA)
  • Human Computer Interaction (AREA)
  • Signal Processing (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)

Abstract

The invention provides a method, a device and electronic equipment for recommending and sequencing video media assets, wherein the method comprises the following steps: constructing a feature matrix for media asset prediction; the characteristic matrix is composed of video media asset characteristics, user characteristics and cross characteristics; inputting the characteristic matrix into a target video sequencing model to obtain a sequencing value of the medium resource to be predicted, which is output by the target video sequencing model; and obtaining a video media asset recommendation sequencing result according to the sequencing value. According to the embodiment of the application, the feature matrix is constructed according to the video media asset features, the user features and the cross features, and the feature matrix is input into the trained target video ranking model for prediction, so that the recommended ranking result of the media assets to be predicted is obtained, integration of model training, online prediction and recommended result viewing is realized, the learning cost of researchers can be reduced, the video media asset recommended ranking efficiency is improved, and the online prediction performance of the model is improved.

Description

Video media asset recommendation and sorting method and device and electronic equipment
Technical Field
The invention relates to the field of video media asset recommendation, in particular to a video media asset recommendation sequencing method, a video media asset recommendation sequencing device and electronic equipment.
Background
The real-time video asset recommendation system plays a considerable role in improving the paying subscription of the user and increasing the stickiness of the user. The technical scheme of the existing video media asset recommendation system relates to the use of a plurality of different technical stacks, and is difficult to quickly deploy and land a model to enable a client to check recommendation effects. Meanwhile, developers need to know knowledge in multiple aspects such as data processing, model tuning, model deployment and the like at the same time, the requirements on the developers are high, and a recommendation model is difficult to construct in a short time, so that the online prediction performance of the existing model for video recommendation is poor.
Disclosure of Invention
The invention aims to provide a method, a device and electronic equipment for recommending and sequencing video media assets, which are used for solving the problem of poor online prediction performance of a model for recommending videos in the prior art.
In order to achieve the above object, an embodiment of the present invention provides a video asset recommendation sorting method, including:
constructing a feature matrix for media asset prediction; the characteristic matrix is composed of video media asset characteristics, user characteristics and cross characteristics;
inputting the characteristic matrix into a target video sequencing model to obtain a sequencing value of the medium resources to be predicted, which is output by the target video sequencing model;
and obtaining a video media asset recommendation sequencing result according to the sequencing value.
Optionally, after constructing the feature matrix for media asset prediction, the method further comprises:
under the condition that a prediction request is received, acquiring the target video sequencing model from a buffer pool;
the buffer pool comprises at least two video sequencing models, the version of each video sequencing model is different, and the target video sequencing model is the video sequencing model with the highest version.
Optionally, the method further comprises:
constructing model training data according to data features, wherein the data features comprise: video asset characteristics, user characteristics, and cross characteristics;
and performing model training on a Light Gradient Boosting Machine (LGBM) model by using the model training data to obtain a video sequencing model.
Optionally, the method further comprises:
and storing the model instance of the video sequencing model into a buffer pool.
Optionally, the building of model training data according to data features includes:
according to the user watching data, the user ordering data and the cold load sample media assets, video media asset characteristics and user characteristics are constructed, and a triple is constructed, wherein the triple comprises: a user ID, a media asset ID and a tag indicating whether the user clicks;
associating the user characteristics and the video media asset characteristics according to the triple to obtain first characteristic data;
calculating cross features according to the first feature data;
wherein the first feature data and the cross-features are the model training data.
Optionally, performing model training on the light gradient lifting LGBM model by using the model training data to obtain a video ranking model, including:
configuring model parameters of a light gradient lifting LGBM model to obtain an initial model; wherein the model parameters include: learning interest rate, iteration times, the number of model leaves, evaluation indexes of a model evaluation module and a cross validation function of a validator;
and training the initial model by using the model training data to obtain the video sequencing model.
Optionally, the constructing a feature matrix for media asset prediction includes:
acquiring the characteristics of the cached video media assets and the characteristics of users;
calculating cross characteristics according to the video media asset characteristics and the user characteristics;
and constructing the feature matrix by using the video media asset features, the user features and the cross features.
Optionally, the method further comprises:
acquiring media information according to the video media asset recommendation sequencing result;
and rendering an application program interface according to the media information.
Optionally, the video asset characteristics include at least one of:
the method comprises the following steps of paying the media assets, the year the media assets belong to, the language of the media assets, the types of the media assets, the license plate parties the media assets belong to, the ordering quantity of the media assets, the viewing quantity of the media assets, the ranking of the viewing quantity of the media assets, the grading of the media assets, a label list of the media assets, a label text feature vector constructed on the basis of the label list by using a word frequency reverse text frequency vector, a text characteristic vector constructed on the basis of the label list by using a word vector, and a media asset coding ID vector constructed by using the word vector.
Optionally, the user characteristics include at least one of:
the method comprises the steps of coding the region where a user is located, watching a video list by the user, watching a user watching vector constructed by using word vectors on the basis of watching the video list, watching a label list by the user, watching a user label vector constructed by using word vectors on the basis of watching the label list, the number of videos watched by the user, constructing a text feature vector of the user label by using a word frequency reverse text frequency vector, and the type of videos watched by the user.
Optionally, the cross-feature comprises at least one of:
the consistency of the video type watched by the user and the type of the media assets;
a cosine dot product of a first feature in the user features and a second feature in the media asset features, the first feature being: the user watching vector is constructed by using a word vector on the basis of a watching video list, and the second characteristic is a media asset coding ID vector constructed by using the word vector;
a cosine dot product of a third feature in the user features and a fourth feature in the media asset features, the third feature being: a user tag vector constructed using a word vector on the basis of the viewing tag list, wherein the fourth feature is: text feature vectors constructed by using word vectors on the basis of the tag list;
a cosine dot product of a fifth feature in the user features and a sixth feature in the funding features, the fifth feature being: a user tag text feature vector constructed by using the word frequency reverse text frequency vector, wherein the sixth feature is as follows: and constructing a label text feature vector by using the word frequency reverse text frequency vector on the basis of the label list.
In order to achieve the above object, an embodiment of the present invention provides a video asset recommendation and ranking apparatus, including:
the characteristic matrix construction module is used for constructing a characteristic matrix for media asset prediction; the characteristic matrix is composed of video media asset characteristics, user characteristics and cross characteristics;
the sequencing prediction module is used for inputting the characteristic matrix into a target video sequencing model to obtain a sequencing value of the medium resources to be predicted, which is output by the target video sequencing model;
and the result generation module is used for obtaining a video media asset recommendation sequencing result according to the sequencing value.
Optionally, the apparatus further comprises:
the first obtaining module is used for obtaining the target video sequencing model from a buffer pool under the condition of receiving a prediction request;
the buffer pool comprises at least two video sequencing models, the version of each video sequencing model is different, and the target video sequencing model is the video sequencing model with the highest version.
Optionally, the apparatus further comprises:
a training data construction module for constructing model training data according to data features, the data features including: video asset characteristics, user characteristics, and cross characteristics;
and the model training module is used for performing model training on the light gradient lifting LGBM model by using the model training data to obtain a video sequencing model.
Optionally, the apparatus further comprises:
and the storage module is used for storing the model instance of the video sequencing model into a buffer pool.
Optionally, the training data construction module includes:
the first construction unit is used for constructing video media asset characteristics and user characteristics according to user watching data, user ordering data and cold load sample media assets, and constructing triples, wherein the triples comprise: a user ID, a media asset ID and a tag indicating whether the user clicks;
the characteristic association unit is used for associating the user characteristic and the video media asset characteristic according to the triple to obtain first characteristic data;
a first calculation unit for calculating a cross feature from the first feature data;
wherein the first feature data and the cross-features are the model training data.
Optionally, the model training module comprises:
the model configuration unit is used for configuring model parameters of the light gradient lifting LGBM model to obtain an initial model; wherein the model parameters include: learning interest rate, iteration times, the number of model leaves, evaluation indexes of a model evaluation module and a cross validation function of a validator;
and the training unit is used for training the initial model by using the model training data to obtain the video sequencing model.
Optionally, the feature matrix building module includes:
the acquisition unit is used for acquiring the cached video media asset characteristics and the user characteristics;
the second calculation unit is used for calculating cross characteristics according to the video media asset characteristics and the user characteristics;
and the characteristic construction unit is used for constructing the characteristic matrix by utilizing the video media asset characteristics, the user characteristics and the cross characteristics.
Optionally, the apparatus further comprises:
the second acquisition module is used for acquiring media information according to the video media asset recommendation sequencing result;
and the page rendering module is used for rendering an application program interface according to the media information.
Optionally, the video asset characteristics include at least one of:
the method comprises the following steps of paying the media assets, the year the media assets belong to, the language of the media assets, the types of the media assets, the license plate parties the media assets belong to, the ordering quantity of the media assets, the viewing quantity of the media assets, the ranking of the viewing quantity of the media assets, the grading of the media assets, a label list of the media assets, a label text feature vector constructed on the basis of the label list by using a word frequency reverse text frequency vector, a text characteristic vector constructed on the basis of the label list by using a word vector, and a media asset coding ID vector constructed by using the word vector.
Optionally, the user characteristics include at least one of:
the method comprises the steps of coding the region where a user is located, watching a video list by the user, watching a user watching vector constructed by using word vectors on the basis of watching the video list, watching a label list by the user, watching a user label vector constructed by using word vectors on the basis of watching the label list, the number of videos watched by the user, constructing a text feature vector of the user label by using a word frequency reverse text frequency vector, and the type of videos watched by the user.
Optionally, the cross feature comprises at least one of:
the consistency of the video type watched by the user and the type of the media assets;
a cosine dot product of a first feature in the user features and a second feature in the media asset features, the first feature being: the user watching vector is constructed by using a word vector on the basis of a watching video list, and the second characteristic is a media asset coding ID vector constructed by using the word vector;
a cosine dot product of a third feature in the user features and a fourth feature in the media asset features, the third feature being: a user tag vector constructed using a word vector on the basis of the viewing tag list, wherein the fourth feature is: text feature vectors constructed by using word vectors on the basis of the tag lists;
a cosine dot product of a fifth feature in the user features and a sixth feature in the funding features, the fifth feature being: a user tag text feature vector constructed by using the word frequency reverse text frequency vector, wherein the sixth feature is as follows: and constructing a label text feature vector by using the word frequency reverse text frequency vector on the basis of the label list.
To achieve the above object, an embodiment of the present invention provides an electronic device, including a processor and a transceiver, wherein,
the processor is configured to: constructing a feature matrix for media asset prediction; the characteristic matrix is composed of video media asset characteristics, user characteristics and cross characteristics;
inputting the characteristic matrix into a target video sequencing model to obtain a sequencing value of the medium resources to be predicted, which is output by the target video sequencing model;
and obtaining a video media asset recommendation sequencing result according to the sequencing value.
Optionally, the processor is further configured to:
under the condition that a prediction request is received, acquiring the target video sequencing model from a buffer pool;
the buffer pool comprises at least two video sequencing models, the version of each video sequencing model is different, and the target video sequencing model is the video sequencing model with the highest version.
Optionally, the processor is further configured to:
constructing model training data according to data features, wherein the data features comprise: video media asset characteristics, user characteristics, and cross characteristics;
and performing model training on the light gradient lifting LGBM model by using the model training data to obtain a video sequencing model.
Optionally, the processor is further configured to:
and storing the model instance of the video sequencing model into a buffer pool.
Optionally, when the processor constructs the video ranking model training data according to the data features, the processor is specifically configured to:
according to the user watching data, the user ordering data and the cold load sample media assets, video media asset characteristics and user characteristics are constructed, and a triple is constructed, wherein the triple comprises: a user ID, a media asset ID and a tag indicating whether the user clicks;
associating the user characteristics and the video media asset characteristics according to the triple to obtain first characteristic data;
calculating cross features according to the first feature data;
wherein the first feature data and the cross-features are the model training data.
Optionally, the processor performs model training on the light gradient lifting LGBM model by using the model training data, and when obtaining the video ranking model, the processor is specifically configured to:
configuring model parameters of a light gradient lifting LGBM model to obtain an initial model; wherein the model parameters include: learning interest rate, iteration times, the number of model leaves, evaluation indexes of a model evaluation module and a cross validation function of a validator;
and training the initial model by using the model training data to obtain the video sequencing model.
Optionally, when the processor constructs a feature matrix for media asset prediction, the feature matrix is specifically configured to:
acquiring the characteristics of the cached video media assets and the characteristics of users;
calculating cross characteristics according to the video media asset characteristics and the user characteristics;
and constructing the feature matrix by using the video media asset features, the user features and the cross features.
Optionally, the processor is further configured to:
acquiring media information according to the video media asset recommendation sequencing result;
and rendering an application program interface according to the media information.
Optionally, the video asset characteristics include at least one of:
the method comprises the following steps of paying the media assets, the year the media assets belong to, the language of the media assets, the types of the media assets, the license plate parties the media assets belong to, the ordering quantity of the media assets, the viewing quantity of the media assets, the ranking of the viewing quantity of the media assets, the grading of the media assets, a label list of the media assets, a label text feature vector constructed on the basis of the label list by using a word frequency reverse text frequency vector, a text characteristic vector constructed on the basis of the label list by using a word vector, and a media asset coding ID vector constructed by using the word vector.
Optionally, the user characteristics include at least one of:
the method comprises the steps of coding the region where a user is located, watching a video list by the user, watching a user watching vector constructed by using word vectors on the basis of watching the video list, watching a label list by the user, watching a user label vector constructed by using word vectors on the basis of watching the label list, the number of videos watched by the user, constructing a text feature vector of the user label by using a word frequency reverse text frequency vector, and the type of videos watched by the user.
Optionally, the cross-feature comprises at least one of:
the consistency of the video type watched by the user and the type of the media assets;
a cosine dot product of a first feature in the user features and a second feature in the media asset features, the first feature being: the user watching vector is constructed by using a word vector on the basis of a watching video list, and the second characteristic is a media asset coding ID vector constructed by using the word vector;
a cosine dot product of a third feature in the user features and a fourth feature in the media asset features, the third feature being: a user tag vector constructed using a word vector on the basis of the viewing tag list, wherein the fourth feature is: text feature vectors constructed by using word vectors on the basis of the tag list;
a cosine dot product of a fifth feature in the user features and a sixth feature in the funding features, the fifth feature being: a user tag text feature vector constructed by using the word frequency reverse text frequency vector, wherein the sixth feature is as follows: and constructing a label text feature vector by using the word frequency reverse text frequency vector on the basis of the label list.
To achieve the above object, an embodiment of the present invention provides an electronic device, which includes a transceiver, a processor, a memory, and a program or instructions stored in the memory and executable on the processor; the processor realizes the video media asset recommendation and ranking method when executing the program or the instructions.
To achieve the above object, an embodiment of the present invention provides a readable storage medium, on which a program or instructions are stored, and the program or instructions, when executed by a processor, implement the steps in the video asset recommendation sorting method as described above.
The technical scheme of the invention has the following beneficial effects:
according to the embodiment of the application, the feature matrix is constructed according to the video media asset features, the user features and the cross features, and the feature matrix is input into the trained target video ranking model for prediction, so that the recommended ranking result of the media assets to be predicted is obtained, integration of model training, online prediction and recommended result viewing is realized, the learning cost of researchers can be reduced, the video media asset recommended ranking efficiency is improved, and the online prediction performance of the model is improved.
Drawings
FIG. 1 is a flowchart of a video asset recommendation sorting method according to an embodiment of the present invention;
FIG. 2 is a diagram illustrating a model buffer queue according to an embodiment of the present invention;
FIG. 3 is a schematic flow chart of constructing model training data according to an embodiment of the present invention;
FIG. 4 is a schematic flow chart of model training according to an embodiment of the present invention;
FIG. 5 is a flow chart illustrating online forecasting of assets, according to an embodiment of the present invention;
FIG. 6 is a second flowchart of a video asset recommendation sorting method according to an embodiment of the present invention;
FIG. 7 is a schematic structural diagram of a video asset recommendation and ranking apparatus according to an embodiment of the present invention;
FIG. 8 is a schematic structural diagram of an electronic device according to an embodiment of the invention;
fig. 9 is a second schematic structural diagram of an electronic device according to an embodiment of the invention.
Detailed Description
In order to make the technical problems, technical solutions and advantages of the present invention more apparent, the following detailed description is given with reference to the accompanying drawings and specific embodiments.
It should be appreciated that reference throughout this specification to "one embodiment" or "an embodiment" means that a particular feature, structure or characteristic described in connection with the embodiment is included in at least one embodiment of the present invention. Thus, the appearances of the phrases "in one embodiment" or "in an embodiment" in various places throughout this specification are not necessarily all referring to the same embodiment. Furthermore, the particular features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.
In various embodiments of the present invention, it should be understood that the sequence numbers of the following processes do not mean the execution sequence, and the execution sequence of each process should be determined by its function and inherent logic, and should not constitute any limitation to the implementation process of the embodiments of the present invention.
In addition, the terms "system" and "network" are often used interchangeably herein.
In the embodiments provided herein, it should be understood that "B corresponding to a" means that B is associated with a from which B can be determined. It should also be understood that determining B from a does not mean determining B from a alone, but may be determined from a and/or other information.
As shown in fig. 1, a method for recommending and ordering video assets in an embodiment of the present invention includes:
step 101, constructing a characteristic matrix for media asset prediction; the feature matrix is composed of video asset features, user features and cross features.
The media assets are media assets such as videos, and for video media asset recommendation, for example: the video recommended to the user for viewing in the display interface of the video application program is usually changed according to a plurality of conditions such as user preference and current playing amount. According to the method, the multiple media assets to be predicted can be predicted and sorted, and therefore the sorting result recommended to the user is obtained.
The video media asset characteristics and the user characteristics are stored in the corresponding databases by taking the media asset ID and the user ID as main keys, and are cached in the media asset recommendation service process. And the cross feature is obtained by real-time calculation according to the user feature and the media asset feature. And the media asset characteristics, the user characteristics and the cross characteristics of the media assets to be predicted jointly form the characteristic matrix which is used as input data of the online prediction of the media assets.
And 102, inputting the characteristic matrix into a target video sequencing model to obtain a sequencing value of the media assets to be predicted, which is output by the target video sequencing model.
The target video sequencing model is one of the video sequencing models which are trained in advance and stored in the buffer pool. The target video ranking model is obtained by training a light gradient lifting LGBM model. It should be noted that after the LGBM model is trained, it may be saved as a file, a single model instance is generated, and then stored in a buffer pool. And storing the model with the updated version into a buffer pool when the media asset recommendation service is started and the model version is updated each time. And when a prediction request comes, taking out the target video sequencing model from the model queue of the buffer pool, and returning model resources after the prediction is finished.
And 103, obtaining a video media asset recommendation sorting result according to the sorting value.
And inputting the characteristic matrix into the target video sequencing model, namely obtaining the sequencing score of each piece of media asset calculated and output by the target video sequencing model, and obtaining the recommended sequencing result of each piece of video media asset according to the sequencing score, so that the display content on a media asset display interface is adjusted, and the video media asset content meeting the user requirement is recommended for the user.
According to the embodiment of the application, the feature matrix is constructed according to the video media asset features, the user features and the cross features, and the feature matrix is input into the trained target video ranking model for prediction, so that the recommended ranking result of the media assets to be predicted is obtained, integration of model training, online prediction and recommended result viewing is realized, the learning cost of researchers can be reduced, the video media asset recommended ranking efficiency is improved, and the online prediction performance of the model is improved.
Optionally, after constructing the feature matrix for media asset prediction, the method further comprises: under the condition that a prediction request is received, acquiring the target video sequencing model from a buffer pool; the buffer pool comprises at least two video sequencing models, the version of each video sequencing model is different, and the target video sequencing model is the video sequencing model with the highest version.
The trained video ranking models are stored in a buffer pool, and new model instances are added to the buffer pool as model versions are updated. The buffer pool forms a model sequencer, and java self-contained Blocking queues (Linked Blocking Queue) can be used in practical application. The model sorting service puts a certain number of model instances in the buffer pool when the service is started and the model updates the version, as shown in fig. 2, when a prediction request arrives, the model sorter takes out the model instance corresponding to the target video sorting model from the model buffer queue, wherein the model instance corresponding to the target video sorting model may be the model instance with the highest version arranged at the first position, and model instance resources are returned after prediction is completed.
In the embodiment, when online prediction of video media resources is performed, the buffer queue of the model stored in the buffer pool can be used for solving the problem of prediction blocking under the condition of large concurrency, a solution for maintaining quick response under a high concurrency scene is provided, and online prediction delay of the model can be reduced.
As an alternative embodiment, the method further comprises:
constructing model training data according to data features, wherein the data features comprise: video asset characteristics, user characteristics, and cross characteristics; and performing model training on the light gradient lifting LGBM model by using the model training data to obtain a video sequencing model.
In this embodiment, before performing online prediction of video assets, model training is required. Training data required by model training is composed of video medium resource characteristics, user characteristics and cross characteristics. It should be noted that the video asset characteristics and user characteristics required for model training may be video asset characteristics and user characteristics of current media assets to be predicted, and may also include acquired historical data.
The training data is used for model training of the video sequencing model. Before training data is constructed, data of videos watched by users, data of videos ordered by users and cold sample media asset data obtained through sampling can be obtained, and the data characteristics can be extracted from the data. And after the data of the video watched by the user, the data of the video ordered by the user and the data of the cold load sample media assets are acquired, preprocessing the data, such as deleting error data. The data characteristics may include: the video resource management system comprises video media asset characteristics, user characteristics and cross characteristics, wherein the cross characteristics are obtained by calculating the video media asset characteristics and the user characteristics.
As an alternative embodiment, when constructing the training data, the data may be constructed and processed by using spark, where spark is a fast and multipurpose clustered computer system, and the String index converter in spark particularly refers to a feature processing function for mapping character strings to integers in spark ml (Machine learning library); the Tfidf vector (word frequency reverse text frequency vector) refers specifically to a feature processing function for converting text into Tfidf vector in spark ml; word2Vec (Word vector) refers specifically to the processing function in spark ml for Word2Vec Word vectorization characterization of text.
After training the data using the model, the feature columns may be merged using spark vectorrAssembler (vector Assembly converter), the mmlspark (Microsoft Machine Learning spark) extended class library is installed on the spark platform, and the ranking model is trained using lightgbm for spark.
After model training is completed, the model instance of the video ranking model can be stored in a buffer pool to deal with the problem of predictive blocking under the condition of large concurrency.
Specifically, as shown in fig. 3, the building of model training data according to data features may include:
according to the user watching data, the user ordering data and the cold load sample media assets, video media asset characteristics and user characteristics are constructed, and a triple is constructed, wherein the triple comprises: user ID, (userid) asset ID (album), and a label (label) indicating whether the user clicked;
associating the user characteristics and the video media asset characteristics according to the triple to obtain first characteristic data; calculating cross features according to the first feature data; wherein the first feature data and the cross-features are the model training data.
The specific process of constructing model training data is shown in fig. 3, user watching data, user ordering data and cold load sample media assets obtained by sampling are obtained, user characteristic calculation and video media asset characteristic calculation are carried out on the three types of data, and a triple of a user, the media assets and a label is constructed. And obtaining training data by using the triple association user characteristics and the media asset characteristics, and calculating cross characteristics to obtain model training data. Optionally, after the video asset characteristics and the user characteristics are obtained through calculation, the video asset characteristics and the user characteristics may be stored in a database (mongodb) for use in online prediction of video assets.
In particular, the video asset characteristics may include at least one of:
pay-per-view (Paytype) of assets; may be represented as a "01" feature.
Year of media asset (Year); the coding can be performed using StringIndexer.
Language of the asset (Language); the coding can be performed using StringIndexer.
Type of asset (channellid); for example, whether the asset is a television show or a movie art, StringIndexer coding may be used.
A license plate party (Cpid) to which the medium assets belong; StringIndexer coding may be used.
A subscription number of assets (TransCnt);
a media asset viewing volume (Cnt);
ranking of the amount of viewing of assets (hotrevrse); such as ranking of the media asset viewing volume in order from high to low.
Scoring of assets (Score);
a tag list (Tagid) of the asset;
a label text feature vector (Tagidtfidf) constructed by using the word frequency reverse text frequency vector on the basis of the label list;
a text property vector (TagidVec) constructed using the word vector on the basis of the tag list;
the media asset code ID vector (albmidvec) is constructed using the word vector.
In particular, the user characteristics include at least one of:
the Area code (Area) where the user is located;
the user watches a video list (Viewedlist);
a user view vector (viewvec) constructed using the word vector on the basis of the view video list;
the user views a tag list (Taglist);
a user tag vector (TaglistVec) constructed using the word vector on the basis of the viewing tag list;
number of videos (viewnum) watched by the user;
a user tag text feature vector (Tagidtfidf) constructed by using the word frequency reverse text frequency vector;
the type of video watched by the user (preferchannel) may be a type of program frequently watched by the user.
It should be noted that the video asset features may include one or more of the video asset features described above, and the user features may include one or more of the user features described above. Preferably, the video asset features include all of the video asset features described above, and the user features include all of the user features described above.
In particular, the cross-feature may comprise at least one of:
channel Equal: the consistency of the video type watched by the user and the type of the media assets, namely whether the preferchannellid of the user is consistent with the channellid of the media assets or not;
ViewedSim: a cosine dot product of a first feature in the user features and a second feature in the media asset features, the first feature being: the user watching vector is constructed by using a word vector on the basis of a watching video list, and the second characteristic is a media asset coding ID vector constructed by using the word vector; namely the cosine dot product of the user's viewvec feature with the asset album vec.
TaglistSim: a cosine dot product of a third feature in the user features and a fourth feature in the media asset features, the third feature being: a user tag vector constructed using a word vector on the basis of the viewing tag list, wherein the fourth feature is: text feature vectors constructed by using word vectors on the basis of the tag list; namely the cosine dot product of the user's TaglistVec and the asset TagidVec.
TagtfidfSim: a cosine dot product of a fifth feature in the user features and a sixth feature in the funding features, the fifth feature being: a user tag text feature vector constructed by using the word frequency reverse text frequency vector, wherein the sixth feature is as follows: label text characteristic vectors constructed by using word frequency reverse text frequency vectors on the basis of the label list; namely the cosine dot product of tagidtfiff of the user and tagidtfiff of the medium resources.
It should be noted that the cross feature is obtained by calculation according to the video asset feature and the user feature, and when the cross feature includes any one or more of the above items, the video asset feature and the user feature should include corresponding features required for calculating the cross feature.
In the embodiment, the media asset characteristic, user characteristic and cross characteristic calculation method used by the training data construction part is the key for constructing the model training data, and the recommendation effect can be effectively improved by constructing the model training data by using the characteristics.
Specifically, after model training data is constructed according to data features, model training is performed on the light gradient lifting LGBM model by using the model training data to obtain a video ranking model, which may include:
configuring model parameters of a light gradient lifting LGBM model to obtain an initial model; wherein the model parameters include: learning interest rate, iteration times, the number of model leaves, evaluation indexes of a model evaluation module and a cross validation function of a validator; and training the initial model by using the model training data to obtain the video sequencing model.
In this embodiment, after the training data is prepared, the feature columns may be merged using spark vector Assembler, the mmlspark extended class library is installed on the spark platform, and the ranking model is trained using lightgbm for spark.
Specifically, as shown in FIG. 4, a learning rate (learning rate), a number of iterations (numIterations), and a number of model leaves can be set by using an LGBM Classifier as a model Classifier;
and b, configuring a model evaluation module (Evaluator), wherein a Binary class configuration Evaluator can be used, and an evaluation index is AUC (Area Under ROC Curve and enclosed by coordinate axes).
And c, configuring a model verifier (validator) and configuring a K-fold cross validation function (kfold) for cross validation.
The model can be trained using spark pipeline.
Specifically, after the video sequencing model is obtained after model training is completed, the trained lightgbm model can be stored into a file to generate a single model instance, the model sequencer is implemented by using a buffer pool to solve the problem of prediction Blocking under the condition of large concurrency, and java self-contained Linked Blocking Queue can be used in practical application. The model ordering service will put a certain number of model instances in the buffer pool when the service is started and the model is updated. When a prediction request comes, the model sequencer takes out the model instance from the buffer queue, and resources are returned after prediction is finished.
Specifically, when media asset online prediction is performed, a feature matrix for online prediction needs to be constructed, and optionally, cached video media asset features and user features are obtained; calculating cross characteristics according to the video media asset characteristics and the user characteristics; and constructing the feature matrix by using the video media asset features, the user features and the cross features.
In this embodiment, the video asset characteristics and the user characteristics obtained when the model training data is constructed may be stored in the corresponding database with the user id and the asset id as the primary keys. Because the online prediction needs to access the features for multiple times, the features need to be cached in service, and performance loss caused by frequent access to the database is avoided. The cross feature is the part that needs to be calculated in real time from the user features and the asset features. After the three-part feature is complete, a feature matrix is formed to wait for prediction.
As an alternative embodiment, the method further comprises: acquiring media information according to the video media asset recommendation sequencing result; and rendering an application program interface according to the media information.
Inputting the feature matrix into a trained target video sequencing model, sequencing and returning media resources from high to low according to the value calculated by the target video sequencing model, inquiring information such as related media resource names, media resource pictures, media resource channels and the like according to a returned media resource id sequence, forming a json format and returning the json format to a front-end rendering page, facilitating algorithm tuning personnel to check unqualified cases (badcases) in time and adjusting the model effect.
The implementation process of online media asset prediction is described below by using a specific embodiment.
As shown in FIG. 5, a springboot framework can be used to build a model online prediction service, and a service cluster can be built by utilizing the microservice concept. After the cluster is subjected to rearrangement service, user characteristics and video asset characteristics cached by a cache characteristic layer can be acquired through a characteristic acquisition module, wherein the user characteristics and the video asset characteristics are acquired and cached through accessing a database (mongodb). After the user characteristics and the video media characteristics are obtained, the characteristic combination calculation module calculates cross characteristics according to the user characteristics and the video media characteristics, forms a characteristic matrix, inputs the characteristic matrix to a target video sequencing model obtained by the model sequencing management module for online prediction, and outputs a prediction result for display.
And the model sorting management module acquires the target video sorting model from a buffer pool through a model sorter. The model sorter may determine which model of the buffer pool the target video sorting model is according to the model version management means. The model version management device manages and updates the model version according to a Hadoop Distributed File System (HDFS) model persistence layer.
In the embodiment, the model online prediction part uses the buffer pool, and the trained video sequencing model forms the buffer queue, so that the model online prediction time delay can be reduced, and a solution for maintaining quick response in a high concurrent scene is provided. The model version manager can be effectively connected with the model training module and the online prediction module, and is the key of the integration of model training and reasoning. And the model recommendation of this embodiment is visualized.
As an alternative embodiment, a complete implementation process of the video asset recommendation and ranking method of the present application is described below by specific embodiments with reference to the accompanying drawings.
As shown in fig. 6, the whole video asset recommendation sorting method is divided into two steps of model construction and online sorting. The process of model construction comprises the following steps: the method comprises three processes of data feature extraction, model training data construction and model training, wherein the specific steps of data feature extraction, model training data construction and model training are not repeated herein.
After a video sequencing model is obtained through model training, the video sequencing model is placed into a buffer pool, and model version management is carried out when a model sequencing service is started and a model updates the version, so that a model buffer queue is formed. When an external online prediction request is received, online feature calculation is carried out by using the stored video media asset features and user features to obtain a feature matrix for media asset prediction, and the feature matrix is input into a target video sequencing model for online sequencing prediction.
According to the embodiment of the application, the characteristic matrix is constructed according to the video media asset characteristics, the user characteristics and the cross characteristics, the characteristic matrix is input into the trained target video sequencing model for prediction, so that the recommended sequencing result of the media asset to be predicted is obtained, the integration of model training, online prediction and recommended result checking is realized, the learning cost of researchers can be reduced, only input data needs to be sampled in an actual production environment, the recommendation effect can be quickly checked by using the existing process to quickly generate the sequencing model, the researchers can conveniently select the model more quickly, and the video media asset recommending and sequencing efficiency is improved. An effective method for reducing model online prediction time delay by using a cache and a buffer queue is provided, a solution for maintaining quick response in a higher concurrency scene is provided, and the online prediction performance of the model can be effectively improved.
As shown in fig. 7, a video asset recommendation sorting apparatus 700 according to an embodiment of the present invention includes:
a feature matrix construction module 710, configured to construct a feature matrix for media asset prediction; the characteristic matrix is composed of video media asset characteristics, user characteristics and cross characteristics;
the sequencing prediction module 720 is configured to input the feature matrix into a target video sequencing model to obtain a sequencing value of the media assets to be predicted, which is output by the target video sequencing model;
and the result generating module 730 is used for obtaining a video media asset recommendation sorting result according to the sorting value.
Optionally, the apparatus further comprises:
the first obtaining module is used for obtaining the target video sequencing model from a buffer pool under the condition of receiving a prediction request;
the buffer pool comprises at least two video sequencing models, the version of each video sequencing model is different, and the target video sequencing model is the video sequencing model with the highest version.
Optionally, the apparatus further comprises:
a training data construction module for constructing model training data according to data features, the data features including: video asset characteristics, user characteristics, and cross characteristics;
and the model training module is used for performing model training on the light gradient lifting LGBM model by using the model training data to obtain a video sequencing model.
Optionally, the apparatus further comprises:
and the storage module is used for storing the model instance of the video sequencing model into a buffer pool.
Optionally, the training data construction module includes:
the first construction unit is used for constructing video media asset characteristics and user characteristics according to user watching data, user ordering data and cold load sample media assets, and constructing triples, wherein the triples comprise: a user ID, a media asset ID and a tag indicating whether the user clicks;
the characteristic association unit is used for associating the user characteristic and the video media asset characteristic according to the triple to obtain first characteristic data;
a first calculation unit for calculating a cross feature from the first feature data;
wherein the first feature data and the cross-features are the model training data.
Optionally, the model training module comprises:
the model configuration unit is used for configuring model parameters of the light gradient lifting LGBM model to obtain an initial model; wherein the model parameters include: learning interest rate, iteration times, the number of model leaves, evaluation indexes of a model evaluation module and a cross validation function of a validator;
and the training unit is used for training the initial model by using the model training data to obtain the video sequencing model.
Optionally, the feature matrix building module includes:
the acquisition unit is used for acquiring the cached video media asset characteristics and the user characteristics;
the second calculation unit is used for calculating the cross characteristics according to the video media asset characteristics and the user characteristics;
and the characteristic construction unit is used for constructing the characteristic matrix by utilizing the video media asset characteristics, the user characteristics and the cross characteristics.
Optionally, the apparatus further comprises:
the second acquisition module is used for acquiring media information according to the video media asset recommendation sequencing result;
and the page rendering module is used for rendering an application program interface according to the media information.
Optionally, the video asset characteristics include at least one of:
the method comprises the following steps of paying the media assets, the year the media assets belong to, the language of the media assets, the types of the media assets, the license plate parties the media assets belong to, the ordering quantity of the media assets, the viewing quantity of the media assets, the ranking of the viewing quantity of the media assets, the grading of the media assets, a label list of the media assets, a label text feature vector constructed on the basis of the label list by using a word frequency reverse text frequency vector, a text characteristic vector constructed on the basis of the label list by using a word vector, and a media asset coding ID vector constructed by using the word vector.
Optionally, the user characteristics include at least one of:
the method comprises the steps of coding the region where a user is located, watching a video list by the user, watching a user watching vector constructed by using word vectors on the basis of watching the video list, watching a label list by the user, watching a user label vector constructed by using word vectors on the basis of watching the label list, the number of videos watched by the user, constructing a text feature vector of the user label by using a word frequency reverse text frequency vector, and the type of videos watched by the user.
Optionally, the cross-feature comprises at least one of:
the consistency of the video type watched by the user and the type of the media assets;
a cosine dot product of a first feature in the user features and a second feature in the media asset features, the first feature being: the user watching vector is constructed by using a word vector on the basis of a watching video list, and the second characteristic is a media asset coding ID vector constructed by using the word vector;
a cosine dot product of a third feature in the user features and a fourth feature in the media asset features, the third feature being: a user tag vector constructed using a word vector on the basis of the viewing tag list, wherein the fourth feature is: text feature vectors constructed by using word vectors on the basis of the tag list;
a cosine dot product of a fifth feature in the user features and a sixth feature in the media asset features, the fifth feature being: a user tag text feature vector constructed by using the word frequency reverse text frequency vector, wherein the sixth feature is as follows: and constructing a label text feature vector by using the word frequency reverse text frequency vector on the basis of the label list.
According to the embodiment of the application, the feature matrix is constructed according to the video media asset features, the user features and the cross features, and the feature matrix is input into the trained target video ranking model for prediction, so that the recommended ranking result of the media assets to be predicted is obtained, integration of model training, online prediction and recommended result viewing is realized, the learning cost of researchers can be reduced, the video media asset recommended ranking efficiency is improved, and the online prediction performance of the model is improved.
It should be noted that, the apparatus provided in the embodiment of the present invention can implement all the method steps implemented by the embodiment of the video asset recommendation and ranking method, and can achieve the same technical effects, and details of the same parts and beneficial effects as those of the method embodiment in this embodiment are not described herein again.
As shown in fig. 8, an electronic device 800 according to an embodiment of the present invention includes a processor 810 and a transceiver 820, wherein the transceiver 820 is configured to receive and transmit data under the control of the processor 810.
The processor 810 is specifically configured to: constructing a feature matrix for media asset prediction; the characteristic matrix is composed of video media asset characteristics, user characteristics and cross characteristics;
inputting the characteristic matrix into a target video sequencing model to obtain a sequencing value of the medium resources to be predicted, which is output by the target video sequencing model;
and obtaining a video media asset recommendation sequencing result according to the sequencing value.
Optionally, the processor 810 is further configured to:
under the condition that a prediction request is received, acquiring the target video sequencing model from a buffer pool;
the buffer pool comprises at least two video sequencing models, the version of each video sequencing model is different, and the target video sequencing model is the video sequencing model with the highest version.
Optionally, the processor 810 is further configured to:
constructing model training data according to data features, wherein the data features comprise: video asset characteristics, user characteristics, and cross characteristics;
and performing model training on the light gradient lifting LGBM model by using the model training data to obtain a video sequencing model.
Optionally, the processor 810 is further configured to:
and storing the model instance of the video sequencing model into a buffer pool.
Optionally, when the processor constructs the video ranking model training data according to the data features, the processor is specifically configured to:
according to the user watching data, the user ordering data and the cold load sample media assets, video media asset characteristics and user characteristics are constructed, and a triple is constructed, wherein the triple comprises: a user ID, a media asset ID and a tag indicating whether the user clicks;
associating the user characteristics and the video media asset characteristics according to the triple to obtain first characteristic data;
calculating cross features according to the first feature data;
wherein the first feature data and the cross-features are the model training data.
Optionally, the processor 810 performs model training on the light gradient boost LGBM model by using the model training data, and when obtaining the video ranking model, is specifically configured to:
configuring model parameters of a light gradient lifting LGBM model to obtain an initial model; wherein the model parameters include: learning interest rate, iteration times, the number of model leaves, evaluation indexes of a model evaluation module and a cross validation function of a validator;
and training the initial model by using the model training data to obtain the video sequencing model.
Optionally, when the processor 810 constructs a feature matrix for media asset prediction, the feature matrix is specifically configured to:
acquiring the characteristics of the cached video media assets and the characteristics of users;
calculating cross characteristics according to the video media asset characteristics and the user characteristics;
and constructing the feature matrix by using the video media asset features, the user features and the cross features.
Optionally, the processor 810 is further configured to:
acquiring media information according to the video media asset recommendation sequencing result;
and rendering an application program interface according to the media information.
Optionally, the video asset characteristics include at least one of:
the method comprises the following steps of paying the media resources, the year the media resources belong to, the language of the media resources, the type of the media resources, the license plate party the media resources belong to, the order number of the media resources, the viewing amount of the media resources, the ranking of the viewing amount of the media resources, the grading of the media resources, a tag list of the media resources, a tag text feature vector constructed on the basis of the tag list by using a word frequency reverse text frequency vector, a text feature vector constructed on the basis of the tag list by using a word vector, and a media resource coding ID vector constructed by using the word vector.
Optionally, the user characteristics include at least one of:
the method comprises the steps of coding the region where a user is located, watching a video list by the user, watching a user watching vector constructed by using word vectors on the basis of watching the video list, watching a label list by the user, watching a user label vector constructed by using word vectors on the basis of watching the label list, the number of videos watched by the user, constructing a text feature vector of the user label by using a word frequency reverse text frequency vector, and the type of videos watched by the user.
Optionally, the cross-feature comprises at least one of:
the consistency of the video type watched by the user and the type of the media assets;
a cosine dot product of a first feature in the user features and a second feature in the media asset features, the first feature being: the user watching vector is constructed by using a word vector on the basis of a watching video list, and the second characteristic is a media asset coding ID vector constructed by using the word vector;
a cosine dot product of a third feature in the user features and a fourth feature in the media asset features, the third feature being: a user tag vector constructed using a word vector on the basis of the viewing tag list, wherein the fourth feature is: text feature vectors constructed by using word vectors on the basis of the tag list;
a cosine dot product of a fifth feature in the user features and a sixth feature in the funding features, the fifth feature being: a user tag text feature vector constructed by using the word frequency reverse text frequency vector, wherein the sixth feature is as follows: and constructing a label text feature vector by using the word frequency reverse text frequency vector on the basis of the label list.
It should be noted that the electronic device provided in the embodiment of the present invention can implement all the method steps implemented by the embodiment of the video asset recommendation and ranking method, and can achieve the same technical effects, and details of the same parts and beneficial effects as those of the method embodiment in this embodiment are not described herein again.
An electronic device according to another embodiment of the present invention, as shown in fig. 9, includes a transceiver 910, a processor 900, a memory 920, and a program or instructions stored in the memory 920 and executable on the processor 900; when the processor 900 executes the program or the instruction, the method for handling the exception of the automatic test task is implemented.
The transceiver 910 is used for receiving and transmitting data under the control of the processor 900.
In fig. 9, among other things, the bus architecture may include any number of interconnected buses and bridges, with one or more processors, represented by processor 900, and various circuits, represented by memory 920, being linked together. The bus architecture may also link together various other circuits such as peripherals, voltage regulators, power management circuits, and the like, which are well known in the art, and therefore, will not be described any further herein. The bus interface provides an interface. The transceiver 910 may be a number of elements including a transmitter and a receiver that provide a means for communicating with various other apparatus over a transmission medium. The processor 900 is responsible for managing the bus architecture and general processing, and the memory 920 may store data used by the processor 900 in performing operations.
The readable storage medium of the embodiment of the present invention stores a program or an instruction thereon, and the program or the instruction when executed by the processor implements the steps in the video asset recommendation and ranking method described above, and can achieve the same technical effect, and the details are not repeated here in order to avoid repetition.
Wherein, the processor is the processor in the video media asset recommendation and ranking method in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk.
It is further noted that the electronic devices described in this specification include, but are not limited to, smart phones, tablets, etc., and that many of the functional components described are referred to as modules in order to more particularly emphasize their implementation independence.
In embodiments of the present invention, modules may be implemented in software for execution by various types of processors. An identified module of executable code may, for instance, comprise one or more physical or logical blocks of computer instructions which may, for instance, be constructed as an object, procedure, or function. Nevertheless, the executables of an identified module need not be physically located together, but may comprise disparate instructions stored in different bits which, when joined logically together, comprise the module and achieve the stated purpose for the module.
Indeed, a module of executable code may be a single instruction, or many instructions, and may even be distributed over several different code segments, among different programs, and across several memory devices. Likewise, operational data may be identified within the modules and may be embodied in any suitable form and organized within any suitable type of data structure. The operational data may be collected as a single data set, or may be distributed over different locations including over different storage devices, and may exist, at least partially, merely as electronic signals on a system or network.
When a module can be implemented by software, considering the level of existing hardware technology, a module implemented by software may build a corresponding hardware circuit to implement a corresponding function, without considering cost, and the hardware circuit may include a conventional Very Large Scale Integration (VLSI) circuit or a gate array and an existing semiconductor such as a logic chip, a transistor, or other discrete components. A module may also be implemented in programmable hardware devices such as field programmable gate arrays, programmable array logic, programmable logic devices or the like.
The exemplary embodiments described above are described with reference to the drawings, and many different forms and embodiments of the invention may be made without departing from the spirit and teaching of the invention, therefore, the invention is not to be construed as limited to the exemplary embodiments set forth herein. Rather, these exemplary embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the invention to those skilled in the art. In the drawings, the size and relative sizes of elements may be exaggerated for clarity. The terminology used herein is for the purpose of describing particular example embodiments only and is not intended to be limiting. As used herein, the singular forms "a", "an" and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will be further understood that the terms "comprises" and/or "comprising," when used in this specification, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof. Unless otherwise indicated, a range of values, when stated, includes the upper and lower limits of the range and any subranges therebetween.
While the foregoing is directed to the preferred embodiment of the present invention, it will be understood by those skilled in the art that various changes and modifications may be made without departing from the spirit and scope of the invention as defined in the appended claims.

Claims (15)

1. A video media asset recommendation and sequencing method is characterized by comprising the following steps:
constructing a feature matrix for media asset prediction; the characteristic matrix is composed of video media asset characteristics, user characteristics and cross characteristics;
inputting the characteristic matrix into a target video sequencing model to obtain a sequencing value of the medium resources to be predicted, which is output by the target video sequencing model;
and obtaining a video media asset recommendation sequencing result according to the sequencing value.
2. The method of claim 1, wherein after constructing the feature matrix for media asset prediction, the method further comprises:
under the condition that a prediction request is received, acquiring the target video sequencing model from a buffer pool;
the buffer pool comprises at least two video sequencing models, the version of each video sequencing model is different, and the target video sequencing model is the video sequencing model with the highest version.
3. The method of claim 1, further comprising:
constructing model training data according to data features, wherein the data features comprise: video asset characteristics, user characteristics, and cross characteristics;
and performing model training on the light gradient lifting LGBM model by using the model training data to obtain a video sequencing model.
4. The method of claim 3, further comprising:
and storing the model instance of the video sequencing model into a buffer pool.
5. The method of claim 3, wherein the building model training data from data features comprises:
according to the user watching data, the user ordering data and the cold load sample media assets, video media asset characteristics and user characteristics are constructed, and a triple is constructed, wherein the triple comprises: a user ID, a media asset ID and a tag indicating whether the user clicks;
associating the user characteristics and the video media asset characteristics according to the triple to obtain first characteristic data;
calculating cross features according to the first feature data;
wherein the first feature data and the cross-features are the model training data.
6. The method of claim 3, wherein performing model training on the light gradient boost LGBM model using the model training data to obtain a video ranking model comprises:
configuring model parameters of a light gradient lifting LGBM model to obtain an initial model; wherein the model parameters include: learning interest rate, iteration times, the number of model leaves, evaluation indexes of a model evaluation module and a cross validation function of a validator;
and training the initial model by using the model training data to obtain the video sequencing model.
7. The method of claim 1, wherein constructing the feature matrix for media asset prediction comprises:
acquiring the characteristics of the cached video media assets and the characteristics of users;
calculating cross characteristics according to the video media asset characteristics and the user characteristics;
and constructing the feature matrix by using the video media asset features, the user features and the cross features.
8. The method of claim 1, further comprising:
acquiring media information according to the video media asset recommendation sequencing result;
and rendering an application program interface according to the media information.
9. The method of claim 1 or 3, wherein the video asset characteristics comprise at least one of:
the method comprises the following steps of paying the media assets, the year the media assets belong to, the language of the media assets, the types of the media assets, the license plate parties the media assets belong to, the ordering quantity of the media assets, the viewing quantity of the media assets, the ranking of the viewing quantity of the media assets, the grading of the media assets, a label list of the media assets, a label text feature vector constructed on the basis of the label list by using a word frequency reverse text frequency vector, a text characteristic vector constructed on the basis of the label list by using a word vector, and a media asset coding ID vector constructed by using the word vector.
10. The method according to claim 1 or 3, wherein the user characteristics comprise at least one of:
the method comprises the steps of coding the region where a user is located, watching a video list by the user, watching a user watching vector constructed by using word vectors on the basis of watching the video list, watching a label list by the user, watching a user label vector constructed by using word vectors on the basis of watching the label list, the number of videos watched by the user, constructing a text feature vector of the user label by using a word frequency reverse text frequency vector, and the type of videos watched by the user.
11. The method of claim 1 or 3, wherein the cross-feature comprises at least one of:
the consistency of the video type watched by the user and the type of the media assets;
a cosine dot product of a first feature in the user features and a second feature in the media asset features, the first feature being: the user watching vector is constructed by using a word vector on the basis of a watching video list, and the second characteristic is a media asset coding ID vector constructed by using the word vector;
a cosine dot product of a third feature in the user features and a fourth feature in the media asset features, the third feature being: a user tag vector constructed using a word vector on the basis of the viewing tag list, wherein the fourth feature is: text feature vectors constructed by using word vectors on the basis of the tag list;
a cosine dot product of a fifth feature in the user features and a sixth feature in the funding features, the fifth feature being: a user tag text feature vector constructed by using the word frequency reverse text frequency vector, wherein the sixth feature is as follows: and constructing a label text feature vector by using the word frequency reverse text frequency vector on the basis of the label list.
12. A video asset recommendation ranking device, comprising:
the characteristic matrix construction module is used for constructing a characteristic matrix for media asset prediction; the characteristic matrix is composed of video media asset characteristics, user characteristics and cross characteristics;
the sequencing prediction module is used for inputting the characteristic matrix into a target video sequencing model to obtain a sequencing value of the medium resources to be predicted, which is output by the target video sequencing model;
and obtaining a video media asset recommendation sequencing result according to the sequencing value.
13. An electronic device, comprising: a transceiver and a processor;
the processor is configured to: constructing a feature matrix for media asset prediction; the characteristic matrix is composed of video media asset characteristics, user characteristics and cross characteristics;
inputting the characteristic matrix into a target video sequencing model to obtain a sequencing value of the medium resources to be predicted, which is output by the target video sequencing model;
and obtaining a video media asset recommendation sequencing result according to the sequencing value.
14. An electronic device, comprising: a transceiver, a processor, a memory, and a program or instructions stored on the memory and executable on the processor; wherein the processor, when executing the program or instructions, implements the video asset recommendation ranking method of any of claims 1-11.
15. A readable storage medium having a program or instructions stored thereon, wherein the program or instructions, when executed by a processor, implement the steps in the video asset recommendation ranking method according to any one of claims 1-11.
CN202110151110.8A 2021-02-03 2021-02-03 Video media asset recommendation and sorting method and device and electronic equipment Pending CN114860988A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110151110.8A CN114860988A (en) 2021-02-03 2021-02-03 Video media asset recommendation and sorting method and device and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110151110.8A CN114860988A (en) 2021-02-03 2021-02-03 Video media asset recommendation and sorting method and device and electronic equipment

Publications (1)

Publication Number Publication Date
CN114860988A true CN114860988A (en) 2022-08-05

Family

ID=82623064

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110151110.8A Pending CN114860988A (en) 2021-02-03 2021-02-03 Video media asset recommendation and sorting method and device and electronic equipment

Country Status (1)

Country Link
CN (1) CN114860988A (en)

Similar Documents

Publication Publication Date Title
US9934260B2 (en) Streamlined analytic model training and scoring system
CN111143686B (en) Resource recommendation method and device
CN111666416B (en) Method and device for generating semantic matching model
CN112119388A (en) Training image embedding model and text embedding model
CN111046275B (en) User label determining method and device based on artificial intelligence and storage medium
CN110909182A (en) Multimedia resource searching method and device, computer equipment and storage medium
US11874798B2 (en) Smart dataset collection system
WO2023040506A1 (en) Model-based data processing method and apparatus, electronic device, computer-readable storage medium, and computer program product
CN112074828A (en) Training image embedding model and text embedding model
CN111738010B (en) Method and device for generating semantic matching model
US11386099B2 (en) Methods and apparatuses for showing target object sequence to target user
US12008047B2 (en) Providing an object-based response to a natural language query
CN111159563A (en) Method, device and equipment for determining user interest point information and storage medium
CN110262906B (en) Interface label recommendation method and device, storage medium and electronic equipment
CN116910357A (en) Data processing method and related device
CN114860988A (en) Video media asset recommendation and sorting method and device and electronic equipment
CN112417260B (en) Localized recommendation method, device and storage medium
CN113762992A (en) Method and device for processing data
CN110222271B (en) Method and device for generating webpage
US20230342587A1 (en) Ontology change graph publishing system
CN117221386A (en) Information pushing method, device, electronic equipment and readable medium
CN113962285A (en) Multi-way recall result fusion method and device, electronic equipment and computer medium
CN116861209A (en) Account characteristic acquisition method and device, computer equipment and storage medium
CN117909562A (en) Content recommendation method, device, equipment and medium based on content recommendation model
CN116975427A (en) Method, device and computing equipment for determining interest degree of object in resource information

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination