Electronic contract processing methods, devices, electronic equipment and media

CN116109387BActive Publication Date: 2026-08-14BEIJING BAIDU NETCOM SCI & TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-03-23
Publication Date
2026-08-14

AI Technical Summary

Technical Problem

[0004]相关技术中,电子合同的生成订单操作的执行相互耦合,在电子合同的生成过程中,会对订单数据进行锁定处理,影响订单操作

Benefits of technology

[0022]根据本公开的技术,可以将订单操作与合同处理解耦,提升订单操作的可用性,提升用户体验。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116109387B_ABST
    Figure CN116109387B_ABST
Patent Text Reader

Abstract

This disclosure provides an electronic contract processing method, apparatus, electronic device, and medium, relating to the field of artificial intelligence technology, specifically cloud computing, and applicable to cloud transaction scenarios. The electronic contract processing method provided by this disclosure includes: obtaining a target order operation from candidate order operations stored in a message storage component, and determining the operation description information of the target order operation; determining the target order to which the target order operation acts based on the operation description information of the target order operation; determining the electronic contract associated with the target order as the target electronic contract; and editing the target electronic contract based on the operation description information of the target order operation. This disclosure decouples order operations from contract processing, improving the usability of order operations and enhancing user experience.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to the field of artificial intelligence technology, and more particularly to the field of cloud computing. Background Technology

[0002] With the continuous development of online business models, society is gradually entering the era of e-commerce. Electronic contracts, with their advantages of efficiency, security, environmental friendliness, and robust credit information mining, are gradually replacing traditional paper contracts and becoming the infrastructure of the market economy in the e-commerce era.

[0003] In the era of e-commerce, users can perform order operations such as order creation, order cancellation, order upgrades, order downgrades, order payments, and order refunds through order services, and generate corresponding electronic contracts based on the order operations initiated by users through contract services.

[0004] In related technologies, the generation of electronic contracts and the execution of order operations are coupled. During the generation of electronic contracts, order data is locked, which affects the order operation. Summary of the Invention

[0005] This disclosure provides an electronic contract processing method, apparatus, electronic device, and medium.

[0006] According to one aspect of this disclosure, an electronic contract processing method is provided, the method comprising:

[0007] Retrieve the target order operation from the candidate order operations stored in the message storage component, and determine the operation description information of the target order operation;

[0008] Based on the operation description information of the target order operation, determine the target order to which the target order operation is applied;

[0009] Identify the electronic contract associated with the target order as the target electronic contract;

[0010] Edit the target electronic contract based on the operation description information of the target order operation.

[0011] According to another aspect of this disclosure, an electronic contract processing apparatus is provided, the apparatus comprising:

[0012] The order operation acquisition module is used to retrieve the target order operation from the candidate order operations stored in the message storage component, and determine the operation description information of the target order operation;

[0013] The target order determination module is used to determine the target order to which the target order operation is applied based on the operation description information of the target order operation.

[0014] The electronic contract determination module is used to determine the electronic contract associated with the target order as the target electronic contract;

[0015] The electronic contract editing module is used to edit the target electronic contract based on the operation description information of the target order operation.

[0016] According to another aspect of this disclosure, an electronic device is provided, the electronic device comprising:

[0017] At least one processor; and

[0018] A memory communicatively connected to the at least one processor; wherein,

[0019] The memory stores instructions that can be executed by the at least one processor to enable the at least one processor to perform the electronic contract processing method according to any embodiment of this disclosure.

[0020] According to another aspect of this disclosure, a non-transitory computer-readable storage medium is provided storing computer instructions, wherein the computer instructions are used to cause a computer to perform the electronic contract processing method described in any embodiment of this disclosure.

[0021] According to another aspect of this disclosure, a computer program product is provided, including a computer program that, when executed by a processor, implements the electronic contract processing method described in any embodiment of this disclosure.

[0022] According to the technology disclosed herein, order operations can be decoupled from contract processing, thereby improving the usability of order operations and enhancing the user experience.

[0023] It should be understood that the description in this section is not intended to identify key or essential features of the embodiments of this disclosure, nor is it intended to limit the scope of this disclosure. Other features of this disclosure will become readily apparent from the following description. Attached Figure Description

[0024] The accompanying drawings are provided to better understand this solution and do not constitute a limitation of this disclosure. Wherein:

[0025] Figure 1 This is a flowchart of an electronic contract processing method provided according to an embodiment of the present disclosure;

[0026] Figure 2 This is a flowchart of another electronic contract processing method provided according to an embodiment of the present disclosure;

[0027] Figure 3 This is a flowchart of another electronic contract processing method provided according to an embodiment of the present disclosure;

[0028] Figure 4 This is a flowchart of another electronic contract processing method provided according to an embodiment of the present disclosure;

[0029] Figure 5 This is a schematic diagram of the structure of an electronic contract processing device according to an embodiment of the present disclosure;

[0030] Figure 6 This is a block diagram of an electronic device used to implement the electronic contract processing method of the embodiments of this disclosure. Detailed Implementation

[0031] The exemplary embodiments of this disclosure are described below with reference to the accompanying drawings, including various details of the embodiments to aid understanding, and should be considered merely exemplary. Therefore, those skilled in the art will recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope and spirit of this disclosure. Similarly, for clarity and brevity, descriptions of well-known functions and structures are omitted in the following description.

[0032] Figure 1 This is a flowchart illustrating an electronic contract processing method according to an embodiment of this disclosure. This embodiment is applicable to processing electronic contracts in a cloud transaction scenario. The method can be executed by an electronic contract processing device, which can be implemented in software and / or hardware and configured within a contract service. Figure 1 As shown, the electronic contract processing method in this embodiment may include:

[0033] S101, retrieve the target order operation from the candidate order operations stored in the message storage component, and determine the operation description information of the target order operation;

[0034] S102, determine the target order to which the target order operation is applied based on the operation description information of the target order operation;

[0035] S103, determine the electronic contract associated with the target order as the target electronic contract;

[0036] S104, Edit the target electronic contract according to the operation description information of the target order operation.

[0037] The message storage component refers to the message middleware used to store order operations. Optionally, the message storage component is a message queue. Candidate order operations are pre-stored in the message storage component through the order service. The contract service can retrieve order operations from the message storage component. The order service is used to process order operation requests. The contract service is used to process electronic contracts based on order operations.

[0038] The contract service retrieves the target order operation from the candidate order operations stored in the message storage component. For example, if the message storage component is a message queue, the contract service can use a subscription mechanism to subscribe to the candidate order operations pre-stored in the message queue by the order service.

[0039] The target order operation is generated from the candidate order operations. The candidate order operations obtained by the contract service are the target order operations. Optionally, the target order operation includes at least one of the following: order payment, order refund, order creation, order upgrade, order downgrade, and order cancellation.

[0040] Order operations are associated with operation description information. Given a specific target order operation, the associated operation description information can be determined. Optionally, the operation description information can be determined based on the order operation requirements. The operation description information describes the operation attributes of the order operation. Optionally, based on the operation description information, the operation object, operation type, and operation parameters of the order operation can be determined. Here, the operation object refers to the target object of the order operation; for example, the operation object can be an order identifier.

[0041] Based on the operation description information of the target order operation, determine the target order to which the target order operation applies. Specifically, based on the operation object in the operation description information, determine the operation object of the target order operation. The target order is the operation object of the target order operation, and the target order operation applies to the target order.

[0042] The target order may or may not have an associated e-contract. Whether a target order is associated with an e-contract depends on the specific circumstances and is not limited here. The target e-contract is pre-generated by the contract service based on the contract creation request for the target order. Optionally, the contract service can query the candidate e-contracts to find the target e-contract associated with the target order.

[0043] Edit the target electronic contract based on the operation description information of the target order.

[0044] Optionally, the target electronic contract can be edited based on the operation type in the operation description information, as well as the operation type and operation parameters.

[0045] This embodiment of the disclosure pre-stores order operations in a message storage component. A target order operation is retrieved from the candidate order operations stored in the message storage component via a contract service. Then, based on the operation description information associated with the target order operation, the target order to which the target order operation applies is determined. Next, based on the operation description information of the target order operation, the target electronic contract associated with the target order is edited. This embodiment of the disclosure uses a message storage component to process electronic contracts, decoupling order operations from contract processing. This eliminates the tightly coupled serial processing relationship between order operations and contract processing, effectively improving the usability of order operations and enhancing user experience. Furthermore, this embodiment of the disclosure supports editing the target electronic contract based on the operation description information of the target order operation, effectively improving the usability and flexibility of electronic contracts.

[0046] In an optional embodiment, the target order operation is stored in the message storage component in the following manner: the first thread of the order service responds to the target order operation obtained from the user and provides feedback on the response result; the second thread of the order service stores the target order operation in the message storage component; wherein the first thread and the second thread are asynchronous threads.

[0047] The system consists of two threads: a first thread for the order service to respond to order operations received from the user and provide feedback; and a second thread for the order service to store order operations in a message storage component so that the contract service can retrieve them. Both threads are asynchronous. The first thread directly handles the order operation response process; the second thread directly handles the order operation storage process.

[0048] It is known that storing order operations in the message storage component involves at least two processes: message body generation and message body sending. Regarding message body sending, if TCP is used, multiple TCP network connections are required. Considering both message body generation and sending times, the total time for order storage is at least tens of milliseconds. Storing order operations in the message storage component using a second thread, with a time consumption comparable to memory operations, can reduce the total time for order storage to a few milliseconds, significantly improving the order service's performance in processing order operations.

[0049] The target order operation is stored in the message storage component through the second thread of the order service. For example, the order service creates a second thread that is asynchronous with the first thread in the asynchronous thread pool. The second thread stores the order operation obtained from the user end into the message storage component.

[0050] The above technical solution, by setting up an asynchronous first thread and a second thread in the order service, with the first thread responding to order operations and the second thread storing order operations, achieves asynchronous completion of the order operation response and storage process. This provides technical support for decoupling order operations from contract processing, improves the order service's response speed and processing performance for order operations, ensures the availability of order operations, and enhances the user experience.

[0051] Figure 2 This is a flowchart of another electronic contract processing method provided according to an embodiment of the present disclosure; this embodiment is an optional solution proposed based on the above embodiments.

[0052] See Figure 2 The electronic contract processing method provided in this embodiment includes:

[0053] S201, retrieve the target order operation from the candidate order operations stored in the message storage component, and determine the operation description information of the target order operation.

[0054] S202, Based on the operation description information of the target order operation, determine the target order to which the target order operation is applied.

[0055] S203, determine the electronic contract associated with the target order as the target electronic contract.

[0056] S204, extract the target operation type of the target order operation from the operation description information of the target order operation.

[0057] The target operation type refers to the operation type to which the target order operation belongs. The operation type of the order operation is used to determine the editing rules of the electronic contract. Optionally, the operation types of the order operation include at least element replacement type and contract cancellation type.

[0058] S205, if the target operation type is feature replacement, the target feature to be replaced and the new parameter value of the target feature are also extracted from the operation description information.

[0059] Element-substitution order operations are used to replace contract elements in electronic contracts. Contract elements are the constituent units of an electronic contract. For example, contract elements include: order price, signing time, contract terms, and contract identifiers, etc.

[0060] Optionally, if the target order operation is an order upgrade or an order downgrade, the target operation type is determined to be an element replacement type.

[0061] Specifically, when the target operation type is element replacement, the target operation parameters of the target order operation can be extracted from the operation description information of the target order operation to obtain the target element to be replaced and the new parameter values ​​of the target element.

[0062] The operation parameters in the operation description information include parameter dimensions and parameter content. Based on the operation parameters in the operation description information, the target element to be replaced and the new parameter values ​​of the target element can be determined. The target element corresponds to the parameter dimension in the operation parameters, and the new parameter value of the target element corresponds to the parameter content in the operation parameters.

[0063] Among them, the target element to be replaced refers to the contract element in the electronic contract that needs to be replaced, and the new parameter value of the target element refers to the replacement content of the target element.

[0064] The target element to be replaced and its specific content are not limited here; they will be determined based on the actual situation. For example, the target element could be the order price.

[0065] S206, replace the original parameter values ​​of the target elements in the target electronic contract with the new parameter values ​​of the target elements.

[0066] The contract service uses new parameter values ​​for the target elements to replace the original parameter values ​​for the target elements in the target electronic contract.

[0067] This disclosed technical solution determines the editing rules of the electronic contract based on the target operation type of the target order operation. When the target operation type is element replacement, it extracts the target element to be replaced and its new parameter values ​​from the operation description information. The new parameter values ​​are then used to replace the original parameter values ​​of the target elements in the target electronic contract. This disclosed embodiment supports flexible adjustments to the electronic contract based on order operations, improving the usability and flexibility of the electronic contract.

[0068] In an optional embodiment, before replacing the original parameter value of the target element in the target electronic contract with the new parameter value of the target element, the method further includes: obtaining the element attribute of the target element from the target electronic contract; and determining whether the element attribute is replaceable.

[0069] It's understandable that not all elements of an electronic contract are replaceable; some elements are irreplaceable. For example, contract identifiers and signing dates generally cannot be changed, while order prices and contract terms can be altered through negotiation. Specifically, which elements of an electronic contract can be replaced depends on the specific circumstances.

[0070] Contract elements in an electronic contract are associated with element attributes. These attributes can be used to determine whether a contract element can be replaced. Optionally, the element attributes are determined during the electronic contract creation process based on the configuration information of the contract elements.

[0071] The above technical solution, before replacing the original parameter values ​​of the target elements in the target electronic contract, first determines whether the element attributes are replaceable based on the element attributes of the target elements, thus providing data support for replacing contract elements in the electronic contract.

[0072] In an optional embodiment, after extracting the target operation type of the target order operation from the operation description information of the target order operation, the method further includes: determining the order status of the target order based on the target operation type of the target order operation; determining the expected status of the target electronic contract based on the order status of the target order; and editing the target electronic contract if the actual status of the target electronic contract matches the expected status.

[0073] The contract status of the target electronic contract is related not only to its associated target order operation but also to the target contract operation. The target contract operation is obtained by the contract service from the user and is used to process the target electronic contract. Optionally, the target contract operation includes at least one of: applying for a target electronic contract, formalizing a target electronic contract, and canceling a target electronic contract. Optionally, the contract status includes one of: draft status, formalized status, or canceled status.

[0074] Before editing the target electronic contract, it is necessary to confirm whether the actual state of the target electronic contract is the desired state.

[0075] The desired status of the electronic contract is determined based on the order status of the target order.

[0076] The order status of a target order is determined based on the target operation type. The operation type includes element replacement or contract cancellation. Element replacement orders are listed as "Created, Pending Payment"; contract cancellation orders are listed as "Cancelled," "Paid," or "Refunded."

[0077] If an order is in the "Created but Unpaid" state, the expected state of the corresponding target electronic contract is "Draft"; if an order is in the "Cancelled," "Paid," or "Refunded" state, the expected state of the corresponding target electronic contract is "Draft" or "Formed".

[0078] Editing of a target electronic contract is only permitted if its actual state matches its desired state. For example, if the target operation type for a target order is element replacement, the order status is "created and awaiting payment," and the desired state of the target electronic contract is "draft," then editing is not possible if the actual state of the target electronic contract is "abandoned."

[0079] The above technical solution determines the order status of the target order based on the target operation type; determines the expected status of the target electronic contract based on the order status; and edits the target electronic contract when the actual status matches the expected status. This establishes the prerequisites for editing the electronic contract and improves the usability of the electronic contract processing method.

[0080] Figure 3 This is a flowchart of another electronic contract processing method provided according to an embodiment of the present disclosure; this embodiment is an optional solution proposed based on the above embodiments.

[0081] See Figure 3 The electronic contract processing method provided in this embodiment includes:

[0082] S301, retrieve the target order operation from the candidate order operations stored in the message storage component, and determine the operation description information of the target order operation.

[0083] S302, determine the target order to which the target order operation is applied based on the operation description information of the target order operation.

[0084] S303, determine the electronic contract associated with the target order as the target electronic contract.

[0085] S304, extract the target operation type of the target order operation from the operation description information of the target order operation.

[0086] S305, if the target operation type is contract cancellation type, determine the contract application batch of the target order.

[0087] When the target operation type is contract cancellation, the target electronic contract needs to be cancelled. In an optional embodiment, when the target order operation is order cancellation, order refund, or order payment, the target operation type is determined to be contract cancellation. Order cancellation, order refund, and order payment correspond to the end of the order lifecycle. The above technical solution provides a practical method for classifying order operation types, providing data support for determining the editing rules of the electronic contract based on the operation type of the target order operation.

[0088] Optionally, if the target order operation is an order payment, then determine whether the contract type of the target electronic contract is a payment request contract. If the target electronic contract is a payment request contract, then determine the target operation type as a contract cancellation type.

[0089] It is known that electronic contracts can be created by merging multiple orders. In other words, a target electronic contract can include other orders in addition to the target order.

[0090] Based on the contract application batch of the target order, other orders that were submitted for electronic contracts in the same batch as the target order can be identified.

[0091] S306, Based on the contract application batch of the target order and the order description information in the target electronic contract, determine the associated orders in the same batch as the target order.

[0092] The order description information is used to describe the order attributes of existing orders in the electronic contract. Optionally, the order description information may include the contract application batch or the order creation time, etc.

[0093] The contract application batch for each order in the target electronic contract can be determined based on the order description information.

[0094] The contract application batch of the target order is compared with the contract application batches of each order in the target electronic contract, and the existing orders in the same batch as the target order in the target electronic contract are identified as related orders of the target order.

[0095] S307, release the target order and the associated order, and cancel the target electronic contract.

[0096] Contract services release target and related orders and cancel target e-contracts, which can reduce unnecessary resource consumption.

[0097] In this embodiment, the editing rules of the electronic contract are determined based on the target operation type of the target order operation. If the target operation type is contract cancellation, the contract application batch of the target order is determined. Based on the contract application batch of the target order and the order description information in the target electronic contract, associated orders in the same batch as the target order are determined, the target order and the associated orders are released, and the target electronic contract is cancelled. This embodiment supports cancelling electronic contracts based on order operations, which can reduce unnecessary resource consumption, improve the resource utilization rate of contract services, and help improve the service performance of contract services.

[0098] Figure 4This is a flowchart of another electronic contract processing method provided according to an embodiment of this disclosure; this embodiment is an optional solution proposed based on the above embodiments. Specifically, the process of creating an electronic contract is detailed.

[0099] See Figure 4 The electronic contract processing method provided in this embodiment includes:

[0100] S401, based on the contract creation application for the target order, query the order description information of the target order from the first order record; wherein, the first order record is generated based on the order operations stored in the message storage component.

[0101] Specifically, the contract creation request for the target order is used to request the contract service to create a target electronic contract for the target order. The contract creation request is generated by the contract service based on the target contract operation initiated by the user. The target contract operation is used to process the target electronic contract.

[0102] For example, if the target contract operation initiated by the user is to apply for a target electronic contract, a contract creation application is generated.

[0103] The contract service retrieves the order description information of the target order from the first order record. The first order record is generated by the contract service based on order operations stored in the message storage component. The order description information is used to determine the contract text of the electronic contract.

[0104] S402, determine the contract text of the electronic contract based on the order description information of the target order.

[0105] The order description information of the target order forms the data basis for generating the contract text. The contract text of the electronic contract constitutes the main content of the electronic contract and serves as the data basis for its generation. The contract service generates the electronic contract text based on the obtained order description information of the target order. Optionally, the electronic contract text can be generated using iText technology. iText is a Java component for generating PDFs.

[0106] S403, Based on the configuration information of the contract elements, determine the element attributes of the contract elements in the electronic contract.

[0107] The configuration information for contract elements is predetermined based on actual business needs. This configuration information is used to determine the element attributes of the contract elements in the electronic contract. Optionally, the element attributes can be used to determine whether a contract element can be replaced.

[0108] Optionally, replaceable contract elements can be marked with a replaceable identifier in their element attributes.

[0109] S404, Generate the target electronic contract for the target order based on the contract text and the element attributes of the contract elements.

[0110] The contract service generates a target electronic contract for the target order based on the contract text and the attribute of the contract elements.

[0111] In this embodiment, based on a contract creation application for a target order, the order description information of the target order is queried from a first order record; the contract text of the electronic contract is determined based on the order description information; the element attributes of the contract elements in the electronic contract are determined based on the configuration information of the contract elements; and a target electronic contract is generated for the target order based on the contract text and the element attributes of the contract elements. This disclosure provides a practical method for creating electronic contracts. During the creation process, the element attributes of the contract elements in the electronic contract are determined based on the configuration information of the contract elements, providing technical support for flexibly adjusting the electronic contract according to order operations.

[0112] In an optional embodiment, the method further includes: obtaining a second order record; wherein the second order record is generated by the order service based on the order operation obtained from the user terminal; performing a consistency comparison between the first order record and the second order record; and if the first order record is inconsistent with the second order record, adjusting the first order record based on the second order record.

[0113] The first order record forms the data foundation for creating the electronic contract, and its accuracy directly impacts the accuracy of the electronic contract. To ensure the accuracy of the electronic contract, the first and second order records need to be compared. While the first and second order records share the same data source, theoretically they should be identical. However, the first and second order records are generated by different entities and have different direct sources.

[0114] Inconsistencies may arise between the first and second order records. The first order record undergoes multiple data processing stages, and an anomaly at any stage could result in missing data. Therefore, the second order record is considered more authoritative than the first. If a discrepancy occurs between the two records, the first order record will be adjusted based on the second record.

[0115] The above technical solution ensures the accuracy of the electronic contract by comparing the consistency of the first order record and the second order record, and adjusting the first order record based on the second order record when the two are inconsistent.

[0116] In an optional embodiment, when the target contract operation initiated by the user is to formalize a target electronic contract, the contract service generates a contract formalization application. The contract service updates the contract status of the target contract from draft to formalized, based on the specific requirements of the target contract. The contract service determines the contract type of the target contract through a rules engine. The rules engine is pre-configured with candidate approval processes. The contract type is used to determine the target approval process that matches the target contract. For example, the contract type includes one of the following: large-value contract, ordinary contract, payment request contract, and departmental joint contract. The target approval process includes at least the approval nodes and approval order of the target electronic contract. Based on the target approval process, the contract service distributes the target electronic contract to the corresponding approval nodes for approval and processes the target electronic contract accordingly based on the approval results from each approval node. For example, if the approval result is approved, the signature information of the corresponding approval node is updated in the target electronic contract, and the target electronic contract is distributed to the next approval node according to the approval process. Otherwise, the approval result of failure, along with the reason for failure, is fed back.

[0117] Figure 5 This is a schematic diagram of an electronic contract processing apparatus according to an embodiment of this disclosure. This disclosure is applicable to processing electronic contracts in cloud transaction scenarios. The apparatus can be implemented using software and / or hardware, and can implement the electronic contract processing method described in any embodiment of this disclosure.

[0118] like Figure 5 As shown, the electronic contract processing device 500 includes:

[0119] The order operation acquisition module 501 is used to acquire the target order operation from the candidate order operations stored in the message storage component, and determine the operation description information of the target order operation;

[0120] The target order determination module 502 is used to determine the target order to which the target order operation is applied based on the operation description information of the target order operation;

[0121] The electronic contract determination module 503 is used to determine the electronic contract associated with the target order as the target electronic contract;

[0122] The electronic contract editing module 504 is used to edit the target electronic contract according to the operation description information of the target order operation.

[0123] This embodiment of the disclosure pre-stores order operations in a message storage component. A target order operation is retrieved from the candidate order operations stored in the message storage component via a contract service. Then, based on the operation description information associated with the target order operation, the target order to which the target order operation applies is determined. Next, based on the operation description information of the target order operation, the target electronic contract associated with the target order is edited. This embodiment of the disclosure uses a message storage component to process electronic contracts, decoupling order operations from contract processing. This eliminates the tightly coupled serial processing relationship between order operations and contract processing, effectively improving the usability of order operations and enhancing user experience. Furthermore, this embodiment of the disclosure supports editing the target electronic contract based on the operation description information of the target order operation, effectively improving the usability and flexibility of electronic contracts.

[0124] Optionally, the electronic contract editing module includes: an operation type extraction submodule, used to extract the target operation type of the target order operation from the operation description information of the target order operation; a target element extraction submodule, used to extract the target element to be replaced and the new parameter value of the target element from the operation description information when the target operation type is an element replacement type; and an element parameter replacement submodule, used to replace the original parameter value of the target element in the target electronic contract with the new parameter value of the target element.

[0125] Optionally, the device further includes: an element attribute acquisition module, used to acquire the element attributes of the target element from the target electronic contract before replacing the original parameter value of the target element in the target electronic contract with the new parameter value of the target element; and an element attribute determination module, used to determine whether the element attribute is replaceable.

[0126] Optionally, the apparatus further includes: an application batch determination module, configured to extract the target operation type of the target order operation from the operation description information of the target order operation, and determine the contract application batch of the target order if the target operation type is a contract cancellation type; an associated order determination module, configured to determine associated orders in the same batch as the target order based on the contract application batch of the target order and the order description information in the target electronic contract; and an electronic contract cancellation module, configured to release the target order and the associated orders, and cancel the target electronic contract.

[0127] Optionally, if the target order operation is order cancellation, order refund, or order payment, the target operation type can be determined as contract cancellation.

[0128] Optionally, the apparatus further includes: an order status determination module, configured to extract the target operation type of the target order operation from the operation description information of the target order operation, and then determine the order status of the target order based on the target operation type; an expected status determination module, configured to determine the expected status of the target electronic contract based on the order status of the target order; and a contract status comparison module, configured to edit the target electronic contract if the actual status of the target electronic contract matches the expected status.

[0129] Optionally, the target order operation is stored in the message storage component in the following manner: the first thread of the order service responds to the target order operation obtained from the user and provides feedback on the response result; the second thread of the order service stores the target order operation in the message storage component; wherein, the first thread and the second thread are asynchronous threads.

[0130] Optionally, the device further includes: an order information query module, used to query the order description information of the target order from a first order record based on a contract creation application for the target order; wherein the first order record is generated based on order operations stored in a message storage component; a contract text determination module, used to determine the contract text of the electronic contract based on the order description information of the target order; an element attribute determination module, used to determine the element attributes of the contract elements in the electronic contract based on the configuration information of the contract elements; and an electronic contract determination module, used to generate the target electronic contract for the target order based on the contract text and the element attributes of the contract elements.

[0131] Optionally, the apparatus further includes: an order record acquisition module for acquiring a second order record; wherein the second order record is generated by the order service based on order operations obtained from the user terminal; an order record comparison module for performing a consistency comparison between the first order record and the second order record; and an order record adjustment module for adjusting the first order record based on the second order record if the first order record and the second order record are inconsistent.

[0132] Optionally, a consistency comparison can be performed between the second order record and the first order record at set time intervals. Of course, this can also be initiated at any time according to business needs. For example, if a second thread, asynchronous to the first thread, is created in the asynchronous thread pool through the order service, the order operations obtained from the user's end can be stored in the message storage component through the second thread. Anomaly monitoring can be performed on the asynchronous thread pool, and the consistency of the two order records can be checked if an anomaly is detected. An anomaly in the asynchronous thread may be caused by the asynchronous thread pool exceeding its maximum number of threads.

[0133] The electronic contract processing apparatus provided in this disclosure can execute the electronic contract processing method provided in any embodiment of this disclosure, and has the corresponding functional modules and beneficial effects for executing the electronic contract processing method.

[0134] The collection, storage, use, processing, transmission, provision, and disclosure of user information involved in the technical solution disclosed herein all comply with the provisions of relevant laws and regulations and do not violate public order and good morals.

[0135] According to embodiments of this disclosure, this disclosure also provides an electronic device, a readable storage medium, and a computer program product.

[0136] Figure 6 A schematic block diagram of an example electronic device 600 that can be used to implement embodiments of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the present disclosure described and / or claimed herein.

[0137] like Figure 6 As shown, the electronic device 600 includes a computing unit 601, which can perform various appropriate actions and processes based on a computer program stored in a read-only memory (ROM) 602 or a computer program loaded from a storage unit 608 into a random access memory (RAM) 603. The RAM 603 may also store various programs and data required for the operation of the electronic device 600. The computing unit 601, ROM 602, and RAM 603 are interconnected via a bus 604. An input / output (I / O) interface 605 is also connected to the bus 604.

[0138] Multiple components in electronic device 600 are connected to I / O interface 605, including: input unit 606, such as keyboard, mouse, etc.; output unit 607, such as various types of displays, speakers, etc.; storage unit 608, such as disk, optical disk, etc.; and communication unit 609, such as network card, modem, wireless transceiver, etc. Communication unit 609 allows electronic device 600 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.

[0139] The computing unit 601 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the computing unit 601 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 601 performs the various methods and processes described above, such as the electronic contract processing method. For example, in some embodiments, the electronic contract processing method may be implemented as a computer software program tangibly contained in a machine-readable medium, such as storage unit 608. In some embodiments, part or all of the computer program may be loaded and / or installed on the electronic device 600 via ROM 602 and / or communication unit 609. When the computer program is loaded into RAM 603 and executed by the computing unit 601, one or more steps of the electronic contract processing method described above may be performed. Alternatively, in other embodiments, the computing unit 601 may be configured to perform the electronic contract processing method by any other suitable means (e.g., by means of firmware).

[0140] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SoCs), payload-programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.

[0141] The program code used to implement the methods of this disclosure may be written in any combination of one or more programming languages. This program code may be provided to a processor or controller of a general-purpose computer, special-purpose computer, or other programmable electronic contract processing device, such that when executed by the processor or controller, the program code causes the functions / operations specified in the flowcharts and / or block diagrams to be implemented. The program code may be executed entirely on a machine, partially on a machine, as a standalone software package partially on a machine and partially on a remote machine, or entirely on a remote machine or server.

[0142] In the context of this disclosure, a machine-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can be, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.

[0143] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device for displaying information to the user (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor); and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the computer. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).

[0144] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as a data server), or computing systems that include middleware components (e.g., an application server), or computing systems that include frontend components (e.g., a user computer with a graphical user interface or web browser through which a user can interact with embodiments of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., a communication network). Examples of communication networks include local area networks (LANs), wide area networks (WANs), and the Internet.

[0145] Computer systems can include clients and servers. Clients and servers are generally located far apart and typically interact via communication networks. Client-server relationships are created by computer programs running on the respective computers and having a client-server relationship with each other. Servers can be cloud servers, servers in distributed systems, or servers incorporating blockchain technology.

[0146] Artificial intelligence (AI) is the study of enabling computers to simulate certain human thought processes and intelligent behaviors (such as learning, reasoning, thinking, and planning). It encompasses both hardware and software technologies. AI hardware technologies generally include sensors, dedicated AI chips, cloud computing, distributed storage, and big data processing. AI software technologies mainly include computer vision, speech recognition, natural language processing, machine learning / deep learning, big data processing, and knowledge graph technologies.

[0147] Cloud computing refers to a technology system that enables access to a shared pool of physical or virtual resources via a network. These resources can include servers, operating systems, networks, software, applications, and storage devices, and can be deployed and managed on demand and in a self-service manner. Cloud computing technology can provide efficient and powerful data processing capabilities for applications such as artificial intelligence and blockchain, as well as for model training.

[0148] It should be understood that the various forms of processes shown above can be used to rearrange, add, or delete steps. For example, the steps described in this disclosure can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution disclosed in this disclosure can be achieved, and this is not limited herein.

[0149] The specific embodiments described above do not constitute a limitation on the scope of protection of this disclosure. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this disclosure should be included within the scope of protection of this disclosure.

Claims

1. An electronic contract processing method, the method comprising: Retrieve the target order operation from the candidate order operations stored in the message storage component, and determine the operation description information of the target order operation; Based on the operation description information of the target order operation, determine the target order to which the target order operation is applied; Identify the electronic contract associated with the target order as the target electronic contract; Edit the target electronic contract based on the operation description information of the target order operation; The target order operation is stored in the message storage component in the following manner: the first thread of the order service responds to the target order operation obtained from the user and provides a response result; the second thread of the order service stores the target order operation in the message storage component; wherein the first thread and the second thread are asynchronous threads; the first thread directly serves the response process of the order operation; the second thread directly serves the storage process of the order operation. The method further includes: querying the order description information of the target order from a first order record based on the contract creation application for the target order; wherein the first order record is generated by the contract service based on order operations stored in the message storage component; determining the contract text of the electronic contract based on the order description information of the target order; determining the element attributes of the contract elements in the electronic contract based on the configuration information of the contract elements; and generating the target electronic contract for the target order based on the contract text and the element attributes of the contract elements. The method further includes: obtaining a second order record; wherein the second order record is generated by an order service based on order operations obtained from the user terminal; performing a consistency comparison between the first order record and the second order record; if the first order record and the second order record are inconsistent, adjusting the first order record based on the second order record; wherein the order service is used to process order operation requirements; and the contract service is used to process electronic contracts based on order operations.

2. The method according to claim 1, wherein, Based on the operation description information of the target order operation, the target electronic contract is edited, including: Extract the target operation type of the target order operation from the operation description information of the target order operation; When the target operation type is feature replacement, the target feature to be replaced and the new parameter values ​​of the target feature are also extracted from the operation description information. The original parameter values ​​of the target elements in the target electronic contract are replaced with the new parameter values ​​of the target elements.

3. The method according to claim 2, before replacing the original parameter value of the target element in the target electronic contract with the new parameter value of the target element, further includes: Obtain the element attributes of the target element from the target electronic contract; Determine whether the attribute of the feature is replaceable.

4. The method according to claim 2, after extracting the target operation type of the target order operation from the operation description information of the target order operation, the method further includes: If the target operation type is contract cancellation, determine the contract application batch for the target order; Based on the contract application batch of the target order and the order description information in the target electronic contract, identify the associated orders in the same batch as the target order; Release the target order and the associated order, and cancel the target electronic contract.

5. The method according to claim 4, wherein, If the target order operation is order cancellation, order refund, or order payment, the target operation type is determined to be contract cancellation.

6. The method according to claim 2, after extracting the target operation type of the target order operation from the operation description information of the target order operation, the method further includes: Determine the order status of the target order based on the target operation type of the target order operation; Based on the order status of the target order, determine the desired status of the target electronic contract; If the actual state of the target electronic contract matches the desired state, the target electronic contract is edited.

7. An electronic contract processing apparatus, the apparatus comprising: The order operation acquisition module is used to retrieve the target order operation from the candidate order operations stored in the message storage component, and determine the operation description information of the target order operation; The target order determination module is used to determine the target order to which the target order operation is applied based on the operation description information of the target order operation. The electronic contract determination module is used to determine the electronic contract associated with the target order as the target electronic contract; The electronic contract editing module is used to edit the target electronic contract based on the operation description information of the target order operation; The target order operation is stored in the message storage component in the following manner: the first thread of the order service responds to the target order operation obtained from the user and provides a response result; the second thread of the order service stores the target order operation in the message storage component; wherein the first thread and the second thread are asynchronous threads; the first thread directly serves the response process of the order operation; the second thread directly serves the storage process of the order operation. The device further includes: an order information query module, used to query the order description information of the target order from a first order record based on a contract creation application for the target order; wherein the first order record is generated by the contract service based on order operations stored in the message storage component; a contract text determination module, used to determine the contract text of the electronic contract based on the order description information of the target order; an element attribute determination module, used to determine the element attributes of the contract elements in the electronic contract based on the configuration information of the contract elements; and an electronic contract determination module, used to generate the target electronic contract for the target order based on the contract text and the element attributes of the contract elements. The device further includes: an order record acquisition module for acquiring a second order record; wherein the second order record is generated by an order service based on order operations obtained from a user terminal; an order record comparison module for performing a consistency comparison between the first order record and the second order record; and an order record adjustment module for adjusting the first order record based on the second order record if the first order record and the second order record are inconsistent; wherein the order service is used to process order operation requirements; and the contract service is used to process electronic contracts based on order operations.

8. The apparatus according to claim 7, wherein, The electronic contract editing module includes: The operation type extraction submodule is used to extract the target operation type of the target order operation from the operation description information of the target order operation; The target element extraction submodule is used to extract the target element to be replaced and the new parameter value of the target element from the operation description information when the target operation type is element replacement. The element parameter replacement submodule is used to replace the original parameter values ​​of the target element in the target electronic contract with the new parameter values ​​of the target element.

9. The apparatus according to claim 8, further comprising: The element attribute acquisition module is used to acquire the element attributes of the target element from the target electronic contract before replacing the original parameter value of the target element in the target electronic contract with the new parameter value of the target element. The feature attribute determination module is used to determine whether the feature attribute is replaceable.

10. The apparatus of claim 8, further comprising: The application batch determination module is used to extract the target operation type of the target order operation from the operation description information of the target order operation, and then determine the contract application batch of the target order if the target operation type is contract cancellation type. The associated order determination module is used to determine associated orders in the same batch as the target order based on the contract application batch of the target order and the order description information in the target electronic contract; The electronic contract cancellation module is used to release the target order and the associated order, and to cancel the target electronic contract.

11. The apparatus according to claim 10, wherein, If the target order operation is order cancellation, order refund, or order payment, the target operation type is determined to be contract cancellation.

12. The apparatus according to claim 8, further comprising: The order status determination module is used to extract the target operation type of the target order operation from the operation description information of the target order operation, and then determine the order status of the target order based on the target operation type of the target order operation. The expected state determination module is used to determine the expected state of the target electronic contract based on the order status of the target order. The contract status comparison module is used to edit the target electronic contract when the actual status of the target electronic contract matches the expected status.

13. An electronic device, comprising: At least one processor; as well as A memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor to enable the at least one processor to perform the electronic contract processing method according to any one of claims 1-6.

14. A non-transitory computer-readable storage medium storing computer instructions, wherein, The computer instructions are used to cause the computer to execute the electronic contract processing method according to any one of claims 1-6.

15. A computer program product comprising a computer program that, when executed by a processor, implements the electronic contract processing method according to any one of claims 1-6.

Citation Information

Patent Citations

  • Universal multi-source heterogeneous large-scale data synchronizing system

    CN107729366A

  • Production, supply and marketing linkage platform, method and system and computer storage medium

    CN111325600A