CN110390052B - Search recommendation method, training method, device and equipment of CTR (China train redundancy report) estimation model - Google Patents

Search recommendation method, training method, device and equipment of CTR (China train redundancy report) estimation model Download PDF

Info

Publication number
CN110390052B
CN110390052B CN201910675882.4A CN201910675882A CN110390052B CN 110390052 B CN110390052 B CN 110390052B CN 201910675882 A CN201910675882 A CN 201910675882A CN 110390052 B CN110390052 B CN 110390052B
Authority
CN
China
Prior art keywords
search
words
word
candidate
historical
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.)
Active
Application number
CN201910675882.4A
Other languages
Chinese (zh)
Other versions
CN110390052A (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.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen 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 Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201910675882.4A priority Critical patent/CN110390052B/en
Publication of CN110390052A publication Critical patent/CN110390052A/en
Application granted granted Critical
Publication of CN110390052B publication Critical patent/CN110390052B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/953Querying, e.g. by the use of web search engines
    • G06F16/9535Search customisation based on user profiles and personalisation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/279Recognition of textual entities
    • G06F40/289Phrasal analysis, e.g. finite state techniques or chunking
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/30Semantic analysis

Abstract

The embodiment of the application relates to the technical field of machine learning, in particular to a search recommendation method, a training method, a device and equipment of a CTR (computer-to-radio ratio) pre-estimation model, wherein the method comprises the following steps: acquiring a search word and a candidate word set of the search word; generating at least one group of model input parameters according to the sequence characteristics of the search words, wherein each group of model input parameters corresponds to one group of search words and candidate words, and the sequence characteristics of the search words are used for representing the input sequence of words contained in the search words; calling a CTR pre-estimation model, and calculating according to model input parameters to obtain the CTR value of the candidate word; and selecting a recommended candidate word corresponding to the search word from the candidate word set according to the CTR value of the candidate word. According to the method and the device, when CTR is estimated, by combining the sequence characteristics of the search words, the estimated CTR value of each candidate word is more accurate, so that the recommended candidate words meeting the requirements of the user are obtained, and the accuracy of the recommended candidate words provided for the user is improved.

Description

Search recommendation method, training method, device and equipment of CTR (China train redundancy report) estimation model
Technical Field
The embodiment of the application relates to the technical field of machine learning, in particular to a search recommendation method, a training device and training equipment of a CTR (computer-to-computational-parameter) estimation model.
Background
After the user inputs a search word in a search box of the application program, the application program may recommend some recommendation candidate words related to the search word to the user, so that the user can directly select a certain recommendation candidate word for content search.
In the related art, a CTR (Click Through Rate) estimation model is used to estimate CTR values of candidate words related to a search word, and then a plurality of recommended candidate words are found out based on the CTR values of the candidate words. For example, several candidate words with the largest CTR value are selected as the recommended candidate words. When the CTR prediction model predicts the CTR value of a candidate word related to a search word, the CTR prediction model needs to combine the feature information of the search word and the feature information of the candidate word, and finally outputs the CTR value of the candidate word.
However, in the related art, when the CTR prediction is performed, the considered features are not comprehensive enough, so that the accuracy of the candidate word recommended to the user is low.
Disclosure of Invention
The embodiment of the application provides a search recommendation method, a training device and training equipment of a CTR (China traffic report) estimation model, and can be used for solving the problem that in the related technology, the accuracy of recommended candidate words related to search words recommended to a user finally is low due to the fact that considered features are not comprehensive enough. The technical scheme is as follows:
in one aspect, an embodiment of the present application provides a search recommendation method, where the method includes:
acquiring a search word and a candidate word set of the search word, wherein the candidate word set comprises at least one candidate word related to the search word;
generating at least one group of model input parameters according to the sequence characteristics of the search words, wherein each group of model input parameters corresponds to one group of search words and the candidate words, and the sequence characteristics of the search words are used for representing the input sequence of the words contained in the search words;
calling a Click Through Rate (CTR) pre-estimation model, and calculating according to the model input parameters to obtain the CTR value of the candidate word;
and selecting a recommended candidate word corresponding to the search word from the candidate word set according to the CTR value of the candidate word.
On the other hand, the embodiment of the application provides a training method of a CTR estimation model, and the method comprises the following steps:
acquiring a historical search word and a historical exposure candidate word corresponding to the historical search word;
constructing at least one group of training samples according to the sequence characteristics of the historical search words, wherein each group of training samples corresponds to one group of the historical search words and the historical exposure candidate words, and the sequence characteristics of the historical search words are used for representing the input sequence of words contained in the historical search words;
and training the CTR prediction model by adopting the training samples to obtain the trained CTR prediction model.
In another aspect, an embodiment of the present application provides a search recommendation apparatus, where the apparatus includes:
the search word acquisition module is used for acquiring search words;
a candidate word acquisition module, configured to acquire a candidate word set of the search word, where the candidate word set includes at least one candidate word related to the search word;
the parameter generating module is used for generating at least one group of model input parameters according to the sequence characteristics of the search words, each group of model input parameters corresponds to one group of search words and the candidate words, and the sequence characteristics of the search words are used for representing the input sequence of the words contained in the search words;
the model calling module is used for calling a Click Through Rate (CTR) estimation model and calculating the CTR value of the candidate word according to the model input parameters;
and the recommendation selection module is used for selecting a recommendation candidate word corresponding to the search word from the candidate word set according to the CTR value of the candidate word.
In some possible designs, the apparatus further comprises:
and the phonetic notation processing module is used for performing phonetic notation processing on the words contained in the search words to obtain the complete spelling of the words contained in the search words.
The full spelling feature generation module is used for generating full spelling features of the search words according to full spelling of the words contained in the search words; wherein the model input parameters further include a spell feature of the search term.
In some possible designs, the apparatus further comprises:
and the first letter acquisition module is used for performing phonetic notation processing on the words contained in the search words to obtain the first letters of the words contained in the search words.
The initial feature generation module is used for generating initial features of the search words according to the initial of the words contained in the search words; wherein the model input parameters further include an initial feature of the search term.
In some possible designs, the model input parameter includes n feature bits for adding sequential features of the search term, where n is an integer greater than 1; when the number m of the words contained in the search word is greater than or equal to n, the n feature bits include the first n words of the words contained in the search word, and m is an integer greater than 1; when the number m of the words contained in the search word is smaller than n, the n feature bits include the m words contained in the search word, and n-m feature positions after the mth feature bit in the n feature bits are empty.
In some possible designs, the candidate word obtaining module is further configured to generate a keyword corresponding to the search word, where the keyword includes at least one of: the words contained in the search words, the full spellings of the words contained in the search words, and the initials of the words contained in the search words; and querying in an inverted index table by adopting the keywords to obtain a candidate word set of the search words, wherein the inverted index table comprises the corresponding relation between the keywords and the candidate words.
In some possible designs, the apparatus further comprises:
a document set construction module, configured to construct a candidate document set, where the candidate document set includes at least one document, and the document includes at least one of the following: historical search terms with a click rate greater than a threshold value, titles of documents in the search database, and titles of popular search events.
A correspondence generating module, configured to generate, for each document, a correspondence related to the document, where a keyword in the correspondence includes at least one of: words contained in the document, spellings of the words contained in the document, initials of the words contained in the document, and candidate words in the correspondence include the document.
And the index table generation module is used for integrating the corresponding relation related to each document to generate the inverted index table.
In some possible designs, the apparatus further comprises:
and the similarity calculation module is used for calculating the similarity between the search word and each candidate word.
The word set updating module is used for determining the candidate words with the similarity larger than the preset similarity as updated candidate word sets; and the CTR pre-estimation model calculates the CTR value of each candidate word in the updated candidate word set.
In a further aspect, an embodiment of the present application provides a training device for a CTR prediction model, where the training device includes:
the word acquisition module is used for acquiring historical search words and historical exposure candidate words corresponding to the historical search words;
the sample construction module is used for constructing at least one group of training samples according to the sequence characteristics of the historical search words, each group of training samples corresponds to one group of the historical search words and the historical exposure candidate words, and the sequence characteristics of the historical search words are used for representing the input sequence of words contained in the historical search words;
and the model training module is used for training the CTR estimation model by adopting the training samples to obtain the trained CTR estimation model.
In some possible designs, the word processing module is configured to divide the historical search word into words according to a word level to obtain each word included in the historical search word; and obtaining the sequence characteristics of the historical search terms according to the sequence of each character contained in the historical search terms.
In some possible designs, the apparatus further comprises:
and the phonetic notation processing module is used for performing phonetic notation processing on the words contained in the historical search words to obtain the full spelling of the words contained in the historical search words.
The full spelling feature generation module is used for generating full spelling features of the historical search words according to full spelling of words contained in the historical search words; wherein the training samples further include spell features of the historical search terms.
In some possible designs, the apparatus further comprises:
and the initial acquisition module is used for performing phonetic notation processing on the words contained in the historical search words to obtain the initial of the words contained in the historical search words.
The initial character generating module is used for generating initial character of the historical search words according to the initial characters of the words contained in the historical search words; wherein the training samples further include initial features of the historical search terms.
In yet another aspect, an embodiment of the present application provides a computer device, where the computer device includes a processor and a memory, where the memory stores at least one instruction, at least one program, a code set, or a set of instructions, and the at least one instruction, the at least one program, the code set, or the set of instructions is loaded and executed by the processor to implement the search recommendation method according to the above aspect, or implement the training method for the CTR prediction model according to the above aspect.
In yet another aspect, an embodiment of the present application provides a computer-readable storage medium, where at least one instruction, at least one program, a code set, or a set of instructions is stored in the computer-readable storage medium, and the at least one instruction, the at least one program, the code set, or the set of instructions is loaded and executed by a processor to implement the search recommendation method according to the above aspect, or implement the training method for the CTR prediction model according to the above aspect.
In a further aspect, an embodiment of the present application provides a computer program product, where the computer program product is used to implement the search recommendation method or implement the training method of the CTR prediction model when being executed by a processor.
The technical scheme provided by the embodiment of the application can have the following beneficial effects:
according to the technical scheme provided by the embodiment of the application, when the CTR values of the candidate words of the search words are estimated through the CTR estimation model, the characteristic information of the search words contained in the model input parameters comprises the sequence characteristics of the search words, the sequence characteristics of the search words represent the input sequence of the words contained in the search words, and the sequence characteristics of the search words can accurately reflect the real search intention of a user, so that when the CTR estimation is carried out through the CTR estimation model, the CTR values of the candidate words estimated by the CTR estimation model can be more accurate by combining the sequence characteristics of the search words, recommended candidate words which meet the requirements of the user can be obtained, and the accuracy of the recommended candidate words provided for the user can be improved.
Drawings
FIG. 1 is a flow chart illustrating a search recommendation method provided herein;
FIG. 2 is a flow diagram of a search recommendation method provided by one embodiment of the present application;
FIG. 3 is a flow diagram of a search recommendation method provided by another embodiment of the present application;
FIG. 4 is a diagram illustrating a model input parameter feature bit setting;
FIG. 5 is a diagram illustrating another model input parameter feature bit setting;
FIG. 6 illustrates a diagram showing recommended candidate words;
FIG. 7 is a flowchart of a search recommendation method provided by one embodiment of the present application;
FIG. 8 illustrates a schematic diagram of a Wide & Deep model;
FIG. 9 is a diagram illustrating a Wide & Deep model training process;
FIG. 10 illustrates a flow diagram of a CTR prediction model training method;
FIG. 11 is a block diagram of a search recommendation device provided in one embodiment of the present application;
fig. 12 is a block diagram of a search recommendation apparatus according to another embodiment of the present application;
fig. 13 is a block diagram of a CTR prediction model apparatus according to an embodiment of the present application;
fig. 14 is a block diagram of a CTR prediction model apparatus according to another embodiment of the present application;
fig. 15 is a block diagram of a computer device according to an embodiment of the present application.
Detailed Description
To make the objects, technical solutions and advantages of the present application more clear, embodiments of the present application will be described in further detail below with reference to the accompanying drawings.
First, terms referred to in the embodiments of the present application will be briefly described.
CTR (Click Through Rate): generally, CTR refers to the click-to-reach rate of network advertisements (such as picture advertisements, text advertisements, video advertisements, etc.), and is an important index for measuring the effectiveness of internet advertisements. For example, after keywords are input into a search engine, searching is performed, related webpages are sequentially arranged according to factors such as bidding and the like, and then a user can select a webpage of interest to click in; the number of times of searching a website is taken as the total number of times, and the ratio of the number of times of clicking and entering the webpage by the user to the total number of times is called click CTR. In the embodiment of the application, the CTR is a CTR value of each candidate word in a candidate word set predicted by a CTR prediction model, and a higher CTR value indicates a higher possibility that the candidate series word is clicked by a user.
Click rate: also commonly referred to as PV (Page View, page View volume), refers to the number of views of a web Page to measure the number of web pages accessed by a user. The user records PV for 1 time when opening one page, and the browsing volume is accumulated when opening the same page for a plurality of times.
In the method provided by the embodiment of the present application, the execution subject of each step may be a Computer device, which refers to an electronic device with data calculation, processing and storage capabilities, such as a PC (Personal Computer) or a server.
According to the technical scheme, search recommendation is achieved by means of a machine learning technology in the field of AI (Artificial Intelligence), so that recommended candidate words meeting requirements of users can be obtained, and accuracy of the recommended candidate words provided for the users is improved.
The artificial intelligence is a theory, method, technology and application system for simulating, extending and expanding human intelligence by using a digital computer or a machine controlled by the digital computer, sensing the environment, acquiring knowledge and obtaining the best result by using the knowledge. In other words, artificial intelligence is a comprehensive technique of computer science that attempts to understand the essence of intelligence and produce a new intelligent machine that can react in a manner similar to human intelligence. Artificial intelligence is the research of the design principle and the implementation method of various intelligent machines, so that the machines have the functions of perception, reasoning and decision making.
The artificial intelligence technology is a comprehensive subject and relates to the field of extensive technology, namely the technology of a hardware level and the technology of a software level. The artificial intelligence base technologies generally include technologies such as sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, big data processing technologies, operation/interaction systems, mechatronics, and the like. The artificial intelligence software technology mainly comprises a computer vision technology, a voice processing technology, a natural language processing technology, machine learning/deep learning and the like.
The ML (Machine Learning) is a multi-domain cross subject, and relates to multiple subjects such as probability theory, statistics, approximation theory, convex analysis, algorithm complexity theory, and the like. The method specially studies how a computer simulates or realizes the learning behavior of human beings so as to acquire new knowledge or skills and reorganize the existing knowledge structure to continuously improve the performance of the computer. Machine learning is the core of artificial intelligence, is the fundamental approach to make computers have intelligence, and is applied in various fields of artificial intelligence. Machine learning and deep learning generally include techniques such as artificial neural networks, belief networks, reinforcement learning, transfer learning, inductive learning, and formal education learning.
With the research and development of artificial intelligence technology, the artificial intelligence technology is developed and researched in a plurality of fields, such as common smart homes, smart wearable devices, virtual assistants, smart speakers, smart marketing, unmanned driving, automatic driving, unmanned aerial vehicles, robots, smart medical services, smart customer service and the like.
The scheme provided by the embodiment of the application relates to the technologies such as machine learning of artificial intelligence, and the like, and is specifically explained by the following embodiment.
Please refer to fig. 1, which schematically shows a flowchart of a search recommendation method provided by the present application.
After obtaining the search term 11, the computer device may perform a query in the inverted index table 12 to obtain a candidate term set 13 of the search term. Thereafter, the computing device may generate model input parameters 14 that include feature information of the search term and feature information of one candidate term, where the feature information of the search term includes an order feature of the search term. The computer equipment can call the CTR pre-estimation model 15 to calculate and obtain the CTR value 16 of each candidate word; and sorting the CTR values 16 of the candidate words in the order from high to low, and then selecting at least one candidate word ranked in the front as a recommended candidate word corresponding to the search word. Finally, the recommended candidate word list 17 is displayed in a drop-down box.
For the generation of the inverted index table, the computer device may obtain the historical search log 18 of the user, and perform filter cleaning on the data in the historical search log 18 to remove a large amount of candidate words that are not clicked by exposure and some abnormal data. Further, the history search words 19 with the click rate larger than the threshold value can be selected from the history search logs after filtering and cleaning, and then added into the candidate document set 20. In addition, the title 21 of the document in the search database and the title 22 of the popular search event may also be added to the candidate document set 20. After the candidate document set 20 is obtained, the candidate document set 20 may be normalized to obtain a standard candidate document set 23. For each document in the standard candidate document set 23, a correspondence relation associated with the document is generated, and the correspondence relations associated with the respective documents are integrated to generate the inverted index table 12.
For training of the CTR prediction model, computer equipment can obtain an exposure log 24 of a candidate word, and obtain a historical exposure candidate corresponding to a historical search word from the exposure log 24; then, a training sample 25 is constructed based on the feature information of the historical search words and the feature information of the historical exposure candidate words, the feature information of the historical search words comprises the sequential features of the historical search words, the training sample 25 is adopted to train 26 the CTR estimation model on line, and the trained CTR estimation model 15 is obtained. After the training of the CTR prediction model is completed, the CTR prediction model 15 may be pushed online, so that other computer devices may call the CTR prediction model 15 for prediction when needed.
In the search recommendation method provided by the embodiment of the application, the execution subject of each step may be a terminal device such as a mobile phone, a tablet computer, a PC, or the like, or may be a server. For example, when the CTR prediction model is deployed on a terminal device, the execution subject of each step of the search recommendation method may be the terminal device; when the CTR prediction model is deployed on a server device, the execution subject of each step of the search recommendation method may be the server device. For convenience of description, in the following embodiments of the search recommendation method, only the execution subject of each step is described as a computer device.
The technical solution of the present application will be described below by means of several embodiments.
Referring to fig. 2, a flowchart of a search recommendation method according to an embodiment of the present application is shown. In the present embodiment, the method is mainly exemplified by being applied to the computer device described above. The method may include the steps of:
step 201, a search word and a candidate word set of the search word are obtained.
The search term set may include at least one candidate term related to the search term, so that the computer device may select a recommended candidate term from the candidate term set of the search term.
Step 202, at least one group of model input parameters is generated according to the sequence characteristics of the search words, each group of model input parameters corresponds to one group of search words and candidate words, and the sequence characteristics of the search words are used for representing the input sequence of the words contained in the search words.
After the search term is obtained, at least one set of model input parameters may be generated according to the sequence characteristics of the search term. Wherein each set of model input parameters corresponds to a set of search terms and candidate terms. For example, assuming that p candidate words related to the search word are obtained, at this time, p sets of model input parameters may be generated, where each set of model parameters includes the search word and one candidate word of the p candidate words, and p is a positive integer.
After the search term is obtained, the computer device can extract the sequence feature of the search term. The sequence feature of the search word is used to characterize the input sequence of the words included in the search word, that is, to characterize which words are included in the search word, and what the input sequence of the words is. For example, the search word is "i like you only", and the input order of the words included in the search word is "i", "only", "like", "you" in this order.
Since the search terms include words in different input orders, the search intention of the represented user may be different. Therefore, in order to accurately know the real search intention of the user, the computer device may extract the sequence feature of the search word, and further perform search recommendation based on the sequence feature.
Optionally, the extracting of the sequence feature of the search word needs to perform word segmentation on the search word first to obtain a word included in the search word. The word segmentation processing may be divided at a word level or a single word level.
After extracting the sequential features of the search term, the computer device may generate at least one set of model input parameters from the sequential features of the search term. The model input parameters are used for inputting into the CTR prediction model to predict the CTR value of each candidate word of the search word.
In an exemplary embodiment, the model input parameters may include feature information of the search word and feature information of the candidate word.
The characteristic information of the search terms is used for representing attribute characteristics of the search terms. The feature information of the search term may include a sequential feature of the search term.
In one example, the feature information of the search word may further include a full-spelling feature of the search word, wherein the full-spelling feature of the search word is used for characterizing the sequence of the corresponding full spellings of the search word.
In this case, before the above-mentioned generating of at least one set of model input parameters, the following steps may also be performed:
(1) Performing phonetic notation processing on the words contained in the search words to obtain the complete spelling of the words contained in the search words;
(2) And generating the full spelling characteristics of the search word according to the full spelling of the words contained in the search word.
The phonetic notation processing is performed on the words contained in the search word, that is, the phonetic notation is performed on the words contained in the search word, so that the full spelling of the words contained in the search word is obtained. For example, the words contained by the search term are "i", "only", "like", "you", and the full spelling of the words contained by the search term is "wo", "zhi", "xihuan", "ni". Based on the full spelling of the words contained in the search term, the full spelling characteristics of the search term can be further generated through a series of processes.
Optionally, the full-spelling feature of the search term may be represented as a one-hot feature, and in this case, when the full spelling of the words included in the search term is obtained, one-hot encoding may be performed, so as to generate the full-spelling feature of the search term represented by the one-hot feature.
In yet another example, the feature information of the search term may further include an initial feature of the search term for characterizing an order of the full spellings corresponding to the search term.
In this case, before the above-mentioned generating of at least one set of model input parameters, the following steps may also be performed:
(1) Performing phonetic notation processing on the words contained in the search words to obtain the first letters of the words contained in the search words;
(2) The first character features of the search terms are generated from the first characters of the words contained by the search terms.
After the phonetic notation processing is carried out on the words contained in the search words, the complete spelling of the words contained in the search words can be obtained, and then the initial letters of the words contained in the search words can be extracted from the complete spelling.
Optionally, when divided at the level of a single word, the search term contains the first letter of the word, i.e. the first letter of the spelling of each word; when the division is made at the level of words and the words contained in the search word include words, the first letter of the words contained in the search word includes the first letter of the first word in the words.
For example, if the search term contains words whose overall spelling is "wo", "zhi", "xi", "huan", "ni", then the search term contains words whose initial letters are "w", "z", "x", "h", "n". For another example, if the word contained in the search term is spelled "wo", "zhi", "xihuan" or "ni", the initial of the word contained in the search term is "w", "z", "x" or "n". Based on the first letter of the word contained in the search word, the first letter characteristic of the search word may be further generated through a series of processes.
Optionally, the first character of the search term may also be represented as a one-hot character, and at this time, when the first character of a word included in the search term is acquired, one-hot encoding may be performed, so as to generate the first character of the search term represented by the one-hot character.
In addition, the feature information of the search word may further include a part-of-speech feature of the search word, where the part-of-speech feature is used to characterize the part-of-speech of the search word, such as a verb, a noun, an adjective, and so on.
The characteristic information of the candidate words is used for representing the attribute characteristics of the candidate words. The feature information of the candidate word may include an order feature of the candidate word, a full spelling feature of the candidate word, an initial feature of the candidate word, a part of speech feature of the candidate word, a category feature of the candidate word, and the like.
Optionally, the model input parameters may include, in addition to the feature information of the search word and the feature information of one candidate word, associated feature information between the search word and the candidate word, where the associated feature information is used to characterize an association relationship between the search word and the candidate word. The associated feature information may include relevance features, cross features, statistical features, and the like. The relevance feature is used for characterizing relevant features between the search word and the candidate word, such as relevance between words contained in the search word and the candidate word; the cross feature is used for characterizing the combined features of two or more features between the search word and the candidate word; the statistical characteristics are used to characterize the numerical characteristics between the search word and the candidate words, such as the number of candidate words corresponding to a certain search word, the number of clicked candidate words in a plurality of candidate words, the number of searched candidate words per day, and the like.
In addition, the model input parameters may also contain user characteristics that characterize the search user's attributes. For example, the user characteristics may include an age characteristic, a gender characteristic, and a geographic characteristic. Of course, the user characteristics are not limited to age characteristics, gender characteristics, geographic characteristics, but may also encompass any attribute characteristics associated with the user.
Step 203, calling a CTR pre-estimation model, and calculating the CTR value of the candidate word according to the model input parameters.
The CTR pre-estimation model is used for calculating the CTR value of the candidate word, and the higher the CTR value is, the higher the possibility that the candidate word is clicked by the user is.
The CTR prediction model may be a Wide & Deep model, a Deep fm (Deep Factorization) model, an AFM (atomic force modeling) model, an attention Factorization (attention) model, or a Data Communication Network (DCN) model. In addition, the CTR prediction model may also be other machine learning models, which is not limited in the embodiment of the present application.
The CTR pre-estimation model can be trained on line and pushed to the line after training is completed, so that the CTR pre-estimation model can be used by computer equipment. For a detailed description of the CTR prediction model, please refer to the following embodiment of fig. 6, which is not repeated herein.
And step 204, selecting a recommended candidate word corresponding to the search word from the candidate word set according to the CTR value of the candidate word.
After the CTR values of the candidate words are obtained, the computer device may select a recommended candidate word corresponding to the search word according to the CTR values of the candidate words, and recommend the recommended candidate word to the user.
Alternatively, the computer device may sort the CTR values of the respective candidate words in order from high to low, and then select at least one candidate word ranked first as the recommendation candidate word corresponding to the search word, for example, 10 candidate words ranked top 10 in CTR value as the recommendation candidate words corresponding to the search word.
Alternatively, the computer device may take the candidate word having the CTR value greater than the threshold value as the recommended candidate word corresponding to the search word.
In summary, according to the technical scheme provided by the embodiment of the application, when the CTR values of the candidate words of the search word are estimated through the CTR estimation model, the feature information of the search word included in the model input parameters includes the sequence features of the search word, the sequence features of the search word represent the input sequence of the words included in the search word, and the sequence features of the search word can accurately reflect the real search intention of the user.
Referring to fig. 3, a flowchart of a search recommendation method according to another embodiment of the present application is shown. In the present embodiment, the method is mainly exemplified by being applied to the computer device described above. The method may include the steps of:
step 301, search terms are obtained.
This step is the same as or similar to step 201 in the embodiment of fig. 2, and is not repeated here.
Step 302, generating a keyword corresponding to the search term.
The keywords include at least one of: the words contained by the search term, the spellings of the words contained by the search term, and the first letters of the words contained by the search term. The computer equipment generates a keyword corresponding to the search word so as to obtain a candidate word set of the search word based on the keyword in the subsequent steps.
Optionally, the computer device may perform a word segmentation process on the search term to obtain a word included in the search term; phonetic notation processing can be carried out on the search word to obtain a complete spelling of the words contained in the search word; further, the computer device may extract the first letter of the word contained by the search term from the full spellings of the words contained by the search term.
For the description of the word segmentation process and the phonetic notation process, refer to the contents in the embodiment of fig. 2, which are not described herein again.
And step 303, querying in the inverted index table by using the keywords to obtain a candidate word set of the search words.
The inverted index table includes a corresponding relationship between the keyword and the candidate word. Each keyword may correspond to at least one candidate word.
Illustratively, the search term is "i like you only", and the keywords corresponding to the search term may include "i", "only", "like", "happy", "you", "wo", "zhi", "xi", "huan", "ni", "w", "z", "x", "h", "n", "woz", "wozhh", "wozoxixi", "wozoxihuan", "wozoxihuanni", "w", "like you", "xihuanni", and the like. Taking keywords as "me", "only", "happy", and "you" as examples, each keyword corresponds to at least one candidate word, as shown in the following table-1:
keyword Candidate word
I am concerned with Candidate word 1, candidate word 2, candidate word 3
Only by Candidate word 1, candidate word 3
Happiness Candidate word 2
A Chinese medicinal composition Candidate word 3
You are Candidate word 2, candidate word 3
TABLE-1
After the keywords are obtained, the candidate word set of the search words can be obtained according to the inverted index table.
Optionally, before the keyword is used for querying in the inverted index table to obtain the candidate word set of the search word, the following steps may be further performed:
(1) And constructing a candidate document set, wherein the candidate document set comprises at least one document.
The above document includes at least one of: historical search terms with click rate greater than a threshold value, titles of documents in the search database, and titles of popular search events.
Optionally, the computer device may obtain a historical search log of the user, and perform filtering and cleaning on data in the log to remove a large number of candidate words that are not clicked by exposure and some abnormal data. Further, historical search terms with click quantity larger than a threshold value can be selected from the filtered and cleaned logs and added into the candidate document set.
The computer device may also obtain titles of documents in a search database, the search database containing at least one document, each document having a respective title. Taking an example of searching in a certain video application by a user, the above search database is a video database in the application, and the video database contains a plurality of videos, and each video has a respective title.
The computer device may also obtain titles of popular search events. Alternatively, the computer device may capture the title of the popular search event from another database (e.g., a database of a search engine, a database of microblogs, etc.).
Optionally, the content in the candidate document set is relatively cluttered because the content in the candidate document set comes from different channels. Therefore, after the candidate document set is obtained, the candidate document set may be subjected to normalization processing to unify the contents in the candidate document set, so as to facilitate subsequent queries.
(2) For each document, a correspondence is generated that is related to the document.
The keywords in the corresponding relationship include at least one of the following: the words contained in the document, the spellings of the words contained in the document, the first letters of the words contained in the document, and the candidate words in the correspondence include the document.
Alternatively, the computer device may perform word segmentation and phonetic notation on each document to obtain words, spellings, and initials contained in the document.
(3) And integrating the corresponding relation related to each document to generate an inverted index table.
Illustratively, the set of candidate documents includes 3 documents: document 1, document 2, and document 3 take the keywords in the correspondence as words contained in the documents as an example. Assume that the contained words of the 3 documents are as follows:
document 1: word 1, word 2, word 3;
document 2: word 1, word 4, word 5;
document 3: word 2, word 3, word 5, word 6.
Integrating the corresponding relations related to the 3 documents, the generated inverted index table can be expressed as:
keyword Candidate word
Character 1 Document 1, document 2
Character 2 Document 1, document 3
Word 3 Document 1, document 3
Character 4 Document 2
Character 5 Document 2, document 3
Character 6 Document 3
TABLE-2
It should be noted that, the order of executing the steps 301, 302, and 303 is not limited, and the step 301 may be executed first, and then the steps 302 and 303 may be executed; or, step 302 and step 303 may be executed first, and then step 301 may be executed; it is also possible to perform steps 301 and 302 simultaneously and to perform step 303 after step 302.
Step 304, calculating the similarity between the search word and each candidate word.
The computer device may also calculate a similarity between the search word and each of the candidate words. The similarity is used for representing the similarity between the search word and each candidate word.
Optionally, the similarity may be calculated in any one of the following manners: TF-IFD (Term Frequency-Inverse Document Term Frequency) algorithm, cosine similarity, euclidean distance and Hamming distance. Of course, the calculation of the similarity is not limited to the above algorithms, and may also cover other algorithms capable of calculating the similarity, which is not limited in the embodiment of the present application.
And 305, determining the candidate words with the similarity greater than the preset similarity as an updated candidate word set.
Further, the computer device may use the candidate word with the similarity greater than the preset similarity as the candidate word in the updated candidate word set.
Optionally, the computer device may sort the similarity degrees in an order from large to small, and use the candidate words corresponding to the previous multiple similarity degrees as candidate words in the updated candidate word set.
By using the candidate words with the similarity greater than the preset similarity as the candidate words in the updated candidate word set, the relevance between the candidate words and the search words is ensured, and the accuracy of candidate word recommendation can be further improved.
Step 306, extracting the sequence feature of the search term.
The sequence feature of the search term is used to characterize the input sequence of the words that the search term contains.
This step is the same as or similar to step 202 in the embodiment of fig. 2, and is not described here again.
And 307, generating at least one group of model input parameters according to the sequence characteristics of the search words, wherein each group of model input parameters corresponds to one group of search words and candidate words, and the sequence characteristics of the search words are used for representing the input sequence of the words contained in the search words.
The model input parameters may also contain the full spelling and/or initial character of the search term. For other descriptions about the model input parameters, please refer to the content of step 203 in the embodiment of fig. 2, which is not described herein again.
Optionally, the model input parameter may further include, in addition to the feature information of the search word and the feature information of one candidate word, associated feature information between the search word and the candidate word, where the associated feature information is used to characterize an association relationship between the search word and the candidate word. The associated feature information may include relevance features, cross features, statistical features, and the like. The relevance feature is used for characterizing relevant features between the search word and the candidate word, such as relevance between words contained in the search word and the candidate word; the cross feature is used for characterizing the combined features of two or more features between the search word and the candidate word; the statistical characteristics are used to characterize the numerical characteristics between the search word and the candidate words, such as the number of candidate words corresponding to a certain search word, the number of clicked candidate words in a plurality of candidate words, the number of times the search word is searched every day, and the like.
In addition, the model input parameters may also contain user characteristics that characterize the search user's attributes. For example, the user characteristics may include an age characteristic, a gender characteristic, and a geographic characteristic. Of course, the user characteristics are not limited to age characteristics, gender characteristics, geographic characteristics, but may also encompass any attribute characteristics associated with the user.
Optionally, n feature bits included in the model input parameter are used to add sequence features of the search term, where n is an integer greater than 1, and if the number m of words included in the search term is greater than or equal to n, the n feature bits include n first words of the words included in the search term, and m is an integer greater than 1; when m is larger than n, the words after the nth word in the words contained in the search word are all cut off and the characteristic bit is not implanted. If the number m of the words contained in the search word is smaller than n, the n feature bits comprise the m words contained in the search word, and n-m feature positions behind the mth feature bit in the n feature bits are empty.
Exemplary, referring to fig. 4 in combination, a schematic diagram of a model input parameter feature bit setting is illustrated. If n is 10, if the search word is "i only likes you", the search word is cut into words at the word level to obtain five words, i "," only "," happy ", and" you ", and the five words are sequentially input into the first 5 feature bits: "I" is added to the first feature bit, "only" is added to the second feature bit, "xi" is added to the third feature bit, "Huan" is added to the fourth feature bit, "you" is added to the fifth feature bit.
With continued reference to fig. 4, when the model input parameters further include the full-spelling character and the initial character of the search word, the full-spelling corresponding to the search word may be input from the 11 th character position according to the sequence of the full-spelling corresponding to the search word; and then inputting the full spelling initials corresponding to the search terms from the 21 st characteristic position according to the sequence of the full spelling initials corresponding to the search terms.
Alternatively, referring to fig. 5 in combination, when the model input parameter includes feature information of a search word, feature information of a candidate word, and associated feature information between the search word and the candidate word, the feature information of the search word, the feature information of the candidate word, and the associated feature information between the search word and the candidate word are sequentially added to the model input parameter.
And 308, calling the CTR prediction model, and calculating the CTR value of the candidate word according to the model input parameters.
After the updated candidate word set is obtained, the computer device may invoke the CTR prediction model, and calculate the CTR value of each candidate word included in the updated candidate word set according to each set of model input parameters.
Step 309, selecting a recommended candidate word corresponding to the search word from the candidate word set according to the CTR value of the candidate word.
After the CTR values of the candidate words are obtained, the computer device may select a recommended candidate word corresponding to the search word according to the CTR values of the candidate words, and recommend the recommended candidate word to the user.
Optionally, when the CTR prediction model is deployed on the terminal device, the terminal device may arrange the CTR values of the candidate words according to a descending order of the CTR values, and select at least one candidate word in the top order as a recommended candidate word corresponding to the search word to be displayed to the user.
Optionally, when the CTR prediction model is deployed on the server device, after the server device filters out the recommendation candidate words, the server device may send, in addition to sending each recommendation candidate word to the terminal device, a result of ranking of the recommendation candidate words or a CTR value of each recommendation candidate word. The sorting result may be a result obtained by sorting the CTR values in descending order. When the terminal device displays the recommended candidate words, the recommended candidate words are ranked and displayed according to the CTR values, for example, the ranked candidate words are ranked according to the sequence of the CTR values from large to small, and the larger the CTR value is, the closer the ranking is, the smaller the CTR value is, and the closer the ranking is. Illustratively, as shown in fig. 6, a user searches in a video application installed on a terminal device. The user enters the search term "i like you only" in the search box 61 of the video-like application; the terminal device may send the search word to the server device; correspondingly, the server equipment can receive the search word and screen out a recommended candidate word by using the CTR pre-estimation model; then, the server device may send each recommended candidate word, the ranking result of the recommended candidate words, or the CTR value of each recommended candidate word to the terminal device. And the video application program on the terminal equipment sorts the recommended candidate words according to the CTR values, and selects the top 5 candidate words with the highest CTR values as a recommended candidate word list 62 to be displayed to the user.
According to the embodiment of the application, when the CTR value is calculated, the sequence characteristics of the search words are considered, so that the calculation result of the CTR value of each candidate word is more accurate, and the sequencing result of each recommended candidate word is more accurate.
In summary, according to the technical scheme provided by the embodiment of the application, when the CTR values of the candidate words of the search word are estimated through the CTR estimation model, the feature information of the search word included in the model input parameters includes the sequence features of the search word, the sequence features of the search word represent the input sequence of the words included in the search word, and the sequence features of the search word can accurately reflect the real search intention of the user.
In addition, the characteristic information of the search word can contain the full spelling characteristic and/or the first letter characteristic of the search word besides the sequence characteristic of the search word, makes up the deficiency of the pinyin, and can ensure the final recommendation effect in the scene of inputting the pinyin, the Chinese or the mixed Chinese and pinyin by the user.
In addition, the candidate words with the similarity greater than the preset similarity are used as the candidate words in the updated candidate word set, so that the correlation between the candidate words and the search words is guaranteed, and the accuracy of candidate word recommendation can be further improved.
In the above embodiment, search recommendation is performed based on the CTR prediction model, and the following describes a training process of the CTR prediction model by way of example.
Please refer to fig. 7, which illustrates a flowchart of a training method of a CTR prediction model according to an embodiment of the present application. In the present embodiment, the method is mainly exemplified by being applied to the computer device described above. The method may include the steps of:
step 701, obtaining a history search word and a history exposure candidate word corresponding to the history search word.
The computer device can acquire a search log and an exposure log of a user, and obtain a historical search word of the user and a historical exposure candidate word corresponding to the historical search word from the search log.
Optionally, the computer device may extract the search log and the exposure click log directly from the running log, or may obtain the search log and the exposure click log from other electronic devices, which is not limited in this embodiment of the present application.
Optionally, after the search log and the exposure log of the user are obtained, cleaning and filtering may be performed on data in the log to remove abnormal data.
Step 702, at least one group of training samples is constructed according to the sequence characteristics of the historical search words, each group of training samples corresponds to one group of historical search words and historical exposure candidate words, and the sequence characteristics of the historical search words are used for representing the input sequence of words contained in the historical search words.
After the historical search terms are obtained, at least one training sample can be constructed according to the sequence characteristics of the historical search terms. Each set of training samples corresponds to a set of historical search terms and historical exposure candidate terms. For example, assuming that q historical exposure candidate words corresponding to the historical search word are obtained, at this time, q sets of training samples may be constructed, where each set of training samples includes the historical search word and one of the q historical exposure candidate words, and q is a positive integer.
The training samples may include positive samples or may include negative samples. In addition, for each training sample, there is included a label value. In the embodiment of the present application, whether the user clicks the label as the training sample is determined, for example, the value of the label corresponding to the user clicking is 1, and the value of the label corresponding to the user not clicking is 0.
Optionally, before at least one group of training samples is constructed according to the sequence features of the historical search words, word segmentation processing can be performed on the historical search words, and the sequence features of the historical search words can be extracted. The sequence feature of the historical search word is used for representing the input sequence of the words contained in the historical search word.
Optionally, the performing the word segmentation process on the historical search term to extract the sequential feature of the historical search term may include the following sub-steps:
(1) Dividing the historical search terms according to the grade of the characters to obtain all characters contained in the historical search terms;
(2) And obtaining the sequence characteristics of the historical search terms according to the sequence of each character contained in the historical search terms.
The above-mentioned dividing the history search word by the word level, that is, dividing all the words contained in the history search word into the independent words. When the historical search word is English, each word is regarded as a character.
Since the input order of each word is different, the search intention of the represented user is different. Therefore, in order to accurately know the real search intention of the user corresponding to the historical search word, the sequence characteristics of the historical search word can be acquired.
Optionally, after the order of each word included in the history search term is obtained, one-hot encoding may be performed on each word included in the history search term, so as to obtain an order feature of the history search term, which is represented by a one-hot feature.
In some other embodiments, the sequence feature of the historical search term may also be expressed in other forms, which is not limited in this application.
In the embodiment of the application, the historical search terms are divided according to the word level, and the sequence characteristics of the historical search terms are obtained according to the sequence of each word contained in the historical search terms, so that on one hand, the influence on the search result due to inaccuracy of word segmentation is avoided; on the other hand, the real search intention of the user corresponding to the historical search word can be accurately obtained by searching based on the word sequence, so that more reasonable results can be provided for the user.
In an exemplary embodiment, the training samples may include feature information of historical search words and feature information of historical exposure candidate words.
The characteristic information of the historical search words is used for representing the attribute characteristics of the historical search words. The feature information of the historical search term includes a sequential feature of the historical search term.
In one example, the feature information of the historical search term further includes a spelling feature of the historical search term.
In this case, before constructing the training sample, the following steps may be performed:
(1) Performing phonetic notation processing on the words contained in the historical search words to obtain the full spelling of the words contained in the historical search words;
(2) And generating the full spelling characteristics of the historical search words according to the full spelling of the words contained in the historical search words.
In another example, the characteristic information of the historical search term further includes the initial characteristic of the historical search term
In this case, before the training sample is constructed, the following steps may be performed:
(1) Performing phonetic notation processing on words contained in the historical search words to obtain first letters of the words contained in the historical search words;
(2) And generating the initial character of the historical search word according to the initial character of the word contained in the historical search word.
The characteristic information of the historical exposure candidate words is used for representing attribute characteristics of the historical exposure candidate words. The feature information of the historical exposure candidate words may include sequential features of the historical exposure candidate words, spelling features of the historical exposure candidate words, initial features of the historical exposure candidate words, part-of-speech features of the historical exposure candidate words, category features of the historical exposure candidate words, and the like.
Optionally, in the training sample, the sequential feature of the historical search terms, the spelling feature of the historical search terms, and the initial feature of the historical search terms are arranged in sequence.
In addition, the training sample may also contain user features that are used to characterize the search user's attributes. For example, the user characteristics may include an age characteristic, a gender characteristic, and a geographic characteristic. Of course, the user characteristics are not limited to age characteristics, gender characteristics, geographic characteristics, but may also encompass any attribute characteristics associated with the user.
And 703, training the CTR prediction model by using the training samples to obtain the trained CTR prediction model.
After the training samples are obtained, the training samples can be adopted to train the CTR estimation model, and the trained CTR estimation model is obtained.
Optionally, after the training of the CTR prediction model is completed, the trained CTR prediction model may be verified. After successful verification, the CTR predictive model can be pushed to the line for other computer equipment to call the CTR predictive model for prediction when needed.
In summary, according to the technical scheme provided by the embodiment of the application, the history search words and the history exposure candidate words corresponding to the history search words are obtained; performing word segmentation processing on the historical search words, and extracting sequence characteristics of the historical search words; constructing a training sample containing the sequence characteristics of the historical search terms; and training the CTR prediction model by adopting the training samples to obtain the trained CTR prediction model. Compared with a feature processing mode in the related art, the sequential features of the historical search terms are considered during model training, so that the trained model can better capture the search intention of the user, and more accurate recommendation results are further provided.
In the following, taking the CTR prediction model as Wide & Deep model as an example, the training process of the model is introduced.
First, the architecture of the Wide & Deep model is briefly introduced. Referring collectively to fig. 8, a schematic diagram of a Wide & Deep model is illustrated.
As shown in fig. 8, the Wide & Deep model includes two parts, i.e., a Wide model (left part in fig. 8) and a Deep model (right part in fig. 8).
For Wide model, which is a generalized linear model, it can be expressed as:
y=w T x+b;
wherein y represents the output of the model, i.e. the estimated CTR value; the characteristic of the input Wide model input of the x representation model comprises low-dimensional dense characteristic and high-dimensional sparse characteristic, and x = [ x1, x2, \8230 ];, xd ] represents that x is a d-dimensional vector; w represents the parameters of the model, w = [ w1, w2, \8230;, wd ]; b represents the weight of the model.
For the Deep model, the discrete feature information is input into the input layer 81, and the input discrete feature information can be compressed into a low-dimensional continuous dense vector through the weight matrix calculation by the Embedding process 82 (Embedding), so that the calculation resources can be saved. These low-dimensional continuous dense vectors are sequentially transmitted to two hidden layers 83, and the output 84 of the model is obtained after the hidden layers 83 are calculated.
As shown in fig. 9, a schematic diagram of a Wide & Deep model training process is exemplarily shown. After the training samples 91 are acquired, the training samples 91 are input into the Wide & Deep model. Calculating continuous features and discrete features input at the side of the Wide model to obtain the weight of the Wide model; the Deep model side first performs embedding processing 92 on the input discrete features to obtain embedded values corresponding to the discrete features. Then, the weight of the Wide model and the embedded value are input into a fully connected Layer 93 (configured Layer), and then through a multi-Layer activation Layer 94, the activation function of the activation Layer 94 may be Relu, and finally, the model is trained by minimizing the value of a loss function (such as a Sigmoid function) in a loss Layer 95 by using whether the user clicks or not as a label.
In the following, a complete training process of the CTR prediction model is briefly introduced. As shown in fig. 10, a flow chart of a CTR prediction model training method is exemplarily shown. The computer device may acquire a search log and an exposure log 100 of a user and obtain a historical search word of the user and a historical exposure candidate word corresponding to the historical search word from the search log. In addition, the computer device may further obtain user data 101 of the user, where the user data may include age information, gender information, region information, and the like, and may further generate user characteristics according to the user data to train the CTR prediction model. Further, word cutting processing 102 is carried out on the historical search words, and sequence features of the historical search words are extracted; and (5) performing phonetic notation processing 103 on the historical search words, extracting the full spelling characteristics of the historical search words, and further obtaining the initial characteristics of the historical search words. The training sample 104 is generated based on the above-mentioned feature information of the historical search words, such as the sequential feature of the historical search words, the full spelling feature of the historical search words, and the initial feature of the historical search words, and the feature information of the historical exposure candidate words. The training samples may then be used for model training 105. Optionally, a pre-training model 106 may be obtained, and training may be performed based on the pre-training model 106. After the training is completed, the trained CTR prediction model may be subjected to model verification 107. After successful verification, model push 108 may be performed, i.e., the CTR prediction model is pushed online for other computer devices to invoke the CTR prediction model for prediction when needed, i.e., model service 109.
The following are embodiments of the apparatus of the present application that may be used to perform embodiments of the method of the present application. For details which are not disclosed in the embodiments of the apparatus of the present application, reference is made to the embodiments of the method of the present application.
Referring to fig. 11, a block diagram of a search recommendation apparatus according to an embodiment of the present application is shown. The device has the function of realizing the search recommendation method example, and the function can be realized by hardware or by hardware executing corresponding software. The apparatus may be a computer device as described above, and may be provided in a computer device. The apparatus 1100 may include: the search word obtaining module 1101, the candidate word obtaining module 1102, the parameter generating module 1103, the model invoking module 1104 and the recommendation selecting module 1105.
A search word acquisition module 1101 configured to acquire a search word;
a candidate word obtaining module 1102, configured to obtain a candidate word set of the search word, where the candidate word set includes at least one candidate word related to the search word.
A parameter generating module 1103, configured to generate at least one set of model input parameters according to the sequence characteristics of the search term, where each set of model input parameters corresponds to a set of the search term and the candidate term, and the sequence characteristics of the search term are used to represent an input sequence of words included in the search term.
And the model calling module 1104 is used for calling the CTR prediction model and calculating the CTR value of the candidate word according to the model input parameters.
And a recommendation selecting module 1105, configured to select, according to the CTR value of the candidate word, a recommendation candidate word corresponding to the search word from the candidate word set.
In summary, according to the technical scheme provided by the embodiment of the application, when the CTR prediction model predicts the CTR values of the candidate words of the search word, the feature information of the search word included in the model input parameter includes the sequence feature of the search word, and the sequence feature of the search word represents the input sequence of the words included in the search word.
In some possible designs, as shown in fig. 12, the apparatus 1100 further comprises: a ZhuYin processing module 1106 and a perfect spelling pattern generation module 1107.
A ZhuYin processing module 1106, configured to perform ZhuYin processing on the words included in the search term to obtain a full spelling of the words included in the search term.
A full spelling feature generation module 1107, configured to generate a full spelling feature of the search term according to a full spelling of words included in the search term; wherein the model input parameters further include a full spelling feature of the search term.
In some possible designs, as shown in fig. 12, the apparatus 1100 further comprises: an initial obtaining module 1108 and an initial feature generating module 1109.
A first letter obtaining module 1108, configured to perform phonetic notation processing on the words included in the search term, so as to obtain the first letter of the words included in the search term.
An initial feature generating module 1109, configured to generate an initial feature of the search word according to an initial of a word included in the search word; wherein the model input parameters further comprise an initial feature of the search term.
In some possible designs, the model input parameter includes n feature bits for adding sequential features of the search term, where n is an integer greater than 1; when the number m of the words contained in the search word is greater than or equal to n, the n characteristic bits comprise the first n words of the words contained in the search word, and m is an integer greater than 1; when the number m of the words contained in the search word is smaller than n, the n feature bits include the m words contained in the search word, and n-m feature positions after the mth feature bit in the n feature bits are empty.
In some possible designs, the candidate word obtaining module 1102 is further configured to generate a keyword corresponding to the search word, where the keyword includes at least one of the following: the words contained by the search terms, the spellings of the words contained by the search terms, and the initials of the words contained by the search terms; and querying in an inverted index table by adopting the keywords to obtain a candidate word set of the search words, wherein the inverted index table comprises the corresponding relation between the keywords and the candidate words.
In some possible designs, as shown in fig. 12, the apparatus 1100 further comprises: a document set construction module 1110, a correspondence generation module 1111, and an index table generation module 1112.
A document set constructing module 1110, configured to construct a candidate document set, where the candidate document set includes at least one document, and the document includes at least one of: historical search terms with click rate greater than a threshold value, titles of documents in the search database, and titles of popular search events.
A correspondence generating module 1111, configured to generate, for each document, a correspondence related to the document, where a keyword in the correspondence includes at least one of: words contained in the document, spellings of the words contained in the document, initials of the words contained in the document, and candidate words in the correspondence include the document.
An index table generating module 1112, configured to integrate the corresponding relationships related to the documents to generate the inverted index table.
In some possible designs, as shown in fig. 12, the apparatus 1100 further comprises: a similarity calculation module 1113 and a word set update module 1114.
A similarity calculating module 1113, configured to calculate a similarity between the search word and each of the candidate words.
The word set updating module 1114 is configured to determine the candidate words with the similarity greater than a preset similarity as an updated candidate word set; and calculating the CTR value of each candidate word in the updated candidate word set by the CTR pre-estimation model.
Please refer to fig. 13, which illustrates a block diagram of a CTR prediction model apparatus according to an embodiment of the present application. The device has the function of realizing the CTR prediction model method example, and the function can be realized by hardware or by hardware executing corresponding software. The device can be the computer device described above, and can also be arranged in the computer device. The apparatus 1300 may include: a word acquisition module 1310, a sample construction module 1320, and a model training module 1330.
A word obtaining module 1310, configured to obtain a history search word and a history exposure candidate word corresponding to the history search word.
A sample construction module 1320, configured to construct at least one set of training samples according to the sequence characteristics of the historical search words, where each set of training samples corresponds to a set of the historical search words and the historical exposure candidate words, and the sequence characteristics of the historical search words are used to represent an input sequence of words included in the historical search words.
The model training module 1330 is configured to train the CTR prediction model by using the training samples to obtain a trained CTR prediction model.
In summary, according to the technical scheme provided by the embodiment of the application, the history search word and the history exposure candidate word corresponding to the history search word are obtained; performing word segmentation processing on the historical search words, and extracting sequence characteristics of the historical search words; constructing a training sample containing the sequence characteristics of the historical search terms; and training the CTR estimation model by adopting the training samples to obtain the trained CTR estimation model. Compared with a feature processing mode in the related art, the sequential features of the historical search words are considered during model training, so that the trained model can better capture the search intention of the user, and more accurate recommendation results are further provided.
In some possible designs, the apparatus 1300 further comprises: a segmentation processing module 1340, and a sequence feature generation module 1350.
The word segmentation processing module 1340 is configured to divide the historical search words according to word levels to obtain each word included in the historical search words.
A sequence feature generating module 1350, configured to obtain sequence features of the historical search terms according to sequences of the characters included in the historical search terms.
In some possible designs, as shown in fig. 14, the apparatus 1300 further comprises: a ZhuYin processing module 1360, and a spell feature generation module 1370.
The phonetic notation processing module 1360 is configured to perform phonetic notation processing on the words included in the historical search term to obtain a full spelling of the words included in the historical search term.
A full spelling feature generation module 1370, configured to generate a full spelling feature of the historical search term according to a full spelling of a word included in the historical search term; wherein the training samples further include full spelling features of the historical search terms.
In some possible designs, as shown in fig. 14, the apparatus 1300 further comprises: an initial acquisition module 1380 and an initial feature generation module 1390.
The initial obtaining module 1380 is configured to perform phonetic notation processing on the words included in the historical search term to obtain the initial of the words included in the historical search term.
An initial feature generation module 1390, configured to generate an initial feature of the historical search term according to an initial of a word included in the historical search term; wherein the training sample further comprises initial features of the historical search terms.
It should be noted that, when the apparatus provided in the foregoing embodiment implements the functions thereof, only the division of the functional modules is illustrated, and in practical applications, the functions may be distributed by different functional modules according to needs, that is, the internal structure of the apparatus may be divided into different functional modules to implement all or part of the functions described above. In addition, the apparatus and method embodiments provided by the above embodiments belong to the same concept, and specific implementation processes thereof are described in the method embodiments for details, which are not described herein again.
Referring to fig. 15, a schematic structural diagram of a computer device according to an embodiment of the present application is shown. Specifically, the method comprises the following steps:
the computer device 1600 includes a Central Processing Unit (CPU) 1601, a system memory 1604 that includes a Random Access Memory (RAM) 1602 and a Read Only Memory (ROM) 1603, and a system bus 1605 that couples the system memory 1604 and the central processing unit 1601. The computer device 1600 also includes a basic input/output system (I/O system) 1606, which facilitates transfer of information between devices within the computer, and a mass storage device 1607 for storing an operating system 1613, application programs 1614, and other program modules 1612.
The basic input/output system 1606 includes a display 1608 for displaying information and an input device 1609 such as a mouse, keyboard, etc. for user input of information. Wherein the display 1608 and the input device 1609 are both connected to the central processing unit 1601 by way of an input-output controller 1610 which is connected to the system bus 1605. The basic input/output system 1606 may also include an input-output controller 1610 for receiving and processing input from a number of other devices, such as a keyboard, mouse, or electronic stylus. Similarly, an input-output controller 1610 may also provide output to a display screen, a printer, or other type of output device.
The mass storage device 1607 is connected to the central processing unit 1601 by a mass storage controller (not shown) connected to the system bus 1605. The mass storage device 1607 and its associated computer-readable media provide non-volatile storage for the computer device 1600. That is, the mass storage device 1607 may include a computer-readable medium (not shown) such as a hard disk or CD-ROM drive.
Without loss of generality, the computer-readable media may comprise computer storage media and communication media. Computer storage media includes volatile and nonvolatile, removable and non-removable media implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data. Computer storage media includes RAM, ROM, EPROM, EEPROM, flash memory or other solid state storage technology, CD-ROM, DVD, or other optical storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices. Of course, those skilled in the art will appreciate that the computer storage media is not limited to the foregoing. The system memory 1604 and mass storage device 1607 described above may be collectively referred to as memory.
According to various embodiments of the present application, the computer device 1600 may also operate as a remote computer connected to a network via a network, such as the Internet. That is, the computer 1600 may be connected to the network 1612 through the network interface unit 1611 coupled to the system bus 1605, or the network interface unit 1611 may be used to connect to other types of networks or remote computer systems (not shown).
The memory also includes at least one instruction, at least one program, set of codes, or set of instructions stored in the memory and configured to be executed by the one or more processors to implement the search recommendation method or to implement the CTR prediction model training method.
In an exemplary embodiment, a computer-readable storage medium is further provided, in which at least one instruction, at least one program, a set of codes, or a set of instructions is stored, which when executed by a processor implements the above search recommendation method or implements the above CTR prediction model training method.
In an exemplary embodiment, a computer program product for implementing the search recommendation method or the CTR prediction model training method is also provided, when the computer program product is executed by a processor.
It should be understood that reference herein to "a plurality" means two or more. "and/or" describes the association relationship of the associated object, indicating that there may be three relationships, for example, a and/or B, which may indicate: a exists alone, A and B exist simultaneously, and B exists alone. The character "/" generally indicates that the former and latter associated objects are in an "or" relationship.
The above description is only exemplary of the present application and should not be taken as limiting the present application, and any modifications, equivalents, improvements and the like that are made within the spirit and principle of the present application should be included in the protection scope of the present application.

Claims (15)

1. A search recommendation method, the method comprising:
acquiring a search word and a candidate word set of the search word, wherein the candidate word set comprises at least one candidate word related to the search word;
generating at least one group of model input parameters according to the sequence characteristics of the search words, wherein each group of model input parameters corresponds to one group of search words and the candidate words, and the sequence characteristics of the search words are used for representing the input sequence of the words contained in the search words;
calling a Click Through Rate (CTR) pre-estimation model, and calculating according to the model input parameters to obtain the CTR value of the candidate word;
and selecting a recommended candidate word corresponding to the search word from the candidate word set according to the CTR value of the candidate word.
2. The method of claim 1, prior to generating at least one set of model input parameters based on sequential features of the search term, further comprising:
performing phonetic notation processing on the words contained in the search words to obtain a full spelling of the words contained in the search words;
generating a full spelling feature of the search term according to a full spelling of the words contained in the search term;
wherein the model input parameters further include a spell feature of the search term.
3. The method of claim 1, wherein prior to generating at least one set of model input parameters based on sequential features of the search term, further comprising:
performing phonetic notation processing on the words contained in the search words to obtain the first letters of the words contained in the search words;
generating the first character characteristics of the search words according to the first characters of the words contained in the search words;
wherein the model input parameters further comprise an initial feature of the search term.
4. The method according to claim 1, wherein the model input parameters comprise n feature bits for adding sequential features of the search term, wherein n is an integer greater than 1;
if the number m of the words contained in the search word is greater than or equal to n, the n feature bits include the first n words of the words contained in the search word, and m is an integer greater than 1;
if the number m of the words contained in the search word is smaller than n, the n feature bits include the m words contained in the search word, and n-m feature positions behind the mth feature bit in the n feature bits are empty.
5. The method of claim 1, wherein the obtaining the set of candidate words for the search word comprises:
generating keywords corresponding to the search terms, wherein the keywords comprise at least one of the following items: the words contained in the search words, the full spellings of the words contained in the search words, and the initials of the words contained in the search words;
and querying in an inverted index table by adopting the keywords to obtain a candidate word set of the search words, wherein the inverted index table comprises the corresponding relation between the keywords and the candidate words.
6. The method of claim 5, wherein before the querying the inverted index table with the keyword to obtain the candidate word set of the search word, the method further comprises:
constructing a candidate document set, wherein the candidate document set comprises at least one document, and the document comprises at least one of the following documents: historical search terms with click rate larger than a threshold value, titles of documents in a search database and titles of popular search events;
for each document, generating a corresponding relation related to the document, wherein a keyword in the corresponding relation comprises at least one of the following items: words contained in the document, spelling of the words contained in the document, first letters of the words contained in the document, candidate words in the correspondence comprising the document;
and integrating the corresponding relation related to each document to generate the inverted index table.
7. The method according to any one of claims 1 to 6, wherein after obtaining the candidate word set of the search word, further comprising:
calculating the similarity between the search word and each candidate word;
determining the candidate words with the similarity greater than the preset similarity as an updated candidate word set;
and the CTR pre-estimation model calculates the CTR value of each candidate word in the updated candidate word set.
8. A training method for a Click Through Rate (CTR) estimation model is characterized by comprising the following steps:
acquiring a historical search word and a historical exposure candidate word corresponding to the historical search word;
constructing at least one group of training samples according to the sequence characteristics of the historical search words, wherein each group of training samples corresponds to one group of the historical search words and the historical exposure candidate words, and the sequence characteristics of the historical search words are used for representing the input sequence of words contained in the historical search words;
and training the CTR prediction model by adopting the training samples to obtain the trained CTR prediction model.
9. The method of claim 8, wherein before constructing at least one set of training samples according to the sequential features of the historical search terms, further comprising:
dividing the historical search words according to the level of the words to obtain all the words contained in the historical search words;
and obtaining the sequence characteristics of the historical search terms according to the sequence of each character contained in the historical search terms.
10. The method of claim 8, wherein before constructing at least one set of training samples according to the sequential features of the historical search terms, further comprising:
performing phonetic notation processing on the words contained in the historical search words to obtain a full spelling of the words contained in the historical search words;
generating a full spelling characteristic of the historical search word according to the full spelling of the words contained in the historical search word;
wherein the training samples further include spell features of the historical search terms.
11. The method of claim 8, wherein before constructing at least one set of training samples according to the sequential features of the historical search terms, further comprising:
performing phonetic notation processing on the words contained in the historical search words to obtain the first letters of the words contained in the historical search words;
generating the initial character of the historical search word according to the initial character of the word contained in the historical search word;
wherein the training sample further comprises initial features of the historical search terms.
12. A search recommendation apparatus, characterized in that the apparatus comprises:
the search word acquisition module is used for acquiring search words;
a candidate word acquisition module, configured to acquire a candidate word set of the search word, where the candidate word set includes at least one candidate word related to the search word;
the parameter generating module is used for generating at least one group of model input parameters according to the sequence characteristics of the search words, each group of model input parameters corresponds to one group of search words and the candidate words, and the sequence characteristics of the search words are used for representing the input sequence of the words contained in the search words;
the model calling module is used for calling a Click Through Rate (CTR) estimation model and calculating the CTR value of the candidate word according to the model input parameters;
and the recommendation selection module is used for selecting a recommendation candidate word corresponding to the search word from the candidate word set according to the CTR value of the candidate word.
13. A training device for a Click Through Rate (CTR) estimation model is characterized by comprising:
the word acquisition module is used for acquiring historical search words and historical exposure candidate words corresponding to the historical search words;
the sample construction module is used for constructing at least one group of training samples according to the sequence characteristics of the historical search words, each group of training samples corresponds to one group of the historical search words and the historical exposure candidate words, and the sequence characteristics of the historical search words are used for representing the input sequence of words contained in the historical search words;
and the model training module is used for training the CTR estimation model by adopting the training samples to obtain the trained CTR estimation model.
14. A computer device comprising a processor and a memory, the memory having stored therein at least one instruction, at least one program, set of codes, or set of instructions, which is loaded and executed by the processor to implement the method of any one of claims 1 to 7 or to implement the method of any one of claims 8 to 11.
15. A computer readable storage medium having stored therein at least one instruction, at least one program, a set of codes, or a set of instructions, which is loaded and executed by a processor to implement the method of any one of claims 1 to 7 or to implement the method of any one of claims 8 to 11.
CN201910675882.4A 2019-07-25 2019-07-25 Search recommendation method, training method, device and equipment of CTR (China train redundancy report) estimation model Active CN110390052B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910675882.4A CN110390052B (en) 2019-07-25 2019-07-25 Search recommendation method, training method, device and equipment of CTR (China train redundancy report) estimation model

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910675882.4A CN110390052B (en) 2019-07-25 2019-07-25 Search recommendation method, training method, device and equipment of CTR (China train redundancy report) estimation model

Publications (2)

Publication Number Publication Date
CN110390052A CN110390052A (en) 2019-10-29
CN110390052B true CN110390052B (en) 2022-10-28

Family

ID=68287267

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910675882.4A Active CN110390052B (en) 2019-07-25 2019-07-25 Search recommendation method, training method, device and equipment of CTR (China train redundancy report) estimation model

Country Status (1)

Country Link
CN (1) CN110390052B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111143543A (en) * 2019-12-04 2020-05-12 北京达佳互联信息技术有限公司 Object recommendation method, device, equipment and medium
CN112434184B (en) * 2020-12-15 2022-03-01 四川长虹电器股份有限公司 Deep interest network sequencing method based on historical movie posters
CN112559895B (en) * 2021-02-19 2021-05-18 深圳平安智汇企业信息管理有限公司 Data processing method and device, electronic equipment and storage medium
CN113409284B (en) * 2021-06-28 2023-10-20 北京百度网讯科技有限公司 Circuit board fault detection method, device, equipment and storage medium
CN113626683B (en) * 2021-06-30 2023-05-30 北京三快在线科技有限公司 CTR (control parameter) estimation processing method and device, electronic equipment and storage medium

Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102360358A (en) * 2011-09-28 2012-02-22 百度在线网络技术(北京)有限公司 Keyword recommendation method and system
CN103365839A (en) * 2012-03-26 2013-10-23 腾讯科技(深圳)有限公司 Recommendation search method and device for search engines
WO2013166916A1 (en) * 2012-05-07 2013-11-14 深圳市世纪光速信息技术有限公司 Information search method and server
CN104636334A (en) * 2013-11-06 2015-05-20 阿里巴巴集团控股有限公司 Keyword recommending method and device
CN106339404A (en) * 2016-06-30 2017-01-18 北京奇艺世纪科技有限公司 Search word recognition method and device
CN106339510A (en) * 2016-10-28 2017-01-18 北京百度网讯科技有限公司 The click prediction method and device based on artificial intelligence
CN106547887A (en) * 2016-10-27 2017-03-29 北京百度网讯科技有限公司 Method and apparatus is recommended in search based on artificial intelligence
CN107273404A (en) * 2017-04-26 2017-10-20 努比亚技术有限公司 Appraisal procedure, device and the computer-readable recording medium of search engine
CN108984656A (en) * 2018-06-28 2018-12-11 北京春雨天下软件有限公司 Medicine label recommendation method and device
CN109145245A (en) * 2018-07-26 2019-01-04 腾讯科技(深圳)有限公司 Predict method, apparatus, computer equipment and the storage medium of clicking rate
CN109189990A (en) * 2018-07-25 2019-01-11 北京奇艺世纪科技有限公司 A kind of generation method of search term, device and electronic equipment
CN109582903A (en) * 2018-11-29 2019-04-05 广州市百果园信息技术有限公司 A kind of method, apparatus, equipment and storage medium that information is shown

Patent Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102360358A (en) * 2011-09-28 2012-02-22 百度在线网络技术(北京)有限公司 Keyword recommendation method and system
CN103365839A (en) * 2012-03-26 2013-10-23 腾讯科技(深圳)有限公司 Recommendation search method and device for search engines
WO2013166916A1 (en) * 2012-05-07 2013-11-14 深圳市世纪光速信息技术有限公司 Information search method and server
CN104636334A (en) * 2013-11-06 2015-05-20 阿里巴巴集团控股有限公司 Keyword recommending method and device
CN106339404A (en) * 2016-06-30 2017-01-18 北京奇艺世纪科技有限公司 Search word recognition method and device
CN106547887A (en) * 2016-10-27 2017-03-29 北京百度网讯科技有限公司 Method and apparatus is recommended in search based on artificial intelligence
CN106339510A (en) * 2016-10-28 2017-01-18 北京百度网讯科技有限公司 The click prediction method and device based on artificial intelligence
CN107273404A (en) * 2017-04-26 2017-10-20 努比亚技术有限公司 Appraisal procedure, device and the computer-readable recording medium of search engine
CN108984656A (en) * 2018-06-28 2018-12-11 北京春雨天下软件有限公司 Medicine label recommendation method and device
CN109189990A (en) * 2018-07-25 2019-01-11 北京奇艺世纪科技有限公司 A kind of generation method of search term, device and electronic equipment
CN109145245A (en) * 2018-07-26 2019-01-04 腾讯科技(深圳)有限公司 Predict method, apparatus, computer equipment and the storage medium of clicking rate
CN109582903A (en) * 2018-11-29 2019-04-05 广州市百果园信息技术有限公司 A kind of method, apparatus, equipment and storage medium that information is shown

Non-Patent Citations (4)

* Cited by examiner, † Cited by third party
Title
How do users describe their information need: Query recommendation based on snippet click model;Yiqun Liu 等;《Expert Systems with Application》;20110503;第38卷(第11期);13847-13856 *
基于朴素贝叶斯点击预测的查询推荐方法;石雁 等;《计算机应用与软件》;20161015;第33卷(第10期);19-22 *
基于点击率预测的微信公众号广告精准投放研究;王忠义 等;《知识管理论坛》;20181228;第3卷(第06期);364-376 *
广告点击率估算技术综述;纪文迪 等;《华东师范大学学报(自然科学版)》;20130525(第03期);2-14 *

Also Published As

Publication number Publication date
CN110390052A (en) 2019-10-29

Similar Documents

Publication Publication Date Title
CN110390052B (en) Search recommendation method, training method, device and equipment of CTR (China train redundancy report) estimation model
AU2018383346B2 (en) Domain-specific natural language understanding of customer intent in self-help
CN111241311B (en) Media information recommendation method and device, electronic equipment and storage medium
CN111753060B (en) Information retrieval method, apparatus, device and computer readable storage medium
US10217058B2 (en) Predicting interesting things and concepts in content
EP2557510A1 (en) Context and process based search ranking
CN104933100A (en) Keyword recommendation method and device
CN111723260A (en) Method and device for acquiring recommended content, electronic equipment and readable storage medium
CN111522886B (en) Information recommendation method, terminal and storage medium
CN111177559A (en) Text travel service recommendation method and device, electronic equipment and storage medium
Carrion et al. A taxonomy generation tool for semantic visual analysis of large corpus of documents
CN114077661A (en) Information processing apparatus, information processing method, and computer readable medium
CN112070550A (en) Keyword determination method, device and equipment based on search platform and storage medium
CN115374781A (en) Text data information mining method, device and equipment
CN114610865A (en) Method, device and equipment for recommending recalled text and storage medium
Saaki et al. Value-wise convnet for transformer models: an infinite time-aware recommender system
CN113515589A (en) Data recommendation method, device, equipment and medium
Liu Python machine learning by example: implement machine learning algorithms and techniques to build intelligent systems
Foote et al. A computational analysis of social media scholarship
Rezaeenour et al. Developing a new hybrid intelligent approach for prediction online news popularity
Melucci Can structural equation models interpret search systems?
CN115374108B (en) Knowledge graph technology-based data standard generation and automatic mapping method
Manek et al. Classification of drugs reviews using W-LRSVM model
CN112131350B (en) Text label determining method, device, terminal and readable storage medium
Tejasree et al. An improved differential bond energy algorithm with fuzzy merging method to improve the document clustering for information mining

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