CN114691981A - Session recommendation method, system, device and storage medium - Google Patents

Session recommendation method, system, device and storage medium Download PDF

Info

Publication number
CN114691981A
CN114691981A CN202210201808.0A CN202210201808A CN114691981A CN 114691981 A CN114691981 A CN 114691981A CN 202210201808 A CN202210201808 A CN 202210201808A CN 114691981 A CN114691981 A CN 114691981A
Authority
CN
China
Prior art keywords
session
representation
vectorization
conversation
data set
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
CN202210201808.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.)
South China University of Technology SCUT
Original Assignee
South China University of Technology SCUT
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 South China University of Technology SCUT filed Critical South China University of Technology SCUT
Priority to CN202210201808.0A priority Critical patent/CN114691981A/en
Publication of CN114691981A publication Critical patent/CN114691981A/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/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/953Querying, e.g. by the use of web search engines
    • G06F16/9535Search customisation based on user profiles and personalisation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • G06F16/2458Special types of queries, e.g. statistical queries, fuzzy queries or distributed queries
    • G06F16/2477Temporal data queries
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/953Querying, e.g. by the use of web search engines
    • G06F16/9537Spatial or temporal dependent retrieval, e.g. spatiotemporal queries
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/22Matching criteria, e.g. proximity measures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • G06F18/241Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches
    • G06F18/2413Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches based on distances to training or reference patterns
    • G06F18/24133Distances to prototypes
    • G06F18/24137Distances to cluster centroïds
    • G06F18/2414Smoothing the distance, e.g. radial basis function networks [RBFN]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/25Fusion techniques
    • G06F18/253Fusion techniques of extracted features
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/049Temporal neural networks, e.g. delay elements, oscillating neurons or pulsed inputs
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/06Buying, selling or leasing transactions
    • G06Q30/0601Electronic shopping [e-shopping]
    • G06Q30/0631Item recommendations

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Evolutionary Computation (AREA)
  • Artificial Intelligence (AREA)
  • Evolutionary Biology (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Computational Linguistics (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Biomedical Technology (AREA)
  • Molecular Biology (AREA)
  • General Health & Medical Sciences (AREA)
  • Biophysics (AREA)
  • Computing Systems (AREA)
  • Health & Medical Sciences (AREA)
  • Business, Economics & Management (AREA)
  • Accounting & Taxation (AREA)
  • Finance (AREA)
  • Fuzzy Systems (AREA)
  • Probability & Statistics with Applications (AREA)
  • Development Economics (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • Strategic Management (AREA)
  • General Business, Economics & Management (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention discloses a method, a system, a device and a storage medium for recommending a session, wherein the method comprises the following steps: acquiring a session recommendation data set, preprocessing and enhancing the data, and processing the data into a user behavior sequence form; inputting the data after data enhancement into a Transformer network, and respectively modeling the session information by utilizing a neighborhood modeling unit and an internal modeling unit; and aggregating the neighborhood conversation information and the current conversation information to obtain a recommendation result. The invention utilizes the historical purchasing information as the cooperative information, can effectively model the consumption behavior of the user, and considers the user behavior with the same preference in the historical conversation and the user when recommending the user, so that the recommending algorithm can more effectively predict the real consumption intention of the user, thereby giving more accurate recommending result. The invention can be widely applied to the technical fields of artificial intelligence, deep learning and recommendation systems.

Description

Session recommendation method, system, device and storage medium
Technical Field
The invention relates to the technical field of artificial intelligence, deep learning and recommendation systems, in particular to a session recommendation method, system, device and storage medium.
Background
With the rapid increase of the information amount on the internet, it is very difficult for the vast users to find the required information from the huge information sea; for a network platform providing services, the ultimate aim is to provide contents which are interested by users, and the users are retained to the maximum extent, so that the platform benefits are improved. Recommendation systems, in turn, have become the basis for helping users alleviate information overload problems and select information of interest in many Web applications, such as search, e-commerce, and streaming media sites. Conversational recommendation is a special field of recommendation systems, most existing recommendation systems assume constant recording of user profiles and past activities. However, in many services, the user identity may be unknown and only a history of user behavior during an ongoing session is available. Therefore, it is important to model the limited behavior in one session and generate recommendations accordingly. In contrast, in this case, conventional recommendation methods that rely on sufficient user-item interactions are problematic in producing accurate conversational recommendation results. However, by introducing a deep learning technology, a large number of user behaviors are analyzed and modeled, and a recommendation result meeting the requirements of a user and a platform can be given according to a plurality of interactions of the user under the condition that user information is anonymous.
In the existing conversation recommendation technology, serialized problems are converted into graph problems, all conversation sequences are modeled through a directed graph, then a hidden vector representation of each commodity is learned through a graph neural network, and further a short-term interest of a user is captured through an attention network architecture model, so that the purpose of capturing the vector representation of the coexistence of long-term and short-term interests is achieved. The technical characteristics include: (1) preprocessing the session data, and modeling the session data into data with a graph structure; (2) modeling the session data by using a GNN model to obtain a session vector representation; (3) and performing similarity calculation by using the final conversation expression vector and the commodity vector to obtain a recommendation result. The disadvantages of this technique are: (1) because the conversation data is built into a graph, the time sequence information of the sequence is lost to a certain extent; (2) the existence of noise in data is not considered, the commodities are directly connected on a graph through various relations, and necessary correlation may not exist among the commodities.
In another existing conversation recommendation technology, a recurrent neural network is used to perform time-sequence modeling on conversation data, and then two memory networks are used to integrate information in the conversation and in the conversation field, so as to obtain vector representation of the conversation. The technical characteristics include: (1) using two networks to model two levels of session information, session interior and session neighborhood, simultaneously, a more complete session vector representation can be obtained. (2) The two levels of session vector representations are fused by a specially designed gated fusion mechanism. The disadvantages of this technique are: (1) the method for considering the session neighborhood is too simple, and effective neighborhood information cannot be fused; (2) the recurrent neural network has the problem of gradient disappearance, and session information cannot be completely modeled.
Disclosure of Invention
To solve at least one of the technical problems in the prior art to some extent, an object of the present invention is to provide a method, a system, an apparatus and a storage medium for session recommendation.
The technical scheme adopted by the invention is as follows:
a session recommendation method comprising the steps of:
acquiring a session data set of a user on an e-commerce platform, wherein the session data set comprises article information, a user purchase timestamp and a user purchase behavior;
performing data enhancement on the session data set;
modeling the session data set after data enhancement into a sequence structure, and inputting the sequence structure into a Transformer network to obtain a preliminary session vectorization representation data set;
storing the sessions in the preliminary session vectorization representation dataset in a historical session vectorization representation memory;
using a Transformer networkModeling global information, extracting local information by using Convolation network, and finally obtaining vectorization expression h of current sessioncurrent
Searching the vectorization representation of K neighborhood sessions with highest similarity in the historical session vectorization representation memory, setting a similarity threshold a, generating the vectorization representation of two representation positions by taking the similarity threshold as a boundary, and fusing the vectorization representation of the K neighborhood sessions with the vectorization representation of the K neighborhood sessions through a Transformer network to obtain a neighborhood session vectorization representation hneighbor
Representing the current session vector as hcurrentAnd neighborhood session vector representation hneighborConnecting the conversation vectorization representation through a fusion layer to obtain a final conversation vectorization representation;
and calculating the final session vectorization representation, calculating cosine similarity with all the articles in the session data set, and taking the article with the highest similarity as a recommendation result.
Further, the method also comprises a step of preprocessing the session data set, and comprises the following steps:
sequencing the conversation data according to the time stamp to obtain a conversation sequence which is sequenced according to time, removing the conversation which is clicked once, and deleting the click item with too low frequency of occurrence;
wherein, each item of the session data comprises the serial number item _ id of the commodity and the time stamp of the commodity being clicked.
Further, the sorting the session data according to the time stamp to obtain a time-sorted session sequence includes:
acquiring N session data from the session data set, wherein s represents a session, v represents a clicked commodity item, all commodity items v in the session are sorted according to the time stamp _ stamp of the clicked commodity, and a session sequence can be represented as s ═ s<v1,v2,v3…vc>And the subscript c of v is used for distinguishing the order of clicking the commodities.
Further, the modeling of the session data set after data enhancement into a sequence structure and inputting the sequence structure into a Transformer network to obtain a preliminary session vectorization representation data set includes:
modeling the click data set after data enhancement into a sequence structure, inputting the sequence structure into a transform model, and obtaining vectorization representation of each commodity in a conversation sequence after training; vectorization representation of each node in the conversation sequence represents vector representation X of one commodity after synthesizing the characteristics of other commodities in the sequence<x1,x2,x3…xn>;
The vectorization representation of all commodity nodes in the conversation sequence is averaged to obtain the vectorization representation of each conversation, and the conversation s is equal to the conversation s<v1,v2,v3…vn>Wherein n is the number of commodities included in the session s, and the preliminary session vectorization is represented as: x ═ X1,x2,…,xn}。
Further, the storing the sessions in the preliminary session vectorization representation data set in a historical session vectorization representation memory includes:
storing a session vectorization representation of user consumption behavior in the preliminary session vectorization representation dataset, the set denoted as M, for subsequent domain information lookup,
Figure BDA0003527707040000031
where p represents the number of sessions a user purchases in the session data set, t represents the length of the session,
Figure BDA0003527707040000032
indicating a session vectorized representation of length j after the above-described data enhancement at the ith session.
Further, the expression of the final session vectorization representation z is as follows:
z=αhcurrent+(1-a)hneighbor
wherein the parameter α ═ σ (W)1hcurrent+W2hneighbor) σ stands for sigmoid function, W1,W2Are model parameters that can be trained.
Further, the cosine similarity is calculated as follows:
Value=softmax(zTx)
wherein z is final session vectorization representation, x is article vectorization representation, and T represents vector transposition; the K items with the highest scores form the final recommended item list.
The other technical scheme adopted by the invention is as follows:
a conversation recommendation system comprising:
the data acquisition module is used for acquiring a session data set of a user on the E-commerce platform, wherein the session data set comprises article information, a user purchase timestamp and a user purchase behavior;
the data enhancement module is used for carrying out data enhancement on the session data set;
the vector extraction module is used for modeling the session data set subjected to data enhancement into a sequence structure and inputting the sequence structure into a Transformer network to obtain a preliminary session vectorization representation data set;
the data storage module is used for storing the sessions in the preliminary session vectorization representation data set in a historical session vectorization representation memory;
the session internal modeling module is used for carrying out global information modeling by using a Transformer network, carrying out local information extraction by using a Convolation network and finally obtaining vectorization expression h of the current sessioncurrent
A session neighborhood modeling module for searching the vectorized representation of K neighborhood sessions with the highest similarity in the historical session vectorized representation memory, then setting a similarity threshold a, taking the similarity threshold as a boundary, generating two vectorized representations of the representation positions, and fusing the vectorized representations of the two representation positions with the vectorized representation of the K neighborhood sessions through a Transformer network to obtain a neighborhood session vectorized representation hneighbor
A vector fusion module for representing the current session vector as hcurrentAnd neighborhood session vector representation hneighborConnected to the substrate via a fusion layerTogether, obtaining a final session vectorization representation;
and the recommendation calculation module is used for calculating the cosine similarity of the final session vectorization representation and all the articles in the session data set, and taking the article with the highest similarity as a recommendation result.
The other technical scheme adopted by the invention is as follows:
a conversation recommendation apparatus comprising:
at least one processor;
at least one memory for storing at least one program;
when executed by the at least one processor, cause the at least one processor to implement the method described above.
The invention adopts another technical scheme that:
a computer readable storage medium in which a processor executable program is stored, which when executed by a processor is for performing the method as described above.
The invention has the beneficial effects that: the method and the system have the advantages that the historical conversation of the historical purchasing behavior of the user is represented and stored, the historical purchasing conversation is used as the collaborative information, the consumption patterns of similar users can be effectively captured, and meanwhile, the user behavior with the same preference as that of the current user in the historical conversation is considered when the current user is recommended, and the neighborhood conversation information is extracted; the neighborhood session information and the current session information are aggregated to give a recommendation result, so that the real requirements of the user can be more effectively predicted by a new recommendation algorithm, and a more accurate recommendation result is given.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following description is made on the drawings of the embodiments of the present invention or the related technical solutions in the prior art, and it should be understood that the drawings in the following description are only for convenience and clarity of describing some embodiments in the technical solutions of the present invention, and it is obvious for those skilled in the art that other drawings can be obtained according to these drawings without creative efforts.
FIG. 1 is a flowchart illustrating steps of a session recommendation method according to an embodiment of the present invention;
fig. 2 is a general flowchart of a session recommendation method according to an embodiment of the present invention.
Detailed Description
Reference will now be made in detail to embodiments of the present invention, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to the same or similar elements or elements having the same or similar function throughout. The embodiments described below with reference to the accompanying drawings are illustrative only for the purpose of explaining the present invention and are not to be construed as limiting the present invention. The step numbers in the following embodiments are provided only for convenience of illustration, the order between the steps is not limited at all, and the execution order of each step in the embodiments can be adapted according to the understanding of those skilled in the art.
In the description of the present invention, it should be understood that the orientation or positional relationship referred to in the description of the orientation, such as the upper, lower, front, rear, left, right, etc., is based on the orientation or positional relationship shown in the drawings, and is only for convenience of description and simplification of description, and does not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and thus, should not be construed as limiting the present invention.
In the description of the present invention, the meaning of a plurality of means is one or more, the meaning of a plurality of means is two or more, and larger, smaller, larger, etc. are understood as excluding the number, and larger, smaller, inner, etc. are understood as including the number. If there is a description of first and second for the purpose of distinguishing technical features only, this is not to be understood as indicating or implying a relative importance or implicitly indicating the number of technical features indicated or implicitly indicating the precedence of technical features indicated.
In the description of the present invention, unless otherwise explicitly limited, terms such as arrangement, installation, connection and the like should be understood in a broad sense, and those skilled in the art can reasonably determine the specific meanings of the above terms in the present invention in combination with the specific contents of the technical solutions.
As shown in fig. 1 and fig. 2, the present embodiment provides a session recommendation method, which uses historical purchase information as collaborative information, and can effectively model consumption behaviors of a user, and when recommending is performed for the user, the user behaviors having the same preference as that of the user in a historical session are considered, so that a recommendation algorithm can more effectively predict a real consumption intention of the user, and a more accurate recommendation result is provided. The method specifically comprises the following steps:
and S1, collecting a conversation data set of the user on the E-commerce platform, wherein the conversation data set comprises the item information, the user purchase time stamp and the user purchase behavior from the public data set.
Specifically, step S1 is as follows: and obtaining a session data set containing item category information, user purchasing time and user purchasing behavior from the public data platform, wherein each item in the session data further comprises a serial number item _ id of the commodity and a time stamp time _ stamp of the commodity when the commodity is clicked.
S2, preprocessing the session data set. The method comprises the following steps: and sequencing the session data on a timestamp to obtain a session sequence which is sequenced according to time, removing sessions which are clicked once and deleting click items with too low occurrence frequency.
Wherein the step S2 specifically includes steps S21-S22:
s21, obtaining N session data from the session data set, S representing the session, v representing the purchased commodity item, and sorting all commodity items v in the session according to the time stamp time _ stamp of the purchased commodity, wherein a session sequence is represented as S ═ S<v1,v2,v3…vc>The subscript c of v is used for distinguishing the order of clicking the commodities;
s22, further pre-processing the sessions obtained after the pre-processing in step S21, in this embodiment, sessions appearing less than 5 times in the whole session database are removed, and then sessions with a session length less than 2 are removed.
And S3, dividing the preprocessed session data set into a training data set and a testing data set according to the time stamp, and respectively using the training data set and the testing data set as model training and testing.
As an optional manner, step S3 is specifically as follows: in the preprocessed session data set, the training set and the test set are divided according to the time stamp, for example, for the session s ═<v1,v2,v3,v4,v5>After division, the training set is<v1,v2,v3>The label is<v2,v3,v4>(ii) a The test set is<v1,v2,v3,v4>The label is<v5>。
And S4, performing data enhancement on the session data set by performing fragment type interception on each data.
As an optional manner, step S4 is specifically as follows: data enhancement is performed on the training set obtained in step S3 in order to expand the data set by intercepting the sequence prefix, e.g. for session S1=<v1,v2,v3,v4,v5>After data enhancement, 4 conversation sequences are obtained<v1,v2>、<v1,v2,v3>、<v1,v2,v3,v4>、<v1,v2,v3,v4,v5>。
And S5, modeling the purchase data set after the data enhancement into a sequence structure, and then inputting the sequence structure into a Transformer network to obtain a preliminary session vectorization representation data set.
Wherein the step S5 specifically includes steps S51-S52:
s51, modeling the user purchase data set after data enhancement in the step S4 into a sequence structure, inputting the sequence structure into a Transformer model, and obtaining vectorization representation of each commodity node in the sequence after training; the vectorized representation of each commodity item in the conversation sequence structure represents a vector representation of an item randomly initialized by an Embedding layer.
S52, converting each conversation in the conversation sequenceThe vectorization representation of a commodity node is subjected to a Transformer network, information of adjacent nodes in the sequence is aggregated, and a preliminary session vectorization representation X ═ X is obtained1,x2,…,xn}。
And S6, storing the sessions in the preliminary session vectorization representation data set in a historical session vectorization representation memory.
As an optional manner, step S6 is specifically as follows: storing the preliminary session vectorized representation, denoted M, for subsequent neighborhood information lookup,
Figure BDA0003527707040000061
where P represents the number of sessions in the session dataset,
Figure BDA0003527707040000062
indicating that the ith session is subjected to the data enhancement and then represented by the session vectorization with the length j.
Such as for session s1=<v1,v2,v3,v4,v5>The result of the data enhancement is
Figure BDA0003527707040000071
Figure BDA0003527707040000072
Corresponding to M is
Figure BDA0003527707040000073
S7, for the conversation to be recommended, performing global information modeling by using a Transformer network, performing local information extraction by using a Convolition network, and finally obtaining vectorization expression h of the current conversationcurrent
For each current session to be recommended, a Transformer network is used for global information modeling, a Convolation network is used for local information extraction, and finally vectorization expression h of the current session is obtainedcurrent
S8 forSearching K neighborhood session vectorization representations with highest similarity in the historical session vectorization representation memory, setting a similarity threshold a, generating two vectorization representations of the representation positions by taking the similarity threshold as a boundary, and fusing the vectorization representations with the session vectorization representations of the K neighborhoods through a Transformer network to obtain a vectorization representation h of the neighborhood sessionneighbor
For each current session to be recommended, searching K sessions with the highest similarity in the purchasing sessions in the set M, and sorting the vectorized representations of the K sessions according to the similarity from high to low.
Setting a similarity threshold alpha, taking alpha as a boundary, and dividing K neighborhood sessions into two types. For the vector representation of two kinds of neighborhood sessions, adding different position coding vector representations respectively, sending the two kinds of vector representations into a Transformer network, carrying out vectorization representation modeling, and generating a final neighborhood vectorization representation hneighbor
For example, for a neighborhood session vector<v1,v2,v3,v4,v5>Their similarity is<0.9,0.8,0.6,0.3,0.1>If the similarity threshold is 0.5, the position code vector with the similarity higher than the threshold is k, and the position code vector with the similarity lower than the threshold is p, the updated neighborhood session vector is<1+k,v2+k,v3+k,v4+p,v5+p>And sending the updated neighborhood session vector to a Transformer network to generate a final neighborhood vectorization representation.
S9, representing the current session vector as hcurrentAnd neighborhood session vector representation hneighborAnd connecting the two layers together through a fusion layer to obtain the final session vectorization representation.
Specifically, the current session vectorization representation and the neighborhood session vectorization representation are connected to obtain a final session vectorization representation z:
z=αhcurrent+(1-a)hneighbor
wherein the parameter α ═ σ (W)1hcurrent+W2hneighbor) σ stands for sigmoid function, W1,W2Can trainAnd (5) training model parameters.
And S10, calculating cosine similarity between the final session vectorization representation and all the items in the session data set, and taking the item with the highest similarity as a recommendation result.
After the final session vectorization representation is obtained, calculating a similarity score value of the final session vectorization representation and the article vectorization representation X as a recommendation basis, wherein the similarity score value is calculated as follows:
Value=softmax(zTx)
wherein T represents a vector transpose; the K items with the highest scores form the final recommended item list.
In summary, compared with the prior art, the method of the present embodiment has the following advantages and beneficial effects:
the method of the embodiment can effectively capture consumption patterns of similar users by representing and storing the historical conversation of the historical purchasing behavior of the users and using the historical purchasing conversation as the cooperative information, and meanwhile, when recommending is carried out to the current user, the user behavior with the same preference as that of the current user in the historical conversation is considered, and the neighborhood conversation information is extracted; the neighborhood session information and the current session information are aggregated to give a recommendation result, so that the real requirements of the user can be more effectively predicted by a new recommendation algorithm, and a more accurate recommendation result is given.
The present embodiment further provides a session recommendation system, including:
the data acquisition module is used for acquiring a session data set of a user on the E-commerce platform, wherein the session data set comprises article information, a user purchase timestamp and a user purchase behavior;
the data enhancement module is used for carrying out data enhancement on the session data set;
the vector extraction module is used for modeling the session data set subjected to data enhancement into a sequence structure and inputting the sequence structure into a Transformer network to obtain a preliminary session vectorization representation data set;
a data storage module, configured to store the sessions in the preliminary session vectorization representation dataset in a historical session vectorization representation memory;
a session internal modeling module used for modeling global information by using a Transformer network, extracting local information by using a Convolition network and finally obtaining a vectorization expression h of the current sessioncurrent
A session neighborhood modeling module for searching the vectorized representation of K neighborhood sessions with the highest similarity in the historical session vectorized representation memory, then setting a similarity threshold a, taking the similarity threshold as a boundary, generating two vectorized representations of the representation positions, and fusing the vectorized representations of the two representation positions with the vectorized representation of the K neighborhood sessions through a Transformer network to obtain a neighborhood session vectorized representation hneighbor
A vector fusion module for representing the current session vector as hcurrentAnd neighborhood session vector representation hneighborConnecting the conversation vectorization representation through a fusion layer to obtain a final conversation vectorization representation;
and the recommendation calculation module is used for calculating the cosine similarity of the final session vectorization representation and all the articles in the session data set, and taking the article with the highest similarity as a recommendation result.
The session recommendation system of the embodiment can execute the session recommendation method provided by the method embodiment of the invention, can execute any combination of the implementation steps of the method embodiment, and has corresponding functions and beneficial effects of the method.
The present embodiment further provides a session recommendation apparatus, including:
at least one processor;
at least one memory for storing at least one program;
when executed by the at least one processor, cause the at least one processor to implement the method of fig. 1.
The session recommendation device of the embodiment can execute the session recommendation method provided by the method embodiment of the invention, can execute any combination of the implementation steps of the method embodiment, and has corresponding functions and beneficial effects of the method.
Embodiments of the present application also disclose a computer program product or computer program comprising computer instructions stored in a computer readable storage medium. The computer instructions may be read by a processor of a computer device from a computer-readable storage medium, and executed by the processor to cause the computer device to perform the method illustrated in fig. 1.
The embodiment also provides a storage medium, which stores an instruction or a program capable of executing the session recommendation method provided by the embodiment of the method of the present invention, and when the instruction or the program is executed, the method can be executed by any combination of the embodiment of the method, and the method has corresponding functions and advantages.
In alternative embodiments, the functions/acts noted in the block diagrams may occur out of the order noted in the operational illustrations. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality/acts involved. Furthermore, the embodiments presented and described in the flow charts of the present invention are provided by way of example in order to provide a more thorough understanding of the technology. The disclosed methods are not limited to the operations and logic flows presented herein. Alternative embodiments are contemplated in which the order of various operations is changed and in which sub-operations described as part of larger operations are performed independently.
Furthermore, although the present invention is described in the context of functional modules, it should be understood that, unless otherwise stated to the contrary, one or more of the described functions and/or features may be integrated in a single physical device and/or software module, or one or more functions and/or features may be implemented in a separate physical device or software module. It will also be understood that a detailed discussion of the actual implementation of each module is not necessary for an understanding of the present invention. Rather, the actual implementation of the various functional modules in the apparatus disclosed herein will be understood within the ordinary skill of an engineer, given the nature, function, and internal relationship of the modules. Accordingly, those skilled in the art can, using ordinary skill, practice the invention as set forth in the claims without undue experimentation. It is also to be understood that the specific concepts disclosed are merely illustrative of and not intended to limit the scope of the invention, which is defined by the appended claims and their full scope of equivalents.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
The logic and/or steps represented in the flowcharts or otherwise described herein, e.g., an ordered listing of executable instructions that can be considered to implement logical functions, can be embodied in any computer-readable medium for use by or in connection with an instruction execution system, apparatus, or device, such as a computer-based system, processor-containing system, or other system that can fetch the instructions from the instruction execution system, apparatus, or device and execute the instructions. For the purposes of this description, a "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transport the program for use by or in connection with the instruction execution system, apparatus, or device.
More specific examples (a non-exhaustive list) of the computer-readable medium would include the following: an electrical connection (electronic device) having one or more wires, a portable computer diskette (magnetic device), a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). Additionally, the computer-readable medium could even be paper or another suitable medium upon which the program is printed, as the program can be electronically captured, via for instance optical scanning of the paper or other medium, then compiled, interpreted or otherwise processed in a suitable manner if necessary, and then stored in a computer memory.
It should be understood that portions of the present invention may be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, the various steps or methods may be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, any one or combination of the following techniques, which are known in the art, may be used: a discrete logic circuit having a logic gate circuit for implementing a logic function on a data signal, an application specific integrated circuit having an appropriate combinational logic gate circuit, a Programmable Gate Array (PGA), a Field Programmable Gate Array (FPGA), or the like.
In the foregoing description of the specification, reference to the description of "one embodiment/example," "another embodiment/example," or "certain embodiments/examples," etc., means that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the invention. In this specification, schematic representations of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples.
While embodiments of the present invention have been shown and described, it will be understood by those of ordinary skill in the art that: various changes, modifications, substitutions and alterations can be made to the embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the claims and their equivalents.
While the preferred embodiments of the present invention have been illustrated and described, it will be understood by those skilled in the art that various changes in form and details may be made therein without departing from the spirit and scope of the invention as defined by the appended claims.

Claims (10)

1. A conversation recommendation method, comprising the steps of:
acquiring a session data set of a user on an e-commerce platform, wherein the session data set comprises article information, a user purchase timestamp and a user purchase behavior;
performing data enhancement on the session data set;
modeling a session data set subjected to data enhancement into a sequence structure, and inputting the sequence structure into a Transformer network to obtain a preliminary session vectorization representation data set;
storing the sessions in the preliminary session vectorization representation dataset in a historical session vectorization representation memory;
performing global information modeling by using a Transformer network, and performing local information extraction by using a Convolation network to obtain vectorization expression h of the current sessioncurrent
Searching the vectorization representation of K neighborhood sessions with highest similarity in the historical session vectorization representation memory, setting a similarity threshold a, generating the vectorization representation of two representation positions by taking the similarity threshold as a boundary, and fusing the vectorization representation of the K neighborhood sessions with the vectorization representation of the K neighborhood sessions through a Transformer network to obtain a neighborhood session vectorization representation hneighbor
Representing the current session vector as hcurrentAnd neighborhood session vector representation hneighborConnecting the conversation vectorization representation through a fusion layer to obtain a final conversation vectorization representation;
and calculating the final session vectorization representation, calculating cosine similarity with all the articles in the session data set, and taking the article with the highest similarity as a recommendation result.
2. The method of claim 1, further comprising a step of preprocessing the session data set after obtaining the session data set, comprising:
sequencing the conversation data according to the time stamp to obtain a conversation sequence which is sequenced according to time, removing the conversation which is clicked once, and deleting the click item with too low frequency of occurrence;
wherein, each item of the session data comprises the serial number item _ id of the commodity and the time stamp of the commodity being clicked.
3. The conversation recommendation method according to claim 2, wherein said sorting conversation data according to time stamp to obtain a time-sorted conversation sequence comprises:
acquiring N session data from the session data set, wherein s represents a session, v represents a clicked commodity item, all commodity items v in the session are sorted according to the time stamp _ stamp of the clicked commodity, and a session sequence can be represented as s ═ s<v1,v2,v3…vc>And the subscript c of v is used for distinguishing the order of clicking the commodities.
4. The method of claim 1, wherein the modeling the data-enhanced session data set into a sequence structure and inputting the sequence structure into a Transformer network to obtain a preliminary session vectorization representation data set comprises:
modeling the click data set after data enhancement into a sequence structure, inputting the sequence structure into a transform model, and obtaining vectorization representation of each commodity in a conversation sequence after training; vectorization representation of each node in the conversation sequence represents vector representation X of one commodity after the characteristics of other commodities in the sequence are integrated<x1,x2,x3…xn>;
The vectorization representation of all commodity nodes in the conversation sequence is averaged to obtain the vectorization representation of each conversation, and the conversation s is equal to the conversation s<v1,v2,v3…vn>Wherein n is the number of commodities included in the session s, and the preliminary session vectorization is represented as: x ═ X1,x2,…,xn}。
5. The method according to claim 1, wherein the storing the sessions in the preliminary session-vectorization-representation dataset in a historical session-vectorization-representation memory comprises:
storing a session vectorization representation of user consumption behavior in the preliminary session vectorization representation dataset, the set denoted as M, for subsequent domain information lookup,
Figure FDA0003527707030000021
where p represents the number of sessions in the user's purchase session data set, t represents the length of the session,
Figure FDA0003527707030000022
indicating a session vectorized representation of length j after the above-described data enhancement at the ith session.
6. The method of claim 1, wherein the final session vectorization representation z comprises the following expression:
z=αhcurrent+(1-a)hneighbor
wherein the parameter α ═ σ (W)1hcurrent+W2hneighbor) σ stands for sigmoid function, W1,W2Are model parameters that can be trained.
7. The conversation recommendation method according to claim 1, wherein the cosine similarity is calculated as follows:
Value=softmax(zTx)
wherein z is final session vectorization representation, x is article vectorization representation, and T represents vector transposition; the K items with the highest scores form the final recommended item list.
8. A conversational recommendation system, comprising:
the data acquisition module is used for acquiring a session data set of a user on the E-commerce platform, wherein the session data set comprises article information, a user purchase timestamp and a user purchase behavior;
the data enhancement module is used for carrying out data enhancement on the session data set;
the vector extraction module is used for modeling the session data set subjected to data enhancement into a sequence structure and inputting the sequence structure into a Transformer network to obtain a preliminary session vectorization representation data set;
a data storage module, configured to store the sessions in the preliminary session vectorization representation dataset in a historical session vectorization representation memory;
the session internal modeling module is used for carrying out global information modeling by using a Transformer network, carrying out local information extraction by using a Convolation network and finally obtaining vectorization expression h of the current sessioncurrent
A session neighborhood modeling module for searching the vectorized representation of K neighborhood sessions with the highest similarity in the historical session vectorized representation memory, then setting a similarity threshold a, taking the similarity threshold as a boundary, generating two vectorized representations of the representation positions, and fusing the vectorized representations of the two representation positions with the vectorized representation of the K neighborhood sessions through a Transformer network to obtain a neighborhood session vectorized representation hneighbor
A vector fusion module for representing the current session vector as hcurrentAnd neighborhood Session vector representation hneighborConnecting the conversation vectorization representation through a fusion layer to obtain a final conversation vectorization representation;
and the recommendation calculation module is used for calculating the cosine similarity of the final session vectorization representation and all the articles in the session data set, and taking the article with the highest similarity as a recommendation result.
9. A conversation recommendation device, comprising:
at least one processor;
at least one memory for storing at least one program;
when executed by the at least one processor, cause the at least one processor to implement the method of any one of claims 1-7.
10. A computer readable storage medium, in which a program executable by a processor is stored, wherein the program executable by the processor is adapted to perform the method according to any one of claims 1 to 7 when executed by the processor.
CN202210201808.0A 2022-03-02 2022-03-02 Session recommendation method, system, device and storage medium Pending CN114691981A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210201808.0A CN114691981A (en) 2022-03-02 2022-03-02 Session recommendation method, system, device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210201808.0A CN114691981A (en) 2022-03-02 2022-03-02 Session recommendation method, system, device and storage medium

Publications (1)

Publication Number Publication Date
CN114691981A true CN114691981A (en) 2022-07-01

Family

ID=82136676

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210201808.0A Pending CN114691981A (en) 2022-03-02 2022-03-02 Session recommendation method, system, device and storage medium

Country Status (1)

Country Link
CN (1) CN114691981A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115271851A (en) * 2022-07-04 2022-11-01 天翼爱音乐文化科技有限公司 Video color ring recommendation method, system, electronic equipment and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115271851A (en) * 2022-07-04 2022-11-01 天翼爱音乐文化科技有限公司 Video color ring recommendation method, system, electronic equipment and storage medium
CN115271851B (en) * 2022-07-04 2023-10-10 天翼爱音乐文化科技有限公司 Video color ring recommending method, system, electronic equipment and storage medium

Similar Documents

Publication Publication Date Title
Fajtl et al. Summarizing videos with attention
Creswell et al. Inverting the generator of a generative adversarial network
CN111339415B (en) Click rate prediction method and device based on multi-interactive attention network
US11521221B2 (en) Predictive modeling with entity representations computed from neural network models simultaneously trained on multiple tasks
CN112651940B (en) Collaborative visual saliency detection method based on dual-encoder generation type countermeasure network
CN111581966A (en) Context feature fusion aspect level emotion classification method and device
Long et al. Learning to localize actions from moments
CN112784118A (en) Community discovery method and device in graph sensitive to triangle structure
CN115687760A (en) User learning interest label prediction method based on graph neural network
CN113434628A (en) Comment text confidence detection method based on feature level and propagation relation network
Chonwiharnphan et al. Generating realistic users using generative adversarial network with recommendation-based embedding
CN113314188B (en) Graph structure enhanced small sample learning method, system, equipment and storage medium
CN113641811B (en) Session recommendation method, system, equipment and storage medium for promoting purchasing behavior
CN115495654A (en) Click rate estimation method and device based on subspace projection neural network
Umaashankar et al. Atlas: A dataset and benchmark for e-commerce clothing product categorization
Sharma et al. DeepWalk Based Influence Maximization (DWIM): Influence Maximization Using Deep Learning.
CN114691981A (en) Session recommendation method, system, device and storage medium
Bhattacharya et al. A community detection model using node embedding approach and graph convolutional network with clustering technique
CN114862496A (en) Session recommendation method, device and medium based on user personalized modeling
CN116932938A (en) Link prediction method and system based on topological structure and attribute information
CN116541592A (en) Vector generation method, information recommendation method, device, equipment and medium
CN113297385B (en) Multi-label text classification system and method based on improved GraphRNN
Pu et al. Sliced Wasserstein cycle consistency generative adversarial networks for fault data augmentation of an industrial robot
Liu et al. ABSNet: Aesthetics-based saliency network using multi-task convolutional network
CN114519600A (en) Graph neural network CTR estimation algorithm fusing adjacent node variances

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