A conversation recommendation method and system based on collaborative interest and price perception reasoning
By constructing item conversation sequences and price sequences, and using heterogeneous graphs and numerical inference networks for logical queries, the problem of insufficient modeling of user interests and price sensitivity in conversation recommendation is solved, and more accurate recommendation results are achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- SUZHOU UNIV
- Filing Date
- 2026-03-09
- Publication Date
- 2026-06-30
AI Technical Summary
Existing conversational recommendation methods struggle to effectively utilize users' long-term historical behavioral data due to privacy and data compliance constraints. Furthermore, their modeling of price information is insufficient, failing to accurately reflect users' price sensitivity and logical reasoning, resulting in inaccurate recommendation results.
We construct item conversation sequences and price sequences, and perform first-order logical queries on item preferences and price preferences through heterogeneous graphs and numerical reasoning networks, respectively. We aggregate high-order collaborative information using box embedding and logical operations, and combine price numerical logical reasoning to generate the final recommendation results.
In privacy-constrained and dynamically changing conversation recommendation scenarios, it significantly improves recommendation accuracy and ranking quality, and can better reflect users' price sensitivity and interest preferences.
Smart Images

Figure CN122309835A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of intelligent decision-making technology, and in particular to a conversation recommendation method and system based on collaborative interest and price perception reasoning. Background Technology
[0002] In practical applications, due to privacy protection and data compliance requirements, it is often difficult to obtain long-term historical user behavior data, thus limiting traditional personalized recommendation methods that rely on full user profiles. Session-Based Recommendation (SBR) has gained widespread attention in this context. This type of method uses only the limited interactions of a user in the current session to predict their next action, enabling effective recommendations in dynamic and privacy-constrained environments. Existing research generally employs techniques such as recurrent neural networks, attention mechanisms, graph neural networks, and large models to learn users' potential interest patterns from session sequences or session graphs, achieving some success.
[0003] However, most of the methods mentioned above focus on learning similarities or statistical correlations from historical interactions, rarely explicitly characterizing the logical reasoning mechanisms underlying user decision-making. In reality, user choices often depend not only on the similarity to previously interacted items but also on a comprehensive judgment of item attributes and their relationships, with price being particularly crucial. Price is not a static feature but a dynamic variable involved in user comparison and budget assessment; users naturally make numerical judgments such as "Is it too expensive?" or "Are there cheaper alternatives?"
[0004] Existing methods for modeling price information have significant shortcomings. They typically discretize continuous prices into coarse-grained intervals and embed them, disrupting price continuity and subtle differences. This makes it difficult to distinguish between prices with similar numerical values but different semantics, and also fails to accurately reflect users' sensitivity to price changes. In contrast, logical reasoning can directly handle continuous numerical values and express numerical comparison relationships, providing a more natural modeling approach for characterizing user price preferences. However, existing logical recommendation methods often focus on local sequence relationships, neglecting higher-order collaborative information and price numerical reasoning, making it difficult to comprehensively simulate real user decision-making processes. Therefore, there is an urgent need for a new method that can integrate collaborative interest modeling and price numerical logical reasoning in conversational recommendation scenarios. Summary of the Invention
[0005] In view of the aforementioned existing problems, the present invention is proposed.
[0006] To solve the above-mentioned technical problems, the present invention provides the following technical solution:
[0007] In a first aspect, the present invention provides a conversation recommendation method based on collaborative interest and price perception reasoning, which includes constructing an item conversation sequence and a price sequence corresponding to the item conversation sequence based on the user's conversation behavior;
[0008] For first-order logical queries on item preferences and price preferences, define two distinct sets of relations;
[0009] The system uses two channels to reason about item preferences and price preferences respectively, resulting in item preference reasoning results and price preference reasoning results. The set of relationships guides the final recommendation reasoning process through the two channels.
[0010] Based on the results of item preference inference and price preference inference, the candidate items are jointly predicted, and the next recommendation result in the session is output.
[0011] As a preferred embodiment of the conversation recommendation method based on collaborative interest and price perception reasoning described in this invention, the relationship set includes item preference reasoning, and the relationship set is defined as follows: ;
[0012] in, This indicates that the user has interacted with the item; This indicates a predictive relationship with the target.
[0013] Price preference reasoning, defining a set of relations: ;
[0014] in, This indicates that the price is too low and cannot meet user expectations; This indicates that the price is beyond the user's acceptable range.
[0015] As a preferred embodiment of the conversation recommendation method based on collaborative interest and price perception reasoning described in this invention, wherein: during the reasoning process of item preference, a heterogeneous graph containing three types of nodes is constructed. :user ,thing and item categories This makes the set of nodes ;
[0016] Assign triples to each user-item-category The triple is decomposed into three edges: , and This forms the basic connection structure for capturing complex relationships;
[0017] in, Represents the set of edges;
[0018] All types of nodes are uniformly represented as box embeddings, and high-order cooperative signals are aggregated in heterogeneous neighborhoods by using logical intersection and logical union operations.
[0019] Based on the aggregated box embedding representation, the problem of predicting the user's next interactive item is modeled as a first-order logical query. By performing sequential reasoning operations of relation projection, logical intersection and logical union on historical interactive items, the user's historical interaction facts and individual interests are explicitly introduced into the reasoning process, thereby deriving the user's dynamic item preferences in the current session in the logical space.
[0020] As a preferred embodiment of the conversation recommendation method based on collaborative interest and price perception reasoning described in this invention, wherein: the reasoning of price preference adopts a numerical reasoning network framework to model price preferences with logical constraints;
[0021] set up Represents a set of numbers. To represent a specific numerical value. Represents an entity set;
[0022] Using the numerical projection mechanism, the derived value is calculated using the following formula:
[0023]
[0024] in, In relation set Projection operator under constraints;
[0025] Before performing price preference inference, the original price values are mapped from the real number space to a high-dimensional embedding space through a deterministic numerical encoding function to maintain the continuity and geometric relationship between prices.
[0026] The encoded price embedding is then fused with a learnable embedding representing the price semantic type to form a numerical embedding representation for price reasoning.
[0027] As a preferred embodiment of the conversation recommendation method based on collaborative interest and price perception reasoning described in this invention, the method involves: performing a numerical projection operation on the price numerical embedding and price relation embedding obtained by numerical encoding according to the numerical logic operation of the numerical reasoning network; and fusing the price numerical embedding and the corresponding relation embedding by introducing a gating mechanism to generate numerical projection results representing different price logic semantics.
[0028] The gating mechanism is used to control the degree of influence of relation embedding on price value embedding, so that the numerical projection result can reflect the comparison relationship between prices.
[0029] The numerical projection results obtained based on different price relationships are used as input. The numerical logic intersection operation is performed with the feedforward network through an attention mechanism with permutation invariance to eliminate numerical intervals that do not meet the price preference constraints, thereby obtaining a numerical representation that conforms to the user's price preference.
[0030] As a preferred embodiment of the conversation recommendation method based on collaborative interest and price perception reasoning described in this invention, the joint prediction includes, when generating the final recommendation result, calculating the distance between the target item and the inference box embedding obtained by item preference reasoning as the item preference score.
[0031] The distance includes an external distance term where the target item is outside the reasoning box and an internal distance term where the target item is inside the reasoning box, and the contribution of the internal distance term is adjusted by a preset coefficient.
[0032] Based on the price preference embedding obtained from price preference reasoning, a price sensitivity gating factor generated by user embedding is introduced to scale the similarity between the price embedding of the target item and the price preference embedding to obtain a price preference score;
[0033] The item preference score and the price preference score are weighted and combined to generate a final predicted score for predicting the next recommended item in the session.
[0034] As a preferred embodiment of the conversation recommendation method based on collaborative interest and price perception reasoning described in this invention, the joint prediction further includes, during model training, constructing a recommendation loss function based on the final prediction score to constrain the predicted ranking of the real next interaction item among all candidate items.
[0035] Meanwhile, for price preference reasoning, a price relation constraint loss is introduced to enhance the ability of price relation projection to distinguish between the semantics of price being too high and price being too low, and a price embedding discriminant loss is introduced to enhance the separability between different price embeddings.
[0036] The recommendation loss function is then weighted and fused with the price relationship constraint loss and the price embedding discriminant loss, and used as the final optimization objective for model training.
[0037] Secondly, the present invention provides a conversation recommendation system based on collaborative interest and price perception reasoning, including a collection unit that constructs an item conversation sequence and a price sequence corresponding to the item conversation sequence based on the user's conversation behavior;
[0038] Define the unit, for first-order logical queries on item preferences and price preferences, and define two different sets of relations;
[0039] The reasoning unit, through two channels, infers item preferences and price preferences respectively, to obtain item preference reasoning results and price preference reasoning results; wherein, the relation set, through the two channels, guides the final recommendation reasoning process;
[0040] The prediction unit uses the results of item preference inference and price preference inference to jointly predict candidate items and output the next recommendation result in the session.
[0041] Thirdly, the present invention provides a computer device including a memory and a processor, wherein the memory stores a computer program, wherein: when the computer program is executed by the processor, it implements any step of the conversation recommendation method based on collaborative interest and price-aware reasoning as described in the first aspect of the present invention.
[0042] Fourthly, the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein: when the computer program is executed by a processor, it implements any step of the conversation recommendation method based on collaborative interest and price-aware reasoning as described in the first aspect of the present invention.
[0043] The beneficial effects of this invention are as follows: By constructing the session recommendation process as a logical decision-making process combining collaborative interest reasoning and price-perceived reasoning, this invention achieves a detailed characterization of users' true decision-making behavior using only limited interaction information within the current session. Compared to existing methods that rely solely on similarity or statistical association for recommendations, this invention introduces a first-order logical reasoning mechanism, enabling the recommendation process to explicitly express item attribute relationships and reasoning constraints, thereby improving the rationality and interpretability of the recommendation results. Regarding interest modeling, this invention constructs a heterogeneous structure of users, items, and item categories, aggregates high-order collaborative information, and utilizes box embedding and logical operations to characterize the uncertainty and inclusion relationships of user interests, effectively compensating for the shortcomings of traditional session models in modeling global collaborative signals. Regarding price modeling, this invention employs numerical logical reasoning to directly model continuous prices, avoiding information loss caused by price discretization, and can characterize numerical constraints such as prices being "too high" or "too low," truly reflecting users' price sensitivity. By jointly predicting the results of item preference inference and price preference inference, and introducing multiple constraint loss for collaborative optimization during training, this invention ensures both interest relevance and price acceptability, significantly improving recommendation accuracy and ranking quality. It is particularly suitable for privacy-constrained and dynamically changing conversation recommendation scenarios. Attached Figure Description
[0044] To more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the following description of the embodiments will be briefly introduced. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0045] Figure 1 This is a flowchart of a conversation recommendation method based on collaborative interest and price perception reasoning.
[0046] Figure 2 This is a computational graph for item preference reasoning in a conversational recommendation method based on collaborative interest and price perception reasoning.
[0047] Figure 3 This is a computational graph for price preference inference in a conversation recommendation method based on collaborative interest and price perception. Detailed Implementation
[0048] To make the above-mentioned objects, features and advantages of the present invention more apparent and understandable, the specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings.
[0049] Many specific details are set forth in the following description in order to provide a full understanding of the invention. However, the invention may also be practiced in other ways different from those described herein, and those skilled in the art can make similar extensions without departing from the spirit of the invention. Therefore, the invention is not limited to the specific embodiments disclosed below.
[0050] Secondly, the term "one embodiment" or "embodiment" as used herein refers to a specific feature, structure, or characteristic that may be included in at least one implementation of the present invention. The phrase "in one embodiment" appearing in different places in this specification does not necessarily refer to the same embodiment, nor is it a single or selective embodiment that is mutually exclusive with other embodiments.
[0051] Example 1, referring to Figures 1-3 This is one embodiment of the present invention, which provides a conversation recommendation method based on collaborative interest and price-aware reasoning, including the following steps:
[0052] S1: Based on the user's session behavior, construct an item session sequence and a price sequence corresponding to the item session sequence.
[0053] Consider a session-based recommendation scenario, where each session , represents a user Interactive A conversation sequence for each item, and its corresponding price sequence. This represents the specific price value of each item. The entire set is defined as the set of items ( ),user Item categories and price ,in Indicates the total number of items in the collection. This represents the total number of users in the user set. This represents the total number of categories in the set of item categories. This indicates the number of different price values in the price set.
[0054] Where u represents the user who initiated the session; These represent the n item entities that the user interacted with in the current session in chronological order. These represent the specific price values of each item that the user interacts with sequentially during the session.
[0055] S2: First-order logical queries on item preferences and price preferences, defining two distinct sets of relations.
[0056] Following the paradigm of logical reasoning in knowledge graphs, the recommendation problem is expressed as two logical queries that answer item preferences and price preferences, and these two queries jointly guide the final recommendation.
[0057] Two distinct sets of relations are defined for these two types of preference-based first-order logic queries.
[0058] The set of relationships includes item preference reasoning, and the set of relationships is defined as follows: ;
[0059] in, This indicates that the user has interacted with the item; Representing the predictive relationship for the target; price preference inference, defining the set of relationships: ;
[0060] in, This indicates that the price is too low and cannot meet user expectations; This indicates that the price is beyond the user's acceptable range.
[0061] S3: Reasoning is performed on item preferences and price preferences through two channels to obtain item preference reasoning results and price preference reasoning results; wherein, the set of relationships guides the reasoning process of the final recommendation through the two channels.
[0062] (1) Item preference reasoning
[0063] Traditional logical reasoning methods that rely solely on sequential interaction patterns suffer from limited information content because they fail to capture neighborhood knowledge and higher-order cooperation signals. To address this limitation, a heterogeneous graph is constructed to aggregate these valuable signals, thereby enhancing the initial logical embedding.
[0064] Heterogeneous graph construction: A heterogeneous graph containing three node types was constructed. :user ,thing and item categories , making Assign a triple to each user-item-category. This triplet is decomposed into three edges: , and ,in, This represents the set of edges; thus forming the basic connection structure that captures complex relationships. The construction process of this heterogeneous graph is as follows: Figure 1 The leftmost part is shown.
[0065] By unifying the representation of various nodes as box embeddings and using logical intersection and logical union operations, high-order cooperative signals are aggregated in heterogeneous neighborhoods, enabling user interest representations to simultaneously possess uncertainty expression capabilities and cooperative semantics, thereby compensating for the lack of neighborhood information caused by relying solely on session sequences.
[0066] Based on the aggregated box embedding representation, the problem of predicting the user's next interactive item is modeled as a first-order logical query. By performing sequential reasoning operations of relation projection, logical intersection and logical union on historical interactive items, the user's historical interaction facts and individual interests are explicitly introduced into the reasoning process, thereby deriving the user's dynamic item preferences in the current session in the logical space.
[0067] It's worth noting that box embedding is an existing representation technique used to model or query axis-aligned hyperrectangles in a continuous vector space. In traditional embeddings, each entity or query is represented as a vector where each dimension is a single point. Unlike traditional embeddings, each dimension of a box embedding is defined by its minimum and maximum boundaries, allowing it to naturally express uncertainty, inclusion, and logical relationships. Formally, a box embedding... Through a fundamental center vector and positive offset vector To parameterize. A box embedding can be defined as... :
[0068]
[0069] in, Indicates the embedding dimension. Inequalities at the dimensional level. Indicates the center of the box It determines the size of the box boundary. Represents a D-dimensional real vector space; Let represent a D-dimensional non-negative real vector space. Let v represent the geometric region corresponding to the box embedding b. Let v ∈ ℝᴰ represent any vector point in the embedding space.
[0070] Query Definition: Following the CBox4CR approach, the task of predicting the next item that user u will interact with is considered a logical query. However, unlike objective tasks such as object detection where the true value is independent of user preferences, recommendations must consider user-specific subjective interests. One user may be interested in all items, while another may only be interested in a subset. Since logical queries in CBox4CR do not explicitly incorporate such specific user interests, the query is redefined by integrating user interests: "ordered chronologically with item 1, item 2, ..., item..." What items will users who have already interacted with the app, or users based on their interests, interact with next? The corresponding logical queries and their computation graphs are as follows: Figure 2 As shown.
[0071] Specifically, in the item preference reasoning module, the following operations are performed:
[0072] 1.1 Box-based graph neural network aggregation:
[0073] After constructing the heterogeneous graph, the representations of all nodes are initialized as box embeddings instead of point embeddings. Therefore, traditional operators such as addition and multiplication become inapplicable. Due to the effectiveness of BoxGNN in label recommendation, its corresponding two logical operations, intersection and union, are used to aggregate the representations.
[0074] 1.1.1 Box logic operations for aggregation:
[0075] Intersection: Given a set of box embeddings , This represents the embedding of the nth interactive entity; the intersection operation produces a combo box. ,in This represents the intersection box. The center and offset are calculated as follows:
[0076]
[0077]
[0078]
[0079] in, This indicates multiplication by dimension. It is a multilayer perceptron. and Both are minimum sum-of-dimensional functions. k and j are indices of the box embedding.
[0080] Union: Similarly, the union operation generates a new box. ,in The center and offset are calculated as follows:
[0081]
[0082]
[0083]
[0084] in, This indicates multiplication by dimension. It is a multilayer perceptron. and They are all minimum sum-exponential functions at the dimensional level.
[0085] These logical operators play different but complementary roles in recommender systems. The intersection operator preserves the overlapping areas between multiple boxes, capturing their common attributes and features. Conversely, the union operation preserves information from all boxes, enabling the aggregate representation to fully integrate the different features from multiple boxes.
[0086] 1.1.2 Box logic operations for aggregation:
[0087] User-aware aggregation: User modeling is the core of recommender systems. It processes two neighbor types separately: category and item, and then combines their semantic representations.
[0088]
[0089]
[0090] in, Indicates the first aggregation from adjacent nodes Layer user embedding vector. and Representing users respectively Neighbors by category and neighbor by item. This represents the box embedding representation of the e-th item's neighbor at level l. Let represent the box embedding representation of the e-th class neighbor at layer l. Under the neighbor type of an item, the first node aggregated from adjacent nodes Layer user embedding vector; Under the neighbor type representing the category, the first node aggregated from adjacent nodes Layer user embedding vector.
[0091] On the one hand, item categories, representing users' explicit interests, can be aggregated through union operations to capture users' diverse interests. On the other hand, applying intersection operations to items that users have historically interacted with helps to extract their common characteristics, thereby revealing users' potential implicit preferences.
[0092] Category-aware aggregation: Categories, as supplementary information, can enrich the embedded representations of users and items, requiring the fusion of these two perspectives:
[0093]
[0094]
[0095] in, Indicates the first aggregation from adjacent nodes Each category embedding vector. and Representing categories The system identifies item neighbors and user neighbors. Since each category can be assigned to multiple users and items, an intersection operation is used to extract shared user interests and item characteristics.
[0096] Item perception aggregation: Aggregating information about items based on both category and user:
[0097]
[0098]
[0099] Indicates the first aggregation from adjacent nodes Each item embedding vector. and Representing items The system considers user neighbors and category neighbors. Since category is an inherent characteristic of items, a union operation is used to aggregate category information. In user modeling, different users may interact with the same item for different motivations. Therefore, a union operation is used to capture this diversity of intentions. Furthermore, the resulting item box volume can serve as an indicator of item popularity. Specifically, under the union operation, the item box volume increases as the number of users who purchase the item increases, thus reflecting its popularity.
[0100] Stacked After the layers, the final box representation for downstream prediction tasks is obtained. and .
[0101] and These are all user representations and item representations obtained after multi-layer graph network aggregation.
[0102] 1.2 First-order logical reasoning based on item preferences:
[0103] Based on the established aggregation box embedding, sequential first-order logical reasoning is used to further perceive and infer users' potential preferences.
[0104] 1.2.1 Box logic operations used for reasoning:
[0105] Based on the logical operations in Query2box and RotatE-Box, these operators are defined as follows:
[0106] Projection: For each relation ,in Define a corresponding projection operator whose relational embedding is as follows: ,in Given an input box embedding The projection operation involves the following steps:
[0107]
[0108] Intersection: To merge multiple box embeddings An intersection operation is used to generate a conjunction box. :
[0109]
[0110]
[0111]
[0112] in, This indicates element-wise multiplication. It is the sigmoid function. The hidden layer dimensions of both multilayer perceptrons (MLPs) are the same as the input embedding size. A permutation-invariant architecture was implemented:
[0113]
[0114] Union: Similarly, since the union operation has permutation invariance, it can be modeled as follows:
[0115]
[0116]
[0117] in It is a permutation-invariant set function (e.g., taking the minimum, maximum, or average value element by element), MLP is a multilayer perceptron. and This represents a learnable linear transformation matrix.
[0118] 1.2.2 Item Preference FOL Inference:
[0119] The complete reasoning process consists of four steps, following Figure 2 The calculation diagram shown:
[0120] Projection: After aggregation using a graph neural network based on box embeddings, the user's... Box embeddings corresponding to item IDs in an interaction sequence are represented as follows: (In the model, an item is represented by a d-dimensional box embedding, therefore the same character as the item is used to represent the item's box embedding, as the same object in different models.) Each box embedding... Defined as .application relation To obtain by projection Each user box. Specifically, calculated as Each resulting box encapsulates a set of user preferences associated with the corresponding interactive item.
[0121] Intersection: Using the intersection operation to... One projection user box Combined to obtain a conjunctive preference representation .
[0122] Predictive projection: applications relation Projection to generate inference boxes: This includes features of potentially interesting items. Additionally, relational projection is applied to predict the current user. Interests: .
[0123] Disjunction: To incorporate specific user interests beyond those extracted from short-term sequences, a union operation is finally performed on the projected user boxes and inferred item boxes to predict the box embedding of the next item, i.e. .
[0124] (2) Price preference reasoning:
[0125] For price preferences, given the inherent need for deterministic and continuous representation of price attributes, a numerical reasoning network (NRN) framework is used to model price preferences with logical constraints. Let... Represents a set of numbers. To represent a specific numerical value. Represents an entity set. Based on numerical relationships. These relationships express numerical constraints for evaluating whether two values satisfy specific conditions, such as or The derived value is calculated using the numerical projection mechanism through the following formula:
[0126]
[0127] This framework supports structured reasoning on numerical relationships, enabling models to semantically enrich numerical price values while maintaining numerical consistency, thus achieving accurate price preference modeling.
[0128] Query Definition: Users generally perceive a low price as indicating poor quality, while a high price may exceed their budget. Traditional price modeling methods are superficial compared to logical reasoning because they often lack continuous price modeling and cannot perform such numerical comparisons. Furthermore, existing logical reasoning frameworks in recommender systems ignore key price factors. To overcome these limitations, numerical logical reasoning is used to filter unacceptable price ranges, and a new price preference reasoning query is defined. For price preference modeling, the following problem is addressed: "Given a user and an item..." To items Given the user's historical interaction prices, what is the appropriate price for the next interactive item, so that the price is neither too expensive nor too cheap based on the user's historical interaction price preferences? The corresponding logical query and its calculation graph are shown below. Figure 3 As shown.
[0129] Before performing price preference reasoning, the original price values are mapped from the real number space to a high-dimensional embedding space through a deterministic numerical encoding function to maintain the continuity and geometric relationship between prices. The encoded price embeddings are then fused with learnable embeddings that represent the semantic type of prices to form a numerical embedding representation for price reasoning.
[0130] Specifically, the implementation process in the price preference inference module is as follows:
[0131] Meanwhile, to capture users' price sensitivity, this module derives a precise price preference range from historical price series using a structured computational graph. This logical reasoning method enables the model to dynamically infer the price threshold acceptable to users for subsequent recommendations.
[0132] 2.1 Numerical Encoding
[0133] Directly using raw numerical values as input to the inference model is often not the optimal choice. Inspired by the effectiveness of Numerical Relationship Networks (NRNs) in numerical reasoning of knowledge graphs, this paper adopts their static encoding scheme to extract raw numerical values from the set of real numbers. Mapped to 3D space This numerical encoding function is denoted as... This is achieved through the following two deterministic coding methods:
[0134] DICE is a deterministic, corpus-independent numerical embedding method that first embeds values... Linear mapping to an angle Then, according to the following formula... Transformation from polar coordinates to Cartesian coordinates in 3D space:
[0135]
[0136] The sine coding scheme was originally introduced in the Transformer for marking positions. It also applies to numerical values and uses the following formula:
[0137]
[0138] As deterministic functions, they map values from the original space to the embedded space, thus preserving geometric properties. sin is the sine function, cos is the cosine function, mod is the remainder calculation, and d is a dimension of the D-dimensional space.
[0139] 2.2 Numerical Reasoning Logic Operations:
[0140] Based on the numerical logical operations in NRN, these operators are defined as follows:
[0141] Projection: Current price series One of the prices and each relationship By projection function To achieve representation transformation, learning is achieved through gating transformation during training:
[0142]
[0143] in, For numerical embedding representation, This indicates the embedding of numerical relationships. This represents the sigmoid activation function. This represents the hyperbolic tangent function. This indicates element-wise multiplication. All and Matrix and bias vector These are all learnable parameters.
[0144] Intersection: A self-attention network followed by a feedforward network is used to implement the permutation-invariant function. Assume that... Numerical embedding representation As input for logical operations. Their intersection. The formal definition is as follows:
[0145]
[0146] in, This is used to project the input into the Query, Key, and Value representations of the attention module, which implements a scaled dot product attention mechanism. T represents the transpose of the representation. It is a numerical embedding representation The result of taking the intersection. Here... N represents a layer of a multilayer perceptron with the GELU activation function, and the summation operation aggregates the transformed representations of all input elements.
[0147] 2.3 Price Preference FOL Inference:
[0148] The complete reasoning process consists of three steps, following... Figure 3 The calculation diagram shown:
[0149] Numerical encoding: given ,in Using a static numerical encoding method, the original numerical values are converted from... Mapped to -Dimensional Space This mapping is formally determined by the encoding function. This indicates that numerical queries typically require not only the quantitative value implicitly, but also its associated semantic type or unit of measurement (e.g., US dollars). To capture this information, learnable embeddings are used. This is used to model the distribution of "price" type items in the numerical space. The resulting price embedding combines this static encoding with distribution modeling of a specific type:
[0150]
[0151] Projection: For price series Applying the projection function and ,in and They represent and Relational embedding.
[0152] Intersection operation: To find price series that are below historical price values Series and price series above historical price values To combine them, first connect them, then apply the intersection operation to extract price preferences that are neither too expensive nor too cheap. .
[0153] S4: Based on the results of item preference inference and price preference inference, perform joint prediction on candidate items and output the next recommendation result in the session.
[0154] The joint prediction includes, when generating the final recommendation result, calculating the distance between the target item and the inference box embedding obtained from item preference reasoning as the item preference score.
[0155] The distance includes an external distance term where the target item is outside the reasoning box and an internal distance term where the target item is inside the reasoning box, and the contribution of the internal distance term is adjusted by a preset coefficient.
[0156] Specifically, let's set For box embeddings derived from item preference inference, from the inference box embeddings Embedded into the target item box distance The definition is as follows:
[0157]
[0158] in, It is a fixed coefficient used to determine the contribution of the internal distance. The definitions of external distance and internal distance are as follows:
[0159]
[0160]
[0161] in, and These represent the maximum and minimum angles of the inference box, respectively. The distance between the corresponding entity and the nearest corner / side of the bounding box. Similarly, The distance between the center of the corresponding box and its edges / corners (or the entity itself if it is inside the box). This indicates that the maximum value is taken at the dimension level.
[0162] Based on the price preference embedding obtained from price preference reasoning, a price sensitivity gating factor generated by user embedding is introduced to scale the similarity between the price embedding of the target item and the price preference embedding, thereby obtaining a price preference score.
[0163] Price sensitivity is calculated as follows:
[0164]
[0165] in, Represents the user box embedding center vector. and These are learnable parameters. This represents the sigmoid function. The threshold value is... This represents a user's price sensitivity; values close to 0 indicate insensitivity, while values close to 1 indicate high price sensitivity. Let... Embed the vector of the results obtained from price inference. For target products The price embedding vector is then used. The price score is obtained by scaling the dot product with a user gate threshold.
[0166]
[0167] The item preference score and the price preference score are weighted and combined to generate a final predicted score for predicting the next recommended item in the session.
[0168]
[0169] in, It is a learnable weight that can dynamically adjust the contribution of price preferences.
[0170] During model training, a recommendation loss function is constructed based on the final prediction score to constrain the predicted ranking of the real next interactive item among all candidate items. Simultaneously, for price preference reasoning, a price relationship constraint loss is introduced to enhance the ability of price relationship projection to distinguish between the semantics of excessively high and excessively low prices, and a price embedding discriminative loss is introduced to enhance the separability between different price embeddings. The recommendation loss function, the price relationship constraint loss, and the price embedding discriminative loss are then weighted and fused as the final optimization objective for model training.
[0171] Specifically, the recommendation loss is as follows: To learn logical embeddings and logical operators, the cross-entropy on the final prediction score is utilized:
[0172]
[0173] in, Indicates the batch size. Indicates the next actual item. It is the total number of all items. It is an item The corresponding price is embedded.
[0174] Price loss: In order for numerical relationship projections to capture and The semantics of relational loss are defined as follows:
[0175]
[0176]
[0177]
[0178] in, Anchor embedding refers to the embedding representation of the median price after the price series is sorted in ascending order in each interactive session. It is by... and It is obtained by projecting the relation. It is by... and It is obtained by projecting the relation. It is the intersection of all embedded representations below the median price. It is the intersection of all embedded representations above the median price. Define a function using the L2 norm Distance metric. It is a margin parameter used to control the degree of separation between positive and negative sample pairs.
[0179] To better learn price representations and enhance the distinguishability between different price embeddings, cross-entropy loss is applied to all price embeddings. Therefore, the formula for price loss is:
[0180]
[0181] in It refers to the batch size. It is the total of all prices.
[0182] The final loss is defined as follows:
[0183]
[0184] in, These are the fixed coefficients of the price loss function during training.
[0185] This embodiment also provides a conversation recommendation system based on collaborative interest and price-aware reasoning, including:
[0186] The data acquisition unit constructs an item session sequence and a price sequence corresponding to the item session sequence based on the user's session behavior.
[0187] Define the unit, and for first-order logical queries on item preferences and price preferences, define two different sets of relations.
[0188] The reasoning unit, through two channels, infers item preferences and price preferences respectively, to obtain item preference reasoning results and price preference reasoning results; wherein, the relation set, through the two channels, guides the reasoning process for the final recommendation.
[0189] The prediction unit uses the results of item preference inference and price preference inference to jointly predict candidate items and output the next recommendation result in the session.
[0190] This embodiment also provides a computer device applicable to the conversation recommendation method based on collaborative interest and price perception reasoning, comprising: a memory and a processor; the memory is used to store computer-executable instructions, and the processor is used to execute the computer-executable instructions to implement the conversation recommendation method based on collaborative interest and price perception reasoning as proposed in the above embodiment.
[0191] The computer device can be a terminal, comprising a processor, memory, communication interface, display screen, and input devices connected via a system bus. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, carrier networks, NFC (Near Field Communication), or other technologies. The display screen can be an LCD screen or an e-ink screen. The input devices can be a touch layer covering the display screen, buttons, a trackball, or a touchpad on the computer device's casing, or an external keyboard, touchpad, or mouse.
[0192] This embodiment also provides a storage medium storing a computer program that, when executed by a processor, implements the conversation recommendation method based on collaborative interest and price perception reasoning as proposed in the above embodiments. The storage medium can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as Static Random Access Memory (SRAM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Erasable Programmable Read Only Memory (EPROM), Programmable Red-Only Memory (PROM), Read-Only Memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.
[0193] Example 2 is an embodiment of the present invention. In order to verify the beneficial effects of the present invention, scientific demonstration is carried out through economic benefit calculation and simulation experiment.
[0194] To evaluate the model's performance, the method was evaluated on three real-world e-commerce datasets.
[0195] The datasets are Electronics, Multi-category, and Cosmetics, and detailed information about the datasets is shown in Table 1.
[0196] Table 1. Statistical Information of Real-World E-commerce Datasets
[0197] Dataset Item count Number of users Number of species Price Number Number of sessions Number of interactions average length Electronics 1179 13158 141 1021 16350 48058 2.94 Multi-category 5221 212291 260 2776 377471 1091354 2.89 Cosmetics 23194 93665 301 1113 156922 1058263 6.74
[0198] Recommendation Performance Comparison: To evaluate model performance, two widely used ranking metrics were employed: Precision (Precision@K, P@k) measures the proportion of correctly predicted cases across all cases, and Standardized Discounted Cumulative Return (NDCG@K, N@K) measures ranking quality. Higher values for these metrics indicate better recommendation accuracy. For more robust and reliable evaluation, all methods were trained and evaluated multiple times, and the average results were reported. Specific recommendation performance is shown in the table below (underlined results represent suboptimal outcomes, bolded results represent model performance). As can be seen, our method's logical reasoning framework achieved better performance than other compared models.
[0199] Table 2. Performance comparison of each recommendation model on the Electronics and Multi-category datasets.
[0200]
[0201] Table 3. Performance comparison of each recommendation model on the Cosmetics dataset.
[0202]
[0203] The results in the table show that, on three real-world e-commerce datasets, the proposed conversation recommendation method based on collaborative interest and price-aware reasoning achieves optimal or significantly leading performance across all evaluation metrics. On the Electronics and Multi-category datasets, compared to recurrent neural networks, graph neural networks, attention mechanisms, and existing logical reasoning models, this invention achieves stable improvements in metrics such as P@10, NDCG@10, P@20, and NDCG@20, demonstrating that the proposed reasoning framework can simultaneously improve recommendation performance in terms of both accuracy and ranking quality.
[0204] Of particular note is that, compared to existing logical reasoning methods (such as CBox4CR and FuzzCR), this invention demonstrates significant advantages on all datasets, indicating that combining high-order collaborative interest modeling with price numerical logical reasoning can effectively compensate for the lack of information inherent in reasoning based solely on local sequence logic. In the Electronics and Multi-category datasets, this invention achieves a performance improvement of approximately 2%–4% over suboptimal models, demonstrating stable improvement in medium-scale and multi-category scenarios.
[0205] In the Cosmetics dataset, a scenario characterized by long session lengths, significant price differences, and more complex user decisions, the advantages of this invention are particularly prominent, achieving significant improvements in both Precision and NDCG metrics, with the highest improvement exceeding 15%.
[0206] The results show that the present invention, by explicitly modeling price continuity and user price sensitivity, can better characterize user behavior in complex decision-making scenarios.
[0207] In summary, the experimental results fully verify the effectiveness and robustness of the present invention under different scales, product categories, and price distribution scenarios, and demonstrate the significant advantages of the recommendation mechanism that combines collaborative interest reasoning and price-aware logic reasoning in practical applications.
[0208] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.
Claims
1. A conversation recommendation method based on collaborative interest and price-perceived reasoning, characterized in that: This includes constructing an item session sequence and a price sequence corresponding to the item session sequence based on the user's session behavior; For first-order logical queries on item preferences and price preferences, define two distinct sets of relations; The system uses two channels to reason about item preferences and price preferences respectively, resulting in item preference reasoning results and price preference reasoning results. The set of relationships guides the final recommendation reasoning process through the two channels. Based on the results of item preference inference and price preference inference, the candidate items are jointly predicted, and the next recommendation result in the session is output.
2. The conversation recommendation method based on collaborative interest and price-perceived reasoning as described in claim 1, characterized in that: The set of relationships includes item preference reasoning, and the set of relationships is defined as follows: ; in, This indicates that the user has interacted with the item; This indicates a predictive relationship with the target. Price preference reasoning, defining a set of relations: ; in, This indicates that the price is too low and cannot meet user expectations; This indicates that the price is beyond the user's acceptable range.
3. The conversation recommendation method based on collaborative interest and price perception reasoning as described in claim 2, characterized in that: In the reasoning process of the item preference, a heterogeneous graph containing three node types is constructed. :user ,thing and item categories This makes the set of nodes ; Assign triples to each user-item-category The triple is decomposed into three edges: , and This forms the basic connection structure for capturing complex relationships; in, Represents the set of edges; All types of nodes are uniformly represented as box embeddings, and high-order cooperative signals are aggregated in heterogeneous neighborhoods by using logical intersection and logical union operations. Based on the aggregated box embedding representation, the problem of predicting the user's next interactive item is modeled as a first-order logical query. By performing sequential reasoning operations of relation projection, logical intersection and logical union on historical interactive items, the user's historical interaction facts and individual interests are explicitly introduced into the reasoning process, thereby deriving the user's dynamic item preferences in the current session in the logical space.
4. The conversation recommendation method based on collaborative interest and price perception reasoning as described in claim 3, characterized in that: The reasoning of price preferences adopts a numerical reasoning network framework to model price preferences with logical constraints. set up Represents a set of numbers. To represent a specific numerical value Represents an entity set; Using the numerical projection mechanism, the derived value is calculated using the following formula: in, In relation set Projection operator under constraints; Before performing price preference inference, the original price values are mapped from the real number space to a high-dimensional embedding space through a deterministic numerical encoding function to maintain the continuity and geometric relationship between prices. The encoded price embedding is then fused with a learnable embedding representing the price semantic type to form a numerical embedding representation for price reasoning.
5. The conversation recommendation method based on collaborative interest and price perception reasoning as described in claim 4, characterized in that: Based on the numerical logic operations of the numerical inference network, a numerical projection operation is performed on the price numerical embedding and price relation embedding obtained by numerical encoding. By introducing a gating mechanism, the price numerical embedding and the corresponding relation embedding are fused to generate numerical projection results representing different price logical semantics. The gating mechanism is used to control the degree of influence of relation embedding on price value embedding, so that the numerical projection result can reflect the comparison relationship between prices. The numerical projection results obtained based on different price relationships are used as input. The numerical logic intersection operation is performed with the feedforward network through an attention mechanism with permutation invariance to eliminate numerical intervals that do not meet the price preference constraints, thereby obtaining a numerical representation that conforms to the user's price preference.
6. The conversation recommendation method based on collaborative interest and price-perceived reasoning as described in claim 5, characterized in that: The joint prediction includes, when generating the final recommendation result, calculating the distance between the target item and the inference box embedding obtained from item preference reasoning as the item preference score. The distance includes an external distance term where the target item is outside the reasoning box and an internal distance term where the target item is inside the reasoning box, and the contribution of the internal distance term is adjusted by a preset coefficient. Based on the price preference embedding obtained from price preference reasoning, a price sensitivity gating factor generated by user embedding is introduced to scale the similarity between the price embedding of the target item and the price preference embedding to obtain a price preference score; The item preference score and the price preference score are weighted and combined to generate a final predicted score for predicting the next recommended item in the session.
7. The conversation recommendation method based on collaborative interest and price perception reasoning as described in claim 6, characterized in that: The joint prediction also includes, during model training, constructing a recommendation loss function based on the final prediction score to constrain the predicted ranking of the real next interactive item among all candidate items; Meanwhile, for price preference reasoning, a price relation constraint loss is introduced to enhance the ability of price relation projection to distinguish between the semantics of price being too high and price being too low, and a price embedding discriminant loss is introduced to enhance the separability between different price embeddings. The recommendation loss function is then weighted and fused with the price relationship constraint loss and the price embedding discriminant loss, and used as the final optimization objective for model training.
8. A conversation recommendation system based on collaborative interest and price-aware reasoning, based on the conversation recommendation method based on collaborative interest and price-aware reasoning as described in any one of claims 1 to 7, characterized in that: This includes a data acquisition unit that constructs an item session sequence and a price sequence corresponding to the item session sequence based on the user's session behavior. Define the unit, for first-order logical queries on item preferences and price preferences, and define two different sets of relations; The reasoning unit, through two channels, infers item preferences and price preferences respectively, to obtain item preference reasoning results and price preference reasoning results; wherein, the relation set, through the two channels, guides the final recommendation reasoning process; The prediction unit uses the results of item preference inference and price preference inference to jointly predict candidate items and output the next recommendation result in the session.
9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, it implements the steps of the conversation recommendation method based on collaborative interest and price perception reasoning as described in any one of claims 1 to 7.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by the processor, it implements the steps of the conversation recommendation method based on collaborative interest and price perception reasoning as described in any one of claims 1 to 7.