CN114579878A - Training method of false news discrimination model, false news discrimination method and device - Google Patents

Training method of false news discrimination model, false news discrimination method and device Download PDF

Info

Publication number
CN114579878A
CN114579878A CN202210254714.XA CN202210254714A CN114579878A CN 114579878 A CN114579878 A CN 114579878A CN 202210254714 A CN202210254714 A CN 202210254714A CN 114579878 A CN114579878 A CN 114579878A
Authority
CN
China
Prior art keywords
news
target
node
content
verification
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210254714.XA
Other languages
Chinese (zh)
Inventor
李晓宇
王志舒
金力
孙显
马豪伟
董鹏程
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Aerospace Information Research Institute of CAS
Original Assignee
Aerospace Information Research Institute of CAS
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Aerospace Information Research Institute of CAS filed Critical Aerospace Information Research Institute of CAS
Priority to CN202210254714.XA priority Critical patent/CN114579878A/en
Publication of CN114579878A publication Critical patent/CN114579878A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/953Querying, e.g. by the use of web search engines
    • G06F16/9536Search customisation based on social or collaborative filtering
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • G06F18/241Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q50/00Systems or methods specially adapted for specific business sectors, e.g. utilities or tourism
    • G06Q50/01Social networking

Abstract

The disclosure provides a training method of a false news discrimination model, a false news discrimination method and a false news discrimination device. The training method comprises the steps of obtaining a news training sample set, wherein the news training sample set comprises a plurality of training samples and label data corresponding to the training samples, the training samples comprise abnormal patterns, the abnormal patterns are generated according to nodes related to news and node relations, the nodes comprise a plurality of initial vectors respectively corresponding to news content, promotion content and user information, and the node relations comprise adjacency matrixes generated according to incidence relations and attention relations corresponding to the news; inputting training samples in the news training sample set into the heteromorphic neural network, and outputting a prediction result; inputting the prediction result and the label data into a loss function to obtain a loss result; and iteratively adjusting network parameters of the neural network of the heterogeneous graph according to the loss result to generate a trained false news discrimination model.

Description

Training method of false news discrimination model, false news discrimination method and device
Technical Field
The present disclosure relates to the technical field of false news discrimination, and more particularly, to a training method of a false news discrimination model, a false news discrimination method, a training device of a false news discrimination model, a false news discrimination device, an electronic device, a readable storage medium, and a program product.
Background
The false news refers to wrong news published by related people or organizations for the purpose of self, which misleads the public opinion of the public and causes great damage to political and economic development. With the development of internet in recent years, false news is spread on various social platforms at an accelerated speed, and in the face of high counterfeiting skills and massive false information, a traditional manual identification mode consumes a large amount of human resources and is difficult to obtain a good identification effect.
Disclosure of Invention
In view of the above, the embodiments of the present disclosure provide a training method for a false news discrimination model, a false news discrimination method, a training apparatus for a false news discrimination model, a false news discrimination apparatus, an electronic device, a readable storage medium, and a program product.
One aspect of the embodiments of the present disclosure provides a training method for a false news discrimination model, including:
acquiring a news training sample set, wherein the news training sample set comprises a plurality of training samples and label data corresponding to the training samples, the training samples comprise heteromorphic graphs, the heteromorphic graphs are generated according to nodes related to news and node relations, the nodes comprise a plurality of initial vectors respectively corresponding to news content, promotion content and user information, and the node relations comprise adjacency matrixes generated according to incidence relations and attention relations corresponding to the news;
inputting the training samples in the news training sample set into a heterogeneous graph neural network, and outputting a prediction result;
inputting the prediction result and the label data into a loss function to obtain a loss result;
iteratively adjusting network parameters of the heteromorphic graph neural network according to the loss result to generate a trained false news discrimination model;
the heteromorphic graph neural network comprises a first attention mechanism layer, a second attention mechanism layer, a full connection layer and a normalization layer;
wherein, the above-mentioned training sample that will concentrate on above-mentioned news training sample inputs the neural network of heterogeneous map, output the prediction result, include:
obtaining a node feature matrix and a node relationship matrix according to the heteromorphic graph, wherein the node relationship matrix comprises the adjacency matrix, the node feature matrix comprises a plurality of news nodes, the node relationship matrix comprises node relationships among the news nodes, and the news nodes comprise a plurality of initial vectors respectively corresponding to the news content, the promotion content and the user information;
for each news node, processing the news node and the node relation related to the news node by using the first attention mechanism layer to obtain a first attention value;
determining related news nodes related to the news nodes according to the node relation of the news nodes;
processing the first attention value and the associated news node by using the second attention mechanism layer to obtain a second attention value of the news node;
determining a first feature vector according to a plurality of the second attention values and a graph network calculation formula;
processing a plurality of first eigenvectors by using the full connection layer to obtain a second eigenvector;
and processing the second feature vector by using the normalization layer to obtain the prediction result.
According to the embodiment of the disclosure, the association relationship comprises a reference relationship, a load transfer relationship and a release relationship;
the training samples are generated in the following mode:
acquiring the news content, the promotion content and the user information, wherein the promotion content is obtained by querying keywords of the news content through an information query interface, and the user information comprises user data and social relations;
generating a plurality of initial vectors corresponding to the news content, the promotion content, and the user information, respectively, based on the news content, the promotion content, and the user information, respectively;
generating the adjacency matrix according to the reference relationship, the reprint relationship, the issue relationship and the attention relationship;
generating the training sample including the abnormal pattern based on the plurality of initial vectors and the adjacency matrix.
According to an embodiment of the present disclosure, the generating a plurality of initial vectors respectively corresponding to the news content, the promotion content, and the user information according to the news content, the promotion content, and the user information includes:
under the condition that the news content comprises text information, a text vector of the text information is obtained by using a paragraph vector method;
under the condition that the news content comprises image information, acquiring an image vector of the image information by using a local binary method;
generating the initial vector corresponding to the news content according to the text vector and/or the image vector;
under the condition that the promotion content comprises original content, acquiring an original vector of the original content by using a paragraph vector method;
under the condition that the promotion content comprises the reprinted content, processing a user viewpoint corresponding to the reprinted content by using a paragraph vector method to obtain a reprinted vector;
generating the initial vector corresponding to the promotion content according to the original vector and/or the transfer vector;
under the condition that the user information comprises text type information, processing the user information by using a paragraph vector method to obtain a text type vector;
under the condition that the user information comprises image information, acquiring an image vector of the image information by using a local binary method;
and generating the initial vector corresponding to the user information according to the text class vector and/or the image class vector.
According to an embodiment of the present disclosure, the image information includes a plurality of image elements and a pixel value corresponding to each of the image elements;
wherein, in the case that the news content includes image information, acquiring an image vector of the image information by using a local binary method includes:
for each of the image elements, processing the pixel values of the image element and the pixel values of the image elements related to the image element by the local binary method to obtain a local binary value of the image element;
and normalizing the plurality of local binary values to obtain the image vector of the image information.
According to the embodiment of the disclosure, the training method of the false news discrimination model further comprises the following steps:
obtaining a news verification sample set, wherein the news verification sample set comprises a plurality of verification samples and verification label data corresponding to the verification samples, the verification samples comprise verification abnormal patterns generated according to verification nodes related to verification news and verification node relations, the verification nodes comprise a plurality of verification initial vectors respectively corresponding to verification news contents, verification promotion contents and verification user information, the verification node relations comprise verification adjacent matrixes generated according to verification incidence relations and verification attention relations, and one-to-one correspondence relations exist between the verification label data and the verification news contents;
inputting a plurality of verification samples into the false news discrimination model and outputting verification results, wherein the verification results comprise verification sub-results corresponding to each verification sample;
matching and comparing the prediction result with a plurality of verification label data to obtain a comparison result;
and under the condition that the comparison result shows that the quantity ratio of the verification result which is the same as the verification label data in the verification results meets the preset ratio, determining the false news discrimination model as a target false news discrimination model.
Another aspect of the embodiments of the present disclosure provides a method for discriminating a false news, including:
acquiring a news data set to be distinguished, wherein the news data set to be distinguished comprises target news, target promotion content, target user information, a target association relation and a target attention relation, and the target promotion content, the target user information, the target association relation and the target attention relation are respectively related to the target news;
generating an abnormal picture to be identified according to the news data set to be distinguished;
and inputting the heterogeneous graph to be identified into a false news discrimination model, and outputting a recognition result, wherein the recognition result is used for representing the true and false types of the target news, and the false news discrimination model is obtained by training by using the method.
According to the embodiment of the disclosure, the target association relationship comprises a target reference relationship, a target reprint relationship and a target release relationship;
wherein, the generating of the abnormal picture to be identified according to the news data set to be distinguished comprises:
generating a plurality of target vectors respectively corresponding to the target news, the target promotion content and the target user information according to the target news, the target promotion content and the target user information;
generating a target adjacency matrix according to the target reference relationship, the target reprint relationship, the target release relationship and the target attention relationship;
and generating the abnormal composition to be identified according to the target vectors and the target adjacency matrix.
Another aspect of the embodiments of the present disclosure provides a training apparatus for a false news discrimination model, including:
a first obtaining module, configured to obtain a news training sample set, where the news training sample set includes a plurality of training samples and tag data corresponding to the training samples, where the training samples include an abnormal graph, the abnormal graph is generated according to a node and a node relationship related to news, the node includes a plurality of initial vectors respectively corresponding to news content, promotion content, and user information, and the node relationship includes an adjacency matrix generated according to an association relationship and an attention relationship corresponding to the news;
the prediction module is used for inputting the training samples in the news training sample set into a heterogeneous graph neural network and outputting a prediction result;
the calculation module is used for inputting the prediction result and the label data into a loss function to obtain a loss result; and
an iteration module, configured to iteratively adjust network parameters of the heteromorphic graph neural network according to the loss result, and generate the trained false news discrimination model;
the heteromorphic graph neural network comprises a first attention mechanism layer, a second attention mechanism layer, a full connection layer and a normalization layer;
wherein, the prediction module comprises:
an obtaining submodule configured to obtain a node feature matrix and a node relationship matrix according to the heterogeneous map, where the node relationship matrix includes the adjacent matrix, the node feature matrix includes a plurality of news nodes, the node relationship matrix includes a node relationship among the plurality of news nodes, and the plurality of news nodes include a plurality of initial vectors corresponding to the news content, the promotion content, and the user information, respectively;
a first processing submodule, configured to, for each of the news nodes, process the news node and the node relationship related to the news node by using the first attention mechanism layer, so as to obtain a first attention value;
the first determining submodule is used for determining related news nodes related to the news nodes according to the node relation of the news nodes;
a second processing sub-module, configured to process the first attention value and the associated news node by using the second attention mechanism layer to obtain a second attention value of the news node;
a second determining submodule for determining a first feature vector according to a plurality of the second attention values and a graph network calculation formula;
a third processing sub-module, configured to process the plurality of first eigenvectors by using the full connection layer to obtain a second eigenvector;
and the normalization submodule is used for processing the second feature vector by utilizing the normalization layer to obtain the prediction result.
Another aspect of the embodiments of the present disclosure provides a false news determination apparatus, including:
the second acquisition module is used for acquiring a news data set to be distinguished, wherein the news data set to be distinguished comprises target news, target promotion content, target user information, a target association relation and a target attention relation which are respectively related to the target news;
the generating module is used for generating an abnormal picture to be identified according to the news data set to be distinguished; and
and the identification module is used for inputting the heterogeneous graph to be identified into a false news discrimination model and outputting an identification result, wherein the identification result is used for representing the true and false types of the target news, and the false news discrimination model is obtained by training by using the method.
Another aspect of an embodiment of the present disclosure provides an electronic device including: one or more processors; memory for storing one or more programs, wherein the one or more programs, when executed by the one or more processors, cause the one or more processors to implement the method as described above.
Another aspect of embodiments of the present disclosure provides a computer-readable storage medium storing computer-executable instructions for implementing the method as described above when executed.
Another aspect of embodiments of the present disclosure provides a computer program product comprising computer executable instructions for implementing the method as described above when executed.
According to the embodiment of the disclosure, by utilizing the node relationship formed by the incidence relationship and the attention relationship corresponding to news and the node formed by a plurality of initial vectors corresponding to news content, promotion content and user information, the training sample formed by the node and the node relationship is used for training the neural network of the heterogeneous graph to obtain the false news judgment model, and the training sample fully considers the node relationship related to the news content, so that the identification result of the to-be-identified news of the trained false news judgment model can accurately determine whether the to-be-identified news is the false news, and the technical problem that the false news cannot be accurately identified and the cognition of a user is easily influenced is at least partially solved.
Drawings
The above and other objects, features and advantages of the present disclosure will become more apparent from the following description of embodiments of the present disclosure with reference to the accompanying drawings, in which:
FIG. 1 schematically illustrates an exemplary system architecture of a training method applying a false news discrimination model or a false news discrimination method according to an embodiment of the present disclosure;
FIG. 2 schematically illustrates a flow chart of a method of training a false news discrimination model according to an embodiment of the present disclosure;
FIG. 3 schematically illustrates a structural diagram of a false news discrimination model according to an embodiment of the present disclosure;
FIG. 4 schematically illustrates a flow chart of a method of training a false news discrimination model according to an embodiment of the present disclosure;
FIG. 5 schematically illustrates a block diagram of a training apparatus for a false news discrimination model according to an embodiment of the present disclosure;
FIG. 6 schematically shows a block diagram of a false news discrimination apparatus according to an embodiment of the present disclosure; and
fig. 7 schematically shows a block diagram of an electronic device implementing a training method of a false news discrimination model or a false news discrimination method according to an embodiment of the present disclosure.
Detailed Description
Hereinafter, embodiments of the present disclosure will be described with reference to the accompanying drawings. It should be understood that the description is illustrative only and is not intended to limit the scope of the present disclosure. In the following detailed description, for purposes of explanation, numerous specific details are set forth in order to provide a thorough understanding of the embodiments of the disclosure. It may be evident, however, that one or more embodiments may be practiced without these specific details. Moreover, in the following description, descriptions of well-known structures and techniques are omitted so as to not unnecessarily obscure the concepts of the present disclosure.
The terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the disclosure. The terms "comprises," "comprising," and the like, as used herein, specify the presence of stated features, steps, operations, and/or components, but do not preclude the presence or addition of one or more other features, steps, operations, or components.
All terms (including technical and scientific terms) used herein have the same meaning as commonly understood by one of ordinary skill in the art unless otherwise defined. It is noted that the terms used herein should be interpreted as having a meaning that is consistent with the context of this specification and should not be interpreted in an idealized or overly formal sense.
Where a convention analogous to "at least one of A, B and C, etc." is used, in general such a construction is intended in the sense one having skill in the art would understand the convention (e.g., "a system having at least one of A, B and C" would include but not be limited to systems that have a alone, B alone, C alone, a and B together, a and C together, B and C together, and/or A, B, C together, etc.).
The embodiment of the disclosure provides a training method of a false news discrimination model, a false news discrimination method and a false news discrimination device. The training method comprises the steps of obtaining a news training sample set, wherein the news training sample set comprises a plurality of training samples and label data corresponding to the training samples, the training samples comprise abnormal patterns, the abnormal patterns are generated according to nodes related to news and node relations, the nodes comprise a plurality of initial vectors respectively corresponding to news content, promotion content and user information, and the node relations comprise adjacency matrixes generated according to incidence relations and attention relations corresponding to the news; inputting training samples in the news training sample set into the heteromorphic neural network, and outputting a prediction result; inputting the prediction result and the label data into a loss function to obtain a loss result; and iteratively adjusting network parameters of the neural network of the heterogeneous graph according to the loss result to generate a trained false news discrimination model.
Fig. 1 schematically illustrates an exemplary system architecture 100 to which a training method of a false news discrimination model or a false news discrimination method may be applied, according to an embodiment of the present disclosure. It should be noted that fig. 1 is only an example of a system architecture to which the embodiments of the present disclosure may be applied to help those skilled in the art understand the technical content of the present disclosure, and does not mean that the embodiments of the present disclosure may not be applied to other devices, systems, environments or scenarios.
As shown in fig. 1, the system architecture 100 according to this embodiment may include terminal devices 101, 102, 103, a network 104 and a server 105. The network 104 serves as a medium for providing communication links between the terminal devices 101, 102, 103 and the server 105. Network 104 may include various connection types, such as wired and/or wireless communication links, and so forth.
The user may use the terminal devices 101, 102, 103 to interact with the server 105 via the network 104 to receive or send messages or the like. The terminal devices 101, 102, 103 may have various messaging client applications installed thereon, such as a model training shopping application, a news discrimination application, a web browser application, a search application, an instant messaging tool, a mailbox client, and/or social platform software, etc. (by way of example only).
The terminal devices 101, 102, 103 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop portable computers, desktop computers, and the like.
The server 105 may be a server providing various services, such as a background management server (for example only) providing support for websites browsed by users using the terminal devices 101, 102, 103. The background management server may analyze and perform other processing on the received data such as the user request, and feed back a processing result (e.g., a webpage, information, or data obtained or generated according to the user request) to the terminal device.
It should be noted that the training method of the false news determination model or the false news determination method provided by the embodiment of the present disclosure may be generally executed by the server 105. Accordingly, the training device of the false news determination model or the false news determination device provided by the embodiment of the present disclosure can be generally disposed in the server 105. The training method of the false news discrimination model or the false news discrimination method provided by the embodiment of the present disclosure may also be performed by a server or a server cluster that is different from the server 105 and is capable of communicating with the terminal devices 101, 102, 103 and/or the server 105. Accordingly, the training device of the false news determination model or the false news determination device provided by the embodiment of the present disclosure may also be disposed in a server or a server cluster different from the server 105 and capable of communicating with the terminal devices 101, 102, 103 and/or the server 105. Alternatively, the training method of the false news discrimination model or the false news discrimination method provided by the embodiment of the present disclosure may also be executed by the terminal device 101, 102, or 103, or may also be executed by another terminal device different from the terminal device 101, 102, or 103. Accordingly, the training device of the false news determination model or the false news determination device provided by the embodiment of the disclosure may also be disposed in the terminal device 101, 102, or 103, or in another terminal device different from the terminal device 101, 102, or 103.
It should be understood that the number of terminal devices, networks, and servers in fig. 1 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
FIG. 2 schematically shows a flow chart of a method of training a false news discrimination model according to an embodiment of the present disclosure.
As shown in FIG. 2, the training method of the false news discrimination model includes operations S201 to S204.
In operation S201, a news training sample set is obtained, where the news training sample set includes a plurality of training samples and label data corresponding to the training samples, where the training samples include an abnormal composition, the abnormal composition is generated according to a node related to news and a node relationship, the node includes a plurality of initial vectors respectively corresponding to news content, promotion content, and user information, and the node relationship includes an adjacency matrix generated according to an association relationship and an attention relationship corresponding to news.
In operation S202, the training samples in the news training sample set are input to the heteromorphic neural network, and a prediction result is output.
In operation S203, the prediction result and the tag data are input to a loss function, resulting in a loss result.
In operation S204, network parameters of the neural network of the heterogeneous graph are iteratively adjusted according to the loss result, and a trained false news discrimination model is generated.
According to an embodiment of the present disclosure, the association relationship may refer to a relationship whether to refer to the news, whether to download the news, or whether to publish the news.
According to an embodiment of the present disclosure, promotional content may refer to content that has promotional properties, such as a user may post a subjective opinion of news by publishing the content.
According to the embodiment of the disclosure, a heterogeneous Graph neural network (HetGNN) can integrate information of various types of nodes and edges composed of heterogeneous structures, and also can consider heterogeneous attributes and heterogeneous contents associated with each node.
According to an embodiment of the present disclosure, the attention relationship may refer to an attention object of the user and a user who is concerned by other users, for example, a user who is concerned by publishing the news, or may refer to a social relationship. The user information may refer to authentication information of the user in the user's homepage.
According to the embodiment of the disclosure, after a news training sample set is obtained, the training samples in the news training sample set are input into a heterogeneous graph neural network, a prediction result corresponding to the training samples is output, a loss result corresponding to the training samples is calculated according to the prediction result and corresponding label data, so that network parameters of the heterogeneous graph neural network are adjusted iteratively according to the loss result, and a trained false news distinguishing model can be generated.
According to the embodiment of the disclosure, by utilizing the node relationship formed by the incidence relationship and the attention relationship corresponding to news and the node formed by a plurality of initial vectors corresponding to news content, promotion content and user information, the training sample formed by the node and the node relationship is used for training the neural network of the heterogeneous graph to obtain the false news judgment model, and the training sample fully considers the node relationship related to the news content, so that the identification result of the to-be-identified news of the trained false news judgment model can accurately determine whether the to-be-identified news is the false news, and the technical problem that the false news cannot be accurately identified and the cognition of a user is easily influenced is at least partially solved.
According to an embodiment of the present disclosure, the association relationship includes a reference relationship, a reprint relationship, and a release relationship.
According to an embodiment of the present disclosure, training samples are generated by:
the method comprises the steps of obtaining news content, promotion content and user information, wherein the promotion content is obtained by inquiring keywords of the news content through an information inquiry interface, and the user information comprises user data and social relations. And generating a plurality of initial vectors respectively corresponding to the news content, the promotion content and the user information according to the news content, the promotion content and the user information. And generating an adjacency matrix according to the reference relation, the transfer relation, the release relation and the attention relation. Training samples including the anomaly map are generated based on the plurality of initial vectors and the adjacency matrix.
According to the embodiment of the disclosure, the source of the news content can be various commercial websites, and the commercial websites can detect whether the news is true or false and provide the judgment of real or false news by experts in various fields, so that the news content can be used as a data source of a news training sample set. The information query interface may include, but is not limited to, an enterprise Api interface that provides social services.
According to the embodiment of the disclosure, under the condition of obtaining news content, the keywords of the news are extracted, the popularization content corresponding to the news content can be obtained by using the information query interface, and meanwhile, the user data and the social relation for releasing the popularization content are obtained.
According to the embodiment of the disclosure, in order to integrate multi-level social background information, the embodiment of the disclosure constructs a heterogeneous graph including nodes of three types, namely news content, promotion content and user information, wherein the heterogeneous graph includes edges of four types, namely a reference relationship, a reprint relationship, a release relationship and an attention relationship, and can be represented as G ═ V, E, where V represents a node and E represents a node relationship or different types of edges.
According to the embodiment of the disclosure, the nodes in the abnormal graph are generated according to the obtained initial vectors of the news content, the promotion content and the user information, and the adjacency matrix is generated according to the reference relationship, the transfer relationship, the release relationship and the attention relationship, wherein the adjacency matrix can represent the node relationship.
According to an embodiment of the present disclosure, generating a plurality of initial vectors corresponding to news content, promotion content, and user information, respectively, according to the news content, the promotion content, and the user information, respectively, may include the following operations:
in the case where the news content includes text information, a text vector of the text information is acquired using a paragraph vector method. In the case where the news content includes image information, an image vector of the image information is acquired using a local binary method. An initial vector corresponding to the news content is generated based on the text vector and/or the image vector. And under the condition that the promotion content comprises the original content, acquiring an original vector of the original content by using a paragraph vector method. And under the condition that the promotion content comprises the reprinted content, processing a user viewpoint corresponding to the reprinted content by using a paragraph vector method to obtain a reprinted vector. And generating an initial vector corresponding to the promotion content according to the original vector and/or the transfer vector. And processing the user information by using a paragraph vector method to obtain an initial vector corresponding to the user information.
According to the embodiment of the disclosure, the news content includes two modalities, namely text information and image information, and in the case that the news content is text information, the text information can be processed by using a paragraph vector method, so as to obtain a corresponding text vector. The paragraph vector method may include a Doc2Vec algorithm.
According to an embodiment of the present disclosure, in a case where news content includes image information, the image information may be processed using a local binary method, thereby obtaining a corresponding image vector. The local Binary method comprises an LBP (local Binary Pattern) algorithm. The text vector and the image vector are fused to obtain an initial vector corresponding to the news content.
According to the embodiment of the disclosure, the promotion content generally comprises two types of original content and reprinted content. Under the condition that the promotion content is original content or reprinted content, a paragraph vector method can be used for processing, so that a corresponding original vector or reprinted vector is obtained, and further an initial vector corresponding to the promotion content is obtained according to the original vector and/or the reprinted vector.
According to the embodiment of the disclosure, the user is an important participant in the social environment, and the identity authentication of the user is an important index of the false news judgment, so that the acquired user information can be processed by using a paragraph vector method to obtain the feature representation of the identity authentication information, and the feature representation can be used as an initial vector of the user information.
According to an embodiment of the present disclosure, image information includes a plurality of image elements and a pixel value corresponding to each image element.
According to an embodiment of the present disclosure, in a case that the news content includes image information, obtaining an image vector of the image information using a local binary method (LBP) may include the following operations:
and for each image element, processing the pixel value of the image element and the pixel value of the image element related to the image element by using a local binary method to obtain a local binary of the image element. And carrying out normalization processing on the plurality of local binary values to obtain an image vector of the image information.
According to an embodiment of the present disclosure, the LBP algorithm is calculated as shown in equation (1) and equation (2).
Figure BDA0003546887400000131
Figure BDA0003546887400000132
Wherein (x)c,yc) Characterizing a picture element in a region, the pixel value being ic,ipRepresenting pixel values of image elements within the region associated with the image element.
According to the embodiment of the disclosure, the local binary value of each image element is calculated by using an LBP algorithm, a plurality of local binary values are counted, normalization processing is carried out, and an image vector of the image information is obtained.
According to an embodiment of the present disclosure, a heterogeneous graph neural network includes a first attention mechanism layer, a second attention mechanism layer, a fully-connected layer, and a normalization layer.
According to an embodiment of the present disclosure, inputting a training sample into a neural network of a heterogeneous graph, and outputting a prediction result may include the following operations:
and obtaining a node characteristic matrix and a node relation matrix according to the abnormal composition, wherein the node relation matrix comprises an adjacency matrix, the node characteristic matrix comprises a plurality of news nodes, the node relation matrix comprises node relations among the news nodes, and the news nodes comprise a plurality of initial vectors respectively corresponding to news content, promotion content and user information. And aiming at each news node, processing the news node and the node relation related to the news node by using a first attention mechanism layer to obtain a first attention value. And determining the associated news nodes related to the news nodes according to the node relation of the news nodes. And processing the first attention value and the associated news node by using a second attention mechanism layer to obtain a second attention value of the node relation. And determining the first feature vector according to the second attention value and a graph network calculation formula. And processing the plurality of first feature vectors by using the full connection layer to obtain a second feature vector. And processing the second feature vector by utilizing a normalization layer to obtain a prediction result.
According to an embodiment of the present disclosure, the first attention value αPThe calculation of (c) is shown in formula (3) and formula (4).
hP=∑i′Aii′hi′ (3)
Figure BDA0003546887400000133
Wherein i represents a news node, P represents a relationship type connected with the news node i, A represents an initial adjacency matrix, and hPCharacterizing a feature vector of the relationship type P; l represents all relationship types connected by the central news node,
Figure BDA0003546887400000141
representing a training parameter with the relation between nodes being P, representing a nonlinear activation function by sigma, and representing vector splicing operation by | l.
According to an embodiment of the present disclosure, the second attention value βi,jThe calculation of (c) is shown in the formula.
Figure BDA0003546887400000142
Wherein h isiAnd hjSeparately characterizing news segmentsFeature vectors, h, for points i and jqThe relationship between the feature and the node i is the feature vector of the neighboring node of P,
Figure BDA0003546887400000143
and characterizing the training parameter with the relation between nodes being P, sigma characterizing the nonlinear activation function, and | | characterizing the vector splicing operation.
According to an embodiment of the present disclosure, according to a plurality of second attention values βi,jForm an attention matrix Bi,j,Bi,j=βi,jAnd combining the graph network calculation formula to obtain the target graph network calculation formula shown in the formula (6).
H(l+1)=σ(B′·H(l)·W(l)) (6)
Wherein the content of the first and second substances,
Figure BDA0003546887400000144
representing a symmetrically normalized attention matrix, Mij=∑jAi,jA represents an initial adjacency matrix, W(l)Representing a trainable transformation matrix.
According to an embodiment of the present disclosure, the first eigenvector H may be determined according to a target graph network calculation formula(l+1)And thus, the full link layer and the normalization layer are utilized for processing to obtain a prediction result.
According to an embodiment of the present disclosure, the prediction result may include a confidence ptOr other types of prediction parameters. The present embodiment is exemplified with the prediction result as the confidence.
According to the embodiment of the disclosure, the problem of difficulty and easiness in identification imbalance of the false news exists, so that the technology adopts a Focal local Loss function, and the Loss function provides a suppression factor gamma, so that the problem of difficulty and easiness in identification sample imbalance of the false news can be effectively solved. The loss function loss is shown in equation (7):
loss=-(1-pt)γlog(pt) (7)
for easily identifiable news, p, according to embodiments of the present disclosuretIs compared withLarge (1-p)t)γThe value of (c) is decreased. Therefore, the influence of easily-identified news on the loss function is reduced, and the identification capability of the model on the news with difficulty in distinguishing true news and false news is enhanced, wherein gamma is an adjusting factor set according to actual requirements.
According to an embodiment of the present disclosure, the training method of the false news discrimination model may further include the following operations:
the method comprises the steps of obtaining a news verification sample set, wherein the news verification sample set comprises a plurality of verification samples and verification label data corresponding to the verification samples, the verification samples comprise verification abnormal patterns generated according to verification nodes related to verification news and verification node relations, the verification nodes comprise a plurality of verification initial vectors corresponding to verification news content, verification promotion content and verification user information respectively, and the verification node relations comprise verification adjacent matrixes generated according to verification incidence relations and verification attention relations.
And inputting the verification samples into the false news discrimination model, and outputting verification results, wherein the verification results comprise verification sub-results respectively corresponding to each verification sample. And matching and comparing the prediction result with the plurality of verification label data to obtain a comparison result. And determining the false news discrimination model as a target false news discrimination model under the condition that the comparison result shows that the number ratio of the verification score results which are the same as the verification label data in the verification score results meets the preset ratio.
According to the embodiment of the disclosure, after the training of the false news discrimination model is completed, the accuracy of the false news discrimination model can be verified by utilizing the news verification sample set, so that the accuracy of the false news discrimination model is ensured to meet the preset requirement.
It should be noted that the process of constructing the news verification sample set is the same as the process of constructing the news training sample set, and details are not repeated here.
According to the embodiment of the disclosure, the verification samples in the news verification sample set are input into the trained false news discrimination model, the verification result can be obtained, a plurality of verification sub-results in the verification result are respectively compared with the corresponding verification label data, and the comparison result which reflects whether the result is accurate or not can be obtained. And under the condition that the comparison result shows that the proportion of the correct number of the verification results meets the preset proportion, determining the false news discrimination model as a target false news discrimination model. And under the condition that the comparison result shows that the proportion of the correct quantity does not meet the preset proportion, continuously training the false news discrimination model by using the news training sample set until the proportion of the correct quantity does not meet the preset proportion. The preset ratio may be specifically set according to specific requirements, and may be set to 80%, 90%, or the like, for example.
In order to more clearly describe the training method of the false news discrimination model, a specific example is introduced below for exemplary description.
In an exemplary embodiment, the method comprises the steps of:
the method comprises the following steps: data preparation
And the data access system automatically accesses according to the authority data issued by a certain website. For example, a website determines "Emmys 2017: when the noise area saving is false news, the data access system will acquire text information and image information in the news according to the url address of the news. And then, taking the news title as a keyword, and utilizing an enterprise Api interface to perform search to obtain a tweet id list for quoting the news. And acquiring the content (news content) of the pushtext, the reprinting information (reprinting relation) of the pushtext, the user who releases the pushtext, the material (namely user information) of the user and the attention network (namely attention relation) of the user according to the pushtext id. Randomly selecting 70% of samples as a news training sample set, 10% of samples as a news verification sample set, 20% of samples as a news data set to be distinguished, wherein the ratio of false news to real news in each sample can be set but is not limited to 1: 1.
Step two: building heterogeneous graphs and feature engineering
A heterogeneous graph containing three types of nodes including news content, popularization content and user information is constructed, firstly, feature engineering is carried out on the three types of nodes, and vector representation of the nodes is obtained. For a news node, news generally contains two parts of text information and image information, and the content is expressed as "Emmys 2017: when the noise Are area saving news is taken as an example, a feature vector of text information with 300 dimensions is obtained by using a Doc2Vec algorithm:
[0.5527,0.1235,0.2367,…,0.2589,0.6781,0.4523]
for image information in news, features of the image information are extracted by an LBP algorithm, and the image information is vectorized. The LBP algorithm samples 8 pixels around the center pixel, resulting in a binary LBP value for the center node, e.g., 00010011, which is converted to decimal 19. The range of the LBP value obtained by the sampling mode of 8 pixel points is 0-255, the occurrence frequency of the LBP value is counted, a 256-dimensional vector is obtained and is used as a feature vector of image information in news, and if:
[0.2833,0.5546,0,9856,…,0.1299,0.5623,0.8815]
and splicing the feature vectors of the text information and the image information to obtain 556-dimensional feature vectors (namely initial vectors of news contents) serving as initial feature representations of news nodes:
[0.5527,0.1235,0.2367,…,0.1299,0.5623,0.8815]
aiming at the promotion content nodes which quote the news, the same mode as that of the news nodes is adopted, the Doc2Vec algorithm and the LBP algorithm are utilized to process text and image information to obtain 556-dimensional initial vectors, and if the text contains no image information, the 556-dimensional initial vectors are supplemented with 0.
Aiming at the user information node, personal data of the user, including nicknames, personal introduction, address information, the number of 'fans' and the like, are obtained, and 300-dimensional feature vectors of the text information are obtained by using a Doc2Vec algorithm. And according to the head portrait picture of the user, obtaining a 256-dimensional characteristic vector of the head portrait by using an LBP algorithm, and splicing and fusing the vectors of the text and the picture to obtain a 556-dimensional initial vector of the user information node.
Stacking all nodes from top to bottom according to the sequence of news content, promotion content and user information to form a feature matrix W of the whole abnormal picturem×nWherein m represents all the nodes of the heterogeneous mapThe number of points, n, represents the dimension of the node feature vector.
And after the characteristic engineering of the nodes in the heterogeneous graph is completed, constructing the edges of the heterogeneous graph. The abnormal composition graph comprises edges of four types including a reference relation, a transfer relation, an issuing relation and an attention relation, an adjacent matrix A of the abnormal composition graph is constructed, if a relation exists between two nodes, the corresponding position on the adjacent matrix is 1, and if not, the corresponding position is 0.
Through the steps, the construction of the abnormal graph and the initial characteristic engineering are completed, and a foundation is provided for the subsequent graph calculation.
Step three: building models
Fig. 3 schematically shows a structural diagram of a false news discrimination model according to an embodiment of the present disclosure.
The heterogeneous graph neural network of the two-layer attention mechanism is taken as the basis of the false news discrimination model in the embodiment (as shown in fig. 3), and the first-layer attention mechanism is relationship type level attention. Taking the promotion content node i as an example, the feature vector of the promotion content node is hiAdding the characteristic vectors of the nodes with the reference relation with the node i to obtain a characteristic vector h of the reference relationy. In the same way, the feature vectors h of the necessary types of the transshipment relation and the release officer are respectively obtainedrAnd hp. Three types of assigned attention weights are then calculated using a relationship-level attention formula, for example, the weights assigned to the referral, reprint, and post relationships may be 0.3, 0.5, 0.2, respectively.
The second layer attention mechanism is node level attention, and also taking the promotion content node i as an example, the promotion content node i has n transshipment relationship type nodes, and with the attention mechanism, the attention allocated to the n nodes is respectively:
[0.23,0.15,0.12,…,0.05,0.11,0.27]
the attention weight of the relation level attention of the first layer is assigned to the load type and is 0.3, and the actually assigned attention of the n nodes is obtained through the multiplication of the attention of the two layers, wherein the attention weight is respectively as follows:
[0.069,0.045,0.036,…,0.015,0.033,0.081]
in the process of graph calculation, the feature vectors of n nodes are assumed to be h respectively1To hnThen, formula (8) for the central node i to aggregate the n pieces of node information is shown:
Figure BDA0003546887400000181
obtaining a feature matrix R of the news content through two-layer graph calculationm×nM represents the number of news contents, and n represents the dimension of the feature vector of the news contents. Input to the fully-connected layer, and a weight matrix Wn×2Multiplying to obtain formula (9):
R′m×2=Rm×n×Wn×2 (9)
then, through a normalization layer, the probability that the news content is true or false is obtained, for example, the vector finally output by the model is [0.3, 0.7], which represents that 70% of the probability in the news is false news, and the news is identified as false.
Step four: model training
In the process of model training, the problem that sample identification is difficult and easy to be unbalanced exists, so the present embodiment adopts the Focal local Loss function for training. Formula (10) of Focal local shows:
loss=-(1-pt)γlog(pt) (10)
wherein p istRepresenting the confidence of correct judgment of the sample, for a real news, if the feature vector output by the model is [0.95, 0.05 ]]Then p istIs 0.95, it is clear that this news is an easily recognizable sample, and the corresponding loss value should be reduced. Conversely, the lower the confidence, the higher the corresponding loss value should be. In this way, the capability of the false news discrimination model for discriminating news which is difficult to distinguish true news from false news can be enhanced. The gamma is used as a regulating factor to reduce the loss value of the easily-judged sample, the specific numerical value can be adjusted according to the actual situation, and the gamma selected by a large number of comparison experiments in the embodiment is 2. And then, back propagation is carried out through the loss value, the model parameters are continuously updated, and the judgment effect of the model on the false news is enhanced.
FIG. 4 schematically shows a flow chart of a method of training a false news discrimination model according to an embodiment of the present disclosure.
As shown in fig. 4, the false news discrimination method includes operations S401 to S403.
In operation S401, a news data set to be distinguished is obtained, where the news data set to be distinguished includes target news, target promotion content, target user information, a target association relationship, and a target attention relationship, which are respectively related to the target news.
In operation S402, an anomaly map to be recognized is generated according to the news data set to be discriminated.
In operation S403, the heterogeneous graph to be recognized is input into a false news discrimination model, and a recognition result is output, where the recognition result is used to represent the true and false types of the target news, and the false news discrimination model is obtained by training using the method described above.
According to the embodiment of the disclosure, when the false news discrimination model is used, the obtained news data set to be discriminated needs to be converted into the heterogeneous graph to be recognized, so that the corresponding recognition result can be output after the heterogeneous graph to be recognized is input into the false news discrimination model, wherein the recognition result may include that "the news is true news" or "the news is false news".
According to the embodiment of the disclosure, by utilizing the node relationship formed by the incidence relationship and the attention relationship corresponding to news and the node formed by a plurality of initial vectors corresponding to news content, promotion content and user information, the training sample formed by the node and the node relationship is used for training the neural network of the heterogeneous graph to obtain the false news judgment model, and the training sample fully considers the node relationship related to the news content, so that the identification result of the to-be-identified news of the trained false news judgment model can accurately determine whether the to-be-identified news is the false news, and the technical problem that the false news cannot be accurately identified and the cognition of a user is easily influenced is at least partially solved.
According to the embodiment of the disclosure, the target association relationship includes a target reference relationship, a target reprint relationship and a target release relationship.
According to the embodiment of the disclosure, generating the abnormal image to be identified according to the news data set to be distinguished may include the following operations:
and generating a plurality of target vectors respectively corresponding to the target news, the target popularization content and the target user information according to the target news, the target popularization content and the target user information. And generating a target adjacency matrix according to the target reference relation, the target reprint relation, the target release relation and the target attention relation. And generating the abnormal image to be identified according to the plurality of target vectors and the target adjacency matrix.
According to the embodiment of the disclosure, the source of the target news is not limited to various news websites or others, such as business software like microblog, twitter and the like.
According to the embodiment of the disclosure, under the condition that the target news is obtained, the keywords of the target news are extracted, the target popularization content corresponding to the target news can be obtained by using the information query interface, and meanwhile, the target user information such as user data and social relations for publishing the target popularization content is obtained.
According to the embodiment of the disclosure, a corresponding target vector is generated according to the obtained target news, target promotion content and target user information, and then a target adjacency matrix is generated according to the target reference relationship, the target reprint relationship, the target release relationship and the target attention relationship, so that the heteromorphic image to be identified can be obtained. And inputting the heterogeneous graph to be identified into a false news discrimination model to discriminate the truth and falseness of the target news.
FIG. 5 schematically shows a block diagram of a training apparatus for a false news discrimination model according to an embodiment of the present disclosure.
As shown in fig. 5, the training apparatus of the false news discrimination model may include a first obtaining module 510, a predicting module 520, a calculating module 530, and an iterating module 540.
The first obtaining module 510 is configured to obtain a news training sample set, where the news training sample set includes a plurality of training samples and label data corresponding to the training samples, where the training samples include an abnormal graph, the abnormal graph is generated according to a node related to news and a node relationship, the node includes a plurality of initial vectors respectively corresponding to news content, promotion content, and user information, and the node relationship includes an adjacency matrix generated according to an association relationship and an attention relationship corresponding to news.
And the prediction module 520 is configured to input the training samples in the news training sample set into the heteromorphic neural network, and output a prediction result.
And a calculating module 530, configured to input the prediction result and the tag data into a loss function to obtain a loss result.
And the iteration module 540 is configured to iteratively adjust network parameters of the neural network of the heterogeneous graph according to the loss result, and generate a trained false news discrimination model.
According to the embodiment of the disclosure, by utilizing the node relationship formed by the incidence relationship and the attention relationship corresponding to news and the node formed by a plurality of initial vectors corresponding to news content, promotion content and user information, the training sample formed by the node and the node relationship is used for training the neural network of the heterogeneous graph to obtain the false news judgment model, and the training sample fully considers the node relationship related to the news content, so that the identification result of the to-be-identified news of the trained false news judgment model can accurately determine whether the to-be-identified news is the false news, and the technical problem that the false news cannot be accurately identified and the cognition of a user is easily influenced is at least partially solved.
According to an embodiment of the present disclosure, the association relationship includes a reference relationship, a reprint relationship, and a publishing relationship.
According to an embodiment of the present disclosure, the training samples may be generated by an acquisition submodule, a first generation submodule, a second generation submodule, and a third generation submodule.
And the acquisition submodule is used for acquiring news content, promotion content and user information, wherein the promotion content is acquired by inquiring keywords of the news content through the information inquiry interface, and the user information comprises user data and social relations.
And the first generation submodule is used for generating a plurality of initial vectors respectively corresponding to the news content, the promotion content and the user information according to the news content, the promotion content and the user information.
And the second generation submodule is used for generating the adjacency matrix according to the reference relationship, the reprint relationship, the release relationship and the attention relationship.
And the third generation submodule is used for generating a training sample comprising an abnormal picture according to the plurality of initial vectors and the adjacency matrix.
According to an embodiment of the present disclosure, the first generation submodule may include a first acquisition unit, a second acquisition unit, a first generation unit, a third acquisition unit, a first obtaining unit, a second generation unit, and a second obtaining unit.
The device comprises a first acquisition unit, a second acquisition unit and a third acquisition unit, wherein the first acquisition unit is used for acquiring a text vector of the text information by using a paragraph vector method under the condition that the news content comprises the text information.
And a second obtaining unit configured to obtain an image vector of the image information by using a local binary method in a case where the news content includes the image information.
And the first generation unit is used for generating an initial vector corresponding to the news content according to the text vector and/or the image vector.
And a third obtaining unit, configured to obtain an original vector of the original content by using a paragraph vector method in a case where the promotion content includes the original content.
And the first obtaining unit is used for processing the user viewpoint corresponding to the reprinted content by using a paragraph vector method to obtain the reprinted vector under the condition that the promotion content comprises the reprinted content.
And the second generating unit is used for generating an initial vector corresponding to the popularization content according to the original vector and/or the transfer vector.
And the second obtaining unit is used for processing the user information by using a paragraph vector method to obtain an initial vector corresponding to the user information.
According to an embodiment of the present disclosure, image information includes a plurality of image elements and a pixel value corresponding to each image element.
According to an embodiment of the present disclosure, the second obtaining unit may include a deriving subunit and a normalizing subunit.
A deriving subunit, configured to, for each image element, process the pixel value of the image element and the pixel value of the image element associated with the image element by using a local binary method to derive a local binary of the image element.
And the normalization subunit is used for performing normalization processing on the plurality of local binary values to obtain an image vector of the image information.
According to an embodiment of the present disclosure, a heterogeneous graph neural network includes a first attention mechanism layer, a second attention mechanism layer, a fully-connected layer, and a normalization layer.
According to an embodiment of the present disclosure, the prediction module 520 may include a obtaining sub-module, a first processing sub-module, a first determining sub-module, a second processing sub-module, a second determining sub-module, a third processing sub-module, and a normalization sub-module.
And the obtaining submodule is used for obtaining a node characteristic matrix and a node relation matrix according to the abnormal composition, wherein the node relation matrix comprises an adjacency matrix, the node characteristic matrix comprises a plurality of news nodes, the node relation matrix comprises node relations among the news nodes, and the news nodes comprise a plurality of initial vectors corresponding to news content, popularization content and user information respectively.
And the first processing submodule is used for processing the news nodes and the node relation related to the news nodes by utilizing the first attention mechanism layer aiming at each news node to obtain a first attention value.
And the first determining submodule is used for determining the associated news nodes related to the news nodes according to the node relation of the news nodes.
And the second processing submodule is used for processing the first attention value and associating the news node by utilizing the second attention mechanism layer to obtain a second attention value of the news node.
And the second determining submodule is used for determining the first feature vector according to the plurality of second attention values and the graph network calculation formula.
And the third processing submodule is used for processing the plurality of first eigenvectors by using the full connection layer to obtain a second eigenvector.
And the normalization submodule is used for processing the second feature vector by utilizing a normalization layer to obtain a prediction result.
According to the embodiment of the disclosure, the training device of the false news discrimination model may further include a third obtaining module, a verifying module, a comparing module and a determining module.
The third acquisition module is used for acquiring a news verification sample set, wherein the news verification sample set comprises a plurality of verification samples and verification label data corresponding to the verification samples, the verification samples comprise verification abnormal patterns generated according to verification nodes related to verification news and verification node relations, the verification nodes comprise a plurality of verification initial vectors respectively corresponding to verification news contents, verification promotion contents and verification user information, and the verification node relations comprise verification adjacency matrixes generated according to verification incidence relations and verification attention relations.
And the verification module is used for inputting the verification samples into the false news discrimination model and outputting verification results, wherein the verification results comprise verification sub-results corresponding to the verification samples respectively.
And the comparison module is used for matching and comparing the prediction result with the plurality of verification label data to obtain a comparison result.
And the determining module is used for determining the false news discrimination model as the target false news discrimination model under the condition that the comparison result shows that the number ratio of the verification score results which are the same as the verification label data in the verification score results meets the preset ratio.
Fig. 6 schematically shows a block diagram of a false news discrimination apparatus according to an embodiment of the present disclosure.
As shown in fig. 6, the fake news determination apparatus 600 may include a second acquisition module 610, a generation module 620, and an identification module 630.
The second obtaining module 610 is configured to obtain a news data set to be distinguished, where the news data set to be distinguished includes target news, target promotion content, target user information, a target association relationship, and a target attention relationship, where the target promotion content, the target user information, the target association relationship, and the target attention relationship are respectively related to the target news.
And the generating module 620 is configured to generate the abnormal image to be identified according to the news data set to be distinguished.
The identifying module 630 is configured to input the heterogeneous graph to be identified into a false news discrimination model, and output an identification result, where the identification result is used to represent a true or false type of the target news, where the false news discrimination model is obtained by training using the method described above.
According to the embodiment of the disclosure, by utilizing the node relationship formed by the incidence relationship and the attention relationship corresponding to news and the node formed by a plurality of initial vectors corresponding to news content, promotion content and user information, the training sample formed by the node and the node relationship is used for training the neural network of the heterogeneous graph to obtain the false news judgment model, and the training sample fully considers the node relationship related to the news content, so that the identification result of the to-be-identified news of the trained false news judgment model can accurately determine whether the to-be-identified news is the false news, and the technical problem that the false news cannot be accurately identified and the cognition of a user is easily influenced is at least partially solved.
According to the embodiment of the disclosure, the target association relationship includes a target reference relationship, a target reprint relationship and a target release relationship.
According to an embodiment of the present disclosure, the generation module 620 may include a fourth generation submodule, a fifth generation submodule, and a sixth generation submodule.
And the fourth generation submodule is used for generating a plurality of target vectors respectively corresponding to the target news, the target popularization content and the target user information according to the target news, the target popularization content and the target user information.
And the fifth generation submodule is used for generating a target adjacency matrix according to the target reference relationship, the target reprint relationship, the target release relationship and the target attention relationship.
And the sixth generation submodule is used for generating the abnormal picture to be identified according to the plurality of target vectors and the target adjacency matrix.
Any number of modules, sub-modules, units, sub-units, or at least part of the functionality of any number thereof according to embodiments of the present disclosure may be implemented in one module. Any one or more of the modules, sub-modules, units, and sub-units according to the embodiments of the present disclosure may be implemented by being split into a plurality of modules. Any one or more of the modules, sub-modules, units, and sub-units according to the embodiments of the present disclosure may be implemented at least partially as a hardware Circuit, such as a Field Programmable Gate Array (FPGA), a Programmable Logic Array (PLA), a system on a chip, a system on a substrate, a system on a package, an Application Specific Integrated Circuit (ASIC), or may be implemented by hardware or firmware in any other reasonable manner of integrating or packaging a Circuit, or implemented by any one of three implementations of software, hardware, and firmware, or any suitable combination of any of them. Alternatively, one or more of the modules, sub-modules, units, sub-units according to embodiments of the disclosure may be implemented at least partly as a computer program module, which when executed, may perform a corresponding function.
For example, any plurality of the first obtaining module 510, the predicting module 520, the calculating module 530 and the iterating module 540, or the second obtaining module 610, the generating module 620 and the identifying module 630 may be combined and implemented in one module/unit/sub-unit, or any one of the modules/units/sub-units may be split into a plurality of modules/units/sub-units. Alternatively, at least part of the functionality of one or more of these modules/units/sub-units may be combined with at least part of the functionality of other modules/units/sub-units and implemented in one module/unit/sub-unit. According to an embodiment of the present disclosure, at least one of the first obtaining module 510, the predicting module 520, the calculating module 530 and the iterating module 540, or the second obtaining module 610, the generating module 620 and the identifying module 630 may be at least partially implemented as a hardware circuit, such as a Field Programmable Gate Array (FPGA), a Programmable Logic Array (PLA), a system on a chip, a system on a substrate, a system on a package, an Application Specific Integrated Circuit (ASIC), or may be implemented by hardware or firmware in any other reasonable manner of integrating or packaging a circuit, or implemented by any one of three manners of software, hardware and firmware, or by a suitable combination of any of them. Alternatively, at least one of the first obtaining module 510, the predicting module 520, the calculating module 530 and the iterating module 540, or the second obtaining module 610, the generating module 620 and the identifying module 630 may be at least partially implemented as a computer program module, which when executed, may perform a corresponding function.
It should be noted that, in the embodiment of the present disclosure, the training device or the part of the false news discrimination model corresponds to the training method or the part of the false news discrimination model in the embodiment of the present disclosure, and the description of the training device or the part of the false news discrimination model specifically refers to the training method or the part of the false news discrimination model, and is not repeated here.
Fig. 7 schematically shows a block diagram of an electronic device adapted to implement the above described method according to an embodiment of the present disclosure. The electronic device shown in fig. 7 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present disclosure.
As shown in fig. 7, an electronic device 700 according to an embodiment of the present disclosure includes a processor 701, which can perform various appropriate actions and processes according to a program stored in a Read-Only Memory (ROM) 702 or a program loaded from a storage section 708 into a Random Access Memory (RAM) 703. The processor 701 may include, for example, a general purpose microprocessor (e.g., a CPU), an instruction set processor and/or associated chipset, and/or a special purpose microprocessor (e.g., an Application Specific Integrated Circuit (ASIC)), among others. The processor 701 may also include on-board memory for caching purposes. The processor 701 may comprise a single processing unit or a plurality of processing units for performing the different actions of the method flows according to embodiments of the present disclosure.
In the RAM 703, various programs and data necessary for the operation of the electronic apparatus 700 are stored. The processor 701, the ROM 702, and the RAM 703 are connected to each other by a bus 704. The processor 701 performs various operations of the method flows according to the embodiments of the present disclosure by executing programs in the ROM 702 and/or the RAM 703. It is noted that the programs may also be stored in one or more memories other than the ROM 702 and RAM 703. The processor 701 may also perform various operations of method flows according to embodiments of the present disclosure by executing programs stored in the one or more memories.
Electronic device 700 may also include input/output (I/O) interface 705, which input/output (I/O) interface 705 is also connected to bus 704, according to an embodiment of the present disclosure. The system 700 may also include one or more of the following components connected to the I/O interface 705: an input portion 706 including a keyboard, a mouse, and the like; an output section 707 including a Display panel such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and a speaker; a storage section 708 including a hard disk and the like; and a communication section 709 including a network interface card such as a LAN card, a modem, or the like. The communication section 709 performs communication processing via a network such as the internet. A drive 710 is also connected to the I/O interface 705 as needed. A removable medium 711 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 710 as necessary, so that a computer program read out therefrom is mounted into the storage section 708 as necessary.
According to embodiments of the present disclosure, method flows according to embodiments of the present disclosure may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable storage medium, the computer program containing program code for performing the method illustrated by the flow chart. In such an embodiment, the computer program can be downloaded and installed from a network through the communication section 709, and/or installed from the removable medium 711. The computer program, when executed by the processor 701, performs the above-described functions defined in the system of the embodiment of the present disclosure. The above described systems, devices, apparatuses, modules, units, etc. may be implemented by computer program modules according to embodiments of the present disclosure.
The present disclosure also provides a computer-readable storage medium, which may be contained in the apparatus/device/system described in the above embodiments; or may exist separately and not be assembled into the device/apparatus/system. The computer-readable storage medium carries one or more programs which, when executed, implement the method according to an embodiment of the disclosure.
According to an embodiment of the present disclosure, the computer-readable storage medium may be a non-volatile computer-readable storage medium. Examples may include, but are not limited to: a portable Computer diskette, a hard disk, a Random Access Memory (RAM), a Read-Only Memory (ROM), an Erasable Programmable Read-Only Memory (EPROM) or flash Memory), a portable compact Disc Read-Only Memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the preceding. In the present disclosure, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
For example, according to embodiments of the present disclosure, a computer-readable storage medium may include the ROM 702 and/or the RAM 703 and/or one or more memories other than the ROM 702 and the RAM 703 described above.
Embodiments of the present disclosure also include a computer program product comprising a computer program containing program code for performing the method provided by the embodiments of the present disclosure, which, when the computer program product is run on an electronic device, is configured to cause the electronic device to implement the training method of the false news discrimination model or the false news discrimination method provided by the embodiments of the present disclosure.
The computer program, when executed by the processor 701, performs the above-described functions defined in the system/apparatus of the embodiments of the present disclosure. The systems, apparatuses, modules, units, etc. described above may be implemented by computer program modules according to embodiments of the present disclosure.
In one embodiment, the computer program may be hosted on a tangible storage medium such as an optical storage device, a magnetic storage device, and the like. In another embodiment, the computer program may also be transmitted in the form of a signal on a network medium, distributed, downloaded and installed via the communication section 709, and/or installed from the removable medium 711. The computer program containing program code may be transmitted using any suitable network medium, including but not limited to: wireless, wired, etc., or any suitable combination of the foregoing.
In accordance with embodiments of the present disclosure, program code for executing computer programs provided by embodiments of the present disclosure may be written in any combination of one or more programming languages, and in particular, these computer programs may be implemented using high level procedural and/or object oriented programming languages, and/or assembly/machine languages. The programming language includes, but is not limited to, programming languages such as Java, C + +, python, the "C" language, or the like. The program code may execute entirely on the user computing device, partly on the user device, partly on a remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computing device (e.g., through the internet using an internet service provider).
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions. Those skilled in the art will appreciate that various combinations and/or combinations of features recited in the various embodiments and/or claims of the present disclosure can be made, even if such combinations or combinations are not expressly recited in the present disclosure. In particular, various combinations and/or combinations of the features recited in the various embodiments and/or claims of the present disclosure may be made without departing from the spirit or teaching of the present disclosure. All such combinations and/or associations are within the scope of the present disclosure.
The embodiments of the present disclosure have been described above. However, these examples are for illustrative purposes only and are not intended to limit the scope of the present disclosure. Although the embodiments are described separately above, this does not mean that the measures in the embodiments cannot be used in advantageous combination. The scope of the disclosure is defined by the appended claims and equivalents thereof. Various alternatives and modifications can be devised by those skilled in the art without departing from the scope of the present disclosure, and such alternatives and modifications are intended to be within the scope of the present disclosure.

Claims (9)

1. A training method of a false news discrimination model comprises the following steps:
acquiring a news training sample set, wherein the news training sample set comprises a plurality of training samples and label data corresponding to the training samples, the training samples comprise heteromorphic graphs, the heteromorphic graphs are generated according to nodes related to news and node relations, the nodes comprise a plurality of initial vectors respectively corresponding to news content, promotion content and user information, and the node relations comprise adjacency matrixes generated according to incidence relations and attention relations corresponding to the news;
inputting the training samples in the news training sample set into a heterogeneous graph neural network, and outputting a prediction result;
inputting the prediction result and the label data into a loss function to obtain a loss result;
iteratively adjusting network parameters of the heteromorphic graph neural network according to the loss result to generate the trained false news discrimination model;
the abnormal graph neural network comprises a first attention mechanism layer, a second attention mechanism layer, a full connection layer and a normalization layer;
wherein, the inputting the training samples in the news training sample set into a neural network of a heterogeneous graph and outputting a prediction result comprises:
obtaining a node feature matrix and a node relation matrix according to the heteromorphic graph, wherein the node relation matrix comprises the adjacency matrix, the node feature matrix comprises a plurality of news nodes, the node relation matrix comprises node relations among the news nodes, and the news nodes comprise a plurality of initial vectors respectively corresponding to the news content, the promotion content and the user information;
for each news node, processing the news node and the node relation related to the news node by using the first attention mechanism layer to obtain a first attention value;
determining related news nodes related to the news nodes according to the node relation of the news nodes;
processing the first attention value and the associated news node by utilizing the second attention mechanism layer to obtain a second attention value of the news node;
determining a first feature vector according to the plurality of second attention values and a graph network calculation formula;
processing a plurality of first feature vectors by using the full connection layer to obtain second feature vectors;
and processing the second feature vector by utilizing the normalization layer to obtain the prediction result.
2. The method of claim 1, the incidence relations comprising a reference relation, a reprint relation, and a publish relation;
wherein the training samples are generated by:
acquiring the news content, the promotion content and the user information, wherein the promotion content is obtained by querying keywords of the news content through an information query interface, and the user information comprises user data and social relations;
generating a plurality of initial vectors respectively corresponding to the news content, the promotion content and the user information according to the news content, the promotion content and the user information respectively;
generating the adjacency matrix according to the reference relationship, the reprint relationship, the release relationship and the concern relationship;
generating the training sample including the abnormal pattern according to the plurality of initial vectors and the adjacency matrix.
3. The method of claim 2, wherein the generating a plurality of the initial vectors corresponding to the news content, the promotional content, and the user information, respectively, from the news content, the promotional content, and the user information, respectively, comprises:
under the condition that the news content comprises text information, a text vector of the text information is obtained by using a paragraph vector method;
under the condition that the news content comprises image information, acquiring an image vector of the image information by using a local binary method;
generating the initial vector corresponding to the news content according to the text vector and/or the image vector;
under the condition that the promotion content comprises original content, acquiring an original vector of the original content by using a paragraph vector method;
under the condition that the promotion content comprises the reprinted content, processing a user viewpoint corresponding to the reprinted content by using a paragraph vector method to obtain a reprinted vector;
generating the initial vector corresponding to the promotion content according to the original vector and/or the transfer vector;
under the condition that the user information comprises text type information, processing the user information by using a paragraph vector method to obtain a text type vector;
under the condition that the user information comprises image information, acquiring an image vector of the image information by using a local binary method;
generating the initial vector corresponding to the user information according to the text class vector and/or the image class vector.
4. The method of claim 3, the image information comprising a plurality of image elements and a pixel value corresponding to each of the image elements;
wherein, in the case that the news content includes image information, acquiring an image vector of the image information by using a local binary method includes:
for each image element, processing the pixel value of the image element and the pixel value of the image element related to the image element by using the local binary method to obtain a local binary of the image element;
and carrying out normalization processing on the plurality of local binary values to obtain the image vector of the image information.
5. The method of claim 1, further comprising:
acquiring a news verification sample set, wherein the news verification sample set comprises a plurality of verification samples and verification label data corresponding to the verification samples, the verification samples comprise verification abnormal patterns generated according to verification nodes related to verification news and verification node relations, the verification nodes comprise a plurality of verification initial vectors respectively corresponding to verification news content, verification promotion content and verification user information, and the verification node relations comprise verification adjacent matrixes generated according to verification incidence relations and verification attention relations;
inputting a plurality of verification samples into the false news discrimination model, and outputting verification results, wherein the verification results comprise verification sub-results corresponding to each verification sample;
matching and comparing the prediction result with a plurality of verification label data to obtain a comparison result;
and determining the false news discrimination model as a target false news discrimination model under the condition that the comparison result shows that the number ratio of the verification score results which are the same as the verification label data in the verification score results meets a preset ratio.
6. A false news discrimination method comprises the following steps:
acquiring a news data set to be distinguished, wherein the news data set to be distinguished comprises target news, target promotion content, target user information, a target association relation and a target attention relation, and the target promotion content, the target user information, the target association relation and the target attention relation are respectively related to the target news;
generating a heteromorphic image to be identified according to the news data set to be distinguished;
inputting the heterogeneous graph to be recognized into a false news discrimination model, and outputting a recognition result, wherein the recognition result is used for representing the true and false types of the target news, and the false news discrimination model is obtained by training by using the method of any one of claims 1 to 5.
7. The method of claim 6, the target association relationship comprising a target reference relationship, a target reprint relationship, and a target publish relationship;
wherein, the generating the abnormal picture to be identified according to the news data set to be distinguished comprises:
generating a plurality of target vectors respectively corresponding to the target news, the target promotion content and the target user information according to the target news, the target promotion content and the target user information;
generating a target adjacency matrix according to the target reference relationship, the target reprinting relationship, the target issuing relationship and the target attention relationship;
and generating the abnormal picture to be identified according to the target vectors and the target adjacency matrix.
8. A training apparatus for a false news discrimination model, comprising:
the news training system comprises a first acquisition module, a second acquisition module and a third acquisition module, wherein the news training sample set comprises a plurality of training samples and label data corresponding to the training samples, the training samples comprise abnormal patterns, the abnormal patterns are generated according to nodes related to news and node relations, the nodes comprise a plurality of initial vectors respectively corresponding to news content, promotion content and user information, and the node relations comprise adjacency matrixes generated according to incidence relations and attention relations corresponding to the news;
the prediction module is used for inputting the training samples in the news training sample set into a heterogeneous graph neural network and outputting prediction results;
the calculation module is used for inputting the prediction result and the label data into a loss function to obtain a loss result; and
the iteration module is used for iteratively adjusting network parameters of the heteromorphic graph neural network according to the loss result to generate the trained false news discrimination model;
the abnormal pattern neural network comprises a first attention mechanism layer, a second attention mechanism layer, a full connection layer and a normalization layer;
wherein the prediction module comprises:
an obtaining submodule, configured to obtain a node feature matrix and a node relationship matrix according to the heterogeneous map, where the node relationship matrix includes the adjacency matrix, the node feature matrix includes a plurality of news nodes, the node relationship matrix includes node relationships among the plurality of news nodes, and the plurality of news nodes include a plurality of initial vectors respectively corresponding to the news content, the promotion content, and the user information;
the first processing submodule is used for processing the news nodes and the node relation related to the news nodes by utilizing the first attention mechanism layer aiming at each news node to obtain a first attention value;
the first determining submodule is used for determining an associated news node related to the news node according to the node relation of the news node;
the second processing submodule is used for processing the first attention value and the associated news node by utilizing the second attention mechanism layer to obtain a second attention value of the news node;
a second determining submodule, configured to determine a first feature vector according to the plurality of second attention values and a graph network calculation formula;
the third processing submodule is used for processing the first eigenvectors by using the full connection layer to obtain a second eigenvector;
and the normalization submodule is used for processing the second feature vector by utilizing the normalization layer to obtain the prediction result.
9. A false news discrimination apparatus comprising:
the second acquisition module is used for acquiring a news data set to be distinguished, wherein the news data set to be distinguished comprises target news, target promotion content, target user information, a target association relation and a target attention relation which are respectively related to the target news;
the generating module is used for generating a heteromorphic graph to be identified according to the news data set to be distinguished; and
the identification module is used for inputting the heterogeneous graph to be identified into a false news discrimination model and outputting an identification result, wherein the identification result is used for representing the true and false types of the target news, and the false news discrimination model is obtained by training according to the method of any one of claims 1 to 5.
CN202210254714.XA 2022-03-15 2022-03-15 Training method of false news discrimination model, false news discrimination method and device Pending CN114579878A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210254714.XA CN114579878A (en) 2022-03-15 2022-03-15 Training method of false news discrimination model, false news discrimination method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210254714.XA CN114579878A (en) 2022-03-15 2022-03-15 Training method of false news discrimination model, false news discrimination method and device

Publications (1)

Publication Number Publication Date
CN114579878A true CN114579878A (en) 2022-06-03

Family

ID=81780826

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210254714.XA Pending CN114579878A (en) 2022-03-15 2022-03-15 Training method of false news discrimination model, false news discrimination method and device

Country Status (1)

Country Link
CN (1) CN114579878A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115269854A (en) * 2022-08-30 2022-11-01 重庆理工大学 False news detection method based on theme and structure perception neural network
CN116579337A (en) * 2023-07-07 2023-08-11 南开大学 False news detection method integrating evidence credibility

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115269854A (en) * 2022-08-30 2022-11-01 重庆理工大学 False news detection method based on theme and structure perception neural network
CN115269854B (en) * 2022-08-30 2024-02-02 重庆理工大学 False news detection method based on theme and structure perception neural network
CN116579337A (en) * 2023-07-07 2023-08-11 南开大学 False news detection method integrating evidence credibility
CN116579337B (en) * 2023-07-07 2023-10-10 南开大学 False news detection method integrating evidence credibility

Similar Documents

Publication Publication Date Title
US11128668B2 (en) Hybrid network infrastructure management
US11651247B2 (en) Method for verifying lack of bias of deep learning AI systems
CN111401558A (en) Data processing model training method, data processing device and electronic equipment
WO2019084922A1 (en) Information processing method and system, server, terminal and computer storage medium
CN114579878A (en) Training method of false news discrimination model, false news discrimination method and device
CN110135978B (en) User financial risk assessment method and device, electronic equipment and readable medium
CN111783039B (en) Risk determination method, risk determination device, computer system and storage medium
US11288673B1 (en) Online fraud detection using machine learning models
CN112231592A (en) Network community discovery method, device, equipment and storage medium based on graph
CN107291774B (en) Error sample identification method and device
CN107256231B (en) Team member identification device, method and system
CN113507419B (en) Training method of traffic distribution model, traffic distribution method and device
WO2022017082A1 (en) Method and apparatus for detecting false transaction orders
US20150120679A1 (en) System and method for identifying an individual from one or more identities and their associated data
CN113609493A (en) Phishing website identification method, device, equipment and medium
CN116155628B (en) Network security detection method, training device, electronic equipment and medium
CN115795345A (en) Information processing method, device, equipment and storage medium
CN116451700A (en) Target sentence generation method, device, equipment and storage medium
CN113869904B (en) Suspicious data identification method, device, electronic equipment, medium and computer program
CN114780807A (en) Service detection method, device, computer system and readable storage medium
CN113609018A (en) Test method, training method, device, apparatus, medium, and program product
CN114219601A (en) Information processing method, device, equipment and storage medium
CN116385115A (en) Product recommendation method, device, equipment and medium based on matrix filling
CN111786937B (en) Method, apparatus, electronic device and readable medium for identifying malicious request
US20210334868A1 (en) Using scenarios to mitigate seller risk to enter online platforms

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination