Logistics traceability system and method based on block chain technology

By building an event graph structure and verification path map, the problems of high storage costs on-chain and lack of verification of off-chain data in logistics traceability are solved, and the structured expression and traceability of data are realized, reducing storage costs and improving the operating efficiency and security of the system.

CN120525433AActive Publication Date: 2025-08-22HUNAN SHUIYANG LOGISTICS CO LTD

Patent Information

Application Number
CN202510980470.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-07-16
Publication Date
2025-08-22
Estimated Expiration
2045-07-16

AI Technical Summary

Technical Problem

In the logistics traceability of the prior art, there are problems such as excessive consumption of on-chain storage resources and lack of structured verification of off-chain data, resulting in high storage costs and inability to effectively support behavioral path reconstruction and traceable positioning of responsible entities.

Method used

Build an event graph structure, calculate the structure closure signature value and responsibility structure weight value of the event node, and build a verification path mapping diagram through path information entropy and transfer degree. Only the key node data is written to the blockchain, and off-chain data is bound and verified.

Benefits of technology

It realizes structured expression and verifiable modeling of logistics event data, reduces on-chain storage costs, improves the integrity and traceability of the event chain, and ensures data credibility and system operation efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120525433A_ABST
    Figure CN120525433A_ABST
Patent Text Reader

Abstract

The invention discloses a logistics traceability system and method based on a block chain technology, and relates to the technical field of logistics traceability, and the method comprises the steps: constructing an event graph structure containing a plurality of behavior event nodes, and calculating a structure closure signature value; judging whether the original data of the behavior event node is written into the block chain or not according to the responsibility structure weight value; constructing a verification path mapping graph based on the structure closure signature value and the responsibility structure weight value; when a traceability request is received, calling the verification path mapping graph, performing consistency verification on the original data of the target behavior event node and the structure mapping hash value, and generating a traceability verification result; according to the method, the credibility of the behavior event data structure is improved, meanwhile, the on-chain storage cost is effectively reduced, and the technical contradiction between full-uplink data and non-uplink data is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of logistics traceability technology, and specifically to a logistics traceability system and method based on blockchain technology. Background Art

[0002] As the logistics industry rapidly develops towards intelligence and dataization, behavioral events in each link of the logistics process are continuously collected in the form of data to achieve process tracking, responsibility division and exception tracing; in order to improve data credibility and traceability, blockchain technology is introduced into the logistics information system to record key node data on the chain, thereby realizing the traceability capability framework of "on-chain evidence storage and off-chain reference".

[0003] However, since the entire logistics process involves numerous nodes and frequent events, if all behavioral event data are written directly into the blockchain, it will lead to a large consumption of storage resources and a significant increase in writing costs, which will be difficult to adapt to the on-chain storage capabilities under conventional business scenarios; at the same time, if only part of the data is written into the blockchain and the rest of the data is retained in the off-chain system, it will be unable to effectively support the structural authenticity verification of the off-chain behavioral sequence due to the lack of a structured verifiable mechanism, especially in terms of behavioral path reconstruction, temporal consistency analysis of previous and subsequent events, and traceability of responsible parties. There are problems of missing evidence or on-chain and off-chain breaks.

[0004] Therefore, there is an urgent need for a logistics traceability system and method based on blockchain technology that can take into account both on-chain storage constraints and off-chain data structural verification requirements throughout the entire logistics process, thereby ensuring that behavioral event data is traceable and structurally consistent. Summary of the Invention

[0005] The present invention aims to solve at least one of the technical problems existing in the prior art; to this end, the present invention proposes a logistics traceability method based on blockchain technology.

[0006] To achieve the above objectives, the present invention provides a logistics traceability method based on blockchain technology, comprising:

[0007] Collect logistics behavior event data, build an event graph structure containing multiple behavior event nodes, and calculate the structural closure signature value for each behavior event node based on the event hash value of its corresponding event data, the structural dependency signature value of the predecessor behavior event node, and the topological position index in the event graph structure. The event data includes a timestamp field, an event type field, and a responsible entity field.

[0008] Based on the event graph structure, all reachable paths involved in each behavior event node are counted, and the path information entropy value of each behavior event node is calculated. The transitive degree is constructed by combining the out-degree and in-degree of the behavior event node. The responsibility structure weight value is jointly calculated based on the path information entropy value and the transitive degree. Based on the size of the responsibility structure weight value, it is determined whether the original data of the behavior event node is written into the blockchain;

[0009] Based on the structure closure signature value and the responsibility structure weight value, a verification path mapping graph is constructed, in which the structure closure signature value of each behavior event node is bound to the storage path of the off-chain data, and a structure mapping hash value is generated;

[0010] When a traceability request is received, the verification path map is called to perform consistency verification on the original data and structure mapping hash value of the target behavior event node to generate a traceability verification result.

[0011] On the other hand, the present invention also provides a logistics traceability system based on blockchain technology, which is implemented based on the above-mentioned logistics traceability method based on blockchain technology, including:

[0012] An acquisition module is used to collect logistics behavior event data, construct an event graph structure containing multiple behavior event nodes, and calculate the structural closure signature value for each behavior event node based on the event hash value of its corresponding event data, the structural dependency signature value of the predecessor behavior event node, and the topological position index in the event graph structure. The event data includes a timestamp field, an event type field, and a responsible entity field;

[0013] An analysis module is used to count all reachable paths involved in each behavior event node based on the event graph structure, calculate the path information entropy value of each behavior event node, construct the transitive degree based on the out-degree and in-degree of the behavior event node, jointly calculate the responsibility structure weight value based on the path information entropy value and the transitive degree, and determine whether the original data of the behavior event node is written into the blockchain based on the size of the responsibility structure weight value;

[0014] An association module is configured to construct a verification path mapping graph based on the structure closure signature value and the responsibility structure weight value, bind the structure closure signature value of each behavior event node to the storage path of the off-chain data in the verification path mapping graph, and generate a structure mapping hash value;

[0015] The traceability module is used to call the verification path mapping diagram when receiving a traceability request, perform consistency verification on the original data and structure mapping hash value of the target behavior event node, and generate a traceability verification result.

[0016] Compared with the prior art, the present invention has the following beneficial effects:

[0017] The present invention realizes the structured expression and verifiable modeling of logistics event data by constructing a behavioral event graph structure and introducing a structural closure signature value, so that each event not only has a unique identifier, but also can reflect the evolutionary dependency relationship with the predecessor event at the structural level; compared with the existing practice of sorting only by time or number, the present invention can accurately restore the real flow path of logistics tasks and prevent illegal event connections, which significantly improves the integrity and traceability of the event chain.

[0018] Furthermore, the present invention constructs the responsibility structure weight value through path information entropy and transfer degree, which effectively solves the cost burden problem brought by all chain-up while ensuring data credibility; the system can automatically identify the key nodes in the structure that truly have communication value and influence, and only write these node data into the blockchain. The remaining nodes are bound and verified off-chain through structural signatures, thereby taking into account the representativeness of the chain data and the economy of on-chain storage, and improving the overall system operation efficiency and trusted computing capabilities.

[0019] In addition, the present invention constructs a verification path mapping graph and introduces a structural mapping hash mechanism, which establishes a strong binding relationship between off-chain data and the graph structure, and supports structural consistency verification of off-chain nodes at any time; even if some event data is not written to the blockchain, the traceability and data verification of the entire chain can still be completed through the verification path, which improves the security and practicality of the system in scenarios such as regulatory audits and compliance accountability, and realizes the unity of on-chain trust and off-chain efficiency.

[0020] In summary, the present invention effectively reduces on-chain storage costs while ensuring data credibility, achieving a technical balance between the fundamental contradiction of "high cost of uploading all data to the chain" and "lack of evidence if data is not uploaded to the chain." BRIEF DESCRIPTION OF THE DRAWINGS

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

[0022] Figure 1 Schematic diagram of the process of the present invention;

[0023] Figure 2 Schematic diagram of the structure of the system of the present invention. DETAILED DESCRIPTION

[0024] The technical solutions of the present invention will be clearly and completely described below in conjunction with the embodiments. Obviously, the embodiments described are only a part of the embodiments of the present invention, not all of them. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of the present invention.

[0025] See also Figure 1 The first embodiment of the present invention provides a logistics traceability method based on blockchain technology, including:

[0026] S101: Collect logistics behavior event data, construct an event graph structure containing multiple behavior event nodes, and calculate the structural closure signature value for each behavior event node based on the event hash value of its corresponding event data, the structural dependency signature value of the predecessor behavior event node, and the topological position index in the event graph structure. The event data includes a timestamp field, an event type field, and a responsible entity field;

[0027] In implementation, the construction of an event graph structure comprising a plurality of behavior event nodes includes:

[0028] Group all logistics behavior event data according to the logistics tracking number field in the event data to obtain multiple event sets;

[0029] It should be noted that the "logistics tracking number field" is identification information used to uniquely identify a logistics task in the logistics system, such as the number of each package, order or waybill. This number is usually assigned by the logistics platform and is unique and stable, such as "SF1234567890" or "JD00213456". When the system receives a large amount of logistics behavior event data, it should group the data according to this field and divide all events with the same logistics tracking number into an "event set". Each event set represents multiple events generated by the logistics task at different time points and different operation links. The purpose of grouping is to organize events belonging to the same business process together for subsequent structural modeling and graph structure construction;

[0030] Performing standardized mapping on the timestamp field of each event data in each event set to generate a corresponding global integer time number, where the time number is unique across all event sets;

[0031] For example, in order to ensure that the time sequence of each event node in the graph structure is unified and computationally controllable, the system will standardize the event time in each event set. Specifically, the system will extract the timestamp field in each event data and sort it in chronological order in the entire event set. Then, based on the sorting result, each event will be assigned a unique and increasing integer number as the "global time number" of the event. For example, if the time of three events is 10:00 am, 2:00 pm, and 4:30 pm, they can be numbered 1, 2, and 3 respectively. The time numbers constructed in this way can be used for subsequent graph edge establishment, topological relationship calculation, and sequential dependency judgment to ensure the consistency and operability of time logic.

[0032] Based on the event type field, calling a preset event evolution template graph, wherein the template graph defines a directed connection relationship between event types;

[0033] It should be understood that the event evolution template graph is usually uploaded and registered in the system by business experts or system administrators based on real logistics process modeling; in order to ensure that the template graph is always consistent with the actual business process, the system supports dynamic synchronization of business rule update mechanisms through smart contracts: when the logistics process changes or new business processes are launched, the relevant template graph will register an updated version in the on-chain contract, and the system will automatically load the latest version of the template when the event graph is constructed, thereby achieving synchronous maintenance of the legitimacy of the graph structure and business consistency; the template graph clearly stipulates the acceptable evolution order of different types of events in the business process; for example, the event type "collection" can evolve into "sorting and warehousing", and "sorting and warehousing" can evolve into "outbound transportation"; each event type is represented as a node in the template graph, and the directed edges between different nodes represent legal event sequence relationships. The purpose of introducing this template graph is to provide business legitimacy constraints for graph structure construction to prevent the system from mistakenly connecting event types that do not conform to the actual process, such as prohibiting "signing for" from connecting to "collection" and other reverse paths;

[0034] In each event set, if the time numbers corresponding to any two event data satisfy an increasing relationship and their event types have a directed connection relationship in the event evolution template graph, a directed edge is established between the corresponding nodes;

[0035] For example, in an event set, if event A has a time number of 2 and a type of "collection"; event B has a time number of 3 and a type of "delivery", and "collection" to "delivery" is defined as a legal directed connection in the template graph, the system will establish a directed edge from A to B for these two nodes in the event graph structure. This edge indicates that event A precedes event B in both time and business evolution, reflecting the sequential dependency between the events. It is important to emphasize that when constructing this edge, the system must simultaneously meet two conditions: first, the event time numbers must meet the order of precedence, and second, there must be a preset legal connection path between the event types in the evolution template graph.

[0036] All event nodes and the directed edges between them are uniformly constructed into an event graph structure. The event graph structure is a directed graph structure. Each node in the graph structure represents a single behavior event, and each edge represents the type legitimacy connection relationship and time number sequence dependency between events;

[0037] It should be noted that after the system extracts nodes and edges, it will uniformly construct a complete event graph structure based on the multiple nodes generated by each event set and the directed connections between them. In this graph structure, each node represents a specific behavioral event, and each directed edge represents the dependency between two events in terms of time sequence and business evolution. The event graph structure uses a directed acyclic graph (DAG), which supports chain, parallel, fork, and confluence relationships between multiple nodes, and can accurately describe the entire process of a logistics task from start to end. In system implementation, this graph structure can support operations such as graph traversal, path finding, and topological sorting, providing basic support for subsequent signature calculation and traceability verification.

[0038] In implementation, the calculation structure closure signature value includes:

[0039] Extract the timestamp field, event type field, and responsible party field from the event data corresponding to the current behavior event node, concatenate them into a target field string in a preset order, and call the set hash function to perform a hash operation on the target field string to obtain the event hash value;

[0040] It should be understood that in order to ensure that each behavioral event node has unique identification in the system, the system will generate an event hash value based on the core fields of the node; the core fields include: the timestamp of the event, the event type, and the responsible party field; among them, the timestamp indicates the time when the event occurred, the event type indicates the operation category of the event in the logistics business, such as "outbound transportation", and the responsible party indicates the organization or person who executed the event, such as "JD Logistics Guangzhou Sorting Center"; these three fields will be spliced ​​into a unified data string in a fixed order as the complete data representation of the current event; the system will then call a cryptographic hash algorithm (such as SHA-256) to perform a digest calculation on the string to obtain a fixed-length event hash value; this hash value can uniquely represent the content of the event data and is the basis for generating the subsequent structure closure signature value;

[0041] Obtain the predecessor behavior event node of the current behavior event node in the event graph structure, extract the structure dependency signature value of each predecessor behavior event node, and construct a structure dependency signature value set;

[0042] It should be noted that in a graph structure, an event node may have one or more predecessor nodes, that is, there are one or more directed edges pointing to the node; in order to represent structural inheritance and dependency relationships, the system needs to read all incoming edges of the node from the graph structure and identify the source nodes of each edge, that is, all predecessor behavior event nodes; the system will then obtain the structural dependency signature values ​​calculated by these predecessor nodes in the previous stage, which is the structural representation result of the predecessor nodes themselves and their dependent paths; the structural dependency signature values ​​of all predecessor nodes will be collected into a set, providing a dependency basis for the generation of the structural closure signature value of the current node;

[0043] Specifically, obtaining the predecessor behavior event node of the current behavior event node in the event graph structure includes:

[0044] Identify the topological position index of the current behavior event node in the event graph structure, and query the incoming edge set of the node based on the event graph structure;

[0045] It should be noted that the so-called "topological position index" refers to the unique position number of the current behavior event node in the entire event graph structure, determined based on its time sequence and business evolution relationship. It is usually determined by processing all nodes in the event graph structure through a topological sorting algorithm (such as the Kahn algorithm). This index can reflect the relative order of the current node in the structural path, which is conducive to the stable identification of path dependencies and the elimination of loops.

[0046] It should be understood that after obtaining the topological position index, the system needs to locate all incoming edges of the current node as the "target node" based on the directed edge set of the event graph structure. The so-called "incoming edge set" refers to the set of all edges with the current node as the end point, indicating the predecessor connection that "points" to the current node in structure.

[0047] For example, if the current node is "Node 4 (In Transit)", its topological index is 4, and the following edge relationships exist: Edge 1: Node 2 (Picking Completed) → Node 4 (In Transit), Edge 2: Node 3 (Outbound) → Node 4 (In Transit); then the incoming edge set identified by the system should be Edge 1 and Edge 2, and the corresponding predecessor nodes are Node 2 and Node 3. This set constitutes the upstream event source that the current behavior event node depends on in the structure. It will be used to extract the structural signatures of these predecessor nodes and calculate the structural closure signature of the current node.

[0048] For each incoming edge in the incoming edge set, extract the topological position index of its source node, and locate the corresponding predecessor behavior event node in the event graph structure based on the topological position index;

[0049] It should be noted that in the event graph structure, each incoming edge is a directed connection from an upstream node (i.e., source node) to the current behavior event node (i.e., target node). By traversing the "incoming edge set" of the current node, the system can obtain the "source information" of these edges one by one;

[0050] It should be understood that each incoming edge contains structural information about its starting point (source node) and end point (destination node). Here, the system focuses on the "source node" because it is the direct predecessor event node of the current node;

[0051] For example, assume the current node is "In Transit", and its incoming edge set includes two edges: edge A: from "Picking Completed" → "In Transit", and edge B: from "Out of Warehouse" → "In Transit". Then for edge A, its source node is "Picking Completed"; for edge B, its source node is "Out of Warehouse".

[0052] Furthermore, the system extracts the topological position index of the "source node" from each incoming edge. This index is usually pre-assigned through topological sorting during graph initialization or structure construction, and is used to identify the sequential position of the node in the graph structure. The purpose of extracting the index is to enable the system to quickly and accurately locate the predecessor node in the graph structure without having to compare each event content one by one.

[0053] The example operation is as follows: the topological index extracted from edge A to the source node is index_2 (assuming that "picking completed" is the second node in the graph structure); the topological index extracted from edge B to the source node is index_3 ("out of warehouse" is the third node in the graph structure); then the system will directly locate the corresponding node object in the node index table of the graph structure based on this index value.

[0054] The located predecessor behavior event nodes are formed into a structured set, and are arranged in ascending order according to the topological position index to form a predecessor behavior event node set of the current behavior event node, which serves as the final output result of obtaining the predecessor behavior event node of the current behavior event node in the event graph structure;

[0055] Each structure-dependency signature value in the structure-dependency signature value set and its corresponding predecessor behavior event node topological position index are combined into a two-tuple set, and the two-tuple set is sorted in ascending order of the topological position index, and the structure-dependency signature value field is extracted from the sorting result to generate an ordered structure-dependency signature sequence;

[0056] For example, in actual processing, the system will combine the structural dependency signature value of each predecessor node with the topological position index of the node in the event graph structure to form a pairing element. For example, if two predecessor nodes are located at the 4th and 7th positions in the graph structure, respectively, their structural closure signature values ​​can be identified as "A" and "B", respectively, and the resulting sets are (4, A) and (7, B). Subsequently, the system will sort these pairing elements in ascending order of topological position index, extract the structural dependency signature values ​​from the sorted results, and splice them into an ordered signature sequence. The purpose of sorting and splicing is to eliminate the impact of different predecessor orders and ensure the stability and repeatability of signature generation.

[0057] The event hash value, the ordered structure dependency signature sequence, and the topological position index of the current behavior event node are sequentially concatenated to form an input string, and a set hash function is called to perform a hash operation on the input string to obtain a structure closure signature value;

[0058] It should be understood that the purpose of generating the structural closure signature value is to combine the ontological information of the current event node with its graph structure position and dependency path to generate a unique and structure-sensitive identifier. The system will splice three parts of information in sequence: one is the event hash value of the current event node, which is used to identify the data content of the node itself; the second is the sorted ordered structural dependency signature sequence, which is used to represent all the predecessor path information it depends on; the third is the topological position index of the node in the graph structure, which is used to reflect its structural position; after the three parts are spliced ​​together using a unified format, the system will call a hash algorithm to perform summary processing on them, and finally generate the structural closure signature value of the current node. This value can be used to represent the structural fingerprint of the node in the entire event graph, and will be used as a key field in data traceability and consistency verification later.

[0059] S102: Based on the event graph structure, all reachable paths involved in each behavior event node are counted, and the path information entropy value of each behavior event node is calculated. The transitive degree is constructed by combining the out-degree and in-degree of the behavior event node. The responsibility structure weight value is jointly calculated based on the path information entropy value and the transitive degree. Based on the size of the responsibility structure weight value, it is determined whether the original data of the behavior event node is written into the blockchain;

[0060] In implementation, the calculation of the path information entropy value of each behavior event node includes:

[0061] In the event graph structure, starting from the current behavior event node, traverse downward to generate a set of all directed reachable paths with the node as the source point. The reachable path set represents all behavior transfer paths that can be triggered by the node in the structure.

[0062] It's important to note that path information entropy measures the structural complexity and distribution balance of the paths connected by an event node. Before calculation, the system performs a series of depth-first or breadth-first graph traversals in the event graph, starting from the current action event node, to find all directed paths that originate from that node and do not repeatedly pass through the same node. This set of paths represents the entire chain of subsequent actions that a node may influence and serves as an important structural foundation for information dissemination or responsibility diffusion.

[0063] For each path in the reachable path set, a structural weight distribution is constructed based on the path length and path frequency, and a path probability distribution vector corresponding to the node is generated accordingly;

[0064] It should be noted that path length refers to the number of behavioral event nodes contained in a path, which is used to measure the "structural depth" or "extensibility of the information dissemination chain" of the path. For example, if a path is: Node A → Node B → Node C → Node D, then the path length is 4. Path frequency refers to the number of times the current path is observed or inferred in historical or simulated evolution data. For example, if the path "picking → outbound → transportation" in the system appears 27 times in historical business records, then its frequency is 27.

[0065] Generating the path probability distribution vector corresponding to the node includes:

[0066] Compute the standard probability distribution vector:

[0067] ;

[0068] Generate the path probability distribution vector of the current behavior event node:

[0069] ;

[0070] Where: , represents the structural weight, represents the path length of the i-th path, represents the path frequency of the i-th path, and is a correction factor greater than zero, determined based on experimental data, for example (set to =0.6, =0.4), is the number of reachable paths connected to the current behavior event node, that is, the total number of paths contained in its reachable path set;

[0071] Based on the path probability distribution vector, the set information entropy formula is called to perform logarithmic weighted summation on the distribution probability of each path to obtain the path information entropy value corresponding to the behavior event node;

[0072] Wherein, the information entropy formula is:

[0073] ;

[0074] Where: represents the logarithmic function, is the path information entropy value, is the total number of reachable paths;

[0075] It is understandable that the system records the above calculation results in the "Path Information Entropy" attribute field of the corresponding node in the event graph structure as a formal evaluation indicator of the node's structural complexity; this value will serve as a core reference in the subsequent calculation of the responsibility structure weight, reflecting the diversity of the behavior chain connected to the current node;

[0076] In implementation, the step of constructing the transitive degree by combining the out-degree and in-degree of the behavior event node includes:

[0077] In the event graph structure, starting from the current behavior event node, a set of all acyclic reachable paths from the current behavior event node is constructed. The acyclic reachable path set represents all downstream event paths that can be conducted by the current behavior event node through directed connections.

[0078] It should be noted that in order to measure the information transmission capability of a behavior event node in the graph structure, the system needs to identify the set of all paths in the event graph structure that start from this node and can extend backward to other nodes in the graph structure; these paths are used to describe the structural paths of "which downstream nodes can be propagated from this node";

[0079] It should be understood that a "loop-free reachable path" means that, starting from the current node, no path is allowed to pass through the same node repeatedly, that is, there is no possibility of returning to a node that has already been visited. Such a path is called a "simple path" or "non-looping path" in the graph structure. The purpose is to eliminate logical conflicts such as loops or self-connections in the path, thereby ensuring the clarity of the information transmission structure.

[0080] For example, assume the following graph structure exists: node A → node B → node C → node D; node B → node E, and node E → node C; then the acyclic paths starting from node A include: A → B → C → D, A → B → E → C → D, and A → B → E → C. However, the path A → B → C → B → E is not acyclic because node B is visited repeatedly, forming a loop.

[0081] Furthermore, the system records structural information for each path, including its node sequence, path length, and whether the path endpoint is a node with "zero out-degree." The collection of these acyclic paths serves as the basis for subsequent calculations of indicators such as "path termination rate," "propagation depth," and "structural diffusion capacity," enabling analysis of the current node's influence and structural diffusion value.

[0082] For each path in the set of acyclic reachable paths, extract the path length value as the number of behavior event nodes contained in the current path, and calculate the proportion of behavior event nodes with zero out-degree in the path, and the proportion is the termination rate value of the path;

[0083] It should be noted that in order to further analyze the structural stability and propagation boundary of the path connected to a certain node, the system will extract the structural features of all its acyclic reachable paths one by one; each path represents a downstream propagation chain that can be reached from the node;

[0084] It should be understood that the number of behavior event nodes contained in each path is called the "path length value." That is, if the node sequence of a path is: Node A → Node B → Node C → Node D, then the path length value is 4, indicating that this path contains a total of 4 behavior event nodes.

[0085] Furthermore, the system determines how many nodes in the path have "out-degree zero" in the current event graph. "Out-degree zero" means that the node has no edges pointing to subsequent nodes in the graph structure, meaning that the node is the end of the structure and cannot propagate or connect to the next event. This is commonly seen in logistics process end states such as "signed for", "order canceled", and "returned".

[0086] For example, if in the path A → B → C → D, node D has no successor nodes (i.e., its out-degree is zero), and the remaining nodes all have connections to other nodes, then there is one node with zero out-degree in the path, and the total number of nodes is 4. The "termination rate value" of the path is calculated as: R = number of nodes with zero out-degree in the path / total number of nodes in the path = 1 / 4 = 0.25;

[0087] It should be emphasized that the termination rate value R reflects the "closed degree" of the path in structure. The higher the value, the easier it is for the path to terminate and the more "shallow" the structure; the lower the value, the stronger the path's ductility and the more open the structure.

[0088] Based on the length and termination rate of all paths, the total path contraction amount is constructed, and combined with the in-degree value of the current behavior event node, it is substituted into the following function:

[0089] ;

[0090] in, is the length of the i-th path, is the termination rate value of the i-th path, is the in-degree value of the current behavior event node, is the transfer degree value of the current behavior event node;

[0091] Writing the transitive degree value of the current behavior event node into the attribute field set of the current behavior event node in the event graph structure as the final processing result of constructing the transitive degree by combining the out-degree and in-degree of the behavior event node;

[0092] It should be noted that the transitivity value is used to measure the "behavioral influence" of the current node in the graph structure. A larger value indicates more downstream structures it connects to and a longer path. The system writes this value into the "transitivity" attribute field of the corresponding node in the event graph structure, providing an input basis for the subsequent calculation of the responsibility weight value.

[0093] In implementation, the calculation of the responsibility structure weight value based on the path information entropy value and the transfer degree includes:

[0094] Extract the path information entropy value and transfer degree value of the current behavior event node. The path information entropy value represents the distribution complexity of the path set connected by the current behavior event node, and the transfer degree value represents the diffusion potential of the current behavior event node in the reachable path structure.

[0095] Construct a set of directed paths from all starting nodes to terminal nodes in the current event graph structure, identify all directed path subsets involved by the current behavior event node, and calculate the path length and termination rate of each path in turn;

[0096] It should be noted that in order to comprehensively analyze the structural position and path contribution of the current behavior event node in the entire event graph structure, the system needs to start from the perspective of the entire graph and first construct a set of all possible directed paths in the entire event graph. These paths must start from the "starting node" and eventually lead to the "end node";

[0097] It should be understood that the so-called "starting node" refers to a node with zero in-degree in the graph structure, that is, a behavioral event with no predecessor node, usually representing the starting event of a logistics process or information flow, such as "order creation" or "collection initiation". The "terminal node" refers to a node with zero in-degree, that is, a behavioral event with no subsequent connection, usually representing the termination event of the process, such as "sign-off completion", "transportation abnormality", "return processing", etc.

[0098] For example, the system will traverse the graph structure to find all complete directed paths starting from a node with zero in-degree and ending at a node with zero out-degree. These paths constitute the full path set of the entire graph, which is used to cover all behavior chains in the system.

[0099] Furthermore, the system needs to filter out all path subsets that contain the "current behavior event node" from the above full path set; that is, the system will identify whether the current node appears in a certain path. If so, the path will be included in the "current node participating path set";

[0100] It should be emphasized that for each path in the participating path set, the system will extract two structural indicators one by one: path length: that is, the number of behavioral event nodes contained in the path, which is used to measure the ductility of the transmission chain; path termination rate: that is, the proportion of nodes with zero out-degree in the path (for example, if a path in the structure contains 4 nodes and 2 of them have zero out-degree, the termination rate is 50%), which is used to measure whether the path tends to terminate;

[0101] For each path containing the current behavior event node, the structural interference factor is calculated according to the following function:

[0102] ;

[0103] Where: H is the path information entropy value, T is the transfer degree value, is the path length, is a positive constant representing a dither term to avoid division by zero errors, is the structural interference factor, which is used to characterize the attribution influence of the current behavioral event node on each path;

[0104] Accumulate the structural interference factors of the current behavior event node on all participating paths as the responsibility structure weight value of the current behavior event node, and write the responsibility structure weight value into the structure attribute field of the current behavior event node as the final processing result of the responsibility structure weight value calculated based on the path information entropy value and the transfer degree;

[0105] It should be noted that in the graph structure, a behavior event node may appear in multiple directed paths, which constitute the "behavior participation path set" of the node, that is, the total position of the node in the entire event evolution structure;

[0106] It should be understood that in order to measure the structural role of the node in each path, the present invention introduces a calculation method for the "structural interference factor". This factor reflects the importance of the current node to the path structure. Its calculation takes into account the node's own path information entropy, structural propagation degree, and path length.

[0107] For example, if a node appears in three paths, and the structural interference factors for each path are 、 、 , the system sums these factors: , where W is the “responsibility structure weight value” of the current behavior event node;

[0108] It is important to emphasize that this weight value is used to indicate the extent of the structural propagation responsibility that the node bears in the overall event graph structure. The larger the value, the higher the structural influence of the node in multiple paths and the more important it is as a key node in the event chain. This value will be used to determine whether to upload the original data corresponding to the node to the chain.

[0109] In implementation, determining whether the original data of the behavior event node is written into the blockchain includes:

[0110] After normalizing the responsibility structure weight value of the current behavior event node, compare it with the preset responsibility structure weight threshold value. If it is greater than or equal to the responsibility structure weight threshold value, it is determined to be a key structural node that needs to be on-chain; otherwise, it is determined to be a node retained off-chain;

[0111] Specifically, the normalized responsibility structure weight value is calculated by combining the responsibility structure weight values ​​of all behavior event nodes. The formula is:

[0112] ;

[0113] Where: is the mean of the responsibility structure weight values ​​of all behavior event nodes, is the standard deviation;

[0114] It should be understood that the system sets a predetermined weight threshold as a judgment standard; when the responsibility structure weight value of a node is greater than or equal to this threshold, it indicates that it has a strong structural influence in the graph structure and should be considered a "key node"; otherwise, it is an ordinary node. Only the original data of key nodes will be written into the blockchain to ensure the structural representativeness and storage efficiency of the on-chain data;

[0115] If it is determined to be a key structural node that needs to be on-chain, the original data of the behavior event node will be written to the blockchain; if it is determined to be an off-chain retained node, the original data will not be written, only its structural closure signature value information will be recorded and saved in the off-chain data system;

[0116] It is understood that when a node is determined to be a critical node, the system writes its original data to the blockchain system to ensure that the data is verifiable and cannot be tampered with. If the node is a non-critical node, it will not be written to the blockchain. Only its structure closure signature value and path information will be saved in the off-chain data system for subsequent auxiliary verification and to reduce on-chain data redundancy.

[0117] S103: Based on the structure closure signature value and the responsibility structure weight value, a verification path mapping graph is constructed, in which the structure closure signature value of each behavior event node is bound to the storage path of the off-chain data, and a structure mapping hash value is generated;

[0118] In implementation, the construction of the verification path map includes:

[0119] According to the direct predecessor signature value contained in the structure closure signature value, a directed connection edge is constructed between the nodes, and a structure closure signature value path subgraph is generated in the event graph. The subgraph is used to restore the path structure of the signature chain;

[0120] It should be noted that in order to implement structure verification and path restoration in an off-chain environment, the system needs to construct a verification graph structure with the "structure closure signature value" as the core. The construction basis of this graph is the "predecessor signature value" contained in the node structure closure signature value. These predecessor signature values ​​have been determined in the previous steps based on the event structure dependency and participated in the signature calculation.

[0121] It should be understood that each structural closure signature value not only represents the current node, but also explicitly or implicitly contains the signature information of all predecessor nodes through its construction process. Therefore, the system can re-establish a "structural restoration connection edge" between nodes based on the direct predecessor signature value contained in the current node, indicating their dependency order in the original graph structure.

[0122] For example, if the structure closure signature value of node A contains the signature values ​​of nodes B and C, the system will establish connections from B → A and C → A in the "verification path mapping graph" to form a "structure closure signature value path subgraph" for path restoration;

[0123] Based on the responsibility structure weight value, select the nodes that meet the set weight threshold as the main mapping node, bind the structure closure signature value of the main mapping node to its off-chain data storage path, and perform a joint hash operation on each binding pair to generate a structure mapping hash value;

[0124] It should be understood that in the complete event graph structure, only some nodes have a critical impact on the structure (i.e., the responsibility structure weight value is relatively high). Therefore, the system introduces a preset weight threshold to screen "structural key nodes", that is, those nodes that need to establish a strong binding relationship off-chain;

[0125] For example, if the responsibility structure weight value of a node is greater than or equal to a preset weight threshold, it is determined as a "primary mapping node"; the system binds the "structure closure signature value" of the node to its "original data storage path" in the off-chain system; the so-called storage path is usually a file system path or object storage address;

[0126] Specifically, generating a structure mapping hash value includes:

[0127] Extract the structure closure signature value, off-chain data storage path, and topological position index of the node in the event graph structure from the current binding pair. The structure closure signature value is the structure dependency identifier of the node, the off-chain data storage path is the file location information of the original data corresponding to the node, and the topological position index is the topological position index of the node in the event graph.

[0128] Concatenate the structure closure signature value, topological location index, and off-chain data storage path in order to construct a joint input string. The fields are concatenated with a fixed delimiter to form a hashable input sequence with consistent format.

[0129] It should be understood that to ensure the consistency and reproducibility of hash calculations, the system concatenates the above three fields in a fixed order, usually using "|" as a separator; for example: SigA123XYZ|Pos_07| / storage / ... / Sig_A123XYZ.json;

[0130] Calling a set one-way hash function to perform digest calculation on the combined input string, where the hash function is a standard cryptographic hash algorithm that meets collision resistance requirements; and using the resulting hash digest value as the structure mapping hash value;

[0131] It is understandable that the system can call a standard irreversible cryptographic hash algorithm (such as SHA-256) to perform a digest operation on the above concatenated string. The resulting hash digest value is the structure mapping hash value, which is used for subsequent data consistency verification. This hash value is tamper-resistant, and any change in any field (such as the signature value, location index, or path) will cause the entire hash value to change.

[0132] Write all main mapping nodes and their structure mapping hash values ​​that meet the weight requirements into the verification path mapping graph as node units, and record the connection relationships in their graph structure to complete the structural construction of the verification path mapping graph;

[0133] It should be noted that after the structure mapping hash value is generated, the system will write all "main mapping nodes" as graph nodes into the "verification path mapping graph". Each node contains its structure closure signature value, data storage path, topology index and mapping hash value;

[0134] At the same time, the system will retain the structural dependency connection edges between each node (derived from the predecessor signature relationship), thereby completing the construction of the entire verification graph structure; this graph can be used as a signature restoration structure, and can also be used to verify the consistency and completeness of the binding data of all nodes in the path when receiving traceability requests.

[0135] S104: When a traceability request is received, the verification path map is called to perform consistency verification on the original data and the structure mapping hash value of the target behavior event node to generate a traceability verification result;

[0136] In implementation, the execution consistency verification includes:

[0137] According to the target behavior event node identifier provided in the traceability request, the structure mapping hash value and off-chain data storage path corresponding to the node are extracted from the verification path map; if the original data of the node is not on-chain, the original data content of the node is read according to the off-chain data storage path;

[0138] It should be noted that in actual applications, users or regulators may initiate a traceability request to verify whether a logistics behavior event is authentic and reliable and whether the data has been tampered with. The request usually contains the identification information of the target behavior event node, such as the event ID, signature value, or business number.

[0139] It should be understood that the system first locates the node unit in the previously constructed verification path map based on the identifier and extracts the structure mapping hash value bound to the node and its off-chain storage path; the structure mapping hash value represents the encrypted fingerprint generated by the node when the map was initially constructed, and the off-chain path is the physical location of the node's original business data;

[0140] For example, if the target node is not written into the blockchain (i.e., a non-critical node), its original data will remain in the off-chain storage system; in this case, the system needs to read the complete original data content from the off-chain path for subsequent hash comparison operations;

[0141] The read original data content, the structure closure signature value of the node, and its topological position index in the event graph are concatenated in a preset order to construct a hash input string; the same one-way hash algorithm used to generate the structure mapping hash value is called to perform a digest operation on the hash input string to obtain the verification hash value of the current node;

[0142] For example, to ensure the accuracy of the consistency check, the system uses the same field concatenation order and hash algorithm as in step S103 to construct a verification string and generate a hash digest. The concatenated fields include: the structural closure signature value of the current node (indicating structural dependencies); the topological position index of the node in the event graph structure (indicating structural position); the original data content or data path read from the off-chain (indicating business content); the three fields are concatenated in a fixed format (such as "field 1 | field 2 | field 3") to form a hash input string. Subsequently, the system calls a set one-way hash function (such as SHA-256) to calculate the hash value of the string, which is the verification hash value of the current node. This value represents the digital signature of the current node's structure, position, and data content, and is the core indicator for determining whether it has been tampered with.

[0143] Compare the verification hash value of the current node with the structure mapping hash value recorded in the verification path mapping diagram one by one; if the two are consistent, it is recorded as "passed", otherwise it is recorded as "failed"; summarize the comparison results of all verification nodes to form a traceability verification result including the node number, verification status and failed node index;

[0144] It should be noted that after the calculation of the verification hash value is completed, the system compares the value with the structure mapping hash value previously stored in the verification path map one by one; if the two are completely consistent, it means that the node has not been tampered with in terms of structure, location and data content, and the verification status is marked as "passed"; if the hash values ​​are inconsistent, it indicates that there is a risk of tampering with the node, and the verification status is marked as "failed";

[0145] It should be understood that the system can continuously verify multiple nodes, for example, verify all main mapping nodes in a complete path node by node; the system will eventually output the verification results in the form of a structured report, which includes each node's: topological location index or node number; verification status (pass / fail); if failed, the failure reason or field difference prompt (such as inconsistent signature value, data content change, etc.); the verification result can be used for subsequent data credibility audits, abnormal alarms, compliance supervision, etc., to ensure the consistency of off-chain data and structure mapping.

[0146] See also Figure 2 Based on the same inventive concept, the second aspect of the present invention provides a logistics traceability system based on blockchain technology. For details not provided in this embodiment, please refer to the description of the relevant parts in Example 1. The system includes:

[0147] Acquisition module 201 is used to collect logistics behavior event data, construct an event graph structure containing multiple behavior event nodes, and calculate the structural closure signature value for each behavior event node based on the event hash value of its corresponding event data, the structural dependency signature value of the predecessor behavior event node, and the topological position index in the event graph structure. The event data includes a timestamp field, an event type field, and a responsible entity field;

[0148] Analysis module 202 is used to count all reachable paths involved in each behavior event node based on the event graph structure, calculate the path information entropy value of each behavior event node, construct the transitive degree based on the out-degree and in-degree of the behavior event node, calculate the responsibility structure weight value based on the path information entropy value and the transitive degree, and determine whether the original data of the behavior event node is written into the blockchain based on the size of the responsibility structure weight value;

[0149] An association module 203 is configured to construct a verification path map based on the structure closure signature value and the responsibility structure weight value, bind the structure closure signature value of each behavior event node to the storage path of the off-chain data in the verification path map, and generate a structure mapping hash value;

[0150] The traceability module 204 is used to call the verification path map when receiving a traceability request, perform consistency verification on the original data and structure mapping hash value of the target behavior event node, and generate a traceability verification result.

[0151] The above embodiments can be implemented in whole or in part via software, hardware, firmware, or any other combination. When implemented using software, the above embodiments can be implemented in whole or in part in the form of a computer program product. The computer program product comprises one or more computer instructions or computer programs. When loaded or executed on a computer, the processes or functions described in accordance with the embodiments of the present invention are fully or partially performed. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transferred from one computer-readable storage medium to another. For example, the computer instructions can be transferred from one website, computer, server, or data center to another website, computer, server, or data center via a wired or wireless network. The computer-readable storage medium can be any available medium accessible by a computer, or a data storage device such as a server or data center that contains a collection of one or more available media. The available medium can be magnetic media (e.g., floppy disks, hard disks, or magnetic tapes), optical media (e.g., DVDs), or semiconductor media. The semiconductor media can be a solid-state drive.

[0152] In the several embodiments provided by the present invention, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of the units is only one type. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0153] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.

[0154] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.

[0155] Some of the data in the above formula are calculated by removing the dimensions and taking their numerical values. The formula is a formula that is closest to the actual situation obtained by software simulation of a large amount of collected data; the preset parameters and preset thresholds in the formula are set by technical personnel in this field according to actual conditions or obtained through simulation of a large amount of data.

[0156] The above embodiments are only used to illustrate the technical method of the present invention and are not intended to limit the present invention. Although the present invention has been described in detail with reference to the preferred embodiments, those skilled in the art should understand that the technical method of the present invention may be modified or replaced by equivalents without departing from the spirit and scope of the technical method of the present invention.

Claims

1. A logistics traceability method based on blockchain technology, characterized in that: include: Collect logistics behavior event data, build an event graph structure containing multiple behavior event nodes, and calculate the structural closure signature value for each behavior event node based on the event hash value of its corresponding event data, the structural dependency signature value of the predecessor behavior event node, and the topological position index in the event graph structure. The event data includes a timestamp field, an event type field, and a responsible entity field. Based on the event graph structure, all reachable paths involved in each behavior event node are counted, and the path information entropy value of each behavior event node is calculated. The transitive degree is constructed by combining the out-degree and in-degree of the behavior event node. The responsibility structure weight value is jointly calculated based on the path information entropy value and the transitive degree. Based on the size of the responsibility structure weight value, it is determined whether the original data of the behavior event node is written into the blockchain; Based on the structure closure signature value and the responsibility structure weight value, a verification path mapping graph is constructed, in which the structure closure signature value of each behavior event node is bound to the storage path of the off-chain data, and a structure mapping hash value is generated; When a traceability request is received, the verification path map is called to perform consistency verification on the original data and structure mapping hash value of the target behavior event node to generate a traceability verification result.

2. A logistics traceability method based on blockchain technology according to claim 1, characterized in that: The calculation structure closure signature value includes: Extract the timestamp field, event type field, and responsible party field from the event data corresponding to the current behavior event node, concatenate them into a target field string in a preset order, and call the set hash function to perform a hash operation on the target field string to obtain the event hash value; Obtain the predecessor behavior event node of the current behavior event node in the event graph structure, extract the structure dependency signature value of each predecessor behavior event node, and construct a structure dependency signature value set; Each structure-dependency signature value in the structure-dependency signature value set and its corresponding predecessor behavior event node topological position index are combined into a two-tuple set, and the two-tuple set is sorted in ascending order of the topological position index, and the structure-dependency signature value field is extracted from the sorting result to generate an ordered structure-dependency signature sequence; The event hash value, the ordered structure dependency signature sequence and the topological position index of the current behavior event node are sequentially concatenated to form an input string, and a set hash function is called to perform a hash operation on the input string to obtain a structure closure signature value.

3. A logistics traceability method based on blockchain technology according to claim 2, characterized in that: The step of obtaining the predecessor behavior event node of the current behavior event node in the event graph structure includes: Identify the topological position index of the current behavior event node in the event graph structure, and query the incoming edge set of the node based on the event graph structure; For each incoming edge in the incoming edge set, extract the topological position index of its source node, and locate the corresponding predecessor behavior event node in the event graph structure based on the topological position index; The located predecessor behavior event nodes are organized into a structured set and arranged in ascending order according to the topological position index to form a predecessor behavior event node set of the current behavior event node, which serves as the final output result of obtaining the predecessor behavior event node of the current behavior event node in the event graph structure.

4. The logistics traceability method based on blockchain technology according to claim 3 is characterized in that: The calculation of the path information entropy value of each behavior event node includes: In the event graph structure, starting from the current behavior event node, traverse downward to generate a set of all directed reachable paths with the node as the source point. The reachable path set represents all behavior transfer paths that can be triggered by the node in the structure. For each path in the reachable path set, a structural weight distribution is constructed based on the path length and path frequency, and a path probability distribution vector corresponding to the node is generated accordingly; Generating the path probability distribution vector corresponding to the node includes: Compute the standard probability distribution vector: ; Generate the path probability distribution vector of the current behavior event node: ; Where: , represents the structural weight, represents the path length of the i-th path, represents the path frequency of the i-th path, and is a correction factor greater than zero, is the number of reachable paths connected to the current behavior event node; Based on the path probability distribution vector, the set information entropy formula is called to perform logarithmic weighted summation on the distribution probability of each path to obtain the path information entropy value corresponding to the behavior event node; Wherein, the information entropy formula is: ; Where: represents the logarithmic function with the natural logarithm base 10, is the path information entropy value, is the total number of reachable paths.

5. The logistics traceability method based on blockchain technology according to claim 4 is characterized in that: The step of constructing the transitive degree by combining the out-degree and in-degree of the behavior event node includes: In the event graph structure, starting from the current behavior event node, a set of all acyclic reachable paths from the current behavior event node is constructed. The acyclic reachable path set represents all downstream event paths that can be conducted by the current behavior event node through directed connections. For each path in the set of acyclic reachable paths, extract the path length value as the number of behavior event nodes contained in the current path, and calculate the proportion of behavior event nodes with zero out-degree in the path, and the proportion is the termination rate value of the path; Based on the length and termination rate of all paths, the total path contraction amount is constructed, and combined with the in-degree value of the current behavior event node, it is substituted into the following function: ; in, is the length of the i-th path, is the termination rate value of the i-th path, is the in-degree value of the current behavior event node, is the transfer degree value of the current behavior event node; The transfer degree value of the current behavior event node is written into the attribute field set of the current behavior event node in the event graph structure as the final processing result of constructing the transfer degree by combining the out-degree and in-degree of the behavior event node.

6. A logistics traceability method based on blockchain technology according to claim 5, characterized in that: The calculation of the responsibility structure weight value based on the path information entropy value and the transfer degree includes: Extract the path information entropy value and transfer degree value of the current behavior event node. The path information entropy value represents the distribution complexity of the path set connected by the current behavior event node, and the transfer degree value represents the diffusion potential of the current behavior event node in the reachable path structure. Construct a set of directed paths from all starting nodes to terminal nodes in the current event graph structure, identify all directed path subsets involved by the current behavior event node, and calculate the path length and termination rate of each path in turn; For each path containing the current behavior event node, the structural interference factor is calculated according to the following function: ; Where: H is the path information entropy value, T is the transfer degree value, is the path length, is a positive constant, is the structural interference factor; The structural interference factors of the current behavior event node on all participating paths are accumulated as the responsibility structure weight value of the current behavior event node, and the responsibility structure weight value is written into the structural attribute field of the current behavior event node as the final processing result of the responsibility structure weight value calculated based on the path information entropy value and the transfer degree.

7. A logistics traceability method based on blockchain technology according to claim 6, characterized in that: The construction verification path mapping diagram includes: According to the direct predecessor signature value contained in the structure closure signature value, a directed connection edge is constructed between the nodes, and a structure closure signature value path subgraph is generated in the event graph. The subgraph is used to restore the path structure of the signature chain; Based on the responsibility structure weight value, select the nodes that meet the set weight threshold as the main mapping node, bind the structure closure signature value of the main mapping node to its off-chain data storage path, and perform a joint hash operation on each binding pair to generate a structure mapping hash value; All main mapping nodes that meet the weight requirements and their structure mapping hash values ​​are written into the verification path mapping graph as node units, and the connection relationships in the graph are recorded to complete the structural construction of the verification path mapping graph.

8. The logistics traceability method based on blockchain technology according to claim 7 is characterized in that: Generating a structure mapping hash value includes: Extract the structure closure signature value, off-chain data storage path, and topological position index of the node in the event graph structure from the current binding pair. The structure closure signature value is the structure dependency identifier of the node, the off-chain data storage path is the file location information of the original data corresponding to the node, and the topological position index is the topological position index of the node in the event graph. Concatenate the structure closure signature value, topological location index, and off-chain data storage path in order to construct a joint input string. The fields are concatenated with a fixed delimiter to form a hashable input sequence with consistent format. A set one-way hash function is called to perform digest calculation on the combined input string, where the hash function is a standard cryptographic hash algorithm that meets collision resistance requirements; and the obtained hash digest value is used as the structure mapping hash value.

9. The logistics traceability method based on blockchain technology according to claim 8 is characterized in that: The execution consistency verification includes: According to the target behavior event node identifier provided in the traceability request, the structure mapping hash value and off-chain data storage path corresponding to the node are extracted from the verification path map; if the original data of the node is not on-chain, the original data content of the node is read according to the off-chain data storage path; The read original data content, the structure closure signature value of the node, and its topological position index in the event graph are concatenated in a preset order to construct a hash input string; the same one-way hash algorithm used to generate the structure mapping hash value is called to perform a digest operation on the hash input string to obtain the verification hash value of the current node; The verification hash value of the current node is compared one by one with the structure mapping hash value recorded in the verification path mapping diagram; if the two are consistent, it is recorded as "passed", otherwise it is recorded as "failed"; the comparison results of all verification nodes are summarized to form a traceability verification result including the node number, verification status and failed node index.

10. A logistics traceability system based on blockchain technology, implemented based on a logistics traceability method based on blockchain technology according to any one of claims 1 to 9, characterized in that: include: An acquisition module is used to collect logistics behavior event data, construct an event graph structure containing multiple behavior event nodes, and calculate the structural closure signature value for each behavior event node based on the event hash value of its corresponding event data, the structural dependency signature value of the predecessor behavior event node, and the topological position index in the event graph structure. The event data includes a timestamp field, an event type field, and a responsible entity field; An analysis module is used to count all reachable paths involved in each behavior event node based on the event graph structure, calculate the path information entropy value of each behavior event node, construct the transitive degree based on the out-degree and in-degree of the behavior event node, jointly calculate the responsibility structure weight value based on the path information entropy value and the transitive degree, and determine whether the original data of the behavior event node is written into the blockchain based on the size of the responsibility structure weight value; An association module is configured to construct a verification path mapping graph based on the structure closure signature value and the responsibility structure weight value, bind the structure closure signature value of each behavior event node to the storage path of the off-chain data in the verification path mapping graph, and generate a structure mapping hash value; The traceability module is used to call the verification path mapping diagram when receiving a traceability request, perform consistency verification on the original data and structure mapping hash value of the target behavior event node, and generate a traceability verification result.

Citation Information

Patent Citations

  • Cross-chain transaction verification and processing method, device and system

    CN116128511A

  • Distributed account book remote data synchronization method and system

    CN119449829A

  • Double-chain fusion product quality tracing method and system applied to production line

    CN120146871A

  • Block chain-based big data security data storage method

    CN120180505A

  • Secure backup and recovery method and system for medical data

    CN120256208A

Cited By

  • Smart tea garden block chain traceability system and method

    CN120746610A

  • Blockchain traceability system and method for smart tea garden

    CN120746610B

  • Encryption-driven financial data cross-chain interaction tamper-proof method, system and equipment

    CN121077820A

  • A tamper-proofing method, system and device for cross-chain interaction of encrypted financial data

    CN121077820B

  • Passport security verification method and system

    CN122020736A