# US 2024/0202446 A1 · Method for training keyword extraction model, keyword extraction method, and computer device

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

- Number: US 2024/0202446 A1
- Document ID: US20240202446A1
- Status: Published application
- Kind: A1
- Application number: 18/592,357
- Filed: 2024-02-29
- Published: 2024-06-20
- Earliest claimed: 2018-12-07
- Assignees: Tencent Technology (Shenzhen) Company Limited
- Applicants: Tencent Technology (Shenzhen) Company Limited
- Inventors: Wenhao ZHENG; Lie Kang; Qiang Yan
- Web page: https://patentgrep.com/patent/US20240202446A1

## CPC

- G06F 40/289: Phrasal analysis, e.g. finite state techniques or chunking
- G06F 40/284: Lexical analysis, e.g. tokenisation or collocates
- G06F 40/30: Semantic analysis
- G06V 30/414: Extracting the geometrical structure, e.g. layout tree; Block segmentation, e.g. bounding boxes for graphics or text
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- G06V: IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING

## Abstract

This application provide a keyword extraction method. The method includes: performing word segmentation on a text, to obtain a plurality of candidate words; selecting, from the plurality of candidate words, a candidate word that appears in the title; determining an extraction threshold according to an attention weight of the selected candidate word relative to the title; and determining a keyword of the text from the candidate words according to the extraction threshold.

## Claims

### Claim 1

A method for extracting a keyword from a text performed at a computer device, the method comprising:
performing word segmentation on the text, to obtain a plurality of candidate words;
selecting, from the plurality of candidate words, a candidate word that appears in the title;
determining an extraction threshold according to an attention weight of the candidate word relative to the title; and
determining a keyword of the text from the candidate words according to the extraction threshold.

### Claim 2 (depends on 1)

The method according to claim 1, wherein the determining an extraction threshold according to an attention weight of the selected candidate word relative to the title comprises:
determining, for each selected candidate word, a weight corresponding to the candidate word according to the attention weight of the candidate word relative to a character in the title; and
determining the extraction threshold according to the weight corresponding to the selected candidate word.

### Claim 3 (depends on 2)

The method according to claim 2, wherein the determining, for each selected candidate word, a weight corresponding to the candidate word according to the attention weight of the candidate word relative to a character in the title comprises:
determining, for the selected candidate word, a maximum attention weight among the attention weights of the plurality of candidate words relative to the character as the weight corresponding to the selected candidate word.

### Claim 4 (depends on 2)

The method according to claim 2, wherein the determining, for each selected candidate word, a weight corresponding to the candidate word according to the attention weight of the candidate word relative to a character in the title comprises:
determining, for the selected candidate word, an average value of the attention weights of the plurality of candidate words relative to the character as the weight corresponding to the selected candidate word.

### Claim 5 (depends on 1)

The method according to claim 1, wherein no keyword of the text exists when none of the plurality of candidate words appear in the title.

### Claim 6 (depends on 1)

The method according to claim 1, wherein the attention weight of each candidate word is obtained by a keyword extraction model including an encoding model and a decoding model.

### Claim 7 (depends on 1)

The method according to claim 1, wherein the attention weight of each candidate word represents a degree of semantic association between the candidate word and the title.

### Claim 8

A computer device, comprising one or more processors and one or more memories, the one or more memories storing at least one piece of program code, the at least one piece of program code being loaded and executed by the one or more processors to perform a method for extracting a keyword from a text including:
performing word segmentation on the text, to obtain a plurality of candidate words;
selecting, from the plurality of candidate words, a candidate word that appears in the title;
determining an extraction threshold according to an attention weight of the candidate word relative to the title; and
determining a keyword of the text from the candidate words according to the extraction threshold.

### Claim 9 (depends on 8)

The computer device according to claim 8, wherein the determining an extraction threshold according to an attention weight of the selected candidate word relative to the title comprises:
determining, for each selected candidate word, a weight corresponding to the candidate word according to the attention weight of the candidate word relative to a character in the title; and
determining the extraction threshold according to the weight corresponding to the selected candidate word.

### Claim 10 (depends on 9)

The computer device according to claim 9, wherein the determining, for each selected candidate word, a weight corresponding to the candidate word according to the attention weight of the candidate word relative to a character in the title comprises:
determining, for the selected candidate word, a maximum attention weight among the attention weights of the plurality of candidate words relative to the character as the weight corresponding to the selected candidate word.

### Claim 11 (depends on 9)

The computer device according to claim 9, wherein the determining, for each selected candidate word, a weight corresponding to the candidate word according to the attention weight of the candidate word relative to a character in the title comprises:
determining, for the selected candidate word, an average value of the attention weights of the plurality of candidate words relative to the character as the weight corresponding to the selected candidate word.

### Claim 12 (depends on 8)

The computer device according to claim 8, wherein no keyword of the text exists when none of the plurality of candidate words appear in the title.

### Claim 13 (depends on 8)

The computer device according to claim 8, wherein the attention weight of each candidate word is obtained by a keyword extraction model including an encoding model and a decoding model.

### Claim 14 (depends on 8)

The computer device according to claim 8, wherein the attention weight of each candidate word represents a degree of semantic association between the candidate word and the title.

### Claim 15

A non-transitory computer-readable storage medium, storing computer-readable instructions that, when executed by a processor of a computer device, cause the computer device to perform a method for extracting a keyword from a text including:
performing word segmentation on the text, to obtain a plurality of candidate words;
selecting, from the plurality of candidate words, a candidate word that appears in the title;
determining an extraction threshold according to an attention weight of the candidate word relative to the title; and
determining a keyword of the text from the candidate words according to the extraction threshold.

### Claim 16 (depends on 15)

The non-transitory computer-readable storage medium according to claim 15, wherein the determining an extraction threshold according to an attention weight of the selected candidate word relative to the title comprises:
determining, for each selected candidate word, a weight corresponding to the candidate word according to the attention weight of the candidate word relative to a character in the title; and
determining the extraction threshold according to the weight corresponding to the selected candidate word.

### Claim 17 (depends on 16)

The non-transitory computer-readable storage medium according to claim 16, wherein the determining, for each selected candidate word, a weight corresponding to the candidate word according to the attention weight of the candidate word relative to a character in the title comprises:
determining, for the selected candidate word, a maximum attention weight among the attention weights of the plurality of candidate words relative to the character as the weight corresponding to the selected candidate word.

### Claim 18 (depends on 16)

The non-transitory computer-readable storage medium according to claim 16, wherein the determining, for each selected candidate word, a weight corresponding to the candidate word according to the attention weight of the candidate word relative to a character in the title comprises:
determining, for the selected candidate word, an average value of the attention weights of the plurality of candidate words relative to the character as the weight corresponding to the selected candidate word.

### Claim 19 (depends on 15)

The non-transitory computer-readable storage medium according to claim 15, wherein no keyword of the text exists when none of the plurality of candidate words appear in the title.

### Claim 20 (depends on 15)

The non-transitory computer-readable storage medium according to claim 15, wherein the attention weight of each candidate word represents a degree of semantic association between the candidate word and the title.
