CN111679916A - Video recommendation method, target service providing terminal, service calling terminal and system - Google Patents

Video recommendation method, target service providing terminal, service calling terminal and system Download PDF

Info

Publication number
CN111679916A
CN111679916A CN202010799879.6A CN202010799879A CN111679916A CN 111679916 A CN111679916 A CN 111679916A CN 202010799879 A CN202010799879 A CN 202010799879A CN 111679916 A CN111679916 A CN 111679916A
Authority
CN
China
Prior art keywords
video
user
recommended
videos
service
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.)
Granted
Application number
CN202010799879.6A
Other languages
Chinese (zh)
Other versions
CN111679916B (en
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.)
Beijing Sohu New Media Information Technology Co Ltd
Original Assignee
Beijing Sohu New Media Information Technology Co Ltd
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 Beijing Sohu New Media Information Technology Co Ltd filed Critical Beijing Sohu New Media Information Technology Co Ltd
Priority to CN202010799879.6A priority Critical patent/CN111679916B/en
Publication of CN111679916A publication Critical patent/CN111679916A/en
Application granted granted Critical
Publication of CN111679916B publication Critical patent/CN111679916B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5027Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals
    • G06F9/505Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals considering the load
    • 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/71Indexing; Data structures therefor; Storage structures
    • 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/78Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually
    • G06F16/783Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually using metadata automatically derived from the content
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N20/00Machine learning

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • General Physics & Mathematics (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Multimedia (AREA)
  • Library & Information Science (AREA)
  • Artificial Intelligence (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Evolutionary Computation (AREA)
  • Medical Informatics (AREA)
  • Computing Systems (AREA)
  • Mathematical Physics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention provides a video recommendation method, a target service provider, a service calling end and a system, wherein the method comprises the following steps: and the service calling end acquires the server instance list and determines a target service providing end from the server instance list according to a preset load balancing strategy. And the service calling end sends the user id of the user to be processed and the video ids of the videos to be recommended to the target service providing end. The target service providing terminal acquires user characteristics according to the user id and video characteristics according to the video id, processes the user characteristics and the video characteristics by using a preset video recommendation model to obtain the predicted click rate of a plurality of videos to be recommended, and feeds the predicted click rate of the videos to be recommended back to the service calling terminal. By setting a plurality of service providers and selecting a corresponding target service provider to perform video recommendation processing by using a load balancing strategy, the video processing capability is improved, and the delay of recommended videos is reduced.

Description

Video recommendation method, target service providing terminal, service calling terminal and system
Technical Field
The invention relates to the technical field of video recommendation, in particular to a video recommendation method, a target service providing terminal, a service calling terminal and a system.
Background
With the development of the internet, more and more video software is appeared in the application market. When the video software is applied, the corresponding video is recommended to the user according to the user characteristics of the user and the video characteristics of the video.
The current video recommendation method is as follows: and predicting the click rate of the video by using a machine learning model in combination with the user characteristics and the video characteristics, and recommending the video according to the predicted click rate. However, as the number of videos increases and the length of the video features increases, it takes a long time to process the videos when recommending the videos to the user, and a large number of videos cannot be processed, so that the capability of processing the videos is low and the delay of recommending the videos is high.
Disclosure of Invention
In view of this, embodiments of the present invention provide a video recommendation method, a target service provider, a service invocation end, and a system, so as to solve the problems of a current video recommendation method, such as a low video processing capability and a high video recommendation delay.
In order to achieve the above purpose, the embodiments of the present invention provide the following technical solutions:
the first aspect of the embodiment of the invention discloses a video recommendation method, which is suitable for a service calling end and comprises the following steps:
acquiring a server instance list, wherein the server instance list comprises a plurality of service providing ends registered in an etcd registration center in advance, and the service providing ends are docker service instances in a docker cluster;
determining a target service provider from the service provider instance list according to a preset load balancing strategy;
sending a user id of a user to be processed and video ids of a plurality of videos to be recommended to the target service providing end, enabling the target service providing end to obtain user characteristics according to the user id and video characteristics according to the video id, processing the user characteristics and the video characteristics by using a preset video recommendation model to obtain predicted click rates of the videos to be recommended, and training a machine learning model according to sample data to obtain the video recommendation model;
and receiving the predicted click rate of the videos to be recommended fed back by the target service provider.
Preferably, the determining a target service provider from the service provider instance list according to a preset load balancing policy includes:
and determining a target service provider from the service provider instance list according to a random number hash algorithm strategy.
The second aspect of the embodiment of the invention discloses a video recommendation method, which is suitable for a target service provider and comprises the following steps:
receiving a user id of a user to be processed and video ids of a plurality of videos to be recommended, which are sent by a service calling end, wherein the service calling end determines a target service providing end from a service end instance list according to a preset load balancing strategy, the service end instance list comprises a plurality of service providing ends registered in an etcd registration center in advance, and the service providing ends are docker service instances in a docker cluster;
acquiring the user characteristics of the user to be processed according to the user id, and acquiring the video characteristics of a plurality of videos to be recommended according to the video id;
according to the user characteristics and the video characteristics, a preset video recommendation model is used for predicting click rate of the videos to be recommended to obtain the predicted click rate of each video to be recommended, and the video recommendation model is obtained by training a machine learning model according to sample data;
and feeding back the predicted click rates of the videos to be recommended to the service calling terminal.
Preferably, the obtaining the user characteristics of the user to be processed according to the user id and obtaining the video characteristics of the videos to be recommended according to the video id includes:
according to the user id, obtaining user characteristics in a libsvm format corresponding to the user id from a distributed cache;
and acquiring the video characteristics of the libsvm format corresponding to each video to be recommended from the distributed cache according to each video id.
Preferably, the predicting the click rate of the plurality of videos to be recommended by using a preset video recommendation model according to the user characteristics and the plurality of video characteristics to obtain the predicted click rate of each video to be recommended includes:
for the video features of each video to be recommended, splicing the video features and the user features to obtain combined features;
and inputting the plurality of combined features into a preset video recommendation model for click rate prediction to obtain the predicted click rate of each video to be recommended.
Preferably, before feeding back the predicted click rate of the videos to be recommended to the service invoking terminal, the method further includes:
and sequencing the videos to be recommended according to the predicted click rate.
Preferably, the method further comprises the following steps:
and sending a keepalive message to the etcd registration center according to a preset period.
A third aspect of the embodiments of the present invention discloses a service invocation end, where the service invocation end includes:
the system comprises an acquisition unit, a processing unit and a processing unit, wherein the acquisition unit is used for acquiring a server instance list, the server instance list comprises a plurality of service providing ends registered in an etcd registration center in advance, and the service providing ends are docker service instances in a docker cluster;
the determining unit is used for determining a target service provider from the service provider instance list according to a preset load balancing strategy;
the sending unit is used for sending a user id of a user to be processed and video ids of a plurality of videos to be recommended to the target service providing end, enabling the target service providing end to obtain user characteristics according to the user id and video characteristics according to the video ids, processing the user characteristics and the video characteristics by using a preset video recommendation model to obtain predicted click rates of the videos to be recommended, and training a machine learning model according to sample data to obtain the video recommendation model;
and the receiving unit is used for receiving the predicted click rates of the videos to be recommended fed back by the target service providing end.
A fourth aspect of the present invention discloses a target service provider, where the target service provider includes:
the system comprises a receiving unit, a service calling end and a plurality of service providers, wherein the receiving unit is used for receiving a user id of a user to be processed and video ids of a plurality of videos to be recommended, the user id and the video ids are sent by the service calling end, the service calling end determines a target service provider from a service instance list according to a preset load balancing strategy, the service instance list comprises a plurality of service providers which are registered in an etcd registration center in advance, and the service provider is a docker service instance in a docker cluster;
the acquisition unit is used for acquiring the user characteristics of the user to be processed according to the user id and acquiring the video characteristics of a plurality of videos to be recommended according to the video id;
the prediction unit is used for predicting the click rate of a plurality of videos to be recommended by utilizing a preset video recommendation model according to the user characteristics and the plurality of video characteristics to obtain the predicted click rate of each video to be recommended, and the video recommendation model is obtained by training a machine learning model according to sample data;
and the feedback unit is used for feeding back the predicted click rate of the videos to be recommended to the service calling end.
A fifth aspect of the embodiments of the present invention discloses a video recommendation system, including: a service invocation end disclosed in the third aspect of the embodiments of the present invention and a target service provider end disclosed in the fourth aspect of the embodiments of the present invention.
Based on the video recommendation method, the target service provider, the service invocation end and the system provided by the embodiment of the invention, the method comprises the following steps: and the service calling end acquires the server instance list and determines a target service providing end from the server instance list according to a preset load balancing strategy. And the service calling end sends the user id of the user to be processed and the video ids of the videos to be recommended to the target service providing end. The target service providing terminal acquires user characteristics according to the user id and video characteristics according to the video id, processes the user characteristics and the video characteristics by using a preset video recommendation model to obtain the predicted click rate of a plurality of videos to be recommended, and feeds the predicted click rate of the videos to be recommended back to the service calling terminal. By setting a plurality of service providers and selecting a corresponding target service provider to perform video recommendation processing by using a load balancing strategy, the video processing capability is improved, and the delay of recommended videos is reduced.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
Fig. 1 is a flowchart of a video recommendation method according to an embodiment of the present invention;
fig. 2 is a block diagram of a service invocation end according to an embodiment of the present invention;
fig. 3 is a block diagram of a target service provider according to an embodiment of the present invention;
fig. 4 is a block diagram of a video recommendation system according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
In this application, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
As known from the background art, at present, the click rate of a video is predicted through a machine learning model, and video recommendation is performed according to the predicted click rate. However, as the number of videos increases and the length of the video features increases, it takes a long time to process the videos when recommending the videos to the user, and a large number of videos cannot be processed, so that the capability of processing the videos is low and the delay of recommending the videos is high.
Therefore, the embodiment of the invention provides a video recommendation method, a target service provider, a service invocation end and a system, and the video recommendation method, the target service provider, the service invocation end and the system improve the video processing capability and reduce the delay of the recommended video by setting a plurality of service providers and selecting the corresponding target service provider to perform video recommendation processing by using a load balancing strategy.
Referring to fig. 1, a flowchart of a video recommendation method provided by an embodiment of the present invention is shown, where the video recommendation method includes:
step S101: and the service calling terminal acquires the service terminal instance list.
It should be noted that the service instance list includes a plurality of service providers registered in the etcd registry in advance, and the service providers are docker service instances in the docker cluster. That is, a plurality of service providers (docker service instances) operate in a docker cluster manner, and each service provider has a function of predicting a click through rate of a video to be recommended.
It should be noted that docker is an open-source application container engine.
It can be understood that, for each service provider registered in the etcd registry, when the service provider starts, the service provider registers a key-value pair including information such as a Time To Live (TTL), an IP, and a port To the etcd registry directory, and during the lifetime of the service provider, the service provider sends a keepalive message To the etcd registry according To a preset period, so as To ensure the existence of the key-value pair of the service provider in the etcd registry. Similarly, when the service provider is offline, the key value pair corresponding to the service provider is automatically deleted after time out.
It should be noted that etcd is a key-value store with high availability and strong consistency.
In the process of implementing step S101 specifically, the service invoking end obtains, in a monitoring or querying manner, a service end instance list that has been registered in the etcd registry, where the service end instance list includes a plurality of service providing ends registered in the etcd registry.
Step S102: and the service calling terminal determines a target service providing terminal from the service terminal instance list according to a preset load balancing strategy.
In the process of implementing step S102 specifically, the service invocation end determines a target service provider from the service instance list according to a random number hash (hash) algorithm policy (one of the load balancing policies), that is, selects a service provider corresponding to the load balancing policy from a plurality of service providers in the service instance list, where the service provider corresponding to the load balancing policy is the target service provider.
As can be seen from the foregoing, each service provider registered in the etcd registry has a key value pair including TTL, IP, and a port, and after a target service provider is determined, the IP and the port corresponding to the target service provider can be obtained.
Step S103: and the service calling end sends the user id of the user to be processed and the video ids of the videos to be recommended to the target service providing end.
In the process of implementing step S103 specifically, the service invocation end obtains the user id of the user to be processed in advance, and obtains the video id of each video to be recommended in advance. And the service calling end sends the user id and the video ids of the videos to be recommended to the target service providing end.
It can be understood that the service invoking terminal sends the video ids of the multiple videos to be recommended to the target service provider in a list form, that is, sends a video id list containing the video id of each video to be recommended to the target service provider.
It should be noted that the service invocation end sends a service invocation request at least including a user id and a multi-video id to the target service provider, and invokes the target service provider to perform click rate prediction on a plurality of videos to be recommended.
Correspondingly, the target service providing end obtains the service calling request based on the thread framework.
It should be noted that the thread framework is an open-source cross-language remote procedure call framework.
Preferably, in combination with the foregoing, the target service provider sends a keepalive message to the etcd registry according to a preset period during the lifetime.
Step S104: and the target service providing terminal acquires the user characteristics of the user to be processed according to the user id and acquires the video characteristics of a plurality of videos to be recommended according to the video id.
It should be noted that the feature engineering process is performed in advance for each user and video. For each user, generating a corresponding user feature in a libsvm format for the user id of the user, and storing the user feature (in the libsvm format) of each user in the distributed cache, that is, for a user, the user feature of the user can be obtained by querying the distributed cache by using the user id of the user.
And corresponding to each video, generating a video feature in a libsvm format corresponding to the video id of the video, and storing the video feature (libsvm format) of each video in a distributed cache, namely for a video, querying the video feature of the video from the distributed cache by using the video id of the video.
In the process of implementing step S104 specifically, the target service provider obtains, from the distributed cache, the user characteristics in libsvm format corresponding to the user id according to the user id of the user to be processed.
And the target service providing terminal acquires video features in a libsvm format corresponding to each video to be recommended from the distributed cache according to the video id of each video to be recommended.
Step S105: and the target service provider predicts the click rate of a plurality of videos to be recommended by using a preset video recommendation model according to the user characteristics and the video characteristics to obtain the predicted click rate of each video to be recommended.
It should be noted that, a video recommendation model of the target service provider is obtained in advance according to the sample data training machine learning model.
The process of training to obtain the recommendation model comprises a sample data acquisition part and a model training part, and the specific content is as follows.
A sample data acquisition section: and collecting all historical behavior logs of the sample users accessing the videos, wherein each historical behavior log of the sample users records information such as user ids of the sample users, video ids of the accessed videos, log timestamps and click labels (whether the videos are clicked or not).
For each historical behavior log, characteristics of the historical behavior log in a libsvm format are generated, namely a plurality of attribute values of a sample user are obtained from a data warehouse from a user id in the historical behavior log, a plurality of attributes of a video id are obtained from the data warehouse for numerical conversion, and a piece of characteristic data in the libsvm format, which can be used for training a machine learning model, is constructed by combining a click label in the historical behavior log.
Through the method, all historical behavior logs are converted into the characteristic data in the libsvm format which can be used for training the machine learning model, and therefore sample data is constructed and obtained.
A model training part: and training the machine learning model by using the sample data until the machine learning model is trained to a convergence state, thus obtaining a corresponding video recommendation model.
In the process of specifically implementing step S105, the target service provider splices the video features and the user features of each video to be recommended to obtain a combined feature. The target service providing end inputs the multiple combined features into a video recommendation model, the video recommendation model accelerates click rate prediction of multiple videos to be recommended by utilizing multithreading calculation in the video recommendation model to obtain the predicted click rate of each video to be recommended, and it can be understood that the predicted click rate of each video to be recommended can be in a score form.
Such as: if the number of the videos to be recommended is N (positive integer), the target service providing terminal obtains N video features, and for each video to be recommended, the target service providing terminal splices the video features of the video to be recommended and the user features of the user to be processed to obtain combined features. By the method, N combined features are obtained in total, the target service provider inputs the N combined features into the video recommendation model, click rate prediction is carried out on N videos to be recommended, and the predicted click rate of each video to be recommended is obtained.
Step S106: and the target service providing terminal feeds back the predicted click rates of the videos to be recommended to the service calling terminal.
In the process of specifically implementing the step S106, the target service provider feeds back the predicted click rates of the multiple videos to be recommended to the service invocation end.
Preferably, the target service provider sorts the videos to be recommended according to the predicted click rate, and feeds the sorted videos to be recommended back to the service calling terminal.
Such as: and assuming that the predicted click rate is a score, sequencing the videos to be recommended according to the sequence of the scores from high to low, and feeding the sequenced videos to be recommended back to the service calling terminal.
In the embodiment of the invention, the service calling terminal acquires the service terminal instance list and determines the target service providing terminal from the service terminal instance list according to the preset load balancing strategy. And the service calling end sends the user id of the user to be processed and the video ids of the videos to be recommended to the target service providing end. The target service providing end obtains user characteristics according to the user id and video characteristics according to the video id, a preset video recommendation model is used for processing the user characteristics and the video characteristics to obtain the predicted click rate of a plurality of videos to be recommended, the predicted click rate of the videos to be recommended is fed back to the service calling end, the service providing ends are arranged in a distributed node mode, the corresponding target service providing end is selected according to a load balancing strategy to perform video recommendation processing, the video processing capacity is improved, and therefore the delay of the recommended videos is reduced.
Corresponding to the video recommendation method provided by the embodiment of the present invention, referring to fig. 2, an embodiment of the present invention further provides a structural block diagram of a service invocation end, where the service invocation end includes: an acquisition unit 201, a determination unit 202, a transmission unit 203, and a reception unit 204;
the obtaining unit 201 is configured to obtain a server instance list, where the server instance list includes a plurality of service providers registered in the etcd registry in advance, and the service providers are docker service instances in a docker cluster.
The determining unit 202 is configured to determine a target service provider from the service provider instance list according to a preset load balancing policy.
In a specific implementation, the determining unit 202 is specifically configured to: and determining a target service provider from the service provider instance list according to a random number hash algorithm strategy.
The sending unit 203 is configured to send the user id of the user to be processed and the video ids of the videos to be recommended to the target service providing end, so that the target service providing end obtains the user characteristics according to the user id and obtains the video characteristics according to the video id, the user characteristics and the video characteristics are processed by using a preset video recommendation model to obtain the predicted click rates of the videos to be recommended, and the video recommendation model is obtained by training a machine learning model according to sample data.
The receiving unit 204 is configured to receive predicted click rates of multiple videos to be recommended, which are fed back by the target service provider.
In the embodiment of the invention, the service calling terminal acquires the service terminal instance list and determines the target service providing terminal from the service terminal instance list according to the preset load balancing strategy. The service calling end sends the user id of the user to be processed and the video ids of the videos to be recommended to the target service providing end, so that the target service providing end obtains user characteristics according to the user id and video characteristics according to the video ids, and the user characteristics and the video characteristics are processed by using a preset video recommendation model to obtain the predicted click rate of the videos to be recommended. The service calling end receives the predicted click rates of the videos to be recommended fed back by the target service providing end, the service providing ends are arranged in a distributed node mode, the corresponding target service providing end is selected according to the load balancing strategy to conduct video recommendation processing, video processing capacity is improved, and therefore the delay of the recommended videos is reduced.
Corresponding to the video recommendation method provided by the embodiment of the present invention, referring to fig. 3, an embodiment of the present invention further provides a structural block diagram of a target service provider, where the target service provider includes: a receiving unit 301, an acquiring unit 302, a predicting unit 303, and a feedback unit 304;
the receiving unit 301 is configured to receive a user id of a user to be processed and video ids of multiple videos to be recommended, which are sent by a service invocation end, where the service invocation end determines a target service provider from a service instance list according to a preset load balancing policy, the service instance list includes multiple service providers registered in an etcd registration center in advance, and the service provider is a docker service instance in a docker cluster.
The obtaining unit 302 is configured to obtain a user characteristic of a user to be processed according to the user id, and obtain a video characteristic of a plurality of videos to be recommended according to the video id.
In a specific implementation, the obtaining unit 302 is specifically configured to: and according to the user id, obtaining the user characteristics in the libsvm format corresponding to the user id from the distributed cache, and according to each video id, obtaining the video characteristics in the libsvm format corresponding to each video to be recommended from the distributed cache.
The prediction unit 303 is configured to predict click rates of multiple videos to be recommended by using a preset video recommendation model according to the user characteristics and the multiple video characteristics, so as to obtain a predicted click rate of each video to be recommended, where the video recommendation model is obtained by training a machine learning model according to sample data.
In a specific implementation, the prediction unit 303 is specifically configured to: and splicing the video characteristics and the user characteristics aiming at the video characteristics of each video to be recommended to obtain combined characteristics, inputting the combined characteristics into a preset video recommendation model to predict the click rate, and obtaining the predicted click rate of each video to be recommended.
And the feedback unit 304 is configured to feed back the predicted click rates of the multiple videos to be recommended to the service invoking end.
Preferably, in combination with the content shown in fig. 3, the target service provider further includes:
and the sorting unit is used for sorting the videos to be recommended according to the predicted click rate.
Preferably, in combination with the content shown in fig. 3, the target service provider further includes:
and the sending unit is used for sending the keepalive message to the etcd registration center according to the preset period.
In the embodiment of the invention, the target service provider receives the user id of the user to be processed and the video ids of a plurality of videos to be recommended, which are sent by the service calling terminal. The target service providing end obtains user characteristics according to the user id and video characteristics according to the video id, a preset video recommendation model is used for processing the user characteristics and the video characteristics to obtain the predicted click rate of a plurality of videos to be recommended, the predicted click rate of the videos to be recommended is fed back to the service calling end, the service providing ends are arranged in a distributed node mode, the corresponding target service providing end is selected according to a load balancing strategy to perform video recommendation processing, the video processing capacity is improved, and therefore the delay of the recommended videos is reduced.
Corresponding to the video recommendation method provided by the embodiment of the present invention, referring to fig. 4, an embodiment of the present invention further provides a structural block diagram of a video recommendation system, where the video recommendation system includes: the execution principle of the service invocation end 401 may refer to the content shown in fig. 2 in the embodiment of the present invention, and the execution principle of the target service provider 402 may refer to the content shown in fig. 3 in the embodiment of the present invention, which is not described herein again.
In summary, embodiments of the present invention provide a video recommendation method, a target service provider, a service invocation end, and a system, where a plurality of service providers are set in a distributed node manner, and a corresponding target service provider is selected according to a load balancing policy to perform video recommendation processing, so as to improve video processing capability, thereby reducing the delay of recommending videos.
The embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, the system or system embodiments are substantially similar to the method embodiments and therefore are described in a relatively simple manner, and reference may be made to some of the descriptions of the method embodiments for related points. The above-described system and system embodiments are only illustrative, wherein the units described as separate parts may or may not be physically separate, and the parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. One of ordinary skill in the art can understand and implement it without inventive effort.
Those of skill would further appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative components and steps have been described above generally in terms of their functionality in order to clearly illustrate this interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (10)

1. A video recommendation method is characterized in that the method is applied to a service calling end, and comprises the following steps:
acquiring a server instance list, wherein the server instance list comprises a plurality of service providing ends registered in an etcd registration center in advance, and the service providing ends are docker service instances in a docker cluster;
determining a target service provider from the service provider instance list according to a preset load balancing strategy;
sending a user id of a user to be processed and video ids of a plurality of videos to be recommended to the target service providing end, enabling the target service providing end to obtain user characteristics according to the user id and video characteristics according to the video id, processing the user characteristics and the video characteristics by using a preset video recommendation model to obtain predicted click rates of the videos to be recommended, and training a machine learning model according to sample data to obtain the video recommendation model;
and receiving the predicted click rate of the videos to be recommended fed back by the target service provider.
2. The method according to claim 1, wherein the determining a target service provider from the service instance list according to a preset load balancing policy comprises:
and determining a target service provider from the service provider instance list according to a random number hash algorithm strategy.
3. A video recommendation method is applied to a target service provider, and comprises the following steps:
receiving a user id of a user to be processed and video ids of a plurality of videos to be recommended, which are sent by a service calling end, wherein the service calling end determines a target service providing end from a service end instance list according to a preset load balancing strategy, the service end instance list comprises a plurality of service providing ends registered in an etcd registration center in advance, and the service providing ends are docker service instances in a docker cluster;
acquiring the user characteristics of the user to be processed according to the user id, and acquiring the video characteristics of a plurality of videos to be recommended according to the video id;
according to the user characteristics and the video characteristics, a preset video recommendation model is used for predicting click rate of the videos to be recommended to obtain the predicted click rate of each video to be recommended, and the video recommendation model is obtained by training a machine learning model according to sample data;
and feeding back the predicted click rates of the videos to be recommended to the service calling terminal.
4. The method according to claim 3, wherein the obtaining the user characteristics of the user to be processed according to the user id and obtaining the video characteristics of the videos to be recommended according to the video id comprises:
according to the user id, obtaining user characteristics in a libsvm format corresponding to the user id from a distributed cache;
and acquiring the video characteristics of the libsvm format corresponding to each video to be recommended from the distributed cache according to each video id.
5. The method according to claim 3, wherein the predicting click rate of each video to be recommended by using a preset video recommendation model according to the user characteristics and the plurality of video characteristics to obtain the predicted click rate of each video to be recommended comprises:
for the video features of each video to be recommended, splicing the video features and the user features to obtain combined features;
and inputting the plurality of combined features into a preset video recommendation model for click rate prediction to obtain the predicted click rate of each video to be recommended.
6. The method according to claim 3, wherein before feeding back the predicted click rate of the plurality of videos to be recommended to the service calling terminal, the method further comprises:
and sequencing the videos to be recommended according to the predicted click rate.
7. The method of claim 3, further comprising:
and sending a keepalive message to the etcd registration center according to a preset period.
8. A service invocation end, characterized in that the service invocation end comprises:
the system comprises an acquisition unit, a processing unit and a processing unit, wherein the acquisition unit is used for acquiring a server instance list, the server instance list comprises a plurality of service providing ends registered in an etcd registration center in advance, and the service providing ends are docker service instances in a docker cluster;
the determining unit is used for determining a target service provider from the service provider instance list according to a preset load balancing strategy;
the sending unit is used for sending a user id of a user to be processed and video ids of a plurality of videos to be recommended to the target service providing end, enabling the target service providing end to obtain user characteristics according to the user id and video characteristics according to the video ids, processing the user characteristics and the video characteristics by using a preset video recommendation model to obtain predicted click rates of the videos to be recommended, and training a machine learning model according to sample data to obtain the video recommendation model;
and the receiving unit is used for receiving the predicted click rates of the videos to be recommended fed back by the target service providing end.
9. A target service provider, wherein the target service provider comprises:
the system comprises a receiving unit, a service calling end and a plurality of service providers, wherein the receiving unit is used for receiving a user id of a user to be processed and video ids of a plurality of videos to be recommended, the user id and the video ids are sent by the service calling end, the service calling end determines a target service provider from a service instance list according to a preset load balancing strategy, the service instance list comprises a plurality of service providers which are registered in an etcd registration center in advance, and the service provider is a docker service instance in a docker cluster;
the acquisition unit is used for acquiring the user characteristics of the user to be processed according to the user id and acquiring the video characteristics of a plurality of videos to be recommended according to the video id;
the prediction unit is used for predicting the click rate of a plurality of videos to be recommended by utilizing a preset video recommendation model according to the user characteristics and the plurality of video characteristics to obtain the predicted click rate of each video to be recommended, and the video recommendation model is obtained by training a machine learning model according to sample data;
and the feedback unit is used for feeding back the predicted click rate of the videos to be recommended to the service calling end.
10. A video recommendation system, the system comprising: the service invocation end according to claim 8 and the target service provider according to claim 9.
CN202010799879.6A 2020-08-11 2020-08-11 Video recommendation method, target service providing terminal, service calling terminal and system Active CN111679916B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010799879.6A CN111679916B (en) 2020-08-11 2020-08-11 Video recommendation method, target service providing terminal, service calling terminal and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010799879.6A CN111679916B (en) 2020-08-11 2020-08-11 Video recommendation method, target service providing terminal, service calling terminal and system

Publications (2)

Publication Number Publication Date
CN111679916A true CN111679916A (en) 2020-09-18
CN111679916B CN111679916B (en) 2020-11-27

Family

ID=72458227

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010799879.6A Active CN111679916B (en) 2020-08-11 2020-08-11 Video recommendation method, target service providing terminal, service calling terminal and system

Country Status (1)

Country Link
CN (1) CN111679916B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112395505A (en) * 2020-12-01 2021-02-23 中国计量大学 Short video click rate prediction method based on cooperative attention mechanism
CN115334321A (en) * 2022-08-10 2022-11-11 北京百度网讯科技有限公司 Method and device for acquiring access heat of video stream, electronic equipment and medium
WO2023040220A1 (en) * 2021-09-14 2023-03-23 北京百度网讯科技有限公司 Video pushing method and apparatus, and electronic device and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170132744A1 (en) * 2015-11-11 2017-05-11 Amazon Technologies, Inc. Application-specific virtualized graphics processing
CN106790660A (en) * 2017-01-18 2017-05-31 咪咕视讯科技有限公司 A kind of dispositions method and device for realizing distributed memory system
CN108924244A (en) * 2018-07-24 2018-11-30 广东神马搜索科技有限公司 Distributed system and flow allocation method and device for the system
US20190155850A1 (en) * 2016-07-29 2019-05-23 Huawei Technologies Co., Ltd. Stream Computing Method, Apparatus, and System
CN111339355A (en) * 2020-05-21 2020-06-26 北京搜狐新媒体信息技术有限公司 Video recommendation method and system

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170132744A1 (en) * 2015-11-11 2017-05-11 Amazon Technologies, Inc. Application-specific virtualized graphics processing
US20190155850A1 (en) * 2016-07-29 2019-05-23 Huawei Technologies Co., Ltd. Stream Computing Method, Apparatus, and System
CN106790660A (en) * 2017-01-18 2017-05-31 咪咕视讯科技有限公司 A kind of dispositions method and device for realizing distributed memory system
CN108924244A (en) * 2018-07-24 2018-11-30 广东神马搜索科技有限公司 Distributed system and flow allocation method and device for the system
CN111339355A (en) * 2020-05-21 2020-06-26 北京搜狐新媒体信息技术有限公司 Video recommendation method and system

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112395505A (en) * 2020-12-01 2021-02-23 中国计量大学 Short video click rate prediction method based on cooperative attention mechanism
WO2023040220A1 (en) * 2021-09-14 2023-03-23 北京百度网讯科技有限公司 Video pushing method and apparatus, and electronic device and storage medium
CN115334321A (en) * 2022-08-10 2022-11-11 北京百度网讯科技有限公司 Method and device for acquiring access heat of video stream, electronic equipment and medium
CN115334321B (en) * 2022-08-10 2024-04-09 北京百度网讯科技有限公司 Method and device for acquiring access heat of video stream, electronic equipment and medium

Also Published As

Publication number Publication date
CN111679916B (en) 2020-11-27

Similar Documents

Publication Publication Date Title
CN111679916B (en) Video recommendation method, target service providing terminal, service calling terminal and system
CN101326493B (en) Method and device for distributing load of multiprocessor server
CN107835437B (en) Dispatching method based on more cache servers and device
CN110336848B (en) Scheduling method, scheduling system and scheduling equipment for access request
CN110633442A (en) Pushing method and device and electronic equipment
CN105847381A (en) Scheduling method and device for content server
CN112751748B (en) Session message management method, device, server and readable storage medium
WO2021237433A1 (en) Message pushing method and apparatus, and electronic device and computer-readable medium
US20130346513A1 (en) Migrating a chat message service provided by a chat server to a new chat server
CN111327647A (en) Method and device for providing service to outside by container and electronic equipment
US20050091653A1 (en) Method and apparatus for load sharing and data distribution in servers
CN109729397A (en) A kind of plug-flow method, system and server
CN113032223B (en) Server state detection method and device
CN111526185B (en) Data downloading method, device, system and storage medium
CN111901396A (en) Resource request response method, redirection server and decision distribution server
CN113382065B (en) File downloading method, device, system, equipment and storage medium
CN111083204A (en) File transmission method, device and storage medium
CN113315689B (en) Information processing method, system, electronic device and readable storage medium
CN117032987A (en) Distributed task scheduling method, system, equipment and computer readable medium
CN103685609A (en) Method and device for collecting routing configuration information in domain name resolution
CN111294553B (en) Method, device, equipment and storage medium for processing video monitoring service signaling
CN110809064B (en) IP address switching method, device and system
CN113626188A (en) Task pushing method and device, computer equipment and storage medium
Heikkinen et al. Dynamic cache optimization for DASH clients in Content Delivery Networks
CN110995890A (en) Domain name request scheduling method and device

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
GR01 Patent grant
GR01 Patent grant