# US 2025/0148523 A1 · Item Recommendation Method and Related Device Thereof

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2025/0148523 A1
- Document ID: US20250148523A1
- Status: Published application
- Kind: A1
- Application number: 18/989,318
- Filed: 2024-12-20
- Published: 2025-05-08
- Earliest claimed: 2022-06-21
- Assignees: Huawei Technologies Co., Ltd.
- Applicants: Huawei Technologies Co., Ltd.
- Inventors: Wei Guo; Enming Yuan; Huifeng Guo; Ruiming Tang
- Web page: https://patentgrep.com/patent/US20250148523A1

## CPC

- G06F 16/35: Clustering; Classification
- G06Q 30/020121: {Sales lead analysis}
- G06N 3/045: Combinations of networks
- G06N 3/09: Supervised learning
- G06Q 30/02022: {based on correlations between customers, products, or services}
- G06Q 30/0631: {Recommending goods or services}
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- G06Q: INFORMATION 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
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS

## Abstract

An item recommendation method includes obtaining N pieces of first information, where an ith piece of first information indicates an ith first item and an ith behavior, the ith behavior is a behavior of a user for the ith item, N behaviors of the user correspond to M categories, i=1, . . . , N, N≥M, and M>1; processing the N pieces of first information based on a multi-head self-attention mechanism, to obtain N pieces of second information; and obtaining an item recommendation result based on the N pieces of second information, where the item recommendation result is used to determine, from K second items, a target item recommended to the user, and K≥1.

## Claims

### Claim 1

A method comprising:
obtaining N pieces of first information, wherein an ith piece of the first information indicates an ith first item and an ith behavior, wherein the ith behavior is a behavior of a user for the ith first item, wherein N behaviors of the user correspond to M categories, and wherein i=1, . . . , N, N≥M, and M>1;
processing the N pieces of first information based on a multi-head self-attention mechanism; to obtain N pieces of second information;
obtaining an item recommendation result based on the N pieces of second information;
determining, based on the item recommendation result, a target item from K second items, wherein K≥1; and
recommending the target item to the user.

### Claim 2 (depends on 1)

The method according to claim 1, wherein processing the N pieces of first information based on the multi-head self-attention mechanism to obtain the N pieces of second information comprises:
performing linear processing on the ith piece of the first information, to obtain an ith piece of Q information, an ith piece of K information, and an ith piece of V information; and
performing a first operation on the ith piece of Q information, N pieces of the K information, N pieces of the V information, and N pieces of weight information corresponding to the ith behavior, to obtain an ith piece of second information, wherein a jth piece of the weight information corresponding to the ith behavior is based on the ith behavior and a jth behavior, and wherein j=1, . . . , N.

### Claim 3 (depends on 2)

The method according to claim 2, further comprising:
obtaining N pieces of third information, wherein an ith piece of the third information indicates the ith behavior; and
performing a second operation on the ith piece of the third information and the N pieces of third information to obtain N pieces of fourth information corresponding to the ith behavior, wherein a jth piece of the fourth information corresponding to the it behavior indicates a distance between the ith behavior and the jth behavior, and
wherein performing the first operation comprises performing the first operation on the ith piece of Q information, the N pieces of the K information, the N pieces of the V information, the N pieces of the weight information, and the N pieces of the fourth information to obtain the ith piece of second information.

### Claim 4 (depends on 3)

The method according to claim 3, wherein the distance comprises an interval between a first order of the ith behavior and a second order of the jth behavior.

### Claim 5 (depends on 1)

The method according to claim 1, wherein obtaining the item recommendation result comprises:
performing feature extraction on the N pieces of second information to obtain fifth information and sixth information, wherein the fifth information indicates a difference between the N behaviors, and wherein the sixth information indicates a same point between the N behaviors;
obtaining seventh information based on the fifth information and the sixth information, wherein the seventh information indicates interest distribution of the user; and
calculating matching degrees between the seventh information and K pieces of eighth information, wherein the matching degrees are used as the item recommendation result, wherein a tth piece of the eighth information indicates a tth second item, and wherein t=1, . . . , K.

### Claim 6 (depends on 5)

The method according to claim 5, wherein the K second items comprise N first items.

### Claim 7

A method comprising:
inputting N pieces of first information into a to-be-trained model to obtain a predicted item recommendation result, wherein the to-be-trained model is configured to: obtain the N pieces of first information, wherein an ith piece of the first information indicates an ith first item and an ith behavior, wherein the ith behavior is a behavior of a user for the ith first item, wherein N behaviors of the user correspond to M categories, and wherein i=1, . . . , N, N≥M, and M>1; process the N pieces of first information based on a multi-head self-attention mechanism to obtain N pieces of second information; obtain the predicted item recommendation result based on the N pieces of second information; determine, based on the predicted item recommendation result, a target item from K second items, wherein K≥1; and recommend the target item to the user;
obtaining a target loss based on the predicted item recommendation result and a real item recommendation result, wherein the target loss indicates a difference between the predicted item recommendation result and the real item recommendation result; and
obtaining a target model by updating a parameter of the to-be-trained model based on the target loss until a model training condition is met.

### Claim 8 (depends on 7)

The method according to claim 7, wherein the to-be-trained model is further configured to:
perform linear processing on the ith piece of the first information to obtain an ith piece of Q information, an ith piece of K information, and an ith piece of V information; and
perform a first operation on the ith piece of Q information, N pieces of the K information, N pieces of the V information, and N pieces of weight information corresponding to the ith behavior to obtain an ith piece of second information, wherein a jth piece of the weight information corresponding to the ith behavior is determined based on the ith behavior and a jth behavior, and wherein j=1, . . . , N.

### Claim 9 (depends on 8)

The method according to claim 8, wherein the to-be-trained model is further configured to:
obtain N pieces of third information, wherein an ith piece of the third information indicates the ith behavior;
perform a second operation on the ith piece of the third information and the N pieces of third information to obtain N pieces of fourth information corresponding to the ith behavior, wherein a jth piece of the fourth information corresponding to the ith behavior indicates a distance between the ith behavior and the jth behavior; and
perform the first operation on the ith piece of Q information, the N pieces of the K information, the N pieces of the V information, the N pieces of the weight information, and the N pieces of the fourth information to obtain the ith piece of second information.

### Claim 10 (depends on 9)

The method according to claim 9, wherein the distance between the ith behavior and the jth behavior comprises an interval between a first order of the ith behavior and a second order of the jth behavior.

### Claim 11 (depends on 7)

The method according to claim 7, wherein the to-be-trained model is further configured to:
perform feature extraction on the N pieces of second information to obtain fifth information and sixth information, wherein the fifth information indicates a difference between the N behaviors, and wherein the sixth information indicates a same point between the N behaviors;
obtain seventh information based on the fifth information and the sixth information, wherein the seventh information indicates interest distribution of the user; and
calculate matching degrees between the seventh information and K pieces of eighth information, wherein the matching degrees are used as the predicted item recommendation result, wherein a tth piece of the eighth information indicates a tth second item, and wherein t=1, . . . , K.

### Claim 12 (depends on 11)

The method according to claim 11, wherein the K second items comprise N first items.

### Claim 13

An apparatus, comprising:
a memory configured to store instructions; and
one or more processors configured to execute the instructions to cause the apparatus to:
obtain N pieces of first information, wherein an ith piece of the first information indicates an ith first item and an ith behavior, wherein the ith behavior is a behavior of a user for the ith first item, wherein N behaviors of the user correspond to M categories, and wherein i=1, . . . , N, N≥M, and M>1;
process the N pieces of first information based on a multi-head self-attention mechanism, to obtain N pieces of second information;
obtain an item recommendation result based on the N pieces of second information;
determine, based on the item recommendation result, a target item from K second items, wherein K≥1; and
recommend the target item to the user.

### Claim 14 (depends on 13)

The apparatus according to claim 13, wherein the instructions, when executed by the one or more processors, further cause the apparatus to process the N pieces of first information by:
performing linear processing on the ith piece of the first information to obtain an ith piece of Q information, an ith piece of K information, and an ith piece of V information, and
performing a first operation on the ith piece of Q information, N pieces of the K information, N pieces of the V information, and N pieces of weight information corresponding to the ith behavior to obtain an ith piece of second information, wherein a jth piece of the weight information corresponding to the ith behavior is based on the ith behavior and a jth behavior, and wherein j=1, . . . , N.

### Claim 15 (depends on 14)

The apparatus according to claim 14, wherein the instructions, when executed by the one or more processors, further cause the apparatus to:
obtain N pieces of third information, wherein an ith piece of the third information indicates the ith behavior;
perform a second operation on the ith piece of the third information and the N pieces of third information to obtain N pieces of fourth information corresponding to the ith behavior, wherein a jth piece of the fourth information corresponding to the ith behavior indicates a distance between the ith behavior and the jth behavior; and
perform the first operation on the ith piece of Q information, the N pieces of the K information, the N pieces of the V information, the N pieces of the weight information, and the N pieces of the fourth information to obtain the ith piece of second information.

### Claim 16 (depends on 15)

The apparatus according to claim 15, wherein the distance comprises an interval between a first order of the ith behavior and a second order of the jth behavior.

### Claim 17 (depends on 13)

The apparatus according to claim 13, wherein the instructions, when executed by the one or more processors, further cause the apparatus to:
perform feature extraction on the N pieces of second information to obtain fifth information and sixth information, wherein the fifth information indicates a difference between the N behaviors, and wherein the sixth information indicates a same point between the N behaviors; and
obtain seventh information based on the fifth information and the sixth information, wherein the seventh information indicates interest distribution of the user.

### Claim 18 (depends on 17)

The apparatus according to claim 17, wherein the K second items comprise N first items.

### Claim 19 (depends on 17)

The apparatus according to claim 17, wherein the instructions, when executed by the one or more processors, further cause the apparatus to perform weighted summation on the fifth information and the sixth information to obtain the seventh information.

### Claim 20 (depends on 17)

The apparatus according to claim 17, wherein the instructions, when executed by the one or more processors, further cause the apparatus to calculate matching degrees between the seventh information and K pieces of eighth information, wherein the matching degrees are used as the item recommendation result, wherein a tth piece of the eighth information indicates a tth second item, and wherein t=1, . . . , K.
