A data processing method and device based on graph attention network

Through the data processing method based on the graph attention network, the information correlation model is used to process text generation requests and sort and filter, the problem of insufficient output information is solved and efficient generation of marketing texts of different lengths is achieved.

CN114357969BActive Publication Date: 2024-11-26GUANGZHOU YOUMI INFORMATION TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202111572546.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-21
Publication Date
2024-11-26
Estimated Expiration
2041-12-21

AI Technical Summary

Technical Problem

During the data processing process, the output amount is insufficient, making it difficult to meet the marketing text generation needs of different lengths.

Method used

The data processing method based on the graph attention network is adopted, and the text generation request is processed using the information correlation model to obtain attribute word information, and the target text word is obtained through sorting and filtering processing, which is used to generate marketing text.

Benefits of technology

The information output of related words is improved to meet the marketing text generation needs of different lengths.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114357969B_ABST
    Figure CN114357969B_ABST
Patent Text Reader

Abstract

The present invention discloses a data processing method and device based on a graph attention network, the method comprising: detecting whether a text generation request is received, and obtaining a detection result; the text generation request includes a plurality of input words; when the detection result is yes, processing the text generation request using a preset information association model, and obtaining attribute word information; the attribute word information includes L attribute word sub-information; L is a positive integer greater than or equal to 1; the information association model includes a first information association model based on a graph attention network, and / or a second information association model; sorting and screening the attribute word information, and obtaining target text word information; the target text word information includes a plurality of target text words; the target text words are used to generate marketing texts. It can be seen that the present invention is conducive to increasing the information output of associated words, thereby meeting the needs of generating marketing texts of different lengths.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of data processing technology, and in particular to a data processing method and device based on a graph attention network. Background Art

[0002] At present, in the data processing process of generating marketing texts from given input texts, the problem of insufficient output information is prone to occur. Therefore, it is particularly important to provide a data processing method and device based on a graph attention network to increase the information output of related words, thereby meeting the needs of generating marketing texts of different lengths. Summary of the invention

[0003] The technical problem to be solved by the present invention is to provide a data processing method and device based on a graph attention network, which can use the information association model to process the text generation request to obtain attribute word information, and then obtain the target text words for generating marketing texts through comprehensive processing such as sorting and screening the attribute word information, which is conducive to improving the information output of related words, thereby meeting the needs of generating marketing texts of different lengths.

[0004] In order to solve the above technical problems, the first aspect of the embodiment of the present invention discloses a data processing method based on a graph attention network, the method comprising:

[0005] Detecting whether a text generation request is received and obtaining a detection result; the text generation request includes a plurality of input words;

[0006] When the detection result is yes, the text generation request is processed using a preset information association model to obtain attribute word information; the attribute word information includes L attribute word sub-information; L is a positive integer greater than or equal to 1; the information association model includes a first information association model based on a graph attention network, and / or a second information association model;

[0007] The attribute word information is sorted and screened to obtain target text word information; the target text word information includes a plurality of target text words; the target text words are used to generate marketing texts.

[0008] As an optional implementation, in the first aspect of the embodiment of the present invention, the using of a preset information association model to process the text generation request to obtain attribute word information includes:

[0009] Using the first information association model to process all the input words to obtain word vector information; the input word vector information includes a plurality of word vector sub-information;

[0010] The word vector information is processed using the second information association model to obtain attribute word information; the attribute word information includes first node word information, and / or second node word information, and / or third node word information; the first node word information, the second node word information and the third node word information respectively include T attribute word sub-information; T is a positive integer greater than or equal to 1.

[0011] As an optional implementation manner, in the first aspect of the embodiment of the present invention, the second information association model includes a first association sub-model, and / or a second association sub-model, and / or a third association sub-model;

[0012] The using the second information association model to process the word vector information to obtain attribute word information includes:

[0013] Inputting the word vector information into the first associated sub-model to obtain the first node word information; the first node word information represents the association relationship between the current node and the directly associated node in the graph attention network; and / or,

[0014] Input the word vector information into the second associated sub-model to obtain the second node word information; the second node word information represents the association relationship between the current node and the first indirect associated node in the graph attention network; the current node and the first indirect associated node are separated by one node; and / or,

[0015] The word vector information is input into the third associated sub-model to obtain the third node word information; the third node word information represents the association relationship between the current node and the second non-directly associated node in the graph attention network; the current node and the second non-directly associated node are separated by two nodes.

[0016] As an optional implementation manner, in the first aspect of the embodiment of the present invention, the using the first information association model to process all the input words to obtain word vector information includes:

[0017] For any of the input words, determine whether a preset knowledge graph contains the input word, and obtain an input determination result;

[0018] When the input judgment result is yes, the input word is input into the first information association model to obtain attribute word sub-information corresponding to the input word;

[0019] When the input judgment result is no, the input word is processed using the preset word threshold and the first information association model to obtain the threshold word information corresponding to the input word; the threshold word information includes M attribute word sub-information; M matches the word threshold; M is a positive integer greater than or equal to 1.

[0020] As an optional implementation, in the first aspect of the embodiment of the present invention, the text generation request further includes text length information;

[0021] The step of sorting and screening the attribute word information to obtain target text word information includes:

[0022] Calculating and sorting the attribute word information to obtain an attribute word sequence;

[0023] The attribute word sequence and the text length information are processed to obtain target text word information.

[0024] As an optional implementation manner, in the first aspect of the embodiment of the present invention, the calculating and sorting the attribute word information to obtain the attribute word sequence includes:

[0025] Using a preset heat model to calculate the heat index of the attribute word information to obtain word selection index information; the word selection index information includes a plurality of word selection indexes; the heat model is used to process at least 5 word selection indexes of any word vector information in the attribute word information;

[0026] All the word selection indexes in the word selection index information are sorted from large to small to obtain an attribute word sequence.

[0027] As an optional implementation manner, in the first aspect of the embodiment of the present invention, the word vector quantum information includes first word vector quantum information and second word vector quantum information;

[0028] The first word vector sub-information includes index identification information, a first word vector and a second word vector; the dimension of the second word vector is greater than or equal to 4;

[0029] The second word vector sub-information includes first connected entity identification information and second connected entity identification information; the first connected entity identification information and the second connected entity identification information represent a link relationship.

[0030] A second aspect of an embodiment of the present invention discloses a data processing device based on a graph attention network, the device comprising:

[0031] A detection module, used to detect whether a text generation request is received and obtain a detection result; the text generation request includes a number of input words;

[0032] A first processing module, for, when the detection result is yes, using a preset information association model to process the text generation request to obtain attribute word information; the attribute word information includes L attribute word sub-information; L is a positive integer greater than or equal to 1; the information association model includes a first information association model based on a graph attention network, and / or a second information association model;

[0033] The second processing module is used to sort and filter the attribute word information to obtain target text word information; the target text word information includes a plurality of target text words; the target text words are used to generate marketing texts.

[0034] As an optional implementation, in the second aspect of the embodiment of the present invention, the first processing module includes a first processing submodule and a second processing submodule, wherein:

[0035] The first processing submodule is used to process all the input words using the first information association model to obtain word vector information; the input word vector information includes a plurality of word vector sub-information;

[0036] The second processing sub-module is used to process the word vector information using the second information association model to obtain attribute word information; the attribute word information includes first node word information, and / or second node word information, and / or third node word information; the first node word information, the second node word information and the third node word information respectively include T attribute word sub-information; T is a positive integer greater than or equal to 1.

[0037] As an optional implementation manner, in the second aspect of the embodiment of the present invention, the second information association model includes a first association sub-model, and / or a second association sub-model, and / or a third association sub-model;

[0038] The second processing submodule processes the word vector information using the second information association model to obtain the attribute word information in the following specific manner:

[0039] Inputting the word vector information into the first associated sub-model to obtain the first node word information; the first node word information represents the association relationship between the current node and the directly associated node in the graph attention network; and / or,

[0040] Input the word vector information into the second associated sub-model to obtain the second node word information; the second node word information represents the association relationship between the current node and the first indirect associated node in the graph attention network; the current node and the first indirect associated node are separated by one node; and / or,

[0041] The word vector information is input into the third associated sub-model to obtain the third node word information; the third node word information represents the association relationship between the current node and the second non-directly associated node in the graph attention network; the current node and the second non-directly associated node are separated by two nodes.

[0042] As an optional implementation, in the second aspect of the embodiment of the present invention, the first processing submodule processes all the input words using the first information association model, and the specific manner of obtaining the word vector information is:

[0043] For any of the input words, determine whether the preset knowledge graph contains the input word, and obtain an input determination result;

[0044] When the input judgment result is yes, the input word is input into the first information association model to obtain attribute word sub-information corresponding to the input word;

[0045] When the input judgment result is no, the input word is processed using the preset word threshold and the first information association model to obtain the threshold word information corresponding to the input word; the threshold word information includes M attribute word sub-information; M matches the word threshold; M is a positive integer greater than or equal to 1.

[0046] As an optional implementation, in the second aspect of the embodiment of the present invention, the text generation request also includes text length information;

[0047] The specific method in which the second processing module performs sorting and screening processing on the attribute word information to obtain the target text word information is:

[0048] Calculating and sorting the attribute word information to obtain an attribute word sequence;

[0049] The attribute word sequence and the text length information are processed to obtain target text word information.

[0050] As an optional implementation, in the second aspect of the embodiment of the present invention, the second processing module performs calculation and sorting processing on the attribute word information to obtain the specific manner of the attribute word sequence:

[0051] Using a preset heat model to calculate the heat index of the attribute word information to obtain word selection index information; the word selection index information includes a plurality of word selection indexes; the heat model is used to process at least 5 word selection indexes of any word vector information in the attribute word information;

[0052] All the word selection indexes in the word selection index information are sorted from large to small to obtain an attribute word sequence.

[0053] As an optional implementation, in the second aspect of the embodiment of the present invention, the word vector quantum information includes first word vector quantum information and second word vector quantum information;

[0054] The first word vector sub-information includes index identification information, a first word vector and a second word vector; the dimension of the second word vector is greater than or equal to 4;

[0055] The second word vector sub-information includes first connected entity identification information and second connected entity identification information; the first connected entity identification information and the second connected entity identification information represent a link relationship.

[0056] The third aspect of the present invention discloses another data processing device based on a graph attention network, the device comprising:

[0057] A memory storing executable program code;

[0058] a processor coupled to the memory;

[0059] The processor calls the executable program code stored in the memory to execute part or all of the steps in the data processing method based on the graph attention network disclosed in the first aspect of the embodiment of the present invention.

[0060] The fourth aspect of the present invention discloses a computer storage medium, which stores computer instructions. When the computer instructions are called, they are used to execute part or all of the steps in the data processing method based on the graph attention network disclosed in the first aspect of the embodiment of the present invention.

[0061] Compared with the prior art, the embodiments of the present invention have the following beneficial effects:

[0062] In an embodiment of the present invention, it is detected whether a text generation request is received to obtain a detection result; the text generation request includes a plurality of input words; when the detection result is yes, the text generation request is processed using a preset information association model to obtain attribute word information; the attribute word information includes L attribute word sub-information; L is a positive integer greater than or equal to 1; the information association model includes a first information association model based on a graph attention network, and / or a second information association model; the attribute word information is sorted and screened to obtain target text word information; the target text word information includes a plurality of target text words; the target text word is used to generate a marketing text. It can be seen that the present invention can use the information association model to process the text generation request to obtain the attribute word information, and then obtain the target text word used to generate the marketing text by performing comprehensive processing such as sorting and screening on the attribute word information, which is conducive to increasing the information output of the associated words, thereby meeting the needs of generating marketing texts of different lengths. BRIEF DESCRIPTION OF THE DRAWINGS

[0063] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0064] Figure 1 It is a flowchart of a data processing method based on a graph attention network disclosed in an embodiment of the present invention;

[0065] Figure 2 It is a flowchart of another data processing method based on a graph attention network disclosed in an embodiment of the present invention;

[0066] Figure 3 It is a structural schematic diagram of a data processing device based on a graph attention network disclosed in an embodiment of the present invention;

[0067] Figure 4 It is a structural schematic diagram of another data processing device based on a graph attention network disclosed in an embodiment of the present invention;

[0068] Figure 5 A schematic diagram of the structure of another data processing device based on a graph attention network disclosed in an embodiment of the present invention. DETAILED DESCRIPTION

[0069] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0070] The terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish different objects, rather than to describe a specific order. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, device, product or equipment that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units that are not listed, or may optionally include other steps or units that are inherent to these processes, methods, products or equipment.

[0071] Reference to "embodiments" herein means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present invention. The appearance of the phrase in various places in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.

[0072] The present invention discloses a data processing method and device based on a graph attention network, which can use an information association model to process a text generation request to obtain attribute word information, and then obtain target text words for generating marketing texts by performing comprehensive processing such as sorting and screening the attribute word information, which is conducive to increasing the information output of related words, thereby meeting the needs of generating marketing texts of different lengths. The following are detailed descriptions.

[0073] Embodiment 1

[0074] See also Figure 1 , Figure 1 is a flow chart of a data processing method based on a graph attention network disclosed in an embodiment of the present invention. Figure 1 The described data processing method based on graph attention network is applied to a data processing system, such as a local server or cloud server for data processing management based on graph attention network, which is not limited in the embodiments of the present invention. Figure 1 As shown, the data processing method based on the graph attention network may include the following operations:

[0075] 101. Detect whether a text generation request is received and obtain a detection result.

[0076] In the embodiment of the present invention, the text generation request includes a plurality of input words.

[0077] 102. When the detection result is yes, the text generation request is processed using a preset information association model to obtain attribute word information.

[0078] In the embodiment of the present invention, the attribute word information includes L attribute word sub-information.

[0079] In the embodiment of the present invention, the above L is a positive integer greater than or equal to 1.

[0080] In an embodiment of the present invention, the above-mentioned information association model includes a first information association model based on a graph attention network, and / or a second information association model.

[0081] 103. Sort and filter the attribute word information to obtain target text word information.

[0082] In the embodiment of the present invention, the target text word information includes a plurality of target text words.

[0083] In the embodiment of the present invention, the above target text words are used to generate marketing texts.

[0084] Optionally, the above L is a positive integer that is an integer multiple of 3.

[0085] It can be seen that the data processing method based on graph attention network described in the embodiment of the present invention can use the information association model to process the text generation request to obtain attribute word information, and then obtain the target text words for generating marketing text through comprehensive processing such as sorting and screening the attribute word information, which is beneficial to increasing the information output of related words, thereby meeting the needs of generating marketing texts of different lengths.

[0086] In an optional embodiment, in the above step 102, the text generation request is processed using a preset information association model to obtain attribute word information, including:

[0087] Using the first information association model to process all input words, obtaining word vector information; the input word vector information includes a plurality of word vector sub-information;

[0088] The word vector information is processed using the second information association model to obtain attribute word information; the attribute word information includes the first node word information, and / or, the second node word information, and / or, the third node word information; the first node word information, the second node word information and the third node word information respectively include T attribute word sub-information; T is a positive integer greater than or equal to 1.

[0089] Optionally, before using the second information association model to process the word vector information, an output threshold of the second information association model is set.

[0090] Optionally, the above output threshold is consistent with T.

[0091] Optionally, the second information association model includes a first association sub-model, and / or a second association sub-model, and / or a third association sub-model, which is not limited in the embodiment of the present invention.

[0092] Optionally, the first association sub-model includes N graph attention layers.

[0093] Furthermore, the above N is a positive integer greater than or equal to 2.

[0094] In this optional embodiment, as an optional implementation manner, the first association sub-model is trained based on the following steps:

[0095] Obtain the model training set and initialize the first training sub-model;

[0096] Input the above model training set into the first training sub-model, and calculate the multi-head attention scores of all neighboring nodes within one hop of each node in the first graph attention layer;

[0097] Sum and average the multi-head attention calculation scores, and update the representation vector of each entity node;

[0098] Perform multi-head attention scores for all neighboring nodes within one hop of each node in the next graph attention layer, and perform summation and average calculation and update the representation vector of each entity node;

[0099] Determine whether the current graph attention layer is the last graph attention layer and obtain the layer judgment result;

[0100] When the judgment result of the above layer is no, the above multi-head attention scores of all neighboring nodes within one hop of each node in the next graph attention layer are triggered, and the summation and average calculation and update of the representation vector of each entity node are performed;

[0101] When the judgment result of the above layer is yes, the sum of the entity vectors of the neighboring nodes within one hop of each node and the entity vector of the intermediate nodes are minimized, and the model parameters of the first training sub-model are updated;

[0102] The updated first training sub-model is determined as the first associated sub-model.

[0103] Optionally, the above hop is a traversal from the current node to a directly associated node.

[0104] Optionally, the first association sub-model is used to process all nodes in one hop.

[0105] Optionally, the second association sub-model is used to process all nodes in the second hop.

[0106] Optionally, the third association sub-model is used to process all nodes of three hops.

[0107] Optionally, the above two hops are a traversal from the current node to a first non-directly associated node that is one node away.

[0108] Optionally, the above three hops are traversals from the current node to a second non-directly associated node separated by two nodes.

[0109] It can be seen that the data processing method based on the graph attention network described in the embodiment of the present invention can use the first information association model and the second information association model to comprehensively process the input words to obtain attribute word information, which is beneficial to increasing the information output of related words, thereby meeting the needs of generating marketing texts of different lengths.

[0110] In another optional embodiment, the word vector information is processed using the second information association model to obtain attribute word information, including:

[0111] Input the word vector information into the first association sub-model to obtain the first node word information; the first node word information represents the association relationship between the current node and the directly associated node in the graph attention network; and / or,

[0112] Input the word vector information into the second associated sub-model to obtain the second node word information; the second node word information represents the association relationship between the current node and the first indirect associated node in the graph attention network; the current node and the first indirect associated node are separated by one node; and / or,

[0113] The word vector information is input into the third associated sub-model to obtain the third node word information; the third node word information representation graph pays attention to the association relationship between the current node and the second non-directly associated node in the network; the current node and the second non-directly associated node are separated by two nodes.

[0114] Optionally, the above nodes represent entity words and / or relationship words, which is not limited in the embodiment of the present invention.

[0115] It can be seen that the data processing method based on the graph attention network described in the embodiment of the present invention can use the first association sub-model, the second association sub-model and the third association sub-model to process the word vector information to obtain the first node word information, the second node word information and the third node word information respectively, which is beneficial to improve the information output of the associated words, thereby meeting the needs of generating marketing texts of different lengths.

[0116] In yet another optional embodiment, the first information association model is used to process all input words to obtain word vector information, including:

[0117] For any input word, determine whether the preset knowledge graph contains the input word and obtain the input judgment result;

[0118] When the input judgment result is yes, the input word is input into the first information association model to obtain the attribute word sub-information corresponding to the input word;

[0119] When the input judgment result is no, the input word is processed using the preset word threshold and the first information association model to obtain the threshold word information corresponding to the input word; the threshold word information includes M attribute word sub-information; M matches the word threshold; M is a positive integer greater than or equal to 1.

[0120] Optionally, the above knowledge graph is constructed based on information points of triples.

[0121] Optionally, the above triple is composed of 2 entity words and 1 relation word.

[0122] Optionally, the above-mentioned entity words include brand words, and / or category words, and / or common sense words, and / or high-frequency words, which is not limited in the embodiment of the present invention.

[0123] Optionally, the above-mentioned relationship words include ingredient relationship words, and / or efficacy relationship words, and / or brand relationship words, and / or category relationship words, which are not limited in the embodiment of the present invention.

[0124] It can be seen that the data processing method based on the graph attention network described in the embodiment of the present invention can obtain attribute word information through comprehensive processing of input words by the knowledge graph and the first information association model, which is more conducive to improving the information output of related words, thereby meeting the needs of generating marketing texts of different lengths.

[0125] Embodiment 2

[0126] See also Figure 2 , Figure 2 is a flow chart of another data processing method based on a graph attention network disclosed in an embodiment of the present invention. Figure 2 The described data processing method based on graph attention network is applied to a data processing system, such as a local server or cloud server for data processing management based on graph attention network, which is not limited in the embodiments of the present invention. Figure 2 As shown, the data processing method based on the graph attention network may include the following operations:

[0127] 201. Detect whether a text generation request is received and obtain a detection result.

[0128] In the embodiment of the present invention, the above text generation request also includes text length information.

[0129] 202. When the detection result is yes, the text generation request is processed using a preset information association model to obtain attribute word information.

[0130] 203. Calculate and sort the attribute word information to obtain an attribute word sequence.

[0131] 204. Process the attribute word sequence and text length information to obtain target text word information.

[0132] In the embodiment of the present invention, for the specific technical details and technical terminology of step 201-step 202, reference can be made to the detailed description of step 101-step 102 in embodiment 1, and the embodiment of the present invention will not be repeated here.

[0133] Optionally, the number of target text words in the above target text word information is positively correlated with the text length information.

[0134] It can be seen that the data processing method based on graph attention network described in the embodiment of the present invention can use the information association model to process the text generation request to obtain attribute word information, and then obtain the attribute word sequence by sorting the attribute word information, and then obtain the target text word for generating marketing text by processing the attribute word sequence and text length information, which is beneficial to improving the information output of related words, thereby meeting the needs of generating marketing texts of different lengths.

[0135] In an optional embodiment, the attribute word information is calculated and sorted in the above step 203 to obtain an attribute word sequence, including:

[0136] The attribute word information is subjected to heat index calculation using a preset heat model to obtain word selection index information; the word selection index information includes a number of word selection indexes; the heat model is used to process at least 5 word selection indexes of any word in the attribute word information to the quantum information;

[0137] All the word selection indexes in the word selection index information are sorted from large to small to obtain an attribute word sequence.

[0138] Optionally, the above heat model is used to process the word co-occurrence count, the number of associated advertisements, the number of associated materials, the number of associated products and the number of searches of the attribute word sub-information in the attribute word information.

[0139] Optionally, the above-mentioned word co-occurrence count corresponds to a word co-occurrence count weight factor.

[0140] Optionally, the above-mentioned number of associated advertisements corresponds to an associated advertisement number weight factor.

[0141] Optionally, the above-mentioned number of associated materials corresponds to an associated material number weight factor.

[0142] Optionally, the above search number corresponds to a search number weight factor.

[0143] Optionally, the above-mentioned word selection index is obtained by processing the number of word co-occurrences, the number of associated advertisements, the number of associated materials, the number of associated products, the number of searches, the weight factor of the number of word co-occurrences, the weight factor of the number of associated advertisements, the weight factor of the number of associated materials and the weight factor of the number of searches using the above-mentioned heat model.

[0144] It can be seen that the data processing method based on the graph attention network described in the embodiment of the present invention can obtain the word selection index information by calculating the attribute word information through the heat model, and then obtain the attribute word sequence by sorting the word selection index, which is more conducive to improving the information output of related words, thereby meeting the needs of generating marketing texts of different lengths.

[0145] In another optional embodiment, the above-mentioned word vector quantum information includes first word vector quantum information and second word vector quantum information;

[0146] The first word vector sub-information includes index identification information, the first word vector and the second word vector; the dimension of the second word vector is greater than or equal to 4;

[0147] The second word vector information includes first connected entity identification information and second connected entity identification information; the first connected entity identification information and the second connected entity identification information represent the link relationship.

[0148] Optionally, the above index identification information is used to index entities in the knowledge graph.

[0149] Optionally, the dimension of the first word vector is variable.

[0150] Preferably, the dimension of the first word vector is 100.

[0151] Optionally, the dimensional information in the second word vector is used to represent the number of associated advertisements, the number of associated materials, the number of associated products and the number of searches.

[0152] Preferably, the dimension of the first word vector information is 105.

[0153] Optionally, the first word vector is located between the index identification information and the second word vector.

[0154] Optionally, the direction of the above link relationship is from right to left.

[0155] Optionally, the first connection entity identification information is an identification of a connected entity.

[0156] Optionally, the second connection entity identification information is an identification of an entity that issues a connection.

[0157] Optionally, the above entity may represent a node.

[0158] It can be seen that the word vector quantum information in the data processing method based on the graph attention network described in the embodiment of the present invention includes the first word vector quantum information and the second word vector quantum information representing the link relationship, which is more conducive to improving the information output of related words, thereby meeting the needs of generating marketing texts of different lengths.

[0159] Embodiment 3

[0160] See also Figure 3 , Figure 3 is a schematic diagram of a data processing device based on a graph attention network disclosed in an embodiment of the present invention. Figure 3 The described device can be applied to a data processing system, such as a local server or a cloud server for data processing management based on a graph attention network, and the embodiments of the present invention are not limited thereto. Figure 3As shown, the device may include:

[0161] The detection module 301 is used to detect whether a text generation request is received and obtain a detection result; the text generation request includes a number of input words;

[0162] The first processing module 302 is used to process the text generation request using a preset information association model to obtain attribute word information when the detection result is yes; the attribute word information includes L attribute word sub-information; L is a positive integer greater than or equal to 1; the information association model includes a first information association model based on a graph attention network, and / or a second information association model;

[0163] The second processing module 303 is used to sort and filter the attribute word information to obtain target text word information; the target text word information includes a number of target text words; the target text words are used to generate marketing texts.

[0164] It can be seen that the implementation Figure 3 The described data processing device based on graph attention network can use the information association model to process the text generation request to obtain attribute word information, and then obtain the target text words for generating marketing text through comprehensive processing such as sorting and screening the attribute word information, which is conducive to improving the information output of related words, thereby meeting the needs of generating marketing texts of different lengths.

[0165] In another optional embodiment, Figure 4 As shown, the first processing module 302 includes a first processing submodule 3021 and a second processing submodule 3022, wherein:

[0166] The first processing submodule 3021 is used to process all input words using the first information association model to obtain word vector information; the input word vector information includes a plurality of word vector sub-information;

[0167] The second processing sub-module 3022 is used to process the word vector information using the second information association model to obtain attribute word information; the attribute word information includes the first node word information, and / or, the second node word information, and / or, the third node word information; the first node word information, the second node word information and the third node word information respectively include T attribute word sub-information; T is a positive integer greater than or equal to 1.

[0168] It can be seen that the implementation Figure 4 The described data processing device based on graph attention network can use the first information association model and the second information association model to comprehensively process the input words to obtain attribute word information, which is beneficial to improving the information output of related words, thereby meeting the needs of generating marketing texts of different lengths.

[0169] In yet another optional embodiment, Figure 4 As shown, the second information association model includes a first association sub-model, and / or a second association sub-model, and / or a third association sub-model;

[0170] The second processing submodule 3022 processes the word vector information using the second information association model to obtain the attribute word information in the following specific manner:

[0171] Input the word vector information into the first association sub-model to obtain the first node word information; the first node word information represents the association relationship between the current node and the directly associated node in the graph attention network; and / or,

[0172] Input the word vector information into the second associated sub-model to obtain the second node word information; the second node word information represents the association relationship between the current node and the first indirect associated node in the graph attention network; the current node and the first indirect associated node are separated by one node; and / or,

[0173] The word vector information is input into the third associated sub-model to obtain the third node word information; the third node word information representation graph pays attention to the association relationship between the current node and the second non-directly associated node in the network; the current node and the second non-directly associated node are separated by two nodes.

[0174] It can be seen that the implementation Figure 4 The described data processing device based on graph attention network can utilize the first association sub-model, the second association sub-model and the third association sub-model to process the word vector information to obtain the first node word information, the second node word information and the third node word information respectively, which is beneficial to improve the information output of associated words, thereby meeting the needs of generating marketing texts of different lengths.

[0175] In yet another optional embodiment, Figure 4 As shown, the first processing submodule 3021 processes all input words using the first information association model, and the specific method of obtaining word vector information is as follows:

[0176] For any input word, determine whether the preset knowledge graph contains the input word and obtain the input judgment result;

[0177] When the input judgment result is yes, the input word is input into the first information association model to obtain the attribute word sub-information corresponding to the input word;

[0178] When the input judgment result is no, the input word is processed using the preset word threshold and the first information association model to obtain the threshold word information corresponding to the input word; the threshold word information includes M attribute word sub-information; M matches the word threshold; M is a positive integer greater than or equal to 1.

[0179] It can be seen that the implementation Figure 4The described data processing device based on graph attention network can obtain attribute word information through comprehensive processing of input words by knowledge graph and first information association model, which is more conducive to improving the information output of related words, thereby meeting the needs of marketing text generation of different lengths.

[0180] In yet another optional embodiment, Figure 4 As shown, the text generation request also includes text length information;

[0181] The second processing module 303 performs sorting and screening processing on the attribute word information to obtain the target text word information in the following specific manner:

[0182] Calculate and sort the attribute word information to obtain an attribute word sequence;

[0183] The attribute word sequence and text length information are processed to obtain the target text word information.

[0184] It can be seen that the implementation Figure 4 The described data processing device based on graph attention network can use the information association model to process the text generation request to obtain attribute word information, then obtain the attribute word sequence by sorting the attribute word information, and then obtain the target text word for generating marketing text by processing the attribute word sequence and text length information, which is beneficial to improve the information output of related words, thereby meeting the needs of generating marketing texts of different lengths.

[0185] In yet another optional embodiment, Figure 4 As shown, the second processing module 303 performs calculation and sorting processing on the attribute word information to obtain the specific method of the attribute word sequence:

[0186] The attribute word information is subjected to heat index calculation using a preset heat model to obtain word selection index information; the word selection index information includes a number of word selection indexes; the heat model is used to process at least 5 word selection indexes of any word in the attribute word information to the quantum information;

[0187] All the word selection indexes in the word selection index information are sorted from large to small to obtain an attribute word sequence.

[0188] It can be seen that the implementation Figure 4 The described data processing device based on graph attention network can obtain word selection index information by calculating and processing attribute word information through the heat model, and then obtain the attribute word sequence by sorting the word selection index, which is more conducive to improving the information output of related words, thereby meeting the needs of marketing text generation of different lengths.

[0189] In yet another optional embodiment, Figure 4 As shown, the word vector quantum information includes first word vector quantum information and second word vector quantum information;

[0190] The first word vector sub-information includes index identification information, the first word vector and the second word vector; the dimension of the second word vector is greater than or equal to 4;

[0191] The second word vector information includes first connected entity identification information and second connected entity identification information; the first connected entity identification information and the second connected entity identification information represent the link relationship.

[0192] It can be seen that the implementation Figure 4 The word vector quantum information in the described graph attention network-based data processing device includes first word vector quantum information and second word vector quantum information representing link relationships, which is more conducive to improving the information output of related words, thereby meeting the needs of generating marketing texts of different lengths.

[0193] Embodiment 4

[0194] See also Figure 5 , Figure 5 is a structural diagram of another data processing device based on a graph attention network disclosed in an embodiment of the present invention. Figure 5 The described device can be applied to a data processing system, such as a local server or a cloud server for data processing management based on a graph attention network, and the embodiments of the present invention are not limited thereto. Figure 5 As shown, the device may include:

[0195] A memory 401 storing executable program codes;

[0196] a processor 402 coupled to the memory 401;

[0197] The processor 402 calls the executable program code stored in the memory 401 to execute the steps in the data processing method based on the graph attention network described in the first or second embodiment.

[0198] Embodiment 5

[0199] An embodiment of the present invention discloses a computer-readable storage medium storing a computer program for electronic data exchange, wherein the computer program enables a computer to execute the steps of the data processing method based on a graph attention network described in Embodiment 1 or Embodiment 2.

[0200] Embodiment 6

[0201] An embodiment of the present invention discloses a computer program product, which includes a non-transitory computer-readable storage medium storing a computer program, and the computer program is operable to enable a computer to execute the steps in the data processing method based on a graph attention network described in Embodiment 1 or Embodiment 2.

[0202] The device embodiments described above are only illustrative, wherein the modules described as separate components may or may not be physically separated, and the components displayed as modules may or may not be physical modules, i.e., they may be located in one place, or they may be distributed on multiple network modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Those of ordinary skill in the art may understand and implement it without creative work.

[0203] Through the specific description of the above embodiments, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on such an understanding, the above technical solution can be essentially or partly contributed to the prior art in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, and the storage medium includes a read-only memory (ROM), a random access memory (RAM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), a one-time programmable read-only memory (OTPROM), an electronically erasable rewritable read-only memory (EEPROM), a compact disc (CD-ROM) or other optical disc storage, magnetic disk storage, magnetic tape storage, or any other computer-readable medium that can be used to carry or store data.

[0204] Finally, it should be noted that the data processing method and device based on graph attention network disclosed in the embodiment of the present invention only disclose the preferred embodiments of the present invention, which are only used to illustrate the technical scheme of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical schemes described in the aforementioned embodiments can still be modified, or some of the technical features can be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical schemes from the spirit and scope of the technical schemes of the embodiments of the present invention.

Claims

1. A data processing method based on graph attention network, characterized in that: The method comprises: Detecting whether a text generation request is received and obtaining a detection result; the text generation request includes a plurality of input words; When the detection result is yes, the text generation request is processed using a preset information association model to obtain attribute word information; the attribute word information includes L attribute word sub-information; L is a positive integer greater than or equal to 1; the information association model includes a first information association model and a second information association model, wherein the type of the first information association model is a word vector model type and is used to analyze all the input words to obtain multiple word vector information, the second information association model includes a first association sub-model, the first association sub-model includes N graph attention layers, and the second information association model is used to analyze all the word vector information to obtain the attribute word information; The attribute word information is sorted and screened to obtain target text word information; the target text word information includes a plurality of target text words; the target text words are used to generate marketing texts.

2. The data processing method based on graph attention network according to claim 1 is characterized in that: The using of a preset information association model to process the text generation request to obtain attribute word information includes: Using the first information association model to process all the input words to obtain word vector information; the input word vector information includes a plurality of word vector sub-information; The word vector information is processed using the second information association model to obtain attribute word information; the attribute word information includes first node word information, and / or second node word information, and / or third node word information; the first node word information, the second node word information and the third node word information respectively include T attribute word sub-information; T is a positive integer greater than or equal to 1.

3. The data processing method based on graph attention network according to claim 2 is characterized in that: The second information association model includes a first association sub-model, and / or a second association sub-model, and / or a third association sub-model; The using the second information association model to process the word vector information to obtain attribute word information includes: Inputting the word vector information into the first associated sub-model to obtain the first node word information; the first node word information represents the association relationship between the current node and the directly associated node in the graph attention network; and / or, Input the word vector information into the second associated sub-model to obtain the second node word information; the second node word information represents the association relationship between the current node and the first indirect associated node in the graph attention network; the current node and the first indirect associated node are separated by one node; and / or, The word vector information is input into the third associated sub-model to obtain the third node word information; the third node word information represents the association relationship between the current node and the second non-directly associated node in the graph attention network; the current node and the second non-directly associated node are separated by two nodes.

4. The data processing method based on graph attention network according to claim 2 is characterized in that: The using the first information association model to process all the input words to obtain word vector information includes: For any of the input words, determine whether a preset knowledge graph contains the input word, and obtain an input determination result; When the input judgment result is yes, the input word is input into the first information association model to obtain attribute word sub-information corresponding to the input word; When the input judgment result is no, the input word is processed using the preset word threshold and the first information association model to obtain the threshold word information corresponding to the input word; the threshold word information includes M attribute word sub-information; M matches the word threshold; M is a positive integer greater than or equal to 1.

5. The data processing method based on graph attention network according to claim 1 is characterized in that: The text generation request also includes text length information; The step of sorting and screening the attribute word information to obtain target text word information includes: Calculating and sorting the attribute word information to obtain an attribute word sequence; The attribute word sequence and the text length information are processed to obtain target text word information.

6. The data processing method based on graph attention network according to claim 5 is characterized in that: The calculating and sorting the attribute word information to obtain an attribute word sequence includes: Using a preset heat model to calculate the heat index of the attribute word information to obtain word selection index information; the word selection index information includes a plurality of word selection indexes; the heat model is used to process at least 5 word selection indexes of any word vector information in the attribute word information; All the word selection indexes in the word selection index information are sorted from large to small to obtain an attribute word sequence.

7. The data processing method based on graph attention network according to any one of claims 1 to 6, characterized in that: The word vector quantum information includes first word vector quantum information and second word vector quantum information; The first word vector sub-information includes index identification information, a first word vector and a second word vector; the dimension of the second word vector is greater than or equal to 4; The second word vector sub-information includes first connected entity identification information and second connected entity identification information; the first connected entity identification information and the second connected entity identification information represent a link relationship.

8. A data processing device based on a graph attention network, characterized in that: The device comprises: A detection module, used to detect whether a text generation request is received and obtain a detection result; the text generation request includes a number of input words; A first processing module, for, when the detection result is yes, using a preset information association model to process the text generation request to obtain attribute word information; the attribute word information includes L attribute word sub-information; L is a positive integer greater than or equal to 1; the information association model includes a first information association model and a second information association model based on a graph attention network, wherein the type of the first information association model is a word vector model type and is used to analyze all the input words to obtain multiple word vector information, the second information association model includes a first association sub-model, the first association sub-model includes N graph attention layers, and the second information association model is used to analyze all the word vector information to obtain the attribute word information; The second processing module is used to sort and filter the attribute word information to obtain target text word information; the target text word information includes a plurality of target text words; the target text words are used to generate marketing texts.

9. A data processing device based on a graph attention network, characterized in that: The device comprises: A memory storing executable program code; a processor coupled to the memory; The processor calls the executable program code stored in the memory to execute the data processing method based on the graph attention network as described in any one of claims 1-7.

10. A computer storable medium, characterized in that: The computer storage medium stores computer instructions, which, when called, are used to execute the data processing method based on the graph attention network as described in any one of claims 1-7.