Method and system for constructing coal mine safety knowledge graph by utilizing crowdsourcing and block chain

By recording coal mine safety-related data on the blockchain and launching crowdsourcing voting using smart contracts, a coal mine safety knowledge graph is built, which solves the problems of knowledge integration and blockchain performance, and achieves high-quality and transparent knowledge graph construction.

CN120069028APending Publication Date: 2025-05-30UNIV OF SCI & TECH OF CHINA
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510130133.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-05
Publication Date
2025-05-30

AI Technical Summary

Technical Problem

It is difficult for existing technologies to effectively integrate and connect diversified coal mine safety knowledge, ensure the performance and scalability of blockchains, and incentivize and manage crowdsourcing participants to build an efficient coal mine safety knowledge map.

Method used

By recording static attribute data and task data on the blockchain, an initial coal mine safety knowledge graph is constructed, and crowdsourcing voting is initiated using blockchain-driven smart contracts, participants are determined based on the whitelist sequence output by the recommendation system, receiving and voting triple proposals, updating the knowledge graph, and building the final coal mine safety knowledge graph.

Benefits of technology

It realizes efficient integration and connection of coal mine safety knowledge, improves the quality and comprehensiveness of the knowledge graph, and provides a transparent and reliable knowledge sharing and collaboration platform, ensuring data transparency and immutability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120069028A_ABST
    Figure CN120069028A_ABST
Patent Text Reader

Abstract

The invention discloses a method and a system for constructing a coal mine safety knowledge graph by utilizing crowdsourcing and a block chain, which are corresponding schemes, in the scheme, the coal mine safety knowledge graph is constructed by applying a block chain technology and a knowledge graph technology, and the method and the system have the advantages of the block chain technology and the knowledge graph technology; a crowdsourcing method is combined and introduced to realize decentralized construction of the knowledge graph, and the process is realized through a smart contract driven by a block chain, so that the openness of the construction process is ensured; generally speaking, the coal mine safety knowledge graph based on the block chain and the crowdsourcing method provides a more transparent and more reliable knowledge sharing and collaboration platform, related entities of coal mine safety can share and interact their knowledge on the platform, and the correctness and integrity of the knowledge graph are improved; meanwhile, the transparency and the traceability of the data and the non-tampering and decentralization of the data also provide powerful guarantee for the management and the use of the knowledge graph.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of coal mine safety information management, and particularly to a method and system for constructing a coal mine safety knowledge graph by using crowdsourcing and blockchain. Background Art

[0002] Coal mine safety is an important issue in global industrial production. Due to the variable working environment of miners, such as the narrow, dark and humid underground environment, they face various safety risks. These safety risks not only pose a direct threat to the lives of miners, but may also cause serious damage to the environment and huge losses to the social economy. Therefore, improving the safety of coal mines is of extremely important significance to global industrial production. However, the knowledge involved in coal mine safety is diversified, including aspects such as engineering technology, regulations and policies, safety management, miner behavior, environmental impact, etc., and there are complex associations among these knowledges. Traditional data management technologies often have difficulty effectively processing these complex associated information, resulting in low efficiency of knowledge extraction and utilization.

[0003] To solve this problem, it is particularly necessary to construct a coal mine safety knowledge graph. The knowledge graph can integrate the knowledge in each information source and connect it in a graphical way to form a large, structured knowledge base, thereby improving the efficiency and accuracy of knowledge search, update and application. Blockchain technology can ensure the transparency, security and immutability of data, thereby improving the credibility of the knowledge graph. The crowdsourcing method can absorb the knowledge of a wider range of professionals and community members, thereby improving the quality and comprehensiveness of the knowledge graph. However, when applying these new technical means, some challenges also exist. For example, how to effectively integrate and connect a large amount of diversified coal mine safety knowledge; how to ensure the performance and scalability of the blockchain to meet the needs of large-scale knowledge graph construction and use; how to motivate and manage a large number of crowdsourcing participants to ensure the quality and efficiency of the knowledge graph. These are all challenges that need to be faced and solved in the process of constructing a coal mine safety knowledge graph.

[0004] In the Chinese invention patent application "A Method for Constructing a Knowledge Graph Based on Blockchain" with the application number CN202210555375.9, the schema layer and data layer of the knowledge graph are constructed, the corresponding schema layer blockchain and data layer blockchain are established, and finally the data layer blockchain is stored in the graph database to complete the construction of the knowledge graph. However, this method requires users to have professional knowledge and technical capabilities for analyzing, generating and verifying block signatures for new data, which may be quite challenging for ordinary users. Frequent operations are more likely to increase the burden on users. Although the method mentions that all users can perform data analysis and update the schema layer and data layer, in actual operation, how to ensure the synchronization and consistency of all users' operations and avoid data conflicts and inconsistencies is an unsolved problem.

[0005] The Chinese invention patent application "A method for marking accounts based on blockchain technology" with application number CN202311357192.7 solves the problem of traditional account marking methods, namely, over-reliance on centralized databases, resulting in their credibility being mainly determined by centralized institutions and being susceptible to single point failures and data tampering risks. However, for large-scale data processing (such as massive account data), the database constructed by this method may not be able to handle a large number of online query tasks. Therefore, considering using a knowledge graph database instead of a traditional database may be an effective solution strategy.

[0006] In general, existing solutions mainly focus on blockchain technology, database construction and storage systems. However, there are still some unresolved issues, such as how to maintain data consistency in the update of the model layer and the data layer, and the insufficient ability of traditional relational databases to handle large-scale online query tasks. Therefore, how to use crowdsourcing methods and blockchain technology to effectively build a coal mine safety knowledge graph and form an efficient storage system is still an unresolved challenge.

[0007] In view of this, the present invention is proposed. Summary of the invention

[0008] The purpose of this invention is to provide a method and system for constructing a coal mine safety knowledge graph using crowdsourcing and blockchain, which not only combines the advantages of blockchain and knowledge graph, but also introduces crowdsourcing methods to collect and utilize coal mine safety knowledge more widely and comprehensively, and has significant advantages and innovations.

[0009] The objective of the present invention is achieved through the following technical solutions:

[0010] A method for constructing a coal mine safety knowledge graph using crowdsourcing and blockchain, comprising:

[0011] By recording static attribute data on the blockchain and task data related to coal mine safety, an initial knowledge graph in the field of coal mine safety is constructed;

[0012] Crowdsourcing voting is initiated through a blockchain-driven smart contract. According to the whitelist sequence of participants output by the recommendation system, the participants participating in the crowdsourcing voting are determined, and the proposals of triples about the coal mine safety knowledge graph returned by each participant are received. At the same time, each participant's vote on the proposals of other participants is received; the initial coal mine safety knowledge graph is updated with the ternary corresponding to the proposal that passes the vote, and the final coal mine safety knowledge graph is constructed.

[0013] A coal mine safety knowledge graph system is constructed by using crowdsourcing and blockchain, which is used to implement the above method. The system includes:

[0014] An initial knowledge graph construction unit for the coal mine safety field, which is used to construct an initial knowledge graph for the coal mine safety field through static attribute data recorded on the blockchain and task data related to coal mine safety;

[0015] A coal mine safety knowledge graph construction unit based on crowdsourcing and blockchain, which is used to start a crowdsourcing vote through a smart contract driven by the blockchain, determine the participants in the crowdsourcing vote according to the whitelist sequence of the participants output by the recommendation system, receive the proposals of each participant on the triples of the coal mine safety field knowledge graph, and at the same time receive the votes of each participant on the proposals of other participants; use the triples corresponding to the proposals passed by the vote to update the initial coal mine safety field knowledge graph and construct the final coal mine safety field knowledge graph.

[0016] A processing device includes: one or more processors; a memory for storing one or more programs;

[0017] Wherein, when the one or more programs are executed by the one or more processors, the one or more processors are caused to implement the foregoing method.

[0018] A readable storage medium stores a computer program, and when the computer program is executed by a processor, the foregoing method is implemented.

[0019] It can be seen from the technical solutions provided by the present invention described above that: 1) The blockchain technology and the knowledge graph technology are used to construct the coal mine safety knowledge graph, combining the advantages of the blockchain technology and the knowledge graph technology; specifically, it has the advantages of transparency and audibility, security and immutability, and decentralization, and can also integrate and connect data, make full use of semantic information, support reasoning and learning, and at the same time provide an intuitive visualization effect; 2) The crowdsourcing method is introduced to achieve the decentralized construction of the knowledge graph, which is realized through a smart contract driven by the blockchain, aiming to ensure the publicity of the construction process. The application of the crowdsourcing method also enables the construction process of the knowledge graph to more widely absorb and use the knowledge of professionals and community members, greatly improving the quality and comprehensiveness of the knowledge graph; 3) The coal mine safety knowledge graph based on the blockchain and the crowdsourcing method provides a more transparent and reliable knowledge sharing and collaboration platform. Relevant entities of coal mine safety can share and interact their knowledge on this platform, improving the correctness and integrity of the knowledge graph; at the same time, the transparency and traceability of data, as well as the immutability and decentralization of data, also provide strong guarantees for the management and use of the knowledge graph. Description of the Drawings

[0020] To more clearly illustrate the technical solutions of the embodiments of the present invention, the following will briefly introduce the accompanying drawings required for the description of the embodiments. Obviously, the accompanying drawings in the following description are only some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can be obtained based on these drawings.

[0021] Figure 1 It is a flowchart of a method for constructing a coal mine safety knowledge graph using crowdsourcing and blockchain provided by an embodiment of the present invention;

[0022] Figure 2 It is a schematic diagram of a system for constructing a coal mine safety knowledge graph using crowdsourcing and blockchain provided by an embodiment of the present invention;

[0023] Figure 3 It is a schematic diagram of a processing device provided by an embodiment of the present invention. Detailed implementation manners

[0024] The following combines the accompanying drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, rather than all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts belong to the protection scope of the present invention.

[0025] First, the following explanations are given for the terms that may be used in this article:

[0026] Descriptions with terms such as "including", "comprising", "containing", "having" or other similar semantics should be interpreted as non-exclusive inclusion. For example: including a certain technical feature element (such as raw materials, components, ingredients, carriers, dosage forms, materials, dimensions, parts, components, mechanisms, devices, steps, processes, methods, reaction conditions, processing conditions, parameters, algorithms, signals, data, products or articles, etc.) should be interpreted as not only including the clearly listed certain technical feature element, but also including other well-known technical feature elements in the art that are not clearly listed.

[0027] The term "consisting of" means excluding any technical feature elements that are not clearly listed. If this term is used in a claim, this term will make the claim a closed type, making it not include technical feature elements other than the clearly listed ones, except for related conventional impurities. If this term only appears in a certain clause of the claim, then it only limits the elements clearly listed in that clause, and the elements recorded in other clauses are not excluded from the overall claim.

[0028] The following provides a detailed description of the solution for constructing a coal mine safety knowledge graph using crowdsourcing and blockchain. The content not described in detail in the embodiments of the present invention belongs to the prior art well-known to those skilled in the art. In the embodiments of the present invention, those not specified in specific conditions are carried out according to the conventional conditions in the art or the conditions recommended by the manufacturer. The instruments used in the embodiments of the present invention not specified in the manufacturer are all conventional products that can be obtained through commercial purchase.

[0029] Embodiment 1

[0030] An embodiment of the present invention provides a method for constructing a coal mine safety knowledge graph using crowdsourcing and blockchain, as Figure 1 shown, mainly including the following steps:

[0031] Step 1: Construct a coarse-grained coal mine safety domain knowledge graph.

[0032] In the embodiment of the present invention, an initial coal mine safety domain knowledge graph is constructed through static attribute data (data related to coal mine enterprises) recorded on the blockchain and task data related to coal mine safety. It is a coarse-grained coal mine safety domain knowledge graph.

[0033] Step 2: Start crowdsourcing voting through a blockchain-driven smart contract, continuously optimize the knowledge graph, and obtain a fine-grained knowledge graph.

[0034] In the embodiment of the present invention, crowdsourcing voting is started through a blockchain-driven smart contract. According to the white list sequence of participants output by the recommendation system, the participants participating in the crowdsourcing voting are determined. The proposal of the triple of the coal mine safety domain knowledge graph returned by each participant is received, and at the same time, the vote of each participant on the proposals of other participants is received; the initial coal mine safety domain knowledge graph is updated using the triples corresponding to the proposals passed by the vote, and the final coal mine safety domain knowledge graph is constructed.

[0035] Preferably, determining the participants participating in the crowdsourcing voting according to the white list sequence of participants output by the recommendation system includes: 1) Taking the coal mine safety knowledge graph to be constructed currently as a new task, inputting the corresponding task data into the recommendation system, and at the same time inputting the task data corresponding to the historical tasks of each participant. The recommendation system evaluates the probability of each participant receiving the new task, outputs the white list sequence of participants based on the probability, and records it on the blockchain; 2) Based on the white list sequence of participants recorded on the blockchain, task allocation is performed to determine the participants participating in the crowdsourcing voting in the new task.

[0036] Preferably, the steps for the recommendation system to output the white list sequence of participants include:

[0037] 1) For the new task, obtain the word embeddings corresponding to each word in the corresponding task data, use the knowledge graph embedding to obtain the corresponding entity embeddings for each word, and use the entity embeddings to obtain the context embeddings, and form the representation vector of the corresponding task data of the new task.

[0038] 2) Respectively transform the entity embeddings and context embeddings in the representation vector of the corresponding task data of the new task through a multi-channel convolutional neural network to obtain the transformed representation vector.

[0039] 3) Use filters with multiple different window sizes to extract features from the transformed representation vector, and perform pooling operations respectively, and then concatenate all the pooled features to obtain the embedding vector of the corresponding task data of the new task.

[0040] 4) In the same way (that is, in the way described in the foregoing 1) to 3)), obtain the embedding vectors corresponding to each historical task of each participant, use the attention mechanism to combine the embedding vectors corresponding to the tasks, calculate the weights between the new task and each historical task of each participant, and weight the corresponding historical tasks to obtain the embedding vectors of each participant;

[0041] 5) Use the embedding vector of the corresponding task data of the task and the embedding vectors of each participant to evaluate the probability that each participant receives the new task;

[0042] 6) According to the probability that each participant receives the new task, output the whitelist sequence of the participants.

[0043] Preferably, the knowledge graph embedding is obtained through the TransR model; the TransR model is trained in the following manner:

[0044] For each triple (h, r, t) in the corresponding knowledge graph, where h represents the head entity, t represents the tail entity, and r represents the relationship, the entity embedding obtained through the TransR model is set as The relationship embedding is set as k and d respectively represent the dimensions of the corresponding embeddings, is the symbol of the real number set;

[0045] For each relationship r, introduce a projection matrix It maps the entity embedding from the entity space to the corresponding relationship space, expressed as:

[0046]

[0047] Among them, h r and t r are the embeddings of the projected head entity and tail entity respectively;

[0048] Train the TransR model using an edge-based scoring function, expressed as:

[0049]

[0050] where γ is the margin, S is the set of correct triples (h, r, t), and S' is the set of incorrect triples (h′, r, t′); f r is the scoring function; h r ′, t r ′ are the embeddings representing the projected head entity h′ and tail entity t′.

[0051] The above solution provided by the embodiments of the present invention mainly has the following advantages:

[0052] 1) The blockchain technology and knowledge graph technology are used to construct the coal mine safety knowledge graph, combining the advantages of both technologies. Specifically, it has the advantages of transparency, auditability, security, immutability, and decentralization, and can also integrate and connect data, make full use of semantic information, support reasoning and learning, and provide intuitive visualization effects at the same time.

[0053] 2) An innovative crowdsourcing method is proposed to achieve the decentralized construction of the knowledge graph. This process is realized through blockchain-driven smart contracts to ensure the publicity of the construction process. The application of the crowdsourcing method also enables the construction process of the knowledge graph to absorb and use the knowledge of professionals and community members more widely, greatly improving the quality and comprehensiveness of the knowledge graph.

[0054] 3) The coal mine safety knowledge graph based on blockchain and crowdsourcing method provides a more transparent and reliable knowledge sharing and collaboration platform. Relevant entities of coal mine safety can share and interact their knowledge on this platform, improving the correctness and integrity of the knowledge graph. At the same time, the transparency, traceability, immutability, and decentralization of data also provide strong guarantees for the management and use of the knowledge graph.

[0055] Generally speaking, the present invention not only combines the advantages of blockchain and knowledge graph, but also introduces the crowdsourcing method to collect and utilize coal mine safety knowledge more widely and comprehensively, with significant advantages and innovation.

[0056] In order to more clearly show the technical solution provided by the present invention and the technical effects produced, the method provided by the embodiments of the present invention will be described in detail below with specific embodiments.

[0057] I. Overall overview of the solution.

[0058] The present invention utilizes deep learning, crowdsourcing, and blockchain technologies to construct and optimize a coal mine safety knowledge graph. The deep learning technology extracts coal mine safety information from the knowledge obtained through crowdsourcing. The crowdsourcing technology enables a large number of participants to share their professional knowledge, enriching the content of the graph. The smart contract of the blockchain ensures the fairness and transparency of the contributions of all participants, preventing a single participant from manipulating. The present invention also constructs a deep recommendation system to promote coal mine safety knowledge. By filtering out irrelevant information and data noise, the present invention reduces the complexity of constructing and updating the knowledge graph, achieving real-time updating and optimization of the knowledge graph. All in all, the present invention proposes a new method to construct a coal mine safety knowledge graph by using deep learning, crowdsourcing, and blockchain technologies.

[0059] II. Detailed introduction of the solution.

[0060] The present invention is divided into two parts, namely, the on-chain part of the blockchain (completed on the blockchain) and the off-chain part of the blockchain (completed outside the blockchain). The on-chain part of the blockchain aims to construct a domain knowledge graph through crowdsourcing, which is realized by a blockchain-driven smart contract; while the off-chain part of the blockchain uses a decentralized knowledge graph for participant recommendation.

[0061] After these two parts, the deep learning recommendation system will return a knowledge graph and a white list sequence {a_1, a_2, …, a_n} of participants. The knowledge graph is the knowledge graph after crowdsourcing and has considerable credibility; the participants on the white list have made quite positive contributions in the crowdsourcing tasks, indicating that when a batch of task data comes, the manager can select participants from this sequence from front to back to participate in the crowdsourcing. Because they have made positive contributions to all previous tasks. The following is a detailed introduction to the on-chain part and the off-chain part of the blockchain respectively.

[0062] 1. On-chain part of the blockchain.

[0063] Step a-1: Task data and static attributes in a specific domain are recorded on the private blockchain within the organization. Due to the transparency of the blockchain, all information is open to each participant. Then, a coarse-grained coal mine safety domain knowledge graph can be constructed based on this.

[0064] Step a-2: In order to continuously optimize this basic graph, a crowdsourcing vote is initiated through a smart contract. Each participant can propose a triple. Here, the participants are obtained through the subsequent off-chain part of the blockchain. The remaining participants will vote on this proposal. If the proposal is passed, the proposed triple will be recorded in the knowledge graph to generate a more fine-grained knowledge graph. The entire process of the crowdsourcing vote is written into the blockchain-driven smart contract and can be automatically executed. The crowdsourcing vote is used to obtain the triples of the knowledge graph.

[0065] 2. Off-chain part of the blockchain

[0066] Step b-1: Use knowledge graph embedding to form low-dimensional representation vectors of entities and relationships in the updated graph. In a typical triple (h, r, t), h represents the head entity, t represents the tail entity, and r represents the relationship. The general idea of entity and relationship embedding is to regard the relationship r as a translation from the head entity h to the tail entity t. The TransR model (which is an entity relationship representation learning model based on knowledge graphs) maps entities and relationships to different spaces, namely the entity space and multiple relationship spaces, and then performs translation in the corresponding relationship space. The following is the specific process:

[0067] Step b-1-1: For each triple (h, r, t), the entity embedding is set to The relationship embedding is set to (k is not necessarily equal to d). For each relationship r, a projection matrix is introduced, which maps the entity embedding from the entity space to the corresponding relationship space. This relationship-specific projection can bring the head / tail entities with that relationship closer, while entities without that relationship are farther away. This way enhances the specificity of the relationship and makes the modeling of the relationship more accurate. This can be expressed in the following mathematical form:

[0068]

[0069] where h r and t r are the projected head and tail entities, and M r is the projection matrix of the relationship r.

[0070] Step b-1-2: After obtaining the projected head entity h r and tail entity t r , the following scoring function can be used:

[0071]

[0072] In practical applications, some constraints need to be executed. For example: for

[0073] Step b-1-3: Train with the following margin-based scoring function

[0074]

[0075] where γ is the margin, and S and S' are the sets of correct and incorrect triples respectively. After training, the vector representations of entities and relationships in the given knowledge graph can be obtained.

[0076] Step b-2: The off-chain deep recommendation system of the blockchain takes the new work task t j and the corresponding task data and the corresponding task data of each participant's previous work tasks as inputs, outputs the probability of each participant accepting the task, thereby quantitatively evaluating the role played by each participant when voting on this triple, and at the same time performing corresponding statistics based on the acceptance probability to obtain a whitelist of participants. The specific steps are as follows:

[0077] Step b-2-1: For the task t of length n j The corresponding data (the task data mentioned in step a-1), its original input sequence can be expressed as t j = w 1:n = [w 1 , w 2 , …, w n , each item is a word, and the representation vector of the task t j can be regarded as the concatenation of word embedding, entity embedding, and context embedding, expressed as:

[0078]

[0079] Among them, among them, w 1:n = [w 1 w 2 … w n is the word embedding set of the corresponding task data of the task t j , n is the number of words, each item corresponds to a word, and can be pre-learned or randomly initialized from a large-scale corpus; e 1:n = [e 1 e 2 …e n is the entity embedding set obtained by using knowledge graph embedding for each word, and each item is the entity embedding of a word; is the context embedding set of entities, and each item is the context embedding of the entity corresponding to a word, which is calculated by calculating the average value of entity contexts.

[0080] The calculation method of a single context embedding is as follows:

[0081]

[0082] Among them, CONTEXT(e) represents the set of context entity embeddings related to entity e (here referring to the entities adjacent to e in the knowledge graph), and |CONTEXT(e)| is the number of elements in the set. This simple concatenation strategy breaks the connection between words and related entities and does not understand the alignment between them. This means that although word embeddings and entity embeddings may be concatenated together, any potential relationships or structural information between these elements are not preserved or utilized.

[0083] Step b-2-2: Use a multi-channel and word-entity alignment KCNN (multi-channel convolutional neural network) to combine word semantics and knowledge information, and introduce the following transformed entity embeddings and transformed context embeddings:

[0084] g(e 1:n ) = [g(e 1 ) g(e 2 ) … g(e n )]

[0085]

[0086] Among them, g(e 1:n ) is the set of transformed entity embeddings, and each item is a transformed entity embedding; is the set of transformed context embeddings, and each item is a transformed context embedding; g is the transformation function.

[0087] Thus, the representation vector corresponding to task t j is rewritten as:

[0088]

[0089] Among them, W′ is the transformed representation vector.

[0090] Step b-2-3: Use M filters q with different window sizes of l to extract local patterns in the task corresponding task data, obtain the corresponding features, use the max-time pooling operation to select the maximum features, and then concatenate all the maximum features to obtain the embedding vector (embedding representation) of the new task corresponding task data, expressed as:

[0091]

[0092] Among them, f is the activation function (generally using the Relu activation function), is the local pattern extracted by the v-th window of the filter, that is, the extracted feature, and W′ v:v+l-1 is the information in the embedding vector corresponding to the v-th window of the filter, where v = 1, 2, …, n - l + 1, and n - l + 1 is the number of windows. is the maximum feature corresponding to the m-th window, where m = 1, 2, …, M, b is the bias term, and e(t j ) is the embedding vector of the task data corresponding to task t j .

[0093] Step b-2-4: Obtain the embedding vectors of the task data corresponding to each historical task of the participant in the same way as in the aforementioned steps b-2-1 to b-2-3. To obtain the embedding vector of the task data corresponding to the new task for the participant, use the attention mechanism to combine the embedding vectors of the task data corresponding to the task, calculate the weights between the new task and each historical task of each participant, and perform weighted aggregation on the embedding vectors of the task data corresponding to the corresponding historical tasks to obtain the embedding vectors of each participant.

[0094] Specifically: For participant i, denote the number of its historical tasks as N i , a single historical task as , the embedding vector of the corresponding task data as Calculate the weight between the new task and the historical task in the following way and then perform weighted aggregation to obtain the embedding vector of a single participant, expressed as:

[0095]

[0096] where e(i) is the embedding vector of participant i, is the attention module, and N i is the number of historical tasks of participant i.

[0097] Each participant calculates the corresponding embedding vector in the above way, which will not be elaborated here.

[0098] Step b-2-5: Input e(t j )(the embedding representation of the task data corresponding to the new task) and e(i) (the embedding representation of the participant) into the deep neural network to calculate the probability j that participant i accepts task t At the same time, first select a probability threshold When the probability is greater than , it means that participant i is competent for task t j . Record the number of tasks that each participant is competent for and the specific tasks that each participant is competent for. The information of these two parts together constitutes the recommendation result. Select a set proportion of participants to join the whitelist sequence according to the number of tasks that each participant is competent for, indicating that the corresponding participants make positive contributions to the knowledge graph returned by the system.

[0099] Step b-3: The recommendation results are fed back to the administrator, who will refer to the recommendation results for task allocation. Meanwhile, the administrator will take some corresponding rewards and punishments based on the whitelist.

[0100] Preferably, the recommendation results are recorded on the blockchain for easy tracking and to prevent tampering. The final task allocation and new task data (continuous data collected according to time series or other sources) are also recorded on the blockchain as the basis for the next round of knowledge graph update.

[0101] III. Example Explanation.

[0102] To facilitate the description of the processing flow of the present invention, a specific example is given below.

[0103] 1. On-chain part of the blockchain.

[0104] Step a-1: A batch of texts (task data) related to coal mine safety are recorded on the private blockchain within the coal mine enterprise. Using this data, a coarse-grained knowledge graph in the field of coal mine safety is established with the previously established static attributes (relevant information of the coal mine company, such as the number of employees, company production capacity, and mine parameters owned by the company, such as mine depth, etc.).

[0105] Step a-2: To continuously optimize this basic graph, crowdsourcing voting is initiated through a smart contract, that is, employees of the coal mine enterprise are asked to vote on the entity relationships in these knowledge graphs to generate a finer-grained knowledge graph, and crowdsourcing voting is used to obtain the triples of the knowledge graph. Each coal mine enterprise employee participating in the voting can propose a triple (for example: an employee believes that the data "The third major hidden danger of coal mine accidents includes the following 15 aspects: (2), gas exceeding the limit operation." proposes the triple ["coal mine", "includes major accident hidden danger", "gas exceeding the limit operation"]). The rest of the participants will vote on this proposal. If the proposal is passed, the proposed triple will be recorded in the knowledge graph. The entire process of crowdsourcing voting is written into the blockchain-driven smart contract and can be automatically executed.

[0106] 2. Off-chain part of the blockchain.

[0107] Step b-1: Use knowledge graph embedding to form low-dimensional representation vectors of entities and relationships in the updated graph. In a typical triple ("coal mine", "includes major accident hazards", "gas overrun operation"), h = "coal mine" represents the head entity, t = "gas overrun operation" represents the tail entity, and r = "includes major accident hazards" represents the relationship. The general idea of entity and relationship embedding is to regard the relationship r as a translation from the head entity h to the tail entity t. TransR maps entities and relationships to different spaces, namely the entity space and multiple relationship spaces, and then performs translation in the corresponding relationship space. The following is the specific process:

[0108] Step b-1-1: Introduce a projection matrix for each triple (h, r, t) Use to obtain the projected head and tail entities. This enhances the specificity of the relationship and makes the modeling of the relationship more accurate.

[0109] Step b-1-2: After obtaining the projected head entity h r and tail entity t r use to calculate the scoring function, and at the same time have the following constraints:

[0110] Step b-1-3: Use L = ∑ (h,r,t)∈S ∑ (h′,r,t′)∈S′ max 0, f r (h, t)+γ - f r (h′, t′)) function for training. Where γ is the margin, S and S' are the sets of correct and incorrect triples respectively (correct and incorrect triples are obtained through crowdsourcing voting. For example: ("coal mine", "includes major accident hazards", "gas overrun operation") is a correct triple, and ("coal mine", "does not include major accident hazards", "gas overrun operation") is an incorrect triple). After training, the vector representations of entities and relationships in the given knowledge graph can be obtained.

[0111] Step b-2: The off-chain depth recommendation system takes the new work task t j the corresponding task data and the corresponding task data of each employee's previous work tasks as input, outputs the probability of each employee accepting the task, so as to quantitatively evaluate the role played by each employee when voting on this triple (how much correct or incorrect contribution is made to a certain triple), and at the same time based on the acceptance probability, corresponding statistics are carried out to obtain a whitelist of participants. The specific process is as follows:

[0112] Step b-2-1: The present invention needs to process the task t of length nj Obtain word embeddings for each word in the task data. Word embedding is a technique that converts text data into numerical vectors.

[0113] For a task t of length n j Corresponding to the task data (the task data mentioned in step a-1), its original input sequence can be represented as t = w 1:n = [w 1 , w 2 , …, w n . The representation vector corresponding to the task data can be regarded as the concatenation of word embeddings, entity embeddings, and context embeddings:

[0114]

[0115] where, w 1:n = [w 1 w 2 … w n is the word embedding of task t j corresponding to the task data, which can be pre-learned from a large corpus or randomly initialized; e 1:n = [e 1 e 2 … e n is the entity embedding obtained by using knowledge graph embedding for each word w i ; is the context embedding of the entity, and the calculation method is the average of its context entities.

[0116] The calculation method of a single context embedding is as follows:

[0117]

[0118] Among them, CONTEXT(e) represents the set of context entity embeddings related to entity e (here it refers to the entities adjacent to e in the knowledge graph), and |CONTEXT(e)| is the number of elements in the set. For example, in the data of the example: "The major hidden dangers of coal mine accidents include the following 15 aspects: (1) Organizing production with overcapacity, over-intensity or overstaffing; (2) Operating with gas overrun." The word segmentations include "coal mine", "major accident", etc., and the present invention obtains embedding representations for these words. Then, the present invention needs to obtain the entity embeddings in the task data corresponding to the task. Entity embeddings are similar to word embeddings, but they are specifically used to represent entities. In this step, the present invention can use a pre-trained entity embedding model to obtain the embedding representation of each entity. For example, for the triple in the example ("coal mine", "includes major hidden dangers of accidents", "operating with gas overrun"), both "coal mine" and "operating with gas overrun" are entities, and the present invention obtains embedding representations for these entities. Finally, the present invention needs to obtain the context embeddings of the task data corresponding to the task. Context embeddings are an embedding technology that can consider the context information of words. In this step, the present invention can use a pre-trained context embedding model (the calculation method is the average value of the context) to obtain the context embeddings of the task data corresponding to the task. For example, the context of "(2) Operating with gas overrun." is "(1) Organizing production with overcapacity, over-intensity or overstaffing", and the present invention obtains an embedding representation for this context.

[0119] Step b-2-2: The present invention uses a multi-channel convolutional neural network (KCNN). A multi-channel convolutional neural network is a deep learning model that can learn and extract features from different input channels (here are word semantics and knowledge information). In the implementation scheme of the present invention, one channel receives word semantic information, and the other channel receives knowledge information; in order to better combine word semantics and knowledge information, the present invention uses a word-entity alignment method. This alignment method can help the present invention understand the relationship between words and entities and better spread this information throughout the network; for entity embeddings and context embeddings, the present invention introduces transformations. These transformations can help the present invention better understand and use these embeddings. For example, the present invention can use linear transformations or non-linear transformations to change the representation of the embeddings so that they can better adapt to the model of the present invention. The present invention uses the following transformation methods:

[0120] g(e 1:n ) = [g(e 1 ) g(e 2 ) … g(e n )]

[0121]

[0122] where g is the transformation function. Then, task t j The representation vector corresponding to the task data is rewritten as:

[0123]

[0124] Step b-2-3: The present invention can further refine the execution process, including using filters of different window sizes, applying a maximum time pooling operation, and concatenating all features to obtain an embedding vector of the task data corresponding to the task.

[0125] First, the present invention uses multiple filters q with different window sizes l. These filters can extract local patterns in the task-corresponding task data. Then, on the output feature map, the present invention uses the maximum time pooling operation. Finally, the present invention obtains the embedding vector of the task-corresponding task data by connecting all features in series. This step merges the outputs of all filters into a long vector that can capture rich information in the task. This embedding vector will be used in subsequent deep learning or machine learning models.

[0126]

[0127] Among them, f is the activation function (generally using the Relu activation function), is the local pattern extracted by the vth window of the filter, that is, the extracted feature, W′ v:v+l-1 is the information in the embedding vector corresponding to the vth window of the filter, v = 1, 2, ..., n-l + 1, n-l + 1 is the number of windows, is the largest feature corresponding to the mth window, m = 1, 2, ..., M, b is the bias term, e(t j ) is the task t j The embedding vector corresponding to the task data.

[0128] The above method effectively extracts local patterns in the task and generates an embedding vector representing the task data corresponding to the task.

[0129] Step b-2-4: Use the above steps b-2-1 to b-2-3 to obtain the embedding vector of the task data corresponding to each historical task of the participant. In order to obtain the embedding representation of the task data corresponding to the new task of the participant, the attention mechanism is used here to automatically match the new task with each previous task of the participant to obtain the weight of the participant's participation in the task. And aggregate them with different weights:

[0130]

[0131] in, is the attention module, Ni is the number of the employee's previous tasks.

[0132] Step b-2-5: Input e(t j )(the embedded representation of the task data corresponding to the new task) and e(i) (the embedded representation of the participant) into the deep neural network, and calculate the probability that participant i accepts task t j Meanwhile, first select a probability threshold When the probability is greater than it indicates that participant i is competent for task t . Record the number of tasks that each participant is competent for and the specific tasks that each participant is competent for. The information in these two parts together constitutes the recommendation result. Select a set proportion of participants to join the whitelist sequence according to the number of tasks that each participant is competent for, indicating that the corresponding participants make positive contributions to the knowledge graph returned by the system. j

[0133] Step b-3: Feed the recommendation result back to the administrator. They will refer to the recommendation result for task assignment. At the same time, based on the previously generated whitelist, the administrator can reward them. For subsequent unknown tasks, the administrator is more inclined to assign these tasks to the participants in the whitelist first or trust the triples proposed by the participants in the whitelist more.

[0134] Through the description of the above implementation manners, those skilled in the art can clearly understand that the above embodiments can be implemented by software or by means of software plus a necessary general hardware platform. Based on such an understanding, the technical solutions of the above embodiments can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.), including several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in various embodiments of the present invention.

[0135] Embodiment 2

[0136] The present invention also provides a coal mine safety knowledge graph system constructed by using crowdsourcing and blockchain, which is mainly used to implement the method provided in the foregoing embodiments. As Figure 3 shown, the system mainly includes:

[0137] An initial coal mine safety domain knowledge graph construction unit, which is used to construct an initial coal mine safety domain knowledge graph by using the static attribute data recorded on the blockchain and the task data related to coal mine safety;

[0138] A construction unit of a coal mine safety knowledge graph based on crowdsourcing and blockchain is used to initiate a crowdsourcing vote through a blockchain-driven smart contract, determine the participants in the crowdsourcing vote according to the whitelist sequence of participants output by the recommendation system, receive the proposals of each participant regarding the triples of the coal mine safety domain knowledge graph, and at the same time receive the votes of each participant for the proposals of other participants; update the initial coal mine safety domain knowledge graph with the triples corresponding to the proposals passed by the vote to construct the final coal mine safety domain knowledge graph.

[0139] Considering that the main technical details involved in this system have been introduced in detail in the previous embodiments, they will not be elaborated here; in addition, when the system implements related methods, certain specific steps can be executed by configuring the corresponding modules.

[0140] Those skilled in the art can clearly understand that, for the convenience and simplicity of description, only the above division of each functional module is used as an example. In practical applications, the above functions can be allocated to different functional modules according to needs, that is, the internal structure of the system is divided into different functional modules to complete all or part of the functions described above.

[0141] Embodiment III

[0142] The present invention also provides a processing device, such as Figure 3 shown, which mainly includes: one or more processors; a memory for storing one or more programs; wherein, when the one or more programs are executed by the one or more processors, the one or more processors implement the methods provided in the foregoing embodiments.

[0143] Furthermore, the processing device further includes at least one input device and at least one output device; in the processing device, the processor, the memory, the input device, and the output device are connected by a bus.

[0144] In the embodiments of the present invention, the specific types of the memory, the input device, and the output device are not limited; for example:

[0145] The input device can be a touch screen, an image acquisition device, a physical button, or a mouse, etc.;

[0146] The output device can be a display terminal;

[0147] The memory can be a Random Access Memory (RAM), or a non-volatile memory, such as a disk memory.

[0148] Embodiment IV

[0149] The present invention also provides a readable storage medium storing a computer program, which implements the method provided in the foregoing embodiments when executed by a processor.

[0150] In an embodiment of the present invention, the readable storage medium, as a computer-readable storage medium, may be disposed in the foregoing processing device. For example, it may be a memory in the processing device. In addition, the readable storage medium may also be various media capable of storing program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a magnetic disk, or an optical disc.

[0151] The foregoing is only a preferred specific implementation manner of the present invention, but the protection scope of the present invention is not limited thereto. Any changes or substitutions that can be easily thought of by those skilled in the art within the technical scope disclosed by the present invention should be covered by the protection scope of the present invention. Therefore, the protection scope of the present invention should be subject to the protection scope of the claims.

Claims

1. A method for constructing a coal mine safety knowledge graph using crowdsourcing and blockchain, characterized in that: include: By recording static attribute data on the blockchain and task data related to coal mine safety, an initial knowledge graph in the field of coal mine safety is constructed; Crowdsourcing voting is initiated through a blockchain-driven smart contract. According to the whitelist sequence of participants output by the recommendation system, the participants participating in the crowdsourcing voting are determined, and the proposals of triples about the knowledge graph in the field of coal mine safety returned by each participant are received. At the same time, each participant's vote on the proposals of other participants is received; the initial knowledge graph in the field of coal mine safety is updated with the ternary corresponding to the proposal that passes the vote, and the final knowledge graph in the field of coal mine safety is constructed.

2. According to claim 1, a method for constructing a coal mine safety knowledge graph using crowdsourcing and blockchain is characterized in that: The participants who participate in the crowdsourcing voting are determined according to the whitelist sequence of participants output by the recommendation system, including: The current construction of the coal mine safety knowledge graph is taken as a new task, and the corresponding task data is input into the recommendation system. At the same time, the historical tasks of each participant are input. The recommendation system evaluates the probability of each participant receiving the new task, outputs the whitelist sequence of the participant based on the probability and records it on the blockchain; Task allocation is performed based on the whitelist sequence of participants recorded on the blockchain, and participants who participate in the crowdsourcing voting in the new task are determined.

3. A method for constructing a coal mine safety knowledge graph using crowdsourcing and blockchain according to claim 1 or 2, characterized in that: The steps for the recommendation system to output the whitelist sequence of participants include: For the task data corresponding to the new task, obtain the word embedding corresponding to each word, and use the knowledge graph embedding to obtain the corresponding entity embedding for each word, and use the entity embedding to obtain the context embedding to form the representation vector of the task data corresponding to the new task; Converting the entity embedding and the context embedding in the representation vector of the new task respectively through a multi-channel convolutional neural network to obtain a converted representation vector; Using multiple filters with different window sizes to extract features from the converted representation vector, and performing pooling operations on each of them, and then concatenating all the pooled features to obtain an embedding vector of the task data corresponding to the new task; In the same way, the embedding vectors of the task data corresponding to each historical task of each participant are obtained, and the weights between the new task and each historical task of each participant are calculated by combining the embedding vectors of the task data corresponding to the task using the attention mechanism, and the embedding vectors of the task data corresponding to the corresponding historical tasks are weighted to obtain the embedding vectors of each participant; Using the embedding vector of the task data corresponding to the new task and the embedding vector of each participant, the probability of each participant accepting the new task is evaluated; According to the probability of each participant receiving the new task, a whitelist sequence of the participant is output.

4. The method for constructing a coal mine safety knowledge graph using crowdsourcing and blockchain according to claim 3 is characterized in that: The knowledge graph embedding is obtained through the TransR model; the TransR model is trained in the following way: For each triple (h, r, t) in the knowledge graph, h represents the head entity, t represents the tail entity, and r represents the relationship. The entity embedding is obtained through the TransR model and is set to The relation embedding is set to k and d represent the corresponding embedding dimensions, is the symbol of the real number set; For each relation r, a projection matrix is ​​introduced It maps entity embeddings from the entity space to the corresponding relation space, expressed as: Among them, h r With t r are the embeddings of the head entity and the tail entity after projection, respectively; The TransR model is trained using an edge-based scoring function, expressed as: Where γ is the edge, S is the set of correct triplets (h, r, t), and S' is the set of incorrect triplets (h', r, t'); f r is the scoring function; h r ′、t r ’ corresponds to the embedding of the projected head entity h’ and tail entity t’.

5. According to claim 3, a method for constructing a coal mine safety knowledge graph using crowdsourcing and blockchain is characterized in that: The step of converting the entity embedding and the context embedding in the representation vector of the new task by means of a multi-channel convolutional neural network to obtain the converted representation vector comprises: The representation vector of the task data corresponding to the new task is recorded as: Among them, w 1:n =[w1 w2 … w n ] is a word embedding set, n is the number of words, and each item corresponds to a word; e 1:n =[e1 e2… e n ] is the entity embedding set obtained for each word using knowledge graph embedding, each item is the entity embedding of a word; is the context embedding set of entities, each item is the context embedding of the entity corresponding to a word, which is calculated by calculating the average value of the entity context; Using a multi-channel convolutional neural network with multi-channel and word-entity alignment, we introduce the following transformed entity embeddings and transformed context embeddings: g(e 1:n )=[g(e1)g(e2)…g(e n )] Among them, g(e 1:n ) is a transformed entity embedding set, each item is a transformed entity embedding; is a transformed context embedding set, each item is a transformed context embedding; g is a transformation function; Then the transformed representation vector is: Among them, W′ is the transformed representation vector.

6. The method for constructing a coal mine safety knowledge graph using crowdsourcing and blockchain according to claim 3 is characterized in that: The method of using a plurality of filters with different window sizes to extract features from the converted representation vector, performing pooling operations respectively, and then concatenating all the pooled features to obtain the embedding vector of the task data corresponding to the new task includes: Use m filters q with different window sizes l to extract local patterns in the task data corresponding to the task, obtain the corresponding features, use the maximum time pooling operation to select the largest feature, and then concatenate all the largest features to obtain the embedding vector of the task data corresponding to the new task, expressed as: Where f is the activation function, is the local pattern extracted by the vth window of the filter, that is, the extracted feature, W′ v:v+l-1 is the information in the embedding vector corresponding to the vth window of the filter, v = 1, 2, ..., n-l + 1, n-l + 1 is the number of windows, is the largest feature corresponding to the mth window, m = 1, 2, ..., M, b is the bias term, e(t j ) is the task t j The embedding vector corresponding to the task data.

7. The method for constructing a coal mine safety knowledge graph using crowdsourcing and blockchain according to claim 3 is characterized in that: The attention mechanism is used in combination with the embedding vector of the task data corresponding to the task, the weight between the new task and each historical task of each participant is calculated, and the embedding vector of the task data corresponding to the corresponding historical task is weighted to obtain the embedding vector of each participant, including: For participant i, the number of its historical tasks is recorded as N i , a single historical task is recorded as t i k , the embedding vector of the corresponding task data is recorded as The new task and the historical task are calculated as follows Weight Then perform weighted aggregation to obtain the embedding vector of a single participant, expressed as: Where e(i) is the embedding vector of participant i, is the attention module, N i is the number of historical tasks of participant i.

8. A coal mine safety knowledge graph system constructed using crowdsourcing and blockchain, characterized in that: For implementing the method described in any one of claims 1 to 7, the system comprises: The initial coal mine safety field knowledge graph construction unit is used to construct the initial coal mine safety field knowledge graph by recording the static attribute data on the blockchain and the task data related to coal mine safety; The coal mine safety knowledge graph construction unit based on crowdsourcing and blockchain is used to initiate crowdsourcing voting through a blockchain-driven smart contract, determine the participants participating in the crowdsourcing voting according to the whitelist sequence of participants output by the recommendation system, receive the proposals of triples about the coal mine safety field knowledge graph returned by each participant, and receive votes from each participant on the proposals of other participants; use the triples corresponding to the proposals that pass the vote to update the initial coal mine safety field knowledge graph, and construct the final coal mine safety field knowledge graph.

9. A processing device, characterized in that: include: one or more processors; A memory for storing one or more programs; When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 7.

10. A readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.

Citation Information

Patent Citations

  • A knowledge graph construction method based on blockchain

    CN115033709B

  • Accounting marking method based on block chain technology

    CN117093654A