A method for collaboration of upstream and downstream enterprise manufacturing services based on a layered blockchain
Through the layered blockchain structure and smart contract algorithm, the trust problem between upstream and downstream enterprises is solved, efficient and transparent manufacturing service collaboration is achieved, and collaborators are encouraged to abide by the rules and malicious behavior is punished.
Patent Information
- Application Number
- CN202211312756.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-10-25
- Publication Date
- 2025-10-24
- Estimated Expiration
- 2042-10-25
AI Technical Summary
Existing technologies make it difficult to establish trust relationships between upstream and downstream companies, resulting in inefficient manufacturing service collaboration. Traditional collaboration platforms also have trust issues and incentive mechanism defects, making it difficult to achieve efficient inter-enterprise collaboration.
It adopts a layered blockchain structure, including the upper chain ΒU and the lower chain ΒL, combined with the upper smart contract XU and the lower smart contract XL, and uses the optimal task matching algorithm and dual incentive algorithm based on quality of service (QoS) to establish a trust mechanism and motivate collaborators.
It improves the collaboration efficiency between upstream and downstream companies, ensures the transparency and security of the collaboration process, prevents malicious behavior, and achieves efficient manufacturing service collaboration.
Smart Images

Figure CN115641082B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the blockchain technology, and in particular to a method for manufacturing service cooperation between upstream and downstream enterprises based on a hierarchical blockchain. BACKGROUND
[0002] In recent years, the manufacturing needs of users are increasingly personalized and diversified, and a single enterprise often has difficulty completing large-scale or customized complex manufacturing tasks. Cooperation between upstream and downstream enterprises is an effective solution to the above problems. With the development of information and communication technology, cooperation solutions have evolved from face-to-face exchanges between known enterprises to the use of intermediary platforms or intermediaries, and finally to manufacturing service cooperation based on industrial internet platforms.
[0003] Manufacturing service cooperation refers to different participants in the industrial internet platform providing various manufacturing services and working together to produce, where the manufacturing services provided by the participants are available and cooperate in a complementary or compatible relationship. Manufacturing service cooperation is more economical and efficient than past face-to-face exchanges and intermediary cooperation, but the trust issues arising during the cooperation process have not been well addressed. Trust is the core driving force for cooperation. Due to the development of information technology, the scope of cooperation between upstream and downstream enterprises has greatly expanded, and cooperation partners are often strangers who meet for the first time, making it difficult to establish a trust relationship between strangers because there is no basis for trust between the two parties.
[0004] In manufacturing service cooperation, trust issues include the trust of participating users in other users participating in the cooperation and the trust in the cooperation platform. Extensive manufacturing service cooperation allows any social enterprise to participate in the cooperation process. Due to the large number of enterprises with varying qualifications, the quality of the products delivered cannot be guaranteed, which can result in significant costs for participating enterprises to seek redress, and participating enterprises can also engage in malicious behavior causing harm to cooperation partners. It is difficult to establish trust between users. Existing cooperation platforms are often centralized, with privileged administrators operating and managing platform affairs, which poses a risk of behind-closed-door operations and the leakage of trade secrets, which can harm the interests of participating enterprises. Trust between users and the platform is also difficult to establish. In addition, due to the irrationality of user decision-making and cooperation behavior, it is difficult to ensure the effectiveness of group cooperation behavior, and enterprise cooperation willingness is low, so it is necessary to effectively incentivize participating enterprises to encourage them to cooperate honestly. Some existing cooperation solutions do not incentivize participants, which makes participants lack motivation, and some incentive solutions have defects, which creates new problems.
[0005] Nowadays, the emergence of blockchain points out a new direction to solve the problems existing in manufacturing service collaboration. Blockchain is a new type of decentralized infrastructure and distributed computing paradigm, which uses chain data structure for verification and storage, and uses distributed consensus algorithm to generate and update data. As a decentralized structure, blockchain has great application prospects in helping collaboration platform solve the trust problem caused by centralized management. The distributed ledger data, consensus mechanism and encryption system of blockchain guarantee the transparency, tamper resistance and security of the collaboration process. The smart contract on the blockchain provides distributed communication between service providers and customers, and can reach consensus on collaboration without intermediaries. Due to the successful application of blockchain in the financial field in the past, researchers have focused on the innovative possibilities of blockchain in manufacturing and supply chain management.
[0006] In manufacturing service collaboration, one of the important tasks of customers is to choose manufacturing services with good quality and competitive price from a large number of service providers. On the one hand, customers cannot fully grasp all the information of the suppliers, and it is difficult to balance between quality and price in the selection of suppliers; on the other hand, in traditional centralized procurement, the dominant position of old suppliers makes it difficult for other suppliers to gain trust, because the products or services of micro, small or medium-sized enterprises are not well-known. The existing blockchain collaboration framework cannot completely solve the above-mentioned existing problems, so that manufacturing service collaboration is still difficult to be applied efficiently between upstream and downstream enterprises. SUMMARY
[0007] The purpose of the present application is to build trust relationships in the collaboration process between upstream and downstream enterprises, promote large-scale manufacturing service collaboration, and provide a manufacturing service collaboration method between upstream and downstream enterprises based on hierarchical blockchain.
[0008] The present application designs a structure and method of manufacturing service collaboration between upstream and downstream enterprises based on hierarchical blockchain, which is characterized by: the structure is a two-layer blockchain, including an upper layer chain B U and a lower layer chain B L ; the node types are divided into two types, including upper layer nodes N U and lower layer nodes N L ; there are two types of smart contracts, including upper layer smart contracts X U and lower layer smart contracts X L ; the method is two core algorithms, including an optimal task matching algorithm based on service quality (QoS) and a double incentive algorithm. The number of lower layer chains in the structure satisfies the condition {NumOf(B L )≥2|NimOf(B L )∈Z +}, the lower layer chain B L is a different upstream / downstream enterprise alliance, and the relationship between different alliances is independent; the upper layer chain BU It is a platform for upstream and downstream enterprises to collaborate on manufacturing services. In the structure, the number of upper chains in the structure satisfies the condition {NumOf(Β U )≡1}, and has the lower chain Β L Endorsed upstream and downstream companies can apply to join the upper chain U Perform manufacturing service collaboration; the lower node N L It is an enterprise endorsed by an upstream / downstream enterprise alliance and has the right to U Upward to upper-level smart contract X U Apply to become an upper-level node N U ; The upper node N U The identity of the lower node N L To the upper-level smart contract N U After applying, it has the upper chain Β U The right to publish and accept tasks; the underlying smart contract X L Manage lower-layer chain Β L , responsible for the new lower-level node N U Application and qualification certification, as well as the current lower-level node N U Identity management and endorsement; the optimal task matching algorithm based on quality of service (QoS) uses the service quality coefficient vector to match the best task undertaker; the dual incentive algorithm uses dual reputation values (reputation R and bonus B) to jointly reward or punish members; the specific manufacturing service collaboration method for upstream and downstream enterprises of the layered blockchain includes the following steps:
[0009] Step S1: Apply for upper-level node identity
[0010] Lower chain Legal lower-level nodes on Getting the underlying smart contract After the endorsement of the upper-level smart contract X U Apply to become an upper-level node, upper-level smart contract X U After receiving the application, if Have an effective Endorsement Successfully joined the upper chain Β U Conduct manufacturing service collaboration, which is in Β U Obtain upper-level node identity
[0011] Step S2: Release the manufacturing service collaboration task
[0012] After the asset mortgage is completed UPublish tasks to seek manufacturing service collaboration. The published task information includes the QoS parameter vector of the task publisher's product requirements. Preference vectors for different dimensions of service quality The latest time for task acceptance T udtk And the hash lock HLock used by the task undertaker to prove the completion of the collaborative task in the future;
[0013] Step S3: Undertake manufacturing service collaboration tasks
[0014] Upper-level node In Β U After observing the release of the collaborative task in step S2, the service quality parameter vector To X U Apply to undertake the collaborative task. The upper-level smart contract calculates the applicant's The applicant with the highest score after the deadline will be awarded the right to undertake the manufacturing service collaboration task;
[0015] Step S4: Task delivery and certification
[0016] Towards Delivering manufacturing service collaboration task results, According to the service quality agreed in advance when undertaking After the acceptance, if all parameters are correct, the hash lock key Key1 will be delivered to the contractor. Use Key1 to X U Prove the correct completion of the manufacturing service collaboration task, X U Updated according to the dual incentive algorithm The reputation is R1 and the bonus is B1.
[0017] Furthermore, the specific steps of applying for upper-layer node identity in step S1 are as follows:
[0018] S1.1. Lower-layer chain endorsement: Towards Send a message
[0019] Request identity endorsement, yes The signature of the message, RequestEndorsement indicates that the message is for requesting endorsement, and nonce is a one-time random number. After the legitimacy and timeliness of the identity, Towards Send a reply message yes Endorsement signature, ReturnEndorsement indicates that this information is a reply to the endorsement request message, T Eds is the timestamp of the message.
[0020] S1.2. Apply for upper-level node identity: To X U Send a message
[0021] ApplyForUpperNode indicates that this message is used to send an upper node to X U Apply for upper-level node identity to participate in collaboration, T Ap is the timestamp of this message. X U Verification Info ApUpNd middle and endorsement Info ReEds The accuracy, consistency and timeliness of Register to join Β U , in Β U The identity above is Regardless of whether the application is successful or unsuccessful, all information in the process is recorded in U superior.
[0022] Furthermore, the specific steps of issuing the manufacturing service collaboration task in step S2 are as follows:
[0023] S2.1. Asset Mortgage: In Β U Before posting a task, you need to mortgage your assets to a reputable financial institution and obtain an asset mortgage bill. The amount of the mortgage The reputation R1 is negatively correlated with The maximum price P for manufacturing services set max The size is positively correlated.
[0024] S2.2. Collaborative Task Release: First, generate a hash lock key Key1 and set the QoS parameter vector of the published task Preference vectors for different dimensions of service quality and task acceptance deadline Then send the above information to X U .X U verify Bills Whether the mortgage amount meets the requirements, if so, X U Set this task in B U Publicly released on.
[0025] Furthermore, the specific steps of asset mortgage in step S2.1 are:
[0026] (1) In Β U Before publishing the task, It is necessary to mortgage assets to banks, insurance companies, trusts and other financial institutions to obtain bills Among them, Sig fi is the signature of the financial institution, T bill is the timestamp of the ticket, Is a uniform resource locator that points to the financial institution on the Internet The bill issued, A rel is the mortgage amount, r rel is the task release mortgage ratio, which is represented by Β U Preset, R1 is credibility.
[0027] Furthermore, the specific steps of the collaborative task release in step S2.2 are:
[0028] (1) First, a hash lock key Key1 is generated and the hash lock HLock←Hash(Key1) is calculated, where the function Hash is a hash function pre-specified by the platform.
[0029] (2) Specify the minimum reputation R required to apply for this task low .
[0030] (3) Describe its task content in detail and specify the QoS parameter vector Preference vectors for different dimensions of service quality and the latest time T for task acceptance udtk . To X U send The PostTask field indicates that the message is used to publish a collaborative task. Tsk1 is the identifier of the manufacturing service collaborative task and T PT is the timestamp of the message.
[0031] Furthermore, the specific steps of undertaking the manufacturing service collaboration task in step S3 are as follows:
[0032] S3.1. Application for Task Acceptance: Applicant In Β U It was observed New manufacturing service collaboration tasks released, To X U Submit application parameter vector Come and compete with other applicants to take on the task.
[0033] S3.2. Determine the task undertaker: X U Calculate the score of each applicant according to the optimal task matching algorithm, the time exceeds T udtk Finally, the applicant with the highest score becomes the final winner and successfully takes over the U superior Published manufacturing service collaboration tasks.
[0034] Furthermore, the specific steps for applying for undertaking the task in step S3.1 are as follows:
[0035] (1) According to Β U Public and Set your own application parameter vector Each QoS parameter proposed Must be better than or equal to the QoS parameter QoS submitted by the task publisher i .
[0036] Furthermore, the specific steps for determining the task undertaker in step S3.2 are as follows:
[0037] (1) To X U Send a message The ApplyTask field indicates that this message is used to apply for undertaking the manufacturing service collaboration task. AT is the timestamp of the message.
[0038] (2) X U From Β U Read on The reputation R2, if R2 <R low , then X U make This application is invalid.
[0039] (3) X U examine Submitted If the specific QoS parameters in Then X U make This application is invalid.
[0040] (4) X U By formula Calculate The score Score2 is recorded in Β U in the block.
[0041] (5) Β U Other competitors apply to compete for Tsk1 and repeat steps (1) to (4).
[0042] (6) Wait until time T udtk End, Β U For task Tsk1, the applicant with the highest score becomes the final undertaker of the manufacturing service collaboration task and is recorded in Β U superior.
[0043] Furthermore, the specific steps for delivering and proving the task results in step S4 are as follows:
[0044] S4.1. Delivery and Certification: After completing the collaborative tasks specified in Tsk1 Deliverables, After acceptance Provide Key1, exist Specify QoS time parameters within Time forward Β U Demonstrate the completion of Tsk1.
[0045] S4.2. Credibility update: If To X within the specified time U supply The pre-set HLock key Key1 proves that it has completed Tsk1, X U Updated according to the dual incentive algorithm Double reputation value: reputation R2 and bonus B2.
[0046] Furthermore, the specific steps of delivery and certification in step S4.1 are:
[0047] (1) After completing the manufacturing service collaboration specified in Tsk1 Deliver collaborative results, according to Recorded in Β when winning the bid U on Vector acceptance of its results, for QoS parameters of completed collaboration results If the conditions are met Then the acceptance of Tsk1 is passed. Deliver the pre-set HLock key Key1 to
[0048] (2)、 to X U sending information The field ProveTask indicates that this information is used to prove the completion of the manufacturing service collaboration task, T PT is the timestamp of this message.
[0049] (3), X U The correctness of the provided hash lock key is verified by calculating H <- Hash (Key1) If the node is rewarded Otherwise, the node is punished for failing to comply with the platform rules to complete the manufacturing service collaboration
[0050] Further, the specific steps of updating the reputation value in step S4.2 are as follows:
[0051] (1)、 If the correct Key1 is successfully used to unlock the hash lock HLock before the reputation R2 and the bonus B2 of are increased, where r rep , r bon are the reputation incentive ratio and the bonus incentive ratio respectively, which are pre-set by the collaboration platform, is the price QoS parameter of the successful bid of the task taker, and e is the natural logarithm.
[0052] (2), if an incorrect Key1 is provided or the time exceeds the last time agreed upon in advance the reputation R2 of is reduced by the punishment formula in the double-incentive algorithm The punishment formula is compared with the incentive formula, and the reputation value of the node is quickly reduced after the evil act, which can effectively prevent the intentional evil act and continuous evil act of high reputation nodes.
[0053] Advantages: Compared with the prior art, the present application has the following advantages:
[0054] (1) The present application proposes a layered blockchain-based upstream and downstream enterprise manufacturing service collaboration structure. Under this structure, the trust relationship between upstream and downstream enterprises and the trust relationship between enterprises and the collaboration platform are established, which improves the collaboration efficiency and helps to promote the implementation of large-scale manufacturing service collaboration between upstream and downstream enterprises.
[0055] (2) The present invention is implemented using a consortium chain. On the collaboration platform, all participants are nodes with equal relationships, and all qualified enterprises are allowed to participate in the collaboration, avoiding the situation in which large enterprises dominate the collaboration in other collaboration schemes. The specific algorithms and codes are made public, and the application of smart contracts that do not require third-party participation and run automatically makes the collaborative task competition process open and transparent, avoiding the black-box operations of privileged persons, reducing the cost of operating the platform, and improving the efficiency of achieving collaboration. The key information in the collaboration process is recorded on the chain, which is transparent, cannot be forged, and cannot be tampered with. This information not only allows customers to select the most suitable supplier, but also can be traced back at any time in the future to resolve possible disputes. Finally, the embodiments of the present invention have excellent performance and meet the needs of upstream and downstream enterprises for manufacturing service collaboration.
[0056] (3) The present invention proposes a dual incentive mechanism that can effectively motivate participants who abide by the rules of collaboration in manufacturing service collaboration and punish malicious attackers. At the same time, it can minimize the losses caused by continuous attacks by malicious members. This mechanism is efficient and can also avoid the "Matthew effect" caused by traditional single reputation value schemes, where the strong become stronger and the weak become weaker. While protecting the security and efficiency of the collaborative platform incentive mechanism, it also solves the problem of participant enthusiasm during the collaborative process. BRIEF DESCRIPTION OF THE DRAWINGS
[0057] Figure 1 It is the overall system flow chart of the present invention.
[0058] Figure 2 It is a sequence diagram of application and release during the collaboration process.
[0059] Figure 3 It is a timing diagram of acceptance and delivery in the collaborative process.
[0060] Figure 4 This is a detailed configuration diagram of the blockchain in the embodiment.
[0061] Figure 5 This is a graph showing how the blockchain throughput changes with the number of connections per unit time in the embodiment.
[0062] Figure 6 This is a graph showing how blockchain transaction delay varies with the number of connections per unit time in the embodiment. DETAILED DESCRIPTION
[0063] The technical solution of the present invention is described in detail below, but the protection scope of the present invention is not limited to the embodiments.
[0064] Example 1: Figure 1 As shown, the present invention relates to a two-layer blockchain structure, including an upper chain B U and lower chain Β L; There are two types of nodes, including upper node N U and lower-level node N L There are two types of smart contracts, including upper-level smart contracts X U and the underlying smart contract X L ; The method is based on two core algorithms, including the optimal task matching algorithm based on quality of service (QoS) and the dual incentive algorithm. The number of lower-level chains in the structure satisfies the condition {NumOf(Β L )≥2|NumOf(Β L )∈Z +}, the lower chain B L It is a different upstream / downstream enterprise alliance, and the relationship between different alliances is independent; the upper chain B U It is a platform for upstream and downstream enterprises to collaborate on manufacturing services. In the structure, the number of upper chains in the structure satisfies the condition {NumOf(Β U )≡1}, and has the lower chain Β L Endorsed upstream and downstream companies can apply to join the upper chain U Perform manufacturing service collaboration; the lower node N L It is an enterprise endorsed by an upstream / downstream enterprise alliance and has the right to U Upward to upper-level smart contract X U Apply to become an upper-level node N U ; The upper node N U The identity of the lower node N L To the upper layer smart contract N U After applying, it has the upper chain Β U The right to publish and accept tasks; the underlying smart contract X L Manage lower-layer chain Β L , responsible for the new lower-level node N U Application and qualification certification, as well as the current lower-level node N U Identity management and endorsement; the optimal task matching algorithm based on quality of service (QoS) uses the service quality coefficient vector to match the best task undertaker; the dual incentive algorithm uses dual reputation values (reputation R and bonus B) to jointly reward or punish members;
[0065] The manufacturing service collaboration structure and method for upstream and downstream enterprises based on a layered blockchain in this embodiment specifically includes the following steps:
[0066] Step 1 (applying for upper-level node identity):
[0067] 1.1. Lower-layer chain endorsement
[0068] Towards Send a message Request identity endorsement, yes The signature of the message, RequestEndorsement indicates that the message is for requesting endorsement, and nonce is a one-time random number. After the legitimacy and timeliness of the identity, Towards Send a reply message
[0069] yes Endorsement signature, ReturnEndorsement indicates that this information is a reply to the endorsement request message, T Eds is the timestamp of the message.
[0070] 1.2. Apply for upper-level node identity
[0071] To X U Send a message
[0072] ApplyForUpperNode indicates that this message is used to send an upper node to X U Apply for upper-level node identity to participate in collaboration, T Ap is the timestamp of this message. X U Verification Info ApUpNd middle and endorsement Info ReEds The accuracy, consistency and timeliness of Register to join Β U , in Β U The identity above is Regardless of whether the application is successful or unsuccessful, all information in the process is recorded in U superior.
[0073] Stage 2 (releasing manufacturing service collaboration tasks):
[0074] 2.1. Asset Mortgage
[0075] In Β U Before publishing the task, It is necessary to mortgage assets to banks, insurance companies, trusts and other financial institutions to obtain bills Among them, Sig fi is the signature of the financial institution, T bill is the timestamp of the ticket, Is a uniform resource locator that points to the financial institution on the Internet The bill issued, A relis the mortgage amount, r rel is the task release mortgage ratio, which is represented by Β U Preset, R1 is credibility.
[0076] 2.2. Collaborative Task Release
[0077] First, generate a hash lock key Key1 and calculate the hash lock HLock←Hash(Key1), where the function Hash is the hash function pre-specified by the platform. Then Specify the minimum reputation R required to apply for this task low .at last Describe its task content in detail and specify the QoS parameter vector Preference vectors for different dimensions of service quality and the latest time T for task acceptance udtk . To X U send
[0078] The PostTask field indicates that the message is used to publish a collaborative task. Tsk1 is the identifier of the manufacturing service collaborative task and T PT is the timestamp of the message.
[0079] Stage 3 (undertaking manufacturing service collaboration tasks)
[0080] 3.1. Apply for Task Acceptance
[0081] According to Β U Public and Set your own application parameter vector
[0082] Each QoS parameter proposed Must be better than or equal to the QoS parameter QoS submitted by the task publisher i .
[0083] 3.2. Determine the task undertaker
[0084] To X U Send a message
[0085] The ApplyTask field indicates that this message is used to apply for undertaking the manufacturing service collaboration task. AT is the timestamp of the message. Then XU From Β U Read on The reputation R2, if R2 <R low , then X U make This application is invalid. Then X U By formula Calculate The score Scpre2 is recorded in Β U In the block. U Other competitors can also apply to compete for Tsk1, and repeat steps (1) to (4). Finally, wait until time T udtk End, Β U For task Tsk1, the applicant with the highest score becomes the final undertaker of the manufacturing service collaboration task and is recorded in Β U superior.
[0086] Stage 4 (Task Results Delivery and Certification)
[0087] 4.1. Delivery and Certification
[0088] After completing the manufacturing service collaboration specified in Tsk1 Deliver collaborative results, according to Recorded in Β when winning the bid U on Vector acceptance of its results, for QoS parameters of completed collaboration results If the conditions are met Then the acceptance of Tsk1 is passed. Deliver the pre-set HLock key Key1 to Then To X U Send a message The ProveTask field indicates that this information is used to prove the completion of the manufacturing service collaboration task. PT Is the timestamp of this message. Last X U Verify by calculating H←Hash(Key1) The correctness of the provided hash lock key, if H = HLock and Incentive Otherwise, those who fail to comply with the platform rules and complete the manufacturing service collaboration will be punished.
[0089] 4.2. Credit Value Update
[0090] In case the correct Key1 is used to successfully open the hash lock HLock, the reputation R2 and the bonus B2 of the task taker are increased by the reward formula and r , respectively, which are the reputation incentive ratio and the bonus incentive ratio, respectively, and are pre-set by the collaboration platform, e is the natural logarithm, rep ,r bon is the price QoS parameter of the bid of the task taker. If the incorrect Key1 is provided or the time exceeds the last time agreed upon in advance , the reputation R(new) and the bonus B(new) of the task taker are reduced by the punishment formula
[0091] The embodiment is based on the upstream and downstream enterprise manufacturing service collaboration structure and method based on the layered blockchain to build a prototype experimental system. A virtual machine with 16 virtual CPU cores, 24 GB of memory and 100 GB of storage space is configured on a personal computer using an Intel i9-10900 CPU, and the installed operating system is Ubuntu 20.04. The blockchain system is composed of 11 organizations, including one ordering node organization and 10 organizations participating in collaboration, and the specific configuration of the blockchain is shown in Figure 4 . The performance of the embodiment based on the application is tested, and the test indicators include system throughput and transaction latency. The detailed results of the performance test are shown in Figure 5 and Figure 6 . When the performance of the system is at the peak, the throughput is more than 340 tps and the latency is less than 3 milliseconds. Under other conditions, the system throughput reaches 210 tps or more, and the transaction delay is below 4 milliseconds.
[0092] As can be seen from the above embodiment, the application can effectively establish the trust relationship between the upstream and downstream enterprises and between the enterprises and the collaboration platform through a kind of upstream and downstream enterprise manufacturing service collaboration structure based on layered blockchain. Moreover, the application uses a double incentive mechanism to encourage participants who comply with the collaboration rules in the manufacturing service collaboration and punish malicious attackers. In addition, the application is implemented based on the alliance chain, which guarantees equal collaboration on the collaboration platform while recording the key information in the collaboration process on the chain, ensuring transparency, non-falsifiability and non-tamperability, and enabling tracing at any time in the future to solve possible disputes. The detailed processes of steps 3 and 4 are shown in Figure 3 . Finally, the prototype system implemented based on the application performs excellently in performance testing, meeting the needs of upstream and downstream enterprises for manufacturing service collaboration.
Claims
1. A method for up-and-down enterprise manufacturing service cooperation based on layered blockchains, characterized in that: The structure of the layered blockchain is a two-layer blockchain, including an upper layer chain B U and a lower layer chain B L ; the node types are divided into two types, including an upper layer node N U and a lower layer node N L ; there are two types of smart contracts, including an upper layer smart contract X U and a lower layer smart contract X L ; The service cooperation method includes an optimal task matching algorithm based on quality of service (QoS) and a double incentive algorithm, the number of lower chains in the structure satisfies the condition {NumOf(B L )≥2|NumOf(B L )∈Z +}, the lower chain B L is a different upstream / downstream enterprise alliance, the relationship between different alliances is independent; the upper chain B U is a platform for manufacturing service cooperation of upstream and downstream enterprises, the number of upper chains in the structure satisfies the condition {NumOf(B U )≡1}, and the upstream and downstream enterprises endorsed by the lower chain B L can apply to join the upper chain B U for manufacturing service cooperation; the lower node N L is an enterprise endorsed by a certain upstream / downstream enterprise alliance, which has the right to apply to become an upper node N U on the upper chain B U to the upper intelligent contract X U ; the identity of the upper node N U is obtained by applying to the upper intelligent contract N L after the lower node N U , which has the right to publish and accept tasks on the upper chain B U ; the lower intelligent contract X L manages the lower chain B L , is responsible for the application and qualification of new lower nodes N U , and the identity management and endorsement of the current lower node N U ; the optimal task matching algorithm based on quality of service QoS uses the quality of service coefficient vector to match the best task taker; the double incentive algorithm uses double reputation values to reward or punish members; the double reputation values are reputation R and bonus B, and the specific upstream and downstream enterprises of the layered block chain are given manufacturing service cooperation method including the following steps: Step S1, applying for an upper node identity, lower layer chain on the legitimate lower layer node after obtaining the endorsement of the lower layer smart contract to the upper layer smart contract X U apply to become an upper layer node, the upper layer smart contract X U after receiving the application, if has a valid endorsement, then successfully joins the upper layer chain B U carries out manufacturing service collaboration, which obtains the upper layer node identity on B U Step S2, publishing a manufacturing service cooperation task, After the assets are mortgaged, in B U A task is published to seek manufacturing service collaboration, and the published task information includes a QoS parameter vector of the product demand of the task publisher Preference vector for different dimensions of service quality Task acceptance deadline T udtk And a hash lock HLock for the task acceptor to prove the completion of the collaboration task in the future Step S3, undertaking the manufacturing service cooperation task, Upper-level node In Β U After observing the release of the collaborative task in step S2, the service quality parameter vector To X U Apply to undertake the collaborative task, the upper-level smart contract calculates the applicant's The applicant with the highest score after the deadline will be awarded the right to undertake the manufacturing service collaboration task; Step S4, task achievement delivery and proof, Towards Delivering manufacturing service collaboration task results, According to the service quality agreed in advance when undertaking After the acceptance, if all parameters are correct, the hash lock key Key1 will be delivered to the contractor. Use Key1 to X U Prove the correct completion of the manufacturing service collaboration task, X U Updated according to the dual incentive algorithm The reputation is R1 and the bonus is B1. 2.The method of upstream and downstream enterprise manufacturing service collaboration based on layered blockchain according to claim 1, characterized in that: The detailed process of applying for an upper node identity in step S1 is as follows: S1.1, lower layer chain endorsement: to send a message Request Endorsement, Eds T S1.
2. Apply for upper-level node identity: To X U Send a message ApplyForUpperNode indicates that this message is used to send an upper node to X U Apply for upper-level node identity to participate in collaboration, T Ap is the timestamp of this message, X U Verification Info ApUpNd middle and endorsement Info ReEds The accuracy, consistency and timeliness of Register to join Β U , in Β U The identity above is Regardless of whether the application is successful or unsuccessful, all information in the process is recorded in U superior. 3.The method of upstream and downstream enterprise manufacturing service collaboration based on layered blockchain according to claim 1, characterized in that: The specific steps of publishing a manufacturing service cooperation task in step S2 are as follows: S2.
1. Asset Mortgage: In Β U Before posting a task, you need to mortgage your assets to a reputable financial institution and obtain an asset mortgage bill. The amount of the mortgage The reputation R1 is negatively correlated with The maximum price P for manufacturing services set max The size is positively correlated. S2.
2. Collaborative Task Release: First, generate a hash lock key Key1 and set the QoS parameter vector of the published task Preference vectors for different dimensions of service quality and task acceptance deadline Then send the above information to X U , X U verify Bills Whether the mortgage amount meets the requirements, if so, X U Set this task in Β U Publicly released on. 4.The method of upstream and downstream enterprise manufacturing service collaboration based on layered blockchain according to claim 3, characterized in that: The detailed process of asset mortgage in step S2.1 is as follows: (1) In the above U publishing a task, need to bank, insurance companies, trust such financial institutions to obtain the bill where Sig fi is the signature of the financial institution, T bill is the timestamp of the bill, is a uniform resource locator, pointing to the Internet the financial institution for issued bills, A rel is the amount of mortgage, r rel is the task publishing mortgage ratio, by Β U pre-set, R1 is the reputation. 5.The method of upstream and downstream enterprise manufacturing service collaboration based on layered blockchain according to claim 3, characterized in that: The detailed process of cooperation task publishing in step S2.2 is as follows: (1), First, a hash lock Key1 is generated, and a hash lock HLock is calculated as HLock = Hash (Key1), where Hash is a hash function previously designated by the platform. (2), assigning the minimum reputation R for which the task is applied low , (3)、 Detailed description of the task content and designation of the QoS parameter vector Preference vector for different dimensions of quality of service And the task acceptance latest time T udtk , Send X U The PostTask field indicates that the sent message is for a collaborative task posting, Tskl is the identity of the manufacturing service collaborative task and T PT is the time stamp of the message. 6.The method of upstream and downstream enterprise manufacturing service collaboration based on layered blockchain according to claim 1, characterized in that: The specific steps of undertaking the manufacturing service cooperation task in step S3 are as follows: S3.1, Application takes the task: Applicant In B U The above observations A new manufacturing service collaboration task is published, To X U Submit the application parameter vector and other applicants to compete for the task; S3.2, Resolve task taker: X U According to the optimal task matching algorithm, the score of each applicant is calculated, and the time exceeds T udtk After that, the applicant with the highest score becomes the final winner, successfully taking over B U Up Published manufacturing service collaboration tasks. 7.The method of upstream and downstream enterprise manufacturing service collaboration based on layered blockchain according to claim 6, characterized in that: The detailed process of task applicant applying for undertaking the task in step S3.1 is as follows: (1), According to B U The above disclosed And Set their own application parameter vector Each Qos parameter proposed Must be better than or equal to the Qos parameter QoS submitted by the task publisher i . 8.The method of upstream and downstream enterprise manufacturing service collaboration based on layered blockchain according to claim 6, characterized in that: The detailed process of the upper smart contract deciding the task undertaker in step S3.2 is as follows: (1)、 To X U Send information ApplyTask field indicates that this message is used to apply to undertake a manufacturing service collaboration task, T AT is the timestamp of the message, (2), X U from B U read from the reputation R2, if R2 low , X U make this application invalid, (3), X U check submitted the specific QoS parameter in, if the condition is met then X U cause this application of to be invalidated, (4), X U By the formula The score Score2 is calculated and recorded in the block of B U , (5), B U other competitor applications compete for the Tskl, and steps (1) to (4) are repeated. (6) Wait until time T udtk Until, B U The applicant with the highest Score for task Tsk1 becomes the final taker of the manufacturing service collaboration task and is recorded in B U above. 9.The method of upstream and downstream enterprise manufacturing service collaboration based on layered blockchain according to claim 1, characterized in that: The specific steps of task achievement delivery and proof in step S4 are as follows: S4.
1. Delivery and Certification: After completing the collaborative tasks specified in Tsk1 Deliverables, After acceptance Provide Key1, exist Specify QoS time parameters within Time forward Β U Prove the completion of Tsk1, S4.2, Reputation value update: if X U provides the pre-set HLock key Key1 to prove that it has completed Tsk1, X U updates the double reputation values of : reputation R2 and bonus B2 according to the double incentive algorithm. 10.The method of upstream and downstream enterprise manufacturing service collaboration based on layered blockchain according to claim 9, characterized in that: The detailed process of delivery and proof in step S4.1 is as follows: (1), Upon completion of the manufacturing service collaboration specified in Tsk1, the collaboration results are delivered, according to the QoS parameters recorded in B U at the time of the bid, the vector accepts the results, for the QoS parameters of the completed collaboration results if the conditions are met then the acceptance of Tsk1 is passed, the pre-set HLock key Key1 is delivered to (2)、 To X U Send information The field ProveTask indicates that this information is used to prove the completion of a manufacturing service collaboration task, T PT is the timestamp of this message, (3), X U Verify by computing H←Hash(Key1) The correctness of the provided hash lock key, if H=HLock and then incentivize else penalize the party that failed to comply with the platform rules to complete the manufacturing service collaboration The detailed method of reputation value updating in step S4.2 is as follows: (1) exist If the correct Key1 is successfully used to unlock the hash lock HLock, the incentive formula in the double incentive algorithm is used. and Increase The reputation R2 and bonus B2, where r rep ,r bon They are the credit incentive ratio and the bonus incentive ratio, which are pre-set by the collaboration platform. is the price Qos parameter of the task undertaker’s winning bid, and e is the natural logarithm; (2) if Key1 is provided wrongly or the time exceeds the last time agreed upon then the reputation R2 of is reduced by the penalty formula in the double incentive algorithm.