CN110688476A - Text recommendation method and device based on artificial intelligence - Google Patents

Text recommendation method and device based on artificial intelligence Download PDF

Info

Publication number
CN110688476A
CN110688476A CN201910901147.0A CN201910901147A CN110688476A CN 110688476 A CN110688476 A CN 110688476A CN 201910901147 A CN201910901147 A CN 201910901147A CN 110688476 A CN110688476 A CN 110688476A
Authority
CN
China
Prior art keywords
text
recommended
standard
user
target user
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201910901147.0A
Other languages
Chinese (zh)
Inventor
杜颖
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tencent Technology Beijing Co Ltd
Original Assignee
Tencent Technology Beijing 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 Beijing Co Ltd filed Critical Tencent Technology Beijing Co Ltd
Priority to CN201910901147.0A priority Critical patent/CN110688476A/en
Publication of CN110688476A publication Critical patent/CN110688476A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/33Querying
    • G06F16/335Filtering based on additional data, e.g. user or group profiles

Abstract

The invention provides a text recommendation method, a text recommendation device, electronic equipment and a storage medium based on artificial intelligence; the method comprises the following steps: determining a standard text from a historical browsing text set of a target user according to a request of the target user for text recommendation; according to the standard text, recalling the text set to be recommended, and determining the text to be recommended corresponding to the standard text; acquiring user interest of a target user for a standard text; fusing the user interest and the standard text to obtain a fused text fused with the user interest; obtaining the similarity between the text to be recommended and the standard text according to the fused text which is fused with the interest of the target user and the text to be recommended; and sequencing the texts to be recommended based on the similarity between the texts to be recommended and the standard texts to obtain recommended texts corresponding to the standard texts, and screening to obtain recommended texts for responding to the requests. By the method and the device, the text which accords with the user interest is recommended to the user according to the individual difference of the user.

Description

Text recommendation method and device based on artificial intelligence
Technical Field
The invention relates to artificial intelligence-based natural language processing technology, in particular to an artificial intelligence-based text recommendation method and device, electronic equipment and a storage medium.
Background
Natural Language Processing (NLP) is an important direction in the fields of computer science and artificial intelligence, and enables effective communication between people and computers using natural Language. Natural language processing is a science integrating linguistics, computer science and mathematics. Therefore, the field relates to natural language, namely the language used by people daily, so that the field is closely related to linguistics. Natural language processing techniques typically include text processing, semantic understanding, machine translation, robotic question and answer, knowledge mapping, and the like.
The text recommendation system is one of important applications in the field of natural language processing, can automatically contact users and articles, can help the users find information possibly interested in the users in an information overload environment, and can push the information to the users interested in the users.
Although, the text recommendation system may recommend text to the user that may be of interest to the user. However, the text recommendation system uniformly recommends the same text to the user according to the history browsing text, which causes inaccurate recommended text and poor user experience.
Disclosure of Invention
The embodiment of the invention provides a text recommendation method and device based on artificial intelligence, electronic equipment and a storage medium, which can recommend texts meeting the user interest to a user according to the individual difference of the user, and improve the user experience.
The technical scheme of the embodiment of the invention is realized as follows:
the embodiment of the invention provides a text recommendation method based on artificial intelligence, which comprises the following steps:
determining at least one standard text from a historical browsing text set of a target user aiming at a request of text recommendation of the target user;
according to the standard text, a text set to be recommended is recalled, and at least one text to be recommended corresponding to the standard text is determined;
acquiring user interest of the target user for a standard text;
fusing the user interest and the standard text to obtain a fused text fused with the user interest;
obtaining the similarity between the text to be recommended and the standard text according to the fused text which is fused with the interest of the target user and the text to be recommended;
sequencing the at least one text to be recommended based on the similarity between the text to be recommended and the standard text to obtain a recommended text corresponding to the standard text;
and screening the recommended texts corresponding to the at least one standard text to obtain the recommended texts for responding to the request.
In the above technical solution, the screening the recommended text corresponding to the at least one standard text to obtain the recommended text for responding to the request includes:
and retrieving the historical browsing text set according to a recommended text corresponding to at least one standard text, and filtering the recommended text to obtain the recommended text for responding to the request when the recommended text is the historical browsing text.
The embodiment of the invention provides a text recommendation device based on artificial intelligence, which comprises:
the determining module is used for determining at least one standard text from a historical browsing text set of a target user aiming at a request of text recommendation of the target user;
the recall module is used for recalling a text set to be recommended according to the standard text and determining at least one text to be recommended corresponding to the standard text;
the first processing module is used for acquiring the user interest of the target user for the standard text;
the fusion module is used for fusing the user interest and the standard text to obtain a fused text fused with the user interest;
the second processing module is used for obtaining the similarity between the text to be recommended and the standard text according to the fused text which is fused with the interest of the target user and the text to be recommended;
the third processing module is used for sequencing the at least one text to be recommended based on the similarity between the text to be recommended and the standard text to obtain a recommended text corresponding to the standard text;
and the screening module is used for screening the recommended texts corresponding to the at least one standard text to obtain the recommended texts for responding to the request.
In the above technical solution, the determining module is further configured to execute one of:
screening the historical browsing text set of the target user, and determining the historical browsing text in a set time period as a standard text;
screening the historical browsing text of the target user, and determining the historical browsing text as the standard text when the time of the historical browsing text used by the target user is greater than a time threshold;
and screening the historical browsing text of the target user, and determining the historical browsing text as the standard text when the frequency of the historical browsing text used by the sample user is greater than a use frequency threshold value.
In the above technical solution, the recall module is further configured to perform word segmentation processing on the standard text to obtain a keyword in the standard text;
and retrieving a text set to be recommended according to the keywords in the standard text, and determining at least one text to be recommended corresponding to the standard text.
In the above technical solution, the first processing module is further configured to determine a similarity between the historical browsing text and the standard text according to the historical browsing text in the historical browsing text set of the target user and the standard text;
and determining the user interest of the target user for the standard text according to the similarity of at least one historical browsing text and the standard text.
In the above technical solution, the first processing module is further configured to sum similarities between at least one historical browsing text and the standard text to obtain a sum of similarities;
determining the similarity between the historical browsing text and the standard text, and determining a first ratio of the similarity to the sum of the similarities;
and carrying out weighted summation on the historical browsing texts and the first ratio to obtain the user interest of the target user for the standard texts.
In the technical scheme, the user interest is a user interest vector, the text to be recommended is a text vector to be recommended, and the standard text is a standard text vector;
the fusion module is further used for summing the user interest vector and the standard text vector to obtain a corresponding sum vector, and determining that the corresponding sum vector is a fusion text fused with the interest of the target user;
the second processing module is further configured to determine the corresponding sum vector and the similarity between the vectors of the texts to be recommended as the similarity between the texts to be recommended and the standard texts.
In the above technical solution, the third processing module is further configured to obtain a weight of the standard text;
obtaining the quantity of recommended texts corresponding to the standard texts according to the proportional relation between the weight and the quantity of the recommended texts and the weight of the standard texts;
and sequencing the at least one text to be recommended in a descending order based on the similarity between the text to be recommended and the standard text to obtain recommended texts corresponding to the quantity of the recommended texts.
In the above technical solution, the third processing module is further configured to sum the time that the at least one standard text is used by the target user to obtain a time sum;
and comparing the time of the standard text used by the target user with the sum of the time to obtain the weight of the standard text.
In the above technical solution, the screening module is further configured to retrieve the historical browsing text set according to a recommended text corresponding to at least one standard text, and filter the recommended text to obtain the recommended text for responding to the request when the recommended text is the historical browsing text.
In the above technical solution, the apparatus further includes:
the acquisition module is used for acquiring a historical browsing text set of a target user from a block chain network according to a request of the target user for text recommendation.
The embodiment of the invention provides a text recommendation device based on artificial intelligence, which comprises:
a memory for storing executable instructions;
and the processor is used for realizing the text recommendation method based on artificial intelligence provided by the embodiment of the invention when the executable instructions stored in the memory are executed.
The embodiment of the invention provides a storage medium, which stores executable instructions and is used for causing a processor to execute the executable instructions so as to realize the text recommendation method based on artificial intelligence provided by the embodiment of the invention.
The embodiment of the invention has the following beneficial effects:
1. determining a standard text from a historical browsing text set of a target user so as to determine a recommended text which is possibly interested by the target user according to the standard text, and improving the accuracy of the recommended text;
2. the user interests of the target user for the standard text are merged into the standard text, so that the text meeting the user interests can be recommended to the user according to the individual difference of the user interests, and the user experience is improved.
Drawings
FIG. 1A is a diagram illustrating an alternative application scenario 10 of an artificial intelligence based text recommendation method according to an embodiment of the present invention;
FIG. 1B is a diagram illustrating an alternative application mode 100 of an artificial intelligence based text recommendation method according to an embodiment of the present invention;
FIG. 2 is a schematic structural diagram of an artificial intelligence based text recommendation device 500 according to an embodiment of the present invention;
3A-3C are flow diagrams of a text recommendation method based on artificial intelligence provided by an embodiment of the invention;
fig. 4-5 are schematic diagrams of terminal display interfaces provided by embodiments of the present invention;
FIG. 6 is a diagram illustrating the results of recommending text that is provided by an embodiment of the present invention;
FIG. 7 is a comparison of the recommendation method provided by an embodiment of the present invention before and after improvement;
fig. 8 is a flowchart illustrating personalized recommendation performed by the news recommendation system according to the embodiment of the present invention;
fig. 9 is a comparison between before and after improvement of the recommendation method provided by the embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention clearer, the present invention will be further described in detail with reference to the accompanying drawings, the described embodiments should not be construed as limiting the present invention, and all other embodiments obtained by a person of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.
In the following description, reference is made to "some embodiments" which describe a subset of all possible embodiments, but it is understood that "some embodiments" may be the same subset or different subsets of all possible embodiments, and may be combined with each other without conflict.
In the description that follows, references to the terms "first", "second", and the like, are intended only to distinguish similar objects and not to indicate a particular ordering for the objects, it being understood that "first", "second", and the like may be interchanged under certain circumstances or sequences of events to enable embodiments of the invention described herein to be practiced in other than the order illustrated or described herein.
Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs. The terminology used herein is for the purpose of describing embodiments of the invention only and is not intended to be limiting of the invention.
Before further detailed description of the embodiments of the present invention, terms and expressions mentioned in the embodiments of the present invention are explained, and the terms and expressions mentioned in the embodiments of the present invention are applied to the following explanations.
1) The target user: the user currently using the text recommendation system, i.e. the current user, for example, user a, is watching news using the text recommendation system, and user a is the target user.
2) Sampling users: other users than the target user, for example, user a is watching news using the text recommendation system, then currently relative to user a, the other users are sampling users of user a.
3) Word segmentation: the process of recombining continuous word sequences into word sequences according to a certain specification. The effect of recognizing words is achieved by letting a computer simulate the understanding of a sentence by a human.
4) Recall (Recall): and retrieving related documents from the document library, for example, roughly selecting a batch of commodities to be recommended for the user.
5) User interest: the behavior tendency of the user is expressed when the user uses the text recommendation system. The text recommendation system may determine the user's interests based on a series of behavioral manifestations of the user.
6) User portrait: the method is also called as a user role, and is an effective tool for delineating target users and connecting user appeal and design direction. User images are widely used in various fields, and in the course of actual operations, attributes and behaviors of users are often combined with expectations by words appearing shallowest and living closely to each other to serve as virtual representations of actual users.
7) word2 vec: used to generate a correlation model of the word vector. All words are vectorized, so that the relationship between the words can be quantitatively measured, and the connection between the words is mined.
8) Blockchain (Blockchain): an encrypted, chained transactional memory structure formed of blocks (blocks).
9) Block chain Network (Blockchain Network): the new block is incorporated into the set of a series of nodes of the block chain in a consensus manner.
The embodiment of the invention provides a text recommendation method and device based on artificial intelligence, electronic equipment and a storage medium, which can recommend texts meeting the user interest to a user according to the individual difference of the user and improve the user experience. An exemplary application of the text recommendation device based on artificial intelligence provided by the embodiment of the present invention is described below, where the text recommendation device based on artificial intelligence provided by the embodiment of the present invention may be a server, for example, a server deployed in a cloud, and provides a text meeting user interests to a target user according to a request for text recommendation for the target user; the text recommendation method can also be used for various types of user terminals such as a notebook computer, a tablet computer, a desktop computer, a mobile device (e.g., a mobile phone, a personal digital assistant), and the like, for example, a handheld terminal, obtaining a text meeting the interest of a target user according to a request for text recommendation for the target user, and displaying the text on a display interface of the handheld terminal so as to realize an interactive process between the handheld terminal and the user.
Referring to fig. 1A, fig. 1A is a schematic diagram of an optional application scenario 10 of the artificial intelligence based text recommendation method according to the embodiment of the present invention, where a terminal 200 is connected to a server 100 through a network 300, and the network 300 may be a wide area network or a local area network, or a combination of the two.
The terminal 200 may be used to obtain a request for text recommendation for a target user, for example, when the target user opens a news application, the terminal automatically obtains the request for text recommendation for the target user.
In some embodiments, the terminal 200 locally executes the artificial intelligence based text recommendation method provided in the embodiments of the present invention to obtain a text meeting the interest of the target user according to the request for text recommendation for the target user, for example, a news Application (APP), such as a news push APP, is installed on the terminal 200, after the user opens the news push APP or clicks a recommendation button on the news push APP, the terminal 200 automatically generates a request for text recommendation for the target user, performs a series of processing, obtains a recommendation text for responding to the recommendation request, and displays the recommendation text on the display interface 210 of the terminal 200.
The terminal 200 may also transmit a request for text recommendation to a target user to the server 100 through the network 300, and invokes a text recommendation function provided by the server 100, the server 100 obtains a recommendation text for responding to a recommendation request through an artificial intelligence based text recommendation method provided by an embodiment of the present invention, for example, a news-push APP is installed on the terminal 200, after the user opens the news-push APP or clicks a recommendation button on the news-push APP, the terminal 200 automatically generates a request for text recommendation for a target user, and transmits a request for text recommendation to the target user to the server 100 through the network 300, and the server 100 performs a series of processes according to the request for text recommendation to the target user, obtains a recommendation text for responding to the recommendation request, and returning the recommended text to the news push APP, and displaying the recommended text on the display interface of the terminal 200.
Referring to fig. 1B, fig. 1B is a schematic diagram of an optional application mode 100 of the artificial intelligence based text recommendation method according to the embodiment of the present invention, which includes a blockchain network 400 (exemplarily illustrating a consensus node 410-1 to a consensus node 410-3), an authentication center 500, a service agent 600, and a service agent 700, which are respectively described below.
The type of blockchain network 400 is flexible and may be, for example, any of a public chain, a private chain, or a federation chain. Taking a public chain as an example, electronic devices of any service subject, such as the terminal device 200 and the server 300, can access the blockchain network 400 without authorization; taking a federation chain as an example, an electronic device (e.g., terminal device 200/server 300) under the jurisdiction of a service entity after obtaining authorization can access the blockchain network 400, and at this time, becomes a client node in the blockchain network 400.
In some embodiments, the client node may act as a mere watcher of the blockchain network 400, i.e., provide functionality to support the business entity to initiate transactions (e.g., for uplink storage of data or querying of data on the chain), and may be implemented by default or selectively (e.g., depending on the specific business requirements of the business entity) with respect to the functions of the consensus node 410 of the blockchain network 400, such as a ranking function, a consensus service, and an accounting function, etc. Therefore, the data and the service processing logic of the service subject can be migrated to the blockchain network 400 to the maximum extent, and the credibility and traceability of the data and service processing process are realized through the blockchain network 400.
Consensus nodes in blockchain network 400 receive transactions submitted by client nodes from different business entities (e.g., business entity 700 and business entity 700 shown in fig. 1B), perform the transactions to update the ledger or query the ledger, and various intermediate or final results of performing the transactions may be returned for display in the business entity's client nodes.
For example, the client node 610/710 may subscribe to events of interest in the blockchain network 400, such as transactions occurring in a particular organization/channel in the blockchain network 400, and the corresponding transaction notifications are pushed by the consensus node 410 to the client node 610/710, thereby triggering the corresponding business logic in the client node 610/710.
An exemplary application of the blockchain network is described below, taking an example in which a plurality of service entities access the blockchain network to implement management of text recommendation.
Referring to fig. 1B, a plurality of business entities involved in the management link, such as the client node 610 may be a client node corresponding to the terminal device 200 in fig. 1A, the client node 710 may be a client node corresponding to the server 100 in fig. 1A, the client node 610 registers with the certificate authority 500 to obtain respective digital certificates, the digital certificates include the public key of the business entity 600 and the digital signature signed by the certificate authority 500 for the public key and the identity information of the business entity 600, and are used to attach to the transaction together with the digital signature of the business entity 600 for the transaction and are sent to the blockchain network, for the blockchain network to take out the digital certificate and signature from the transaction, verify the authenticity of the message (i.e. whether it has not been tampered with) and the identity information of the service entity sending the message, and the blockchain network will verify according to the identity, for example whether it has the right to initiate the transaction. Clients running on electronic devices (e.g., terminals or servers) hosted by the business entity may request access from the blockchain network 200 to become client nodes.
The client node 610 is configured to store the historical text set of the target user in the blockchain network 400 and may also store logic of the text recommendation process in the blockchain network 400. The client node 610 generates a transaction corresponding to the update operation according to the historical text set of the target user, specifies the smart contract that needs to be invoked to implement the update operation and the parameters passed to the smart contract in the transaction, and the transaction also carries the digital certificate of the client node 610, a signed digital signature (e.g., obtained by encrypting a digest of the transaction using a private key in the digital certificate of the client node 610), and broadcasts the transaction to the consensus node 410 in the blockchain network 400.
When the transaction is received in the consensus node 410 in the blockchain network 400, the digital certificate and the digital signature carried by the transaction are verified, after the verification is successful, whether the service agent 600 has the transaction right or not is determined according to the identity of the service agent 600 carried in the transaction, and the transaction fails due to any verification judgment of the digital signature and the right verification. After successful verification, the node's own digital signature (e.g., encrypted using the private key of node 410-1 to obtain a digest of the transaction) is signed and broadcast on the blockchain network 400.
After receiving the transaction successfully verified, the consensus node 410 in the blockchain network 400 fills the transaction into a new block and broadcasts the new block. When a new block is broadcasted by the consensus node 410 in the blockchain network 400, the consensus process is performed on the new block, if the consensus is successful, the new block is added to the tail of the blockchain stored in the new block, and the state database is updated according to the transaction result to execute the transaction in the new block.
The service person of the service agent 700 logs in at the client node 710, the client node 710 generates a corresponding transaction according to a request for text recommendation for a target user, the transaction also carries a digital certificate of the client node 710, a signed digital signature (e.g., obtained by encrypting a digest of the transaction using a private key in the digital certificate of the client node 710) according to an intelligent contract specified to be invoked in the transaction and parameters passed to the intelligent contract, and broadcasts the transaction to the consensus node 410 in the blockchain network 400.
After receiving the transaction in the consensus node 410 in the blockchain network 400, verifying the transaction, filling the block and making the consensus consistent, adding the filled new block to the tail of the blockchain stored in the new block, updating the state database according to the transaction result, and executing the transaction in the new block: and for the submitted transaction of the historical browsing text set of the query target user, querying a key value pair corresponding to the historical browsing text set of the target user from the state database, and returning a transaction result.
It should be noted that the text set to be recommended may also be collected through an intelligent contract in the blockchain network, and fig. 2 exemplarily shows a process of directly linking the text set to be recommended, but in other embodiments, for a case where the data volume of the text set to be recommended is large, the client node 410 may link the hash of the text set to be recommended and store the text set to be recommended in a distributed file system or a database. After the client node 510 obtains the text set to be recommended from the distributed file system or the database, verification may be performed in combination with the corresponding hash in the blockchain network 200, so as to reduce the workload of uplink operation.
Continuing to describe the structure of the artificial intelligence based text recommendation device provided by the embodiment of the present invention, the artificial intelligence based text recommendation device may be various terminals, such as a mobile phone, a computer, and the like, and may also be the server 100 shown in fig. 1.
Referring to fig. 2, fig. 2 is a schematic structural diagram of an artificial intelligence based text recommendation device 500 according to an embodiment of the present invention, and the artificial intelligence based text recommendation device 500 shown in fig. 2 includes: at least one processor 510, memory 550, at least one network interface 520, and a user interface 530. The various components in artificial intelligence based text recommendation device 500 are coupled together by bus system 540. It is understood that the bus system 540 is used to enable communications among the components. The bus system 540 includes a power bus, a control bus, and a status signal bus in addition to a data bus. For clarity of illustration, however, the various buses are labeled as bus system 540 in fig. 2.
The Processor 510 may be an integrated circuit chip having Signal processing capabilities, such as a general purpose Processor, a Digital Signal Processor (DSP), or other programmable logic device, discrete gate or transistor logic device, discrete hardware components, or the like, wherein the general purpose Processor may be a microprocessor or any conventional Processor, or the like.
The user interface 530 includes one or more output devices 531 enabling presentation of media content, including one or more speakers and/or one or more visual display screens. The user interface 530 also includes one or more input devices 532, including user interface components to facilitate user input, such as a keyboard, mouse, microphone, touch screen display, camera, other input buttons and controls.
The memory 550 may comprise volatile memory or nonvolatile memory, and may also comprise both volatile and nonvolatile memory. The non-volatile Memory may be a Read Only Memory (ROM), and the volatile Memory may be a Random Access Memory (RAM). The memory 550 described in connection with embodiments of the invention is intended to comprise any suitable type of memory. Memory 550 optionally includes one or more storage devices physically located remote from processor 510.
In some embodiments, memory 550 can store data to support various operations, examples of which include programs, modules, and data structures, or subsets or supersets thereof, as exemplified below.
An operating system 551 including system programs for processing various basic system services and performing hardware-related tasks, such as a framework layer, a core library layer, a driver layer, etc., for implementing various basic services and processing hardware-based tasks;
a network communication module 552 for communicating to other computing devices via one or more (wired or wireless) network interfaces 520, exemplary network interfaces 520 including: bluetooth, wireless compatibility authentication (WiFi), and Universal Serial Bus (USB), etc.;
a display module 553 for enabling presentation of information (e.g., a user interface for operating peripherals and displaying content and information) via one or more output devices 531 (e.g., a display screen, speakers, etc.) associated with the user interface 530;
an input processing module 554 to detect one or more user inputs or interactions from one of the one or more input devices 532 and to translate the detected inputs or interactions.
In some embodiments, the artificial intelligence based text recommendation apparatus provided by the embodiments of the present invention may be implemented by a combination of hardware and software, and by way of example, the artificial intelligence based text recommendation apparatus provided by the embodiments of the present invention may be a processor In the form of a hardware decoding processor, which is programmed to execute the artificial intelligence based text recommendation method provided by the embodiments of the present invention, for example, the processor In the form of the hardware decoding processor may employ one or more Application Specific Integrated Circuits (ASICs), DSPs, Programmable Logic Devices (PLDs), Complex Programmable Logic Devices (CPLDs), Field Programmable Gate Arrays (FPGAs), or other electronic components.
In other embodiments, the artificial intelligence based text recommendation apparatus provided by the embodiment of the present invention may be implemented in software, and fig. 2 illustrates an artificial intelligence based text recommendation apparatus 555 stored in a memory 550, which may be software in the form of programs, plug-ins, and the like, and includes a series of modules including a determination module 5551, a recall module 5552, a first processing module 5553, a fusion module 5554, a second processing module 5555, a third processing module 5556, and a filtering module 5557; the determining module 5551, the recall module 5552, the first processing module 5553, the fusion module 5554, the second processing module 5555, the third processing module 5556, and the screening module 5557 are used to implement the text recommendation method based on artificial intelligence provided by the embodiment of the present invention.
The text recommendation method based on artificial intelligence provided by the embodiment of the invention is described below by combining the exemplary application and implementation of the terminal provided by the embodiment of the invention. Referring to fig. 3A, fig. 3A is a flowchart illustrating a text recommendation method based on artificial intelligence according to an embodiment of the present invention, which is described in conjunction with the steps shown in fig. 3A.
In step 101, at least one standard text is determined from a set of historically viewed texts of a target user for a request for a text recommendation by the target user.
The set of historically viewed text may be the set of all text that the target user has viewed in the past; the history browsing text set may also be a set of texts browsed by the target user within a preset time period, for example, the history browsing text set is a set of texts browsed by the target user on the previous day; the historically viewed text set may also be a set of texts viewed by the target user within a preset time period from the current time, for example, the historically viewed text set is a set of texts viewed by the target user within 5 hours from the current time.
After a target user opens a certain text recommendation application on a terminal, the terminal automatically generates a request for text recommendation for the target user, and determines at least one standard text from a historical browsing text set browsed by the target user, so as to perform text recommendation according to the standard text, wherein the standard text is one text in the historical browsing text set. For example, after the target user opens the news push APP on the terminal, the terminal automatically generates a request for news recommendation for the target user, and determines at least one piece of news from the news browsed by the target user as a standard text, so that the news is recommended to the target user according to the standard text in the following process.
In some embodiments, the user may also preset a time interval at the terminal, for example, the time interval may be 1 minute or 5 minutes. The terminal can automatically generate a request for text recommendation for a target user at preset time intervals, and determine at least one standard text from a historical browsing text set browsed by the target user, so as to perform text recommendation according to the standard text later.
In some embodiments, the terminal adds the text browsed by the user in real time into the historical browsing text set, automatically generates a request for text recommendation for the target user, and determines at least one standard text from the historical browsing text set browsed by the target user, so as to perform text recommendation according to the standard text later. Or, after the user browses a preset number of texts, the terminal automatically generates a request for text recommendation for the target user, so as to perform text recommendation, for example, adding the texts browsed by the user in real time into a history browsing text set, and after the user browses 5 news, the terminal automatically generates a request for text recommendation for the target user, and performs text recommendation.
In addition, after a text recommendation application on the terminal is opened, the target user can click a recommendation button on the text recommendation application, the terminal automatically generates a request for text recommendation for the target user, and determines at least one standard text from a historical browsing text set browsed by the target user, so that text recommendation can be performed according to the standard text. As shown in fig. 4, after the target user opens the news push APP on the terminal, the "recommend" button 401 on the news push APP is clicked, so that the terminal automatically generates a request for recommending news to the target user, and determines at least one piece of news from the news browsed by the target user as a standard text, so as to recommend the news to the target user according to the standard text in the following process. As shown in fig. 5, after the target user opens the article search APP on the terminal, the "recommend" button 501 on the article search APP is clicked, so that the terminal automatically generates a request for article recommendation for the target user, and determines at least one article from the articles browsed by the target user as a standard text, so as to recommend the article to the target user according to the standard text later.
In some embodiments, the at least one standard text is determined from a set of historically viewed texts of the target user, including one of: screening a historical browsing text set of a target user, and determining that the historical browsing text in a set time period is a standard text; screening the historical browsing text of the target user, and determining the historical browsing text as a standard text when the time of the historical browsing text used by the target user is greater than a time threshold; and screening the historical browsing texts of the target user, and determining the historical browsing texts as standard texts when the frequency of the historical browsing texts used by the sample user is greater than a use frequency threshold value.
The terminal can screen the historical browsing text set browsed by the target user aiming at the request of text recommendation of the target user, so that the historical browsing text in a set time period is determined to be a standard text, and text recommendation can be carried out according to the standard text later. The set time period is set according to the requirements of the user, for example, the set time period may be half an hour, and the terminal screens the historical browsing text set browsed by the target user and determines that the historical browsing text browsed by the user in the half hour is a standard text.
The terminal can also screen a historical browsing text set browsed by the target user according to the request of the target user for text recommendation, and when the time of the historical browsing text used by the target user is greater than a time threshold, the historical browsing text is determined to be a standard text, so that text recommendation can be performed according to the standard text. The time threshold is set according to the requirements of the user, for example, the time threshold may be 5 minutes, the terminal screens a historical browsing text set browsed by the target user, and when the target user spends 10 minutes browsing a certain historical browsing text, the time of the historical browsing text used by the target user is greater than the time threshold, and the historical browsing text is determined to be a standard text.
The terminal can also screen a historical browsing text set browsed by the target user according to the request of the target user for text recommendation, and when the frequency of the historical browsing text used by the sample user is greater than the use frequency threshold, the historical browsing text is determined to be a standard text, so that the text recommendation can be performed according to the standard text. The frequency threshold is set according to the requirements of the user, for example, the frequency threshold may be 10 times, the terminal screens a historical browsing text set browsed by the target user, when 15 sample users browse a certain historical browsing text, the frequency of the historical browsing text used by the sample users is greater than the use frequency threshold, and the historical browsing text is determined to be a standard text.
In step 102, according to the standard text, a text set to be recommended is recalled, and at least one text to be recommended corresponding to the standard text is determined.
After the terminal obtains the at least one standard text, a text set to be recommended can be recalled according to the standard text, and the at least one text to be recommended corresponding to the standard text is determined, wherein the text set to be recommended comprises texts browsed by a user (historical browsing texts) and texts not browsed by the user.
In some embodiments, the recalling the set of texts to be recommended according to the standard text, and determining at least one text to be recommended corresponding to the standard text includes: performing word segmentation processing on the standard text to obtain key words in the standard text; and searching the text set to be recommended according to the keywords in the standard text, and determining at least one text to be recommended corresponding to the standard text.
After the terminal obtains the standard text, word segmentation processing can be performed on the standard text, so that keywords in the standard text are obtained, a text set to be recommended is retrieved according to the keywords in the standard text, and when the text set to be recommended contains the keywords or comprises N keywords, the text to be recommended is determined to be the text to be recommended corresponding to the standard text. And N is an integer and can be set according to the requirement of a user.
In step 103, user interests of the target user for the standard text are obtained.
After the terminal obtains the standard text, the user interest of the target user for the standard text can be obtained, so that the user interest can be merged into the standard text subsequently, and differential recommendation is performed by considering the individual characteristics of each user.
Referring to fig. 3B, fig. 3B is an optional flowchart diagram provided in an embodiment of the present invention, and in some embodiments, fig. 3A illustrates that step 103 may be implemented by steps 1031 to 1032 illustrated in fig. 3B.
In step 1031, the similarity between the historical browsing text and the standard text is determined according to the historical browsing text in the historical browsing text set of the target user and the standard text.
And calculating the similarity of the historical browsing text and the standard text according to the historical browsing text vector and the standard text vector to obtain the similarity of the historical browsing text and the standard text. The similarity may be a cosine similarity or an euclidean distance. Cosine similarity is a cosine value of an included angle between two vectors in a vector space and is used for measuring the difference between the two individuals, and Euclidean distance is an absolute distance between the two vectors in the vector space. The cosine similarity is taken as an example, and the cosine similarity between the historical browse text and the standard text is determined according to the historical browse text in the historical browse text set of the target user and the standard text, so that the similarity between the historical browse text and the standard text can be obtained.
In step 1032, the user interest of the target user for the standard text is determined according to the similarity between the at least one historical browsing text and the standard text.
After the terminal sequentially obtains the similarity between the historical browse texts and the standard texts, the user interest of the target user for the standard texts can be obtained according to the similarity between at least one historical browse text and the standard text. The historical browsing text and the standard text can be weighted and summed, so that the user interest of the target user for the standard text is obtained.
In some embodiments, determining the user interest of the target user for the standard text according to the similarity between the at least one historical browsing text and the standard text comprises: summing the similarity of at least one historical browsing text and the standard text to obtain a similarity sum; determining the similarity between the historical browsing text and the standard text, and determining a first ratio of the similarity to the sum of the similarities; and carrying out weighted summation on the historical browsing text and the first ratio to obtain the user interest of the target user for the standard text.
First, the similarity between at least one historical browsing text and the standard text may be summed to obtain a similarity sum. Then, the similarity of the historical browsing text and the standard text is compared with the sum of the similarities, so that a first ratio is obtained. And finally, carrying out weighted summation on the historical browsing texts and the first ratio so as to obtain the user interest of the target user for the standard texts, namely to obtain the preference of the user for the texts.
In step 104, the user interest and the standard text are fused to obtain a fused text fused with the user interest.
In order to recommend texts meeting the user interests to the users according to the individual differences of the users, the user interests can be merged into the standard texts to obtain merged texts merged with the user interests, so that different preferences of the users on the texts are considered.
In some embodiments, the user interest is a user interest vector, the text to be recommended is a text vector to be recommended, and the standard text is a standard text vector; fusing the user interest and the standard text to obtain a fused text fused with the target user interest, wherein the fused text comprises the following steps: and summing the user interest vector and the standard text vector to obtain a corresponding sum vector, and determining the corresponding sum vector as a fusion text which is fused with the interest of the target user.
In order to recommend text to the user that meets the user's interests, the user's interests may be incorporated into the standard text by summing the user interest vector with the standard text vector.
In step 105, according to the fused text fused with the interest of the target user and the text to be recommended, the similarity between the text to be recommended and the standard text is obtained.
And calculating the similarity according to the fusion text vector and the text vector to be recommended so as to obtain the similarity between the text to be recommended and the standard text. The cosine similarity is taken as an example, and the cosine similarity between the text to be recommended and the standard text is determined according to the fused text and the text to be recommended so as to obtain the similarity between the text to be recommended and the standard text.
In some embodiments, the user interest is a user interest vector, the text to be recommended is a text vector to be recommended, and the standard text is a standard text vector; obtaining the similarity between the text to be recommended and the standard text according to the fused text fused with the interest of the target user and the text to be recommended, wherein the similarity comprises the following steps: and determining the similarity between the corresponding sum vector and the text vector to be recommended as the similarity between the text to be recommended and the standard text.
After the user interest vector and the standard text vector are summed by the terminal to obtain a corresponding sum vector, the similarity between the corresponding sum vector and the text vector to be recommended can be calculated, and the similarity is determined as the similarity between the text to be recommended and the standard text. Wherein the similarity may be a cosine similarity.
In step 106, at least one text to be recommended is ranked based on the similarity between the text to be recommended and the standard text, so as to obtain a recommended text corresponding to the standard text.
After the terminal obtains the similarity between the text to be recommended and the standard text, at least one text to be recommended can be sorted in a descending order based on the similarity between the text to be recommended and the standard text, so that the first N recommended texts corresponding to the standard text are obtained. And N is an integer and can be set according to the requirement of a user.
Referring to fig. 3C, fig. 3C is an optional flowchart provided in an embodiment of the present invention, and in some embodiments, fig. 3C illustrates that step 106 may be implemented by step 1061 to step 1063 illustrated in fig. 3C.
In step 1061, the weight of the standard text is obtained.
Different standard texts may correspond to different numbers of recommended texts. In order to distinguish the recommended text quantity corresponding to the standard text, the recommended text quantity can be measured by the weight of the standard text.
In some embodiments, obtaining the weight of the standard text comprises: summing the time of the at least one standard text used by the target user to obtain a time sum; and obtaining the weight of the standard text by comparing the time of the standard text used by the target user with the sum of the time.
In order to obtain the weight of the standard text, the time of all the standard texts used by the target user may be counted and summed to obtain a time sum, and then the ratio of the time of the standard text used by the target user to the time sum is obtained, so as to obtain the weight of the standard text. For example, the sum of the time is 2 hours, the time of the standard text used by the target user is 0.5 hour, and the weight of the standard text is 0.25.
In some embodiments, the frequency of a standard text used by a sample user in a set time period may be obtained first, the number of times that the sample user uses the standard text in the set time period is obtained, and then the ratio of the frequency of the standard text used by the sample user to the number of times that the sample user uses the standard text is obtained, so as to obtain the weight of the standard text.
In step 1062, the recommended text amount corresponding to the standard text is obtained according to the proportional relationship between the weight and the recommended text amount and the weight of the standard text.
The proportional relation can be a corresponding relation between the weight and the number of recommended texts, and after the weight of the standard text is obtained, the proportional relation between the weight and the number of recommended texts can be obtained, so that the number of recommended texts corresponding to the standard text can be obtained according to the proportional relation between the weight and the number of recommended texts and the weight of the standard text. Therefore, when the weight of the standard text is larger, the number of recommended texts corresponding to the standard text is larger, which indicates that the target user prefers the text of the standard text class.
In step 1063, based on the similarity between the text to be recommended and the standard text, at least one text to be recommended is sorted in a descending order to obtain recommended texts corresponding to the number of recommended texts.
After the terminal obtains the number N of recommended texts corresponding to the standard texts, at least one text to be recommended is sorted in a descending order based on the similarity between the text to be recommended and the standard texts, and the first N recommended texts are obtained.
In step 107, the recommended texts corresponding to at least one standard text are screened to obtain recommended texts for responding to the request.
After the terminal obtains the recommended text corresponding to the standard text, the terminal can also screen the recommended text, so that the recommended text which finally responds to the request for text recommendation for the target user is obtained.
In some embodiments, the screening of the recommended text corresponding to the at least one standard text to obtain the recommended text for responding to the request includes: and searching the historical browsing text set according to the recommended text corresponding to the at least one standard text, and filtering the recommended text to obtain the recommended text for responding to the request when the recommended text is the historical browsing text.
And when a certain recommended text is determined to be the text browsed by the target user in the process of searching the historical browsing text set according to the recommended text corresponding to the at least one standard text, filtering the text to avoid repeated recommendation. As shown in fig. 4, after the target user opens the news push APP on the terminal, the "recommend" button on the news push APP is clicked, so that the terminal automatically generates a request for performing news recommendation on the target user, and obtains recommended news for responding to the request through a series of processing, and displays the recommended news on the display interface of the terminal, as shown in fig. 6.
So far, the text recommendation method based on artificial intelligence provided in the embodiment of the present invention has been described in conjunction with the exemplary application and implementation of the terminal provided in the embodiment of the present invention, and a scheme for implementing text recommendation based on artificial intelligence in cooperation with each module in the text recommendation device 555 based on artificial intelligence provided in the embodiment of the present invention is continuously described below.
A determining module 5551, configured to determine, for a request for text recommendation by a target user, at least one standard text from a historical browsing text set of the target user;
the recall module 5552 is configured to perform recall processing on a to-be-recommended text set according to the standard text, and determine at least one to-be-recommended text corresponding to the standard text;
a first processing module 5553, configured to obtain a user interest of the target user for a standard text;
the fusion module 5554 is configured to fuse the user interest and the standard text to obtain a fused text fused with the user interest;
the second processing module 5555 is configured to obtain a similarity between the text to be recommended and the standard text according to the fusion text of the interest of the fusion target user and the text to be recommended;
the third processing module 5556 is configured to rank, based on the similarity between the text to be recommended and the standard text, the at least one text to be recommended to obtain a recommended text corresponding to the standard text;
the screening module 5557 is configured to screen a recommended text corresponding to at least one standard text to obtain a recommended text for responding to the request.
In some embodiments, the determining module 5551 is further configured to perform one of:
screening the historical browsing text set of the target user, and determining the historical browsing text in a set time period as a standard text;
screening the historical browsing text of the target user, and determining the historical browsing text as the standard text when the time of the historical browsing text used by the target user is greater than a time threshold;
and screening the historical browsing text of the target user, and determining the historical browsing text as the standard text when the frequency of the historical browsing text used by the sample user is greater than a use frequency threshold value.
In some embodiments, the recall module 5552 is further configured to perform word segmentation on the standard text to obtain keywords in the standard text; and retrieving a text set to be recommended according to the keywords in the standard text, and determining at least one text to be recommended corresponding to the standard text.
In some embodiments, the first processing module 5553 is further configured to determine, according to the historical browsing text in the set of historical browsing texts of the target user and the standard text, a similarity between the historical browsing text and the standard text; and determining the user interest of the target user for the standard text according to the similarity of at least one historical browsing text and the standard text.
In some embodiments, the first processing module 5553 is further configured to sum similarities between at least one historical browsing text and the standard text, so as to obtain a sum of similarities; determining the similarity between the historical browsing text and the standard text, and determining a first ratio of the similarity to the sum of the similarities; and carrying out weighted summation on the historical browsing texts and the first ratio to obtain the user interest of the target user for the standard texts.
In some embodiments, the user interest is a user interest vector, the text to be recommended is a text vector to be recommended, and the standard text is a standard text vector; the fusion module 5554 is further configured to sum the user interest vector and the standard text vector to obtain a corresponding sum vector, and determine that the corresponding sum vector is a fusion text that is fused with the interest of the target user; the second processing module 5555 is further configured to determine a similarity between the corresponding sum vector and the vector of the text to be recommended as a similarity between the text to be recommended and the standard text.
In some embodiments, the third processing module 5556 is further configured to obtain a weight of the standard text; obtaining the quantity of recommended texts corresponding to the standard texts according to the proportional relation between the weight and the quantity of the recommended texts and the weight of the standard texts; and sequencing the at least one text to be recommended in a descending order based on the similarity between the text to be recommended and the standard text to obtain recommended texts corresponding to the quantity of the recommended texts.
In some embodiments, the third processing module 5556 is further configured to sum the time of the at least one standard text used by the target user, resulting in a sum of time; and comparing the time of the standard text used by the target user with the sum of the time to obtain the weight of the standard text.
In some embodiments, the screening module 5557 is further configured to retrieve the historical browsing text set according to a recommended text corresponding to at least one standard text, and filter the recommended text to obtain a recommended text for responding to the request when the recommended text is the historical browsing text.
In some embodiments, the artificial intelligence based text recommender 555 further comprises:
an obtaining module 5558 is configured to, for a request of text recommendation by a target user, obtain a historical browsing text set of the target user from a blockchain network.
Embodiments of the present invention also provide a storage medium storing executable instructions, which when executed by a processor, will cause the processor to perform an artificial intelligence based text recommendation method provided by embodiments of the present invention, for example, the artificial intelligence based text recommendation method shown in fig. 3A to 3C.
In some embodiments, the storage medium may be a memory such as FRAM, ROM, PROM, EPROM, EE PROM, flash, magnetic surface memory, optical disk, or CD-ROM; or may be various devices including one or any combination of the above memories.
In some embodiments, executable instructions may be written in any form of programming language (including compiled or interpreted languages), in the form of programs, software modules, scripts or code, and may be deployed in any form, including as a stand-alone program or as a module, component, subroutine, or other unit suitable for use in a computing environment.
By way of example, executable instructions may correspond, but do not necessarily have to correspond, to files in a file system, may be stored in a portion of a file that holds other programs or data, e.g., in one or more scripts in a HyperText markup Language (H TML) document, in a single file dedicated to the program in question, or in multiple coordinated files (e.g., files that store one or more modules, sub-programs, or portions of code).
By way of example, executable instructions may be deployed to be executed on one computing device or on multiple computing devices at one site or distributed across multiple sites and interconnected by a communication network.
In the following, an exemplary application of the embodiments of the present invention in a practical application scenario will be described.
The news personalized recommendation is to recommend news which the user is interested in to the user according to the interest characteristics and the reading behaviors of the user. The click sequence of the user is important information for mining the user interest, which not only reflects the interest distribution of the user, but also implies the association relationship between the articles.
The item embedding (item embedding) based collaborative filtering recommendation algorithm is a feasible recommendation algorithm. Firstly, mapping an article set (a text set to be recommended) to the same vector space, wherein each article has a unique vector representation; then, the similarity between two articles in the article set, i.e. the cosine similarity of the embedded (embedding) vector, such as cos (a, B), cos (a, C), cos (a, D), etc., is calculated. Obtaining a similar article set corresponding to each article, such as a similar article set top sim set of article a (standard text) { B, F, T, E, P }; and finally, recommending an article set similar to the historical articles according to the historical articles browsed by the user in the past.
However, the collaborative filtering recommendation algorithm based on item embedding has some problems:
when article recommendation is performed on the same historical article read by different users, the recommended similar article sets are the same, and the difference between the users is not considered. For example, if the user U1 and the user U2 both read the article a, the recommended articles for the user U1 and the user U2 both contain the similar article set top sim set of the article a { B, F, T, E, P }.
However, there are differences between different users and different interest tendencies. Even if the user U1 and the user U2 both read the article a, the points of interest of the user U1 and the user U2 for the article a are different, and the current collaborative filtering recommendation algorithm based on itembedding cannot take the difference into account, but the top sim set { B, F, T, E, P } for recommending the article a for the user U1 and the user U2 is unified, so that the recommended article is inaccurate.
In order to solve the above problem, an embodiment of the present invention provides an item embedding collaborative filtering recommendation algorithm (text recommendation method based on artificial intelligence) that introduces an attention mechanism: firstly, mapping an article set to the same vector space, wherein each article has a unique vector representation; secondly, when recommending a similar article set of articles read from the history for the user, for example, the user U1 reads article a, when calculating the similar article set of articles read from the history, an attention mechanism is introduced, and an interest vector of the user U1 is introduced into the similar article set, so as to take into account individual differences among different users and differences of points of interest of different users for the same reading article. Namely, an interest vector of the user is introduced, similarity between every two articles in the article set is calculated, for example, cos (U1+ A, B), cos (U1+ A, C) and cos (U1+ A, D) are calculated, and then the user U1 is recommended to the article set which is similar to the historical reading article A and accords with the historical interest of the user U1. The U1 vector is a vector representing the user by reading the article according to the user's history, and paying attention (attention) to the article to be recommended currently.
Therefore, through the attention mechanism, after the interest vector of the user is introduced into the similarity calculation, the individual difference of the user and the attention point difference of the same reading article are introduced, so that the recommended article set can be more close to the real interest of the user.
The text recommendation method based on artificial intelligence provided by the embodiment of the invention can be applied to a news recommendation system, when an article set similar to a historically read article is recommended for a user, not only the similarity between every two articles is calculated, but also an attention mechanism is introduced when the similar article set of the historically read article A is calculated, the interest vector of the current user is introduced into the text recommendation method, and the individual difference between different users and the attention point difference of the different users to the same reading article are considered. As shown in fig. 7, in the conventional recommendation method, as long as the user U1, the user U2 and the user U3 read the article a, and the similar articles of the user U1, the user U2 and the user U3 about the article a are calculated to be the same, the related article sets about the article a recommended to the user U1, the user U2 and the user U3 are the same. The attention mechanism is introduced into the recommendation method, similar articles of the article A are calculated differently by the user U1, the user U2 and the user U3, and in the calculation process of the similar articles of the article A, the related article sets of the article A, recommended to the user U1, the user U2 and the user U3, are different by introducing the interest vector of the user.
Therefore, through the attention mechanism, after the interest vectors of the users are introduced into the similarity calculation, the individual difference of the users and the attention point difference of the same reading article are introduced, so that the recommended article set can be more close to the real interest of the users.
Here, a news recommender system typically comprises four modules: the system comprises a user portrait module (a first processing module), a recall module, a Click Through Rate (CTR) pre-estimation module (a fusion module, a second processing module and a third processing module) and a rearrangement module (a screening module). As shown in fig. 8, fig. 8 is a flow chart of personalized recommendation performed by the news recommendation system according to the embodiment of the present invention, after receiving a request of an access layer, the news recommendation system first calls a portrait service module to obtain a portrait of a user (user interest), then transmits the portrait of the user to a recall module, the recall module filters coarsely arranged articles (articles to be recommended) from an article pool and outputs the coarsely arranged articles to a CTR pre-estimation module, the CTR pre-estimation module performs fine ranking on the recalled articles, finally, the first K articles after the fine ranking are taken to a rearrangement module, the rearrangement module performs final filtering (removing the articles that the user has browsed) and diversity ranking, and finally outputs the articles to the user for article recommendation.
The personalized news recommendation is to recommend news which are interested to users according to the interest characteristics and reading behaviors of the users. The click sequence of the user is important information for mining the user interest, which not only reflects the interest distribution of the user, but also implies the association relationship between the articles.
The collaborative filtering recommendation algorithm based on item embedding realizes article recommendation through the following steps:
firstly, articles clicked by a user in a time period (section) are arranged according to the sequence of click time, and are used as training samples to be input into a word2vec or other models for training to obtain vector representation of the articles;
then, calculating cosine similarity between every two articles in the article set to obtain a similar article set corresponding to each article, for example, the similar article set top sim set of the article a is { B, F, T, E, P };
and finally, calculating the first K similar articles aiming at the articles recently browsed by the user, and generating an article set so as to recommend the articles to the user.
However, the collaborative filtering recommendation algorithm based on item embedding has some problems: the fact that users have different interest tendencies cannot be considered, but a similar article set top simset of the article A is uniformly recommended to the users, namely { B, F, T, E, P }, so that inaccurate recommendation is caused.
In order to solve the above problem, in the embodiment of the present invention, when calculating the similar article sets of the articles a, the interest vectors of the users are introduced, and cos (U1+ a, B), cos (U1+ a, C), and cos (U1+ a, D) are calculated, so as to recommend the article sets, which are similar to the historical reading articles a and meet the historical interests of the users, to the users U1. As shown in fig. 9, fig. 9 is a comparison diagram before and after improvement of the recommendation method according to the embodiment of the present invention, where a U1 vector is represented by an attribute to a reading article to be currently recommended, that is, a user vector, according to a historical reading article of the user.
Articles a, J, F, G, … historically read by user U1. Now, for an article a, a related article set is recommended, and after an attention mechanism is introduced, the following formula (1) is calculated for the interest vector of the user U1A of the article a to be recommended currently:
U1A=J*(exp(cos(J,A))/S)+F*(exp(cos(F,A))/S)+G*(exp(cos(G,A))/S)+...(1)
where S denotes sum (exp (cos (J, a)), exp (cos (F, a)), exp (cos (G, a)),. a denotes an article a vector, F denotes an article F vector, G denotes an article G vector, and cos (·) denotes cosine similarity calculation.
The item embedding collaborative filtering recommendation algorithm with attention mechanism introduced in the embodiment of the invention is exemplified as follows:
if there are user U1 and user U2, user U1 prefers entertainment, user U2 prefers sports, and user U1 and user U2 read article A at the same time;
article A: the young ping-pong ball game cherishes.
Articles similar to the article a vector include the following:
article B: how many days, how are Xiaoming and Xiaohong divided into hands, what is the near condition?
Article C: xiaoming has settled retirement? Go to the Top-school, start 200 tea shops, and visit XX corporation.
Article D: xiaoming ginseng is combined with the general skill of CC Life.
Article E: xiaoming 4:5 cherish amateur players actively promote the interaction between the ball and the vermicelli.
Article F: xiaoming Xibai, opponent details are worth respecting.
The traditional item embedding collaborative filtering recommendation algorithm will recommend B, C, D, E, F article sets for user U1 and user U2 simultaneously.
Through the improvement of the invention, after the interest vectors of the users are introduced, the article sets recommended for the user U1 and the user U2 are different: because the user U1 is inclined to be entertainment, the article set B, C, D is recommended after the user vector is introduced; since the user U2 prefers sports hobbies, the article set E, F will be recommended after introducing the user vector.
Therefore, after the interest vectors of the users are introduced into the similarity calculation through the attention mechanism, the individual difference of the users and the attention point difference of the same reading article are introduced, so that the recommended article set can be more close to the real interest of the users.
In summary, the embodiment of the present invention has the following beneficial effects by incorporating the user interests into the standard text:
1. determining a standard text from a historical browsing text set of a target user so as to determine a recommended text which is possibly interested by the target user according to the standard text, and improving the accuracy of the recommended text;
2. the user interests of the target user for the standard text are merged into the standard text, so that the text meeting the user interests can be recommended to the user according to the individual difference of the user interests, and the user experience is improved.
The above description is only an example of the present invention, and is not intended to limit the scope of the present invention. Any modification, equivalent replacement, and improvement made within the spirit and scope of the present invention are included in the protection scope of the present invention.

Claims (10)

1. A text recommendation method based on artificial intelligence, characterized in that the method comprises:
determining at least one standard text from a historical browsing text set of a target user aiming at a request of text recommendation of the target user;
according to the standard text, a text set to be recommended is recalled, and at least one text to be recommended corresponding to the standard text is determined;
acquiring user interest of the target user for a standard text;
fusing the user interest and the standard text to obtain a fused text fused with the user interest;
obtaining the similarity between the text to be recommended and the standard text according to the fused text which is fused with the interest of the target user and the text to be recommended;
sequencing the at least one text to be recommended based on the similarity between the text to be recommended and the standard text to obtain a recommended text corresponding to the standard text;
and screening the recommended texts corresponding to the at least one standard text to obtain the recommended texts for responding to the request.
2. The method of claim 1, wherein determining at least one standard text from the set of historical browsing texts of the target user comprises one of:
screening the historical browsing text set of the target user, and determining the historical browsing text in a set time period as a standard text;
screening the historical browsing text of the target user, and determining the historical browsing text as the standard text when the time of the historical browsing text used by the target user is greater than a time threshold;
and screening the historical browsing text of the target user, and determining the historical browsing text as the standard text when the frequency of the historical browsing text used by the sample user is greater than a use frequency threshold value.
3. The method according to claim 1 or 2, wherein the recalling the set of texts to be recommended according to the standard text to determine at least one text to be recommended corresponding to the standard text comprises:
performing word segmentation processing on the standard text to obtain keywords in the standard text;
and retrieving a text set to be recommended according to the keywords in the standard text, and determining at least one text to be recommended corresponding to the standard text.
4. The method according to claim 1 or 2, wherein the obtaining of the user interest of the target user for standard text comprises:
determining the similarity between the historical browsing text and the standard text according to the historical browsing text in the historical browsing text set of the target user and the standard text;
and determining the user interest of the target user for the standard text according to the similarity of at least one historical browsing text and the standard text.
5. The method of claim 4, wherein determining the user interest of the target user for the standard text according to the similarity between the at least one historical browsing text and the standard text comprises:
summing the similarity of at least one historical browsing text and the standard text to obtain a similarity sum;
determining the similarity between the historical browsing text and the standard text, and determining a first ratio of the similarity to the sum of the similarities;
and carrying out weighted summation on the historical browsing texts and the first ratio to obtain the user interest of the target user for the standard texts.
6. The method according to claim 1 or 2,
the user interest is a user interest vector, the text to be recommended is a text vector to be recommended, and the standard text is a standard text vector;
the fusing the user interest and the standard text to obtain a fused text fused with the target user interest, comprising:
summing the user interest vector and the standard text vector to obtain a corresponding sum vector, and determining that the corresponding sum vector is a fusion text fused with the interest of the target user;
the obtaining of the similarity between the text to be recommended and the standard text according to the fused text fused with the interest of the target user and the text to be recommended includes:
and determining the similarity between the corresponding sum vector and the text vector to be recommended as the similarity between the text to be recommended and the standard text.
7. The method according to claim 1 or 2, wherein the sorting the at least one text to be recommended based on the similarity between the text to be recommended and the standard text to obtain a recommended text corresponding to the standard text comprises:
acquiring the weight of the standard text;
obtaining the quantity of recommended texts corresponding to the standard texts according to the proportional relation between the weight and the quantity of the recommended texts and the weight of the standard texts;
and sequencing the at least one text to be recommended in a descending order based on the similarity between the text to be recommended and the standard text to obtain recommended texts corresponding to the quantity of the recommended texts.
8. The method of claim 7, wherein obtaining the weight of the standard text comprises:
summing the time of the at least one standard text used by the target user to obtain a time sum;
and comparing the time of the standard text used by the target user with the sum of the time to obtain the weight of the standard text.
9. The method of claim 1, further comprising:
and acquiring a historical browsing text set of a target user from a block chain network according to a request of the target user for text recommendation.
10. An artificial intelligence based text recommendation apparatus, the apparatus comprising:
the determining module is used for determining at least one standard text from a historical browsing text set of a target user aiming at a request of text recommendation of the target user;
the recall module is used for recalling a text set to be recommended according to the standard text and determining at least one text to be recommended corresponding to the standard text;
the first processing module is used for acquiring the user interest of the target user for the standard text;
the fusion module is used for fusing the user interest and the standard text to obtain a fused text fused with the user interest;
the second processing module is used for obtaining the similarity between the text to be recommended and the standard text according to the fused text which is fused with the interest of the target user and the text to be recommended;
the third processing module is used for sequencing the at least one text to be recommended based on the similarity between the text to be recommended and the standard text to obtain a recommended text corresponding to the standard text;
and the screening module is used for screening the recommended texts corresponding to the at least one standard text to obtain the recommended texts for responding to the request.
CN201910901147.0A 2019-09-23 2019-09-23 Text recommendation method and device based on artificial intelligence Pending CN110688476A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910901147.0A CN110688476A (en) 2019-09-23 2019-09-23 Text recommendation method and device based on artificial intelligence

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910901147.0A CN110688476A (en) 2019-09-23 2019-09-23 Text recommendation method and device based on artificial intelligence

Publications (1)

Publication Number Publication Date
CN110688476A true CN110688476A (en) 2020-01-14

Family

ID=69110079

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910901147.0A Pending CN110688476A (en) 2019-09-23 2019-09-23 Text recommendation method and device based on artificial intelligence

Country Status (1)

Country Link
CN (1) CN110688476A (en)

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111310056A (en) * 2020-03-11 2020-06-19 腾讯科技(深圳)有限公司 Information recommendation method, device, equipment and storage medium based on artificial intelligence
CN111310436A (en) * 2020-02-11 2020-06-19 腾讯科技(深圳)有限公司 Text processing method and device based on artificial intelligence and electronic equipment
CN111475721A (en) * 2020-03-31 2020-07-31 百度在线网络技术(北京)有限公司 Information pushing method, device, equipment and storage medium
CN111563198A (en) * 2020-04-16 2020-08-21 百度在线网络技术(北京)有限公司 Material recall method, device, equipment and storage medium
CN111859147A (en) * 2020-07-31 2020-10-30 中国工商银行股份有限公司 Object recommendation method, object recommendation device and electronic equipment
CN112559899A (en) * 2021-02-25 2021-03-26 北京睿企信息科技有限公司 User portrait generation method
CN113051475A (en) * 2021-03-25 2021-06-29 平安银行股份有限公司 Content recommendation method and device, electronic equipment and readable storage medium
CN113420203A (en) * 2021-05-18 2021-09-21 北京达佳互联信息技术有限公司 Object recommendation method and device, electronic equipment and storage medium
CN113536785A (en) * 2021-06-15 2021-10-22 合肥讯飞数码科技有限公司 Text recommendation method, intelligent terminal and computer readable storage medium
CN114780844A (en) * 2022-04-21 2022-07-22 杭州樱熊网络科技有限公司 Novel recommendation method and system based on user habits

Cited By (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111310436B (en) * 2020-02-11 2022-02-15 腾讯科技(深圳)有限公司 Text processing method and device based on artificial intelligence and electronic equipment
CN111310436A (en) * 2020-02-11 2020-06-19 腾讯科技(深圳)有限公司 Text processing method and device based on artificial intelligence and electronic equipment
CN111310056A (en) * 2020-03-11 2020-06-19 腾讯科技(深圳)有限公司 Information recommendation method, device, equipment and storage medium based on artificial intelligence
CN111310056B (en) * 2020-03-11 2023-04-14 深圳市雅阅科技有限公司 Information recommendation method, device, equipment and storage medium based on artificial intelligence
CN111475721A (en) * 2020-03-31 2020-07-31 百度在线网络技术(北京)有限公司 Information pushing method, device, equipment and storage medium
CN111475721B (en) * 2020-03-31 2023-12-29 百度在线网络技术(北京)有限公司 Information pushing method, device, equipment and storage medium
CN111563198A (en) * 2020-04-16 2020-08-21 百度在线网络技术(北京)有限公司 Material recall method, device, equipment and storage medium
CN111859147B (en) * 2020-07-31 2023-08-22 中国工商银行股份有限公司 Object recommendation method, object recommendation device and electronic equipment
CN111859147A (en) * 2020-07-31 2020-10-30 中国工商银行股份有限公司 Object recommendation method, object recommendation device and electronic equipment
CN112559899A (en) * 2021-02-25 2021-03-26 北京睿企信息科技有限公司 User portrait generation method
CN113051475A (en) * 2021-03-25 2021-06-29 平安银行股份有限公司 Content recommendation method and device, electronic equipment and readable storage medium
CN113051475B (en) * 2021-03-25 2023-05-23 平安银行股份有限公司 Content recommendation method, device, electronic equipment and readable storage medium
CN113420203A (en) * 2021-05-18 2021-09-21 北京达佳互联信息技术有限公司 Object recommendation method and device, electronic equipment and storage medium
CN113536785A (en) * 2021-06-15 2021-10-22 合肥讯飞数码科技有限公司 Text recommendation method, intelligent terminal and computer readable storage medium
CN114780844A (en) * 2022-04-21 2022-07-22 杭州樱熊网络科技有限公司 Novel recommendation method and system based on user habits

Similar Documents

Publication Publication Date Title
CN110688476A (en) Text recommendation method and device based on artificial intelligence
CN111680221B (en) Information recommendation method, device, equipment and computer readable storage medium
CN110139162B (en) Media content sharing method and device, storage medium and electronic device
CN110020188A (en) Recommended based on the Global Vector of implicit interactions and profile data
US20190354555A1 (en) Dynamic faceting for personalized search and discovery
CN110597962B (en) Search result display method and device, medium and electronic equipment
Li et al. Understanding the long-term evolution of mobile app usage
CN107209905A (en) For personalized and task completion service, correspondence spends theme and sorted out
CN106104522B (en) For reinforcing the method, system and computer memory device of any user content
CN110825956A (en) Information flow recommendation method and device, computer equipment and storage medium
Yin et al. Mobi-sage: A sparse additive generative model for mobile app recommendation
US20160162583A1 (en) Apparatus and method for searching information using graphical user interface
KR102141245B1 (en) Online contents funding system and method based upon matching with contents creator and investor
CN111949886B (en) Sample data generation method and related device for information recommendation
CN112307344A (en) Object recommendation model, object recommendation method and device and electronic equipment
US9536445B2 (en) System and method for visually tracking a learned process
CN111476469A (en) Guest expansion method, terminal equipment and storage medium
CN111967914A (en) User portrait based recommendation method and device, computer equipment and storage medium
CN112868003A (en) Entity-based search system using user interactivity
Wang et al. CROWN: a context-aware recommender for web news
CN111159570A (en) Information recommendation method and server
CN116089745A (en) Information recommendation method, device, electronic equipment and computer readable storage medium
CN116956183A (en) Multimedia resource recommendation method, model training method, device and storage medium
US10248983B1 (en) Customized item descriptions based on skill level
CN111399731B (en) Picture operation intention processing method, recommendation method and device, electronic equipment and storage medium

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