Data settlement method, data display method, device, and storage medium
By using streaming computing technology and carbon credit settlement methods, carbon labels and consumption data in transaction information are identified, which solves the problem of users' lack of understanding of carbon emission and absorption concepts, improves the efficiency of carbon credit settlement, promotes environmentally friendly behavior, reduces carbon emissions, and promotes sustainable development.
Patent Information
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- RAJAX NETWORK &TECHNOLOGY (SHANGHAI) CO LTD
- Filing Date
- 2025-08-26
- Publication Date
- 2026-07-23
Smart Images

Figure CN2025116902_23072026_PF_FP_ABST
Abstract
Description
Data settlement and display methods, equipment and storage media
[0001] This application claims priority to Chinese Patent Application No. 2025100646356, filed on January 15, 2025, entitled “Data Settlement and Display Method, Apparatus and Storage Medium”, the entire contents of which are incorporated herein by reference. Technical Field
[0002] This application relates to the field of data processing technology, and in particular to a data settlement and display method, device and storage medium. Background Technology
[0003] Today, "low carbon" has become a lifestyle. Raising awareness of energy conservation and emission reduction, and changing lifestyles or consumption habits, is of great significance for reducing global greenhouse gas emissions. Low-carbon living and energy conservation are conducive to slowing down the rate of global warming and environmental degradation.
[0004] Currently, consumers are gradually increasing their carbon emissions during travel, residence, and consumption. However, in daily life, people have very little understanding of the concepts of carbon emissions, carbon absorption, and carbon footprint. They talk a lot about low-carbon living and carbon reduction, but few actually take action. To achieve significant results in low-carbon living and carbon reduction and control the strengthening of the "greenhouse effect," the general public must take action. People's lack of understanding of the concepts of carbon emissions and carbon absorption has become an insurmountable barrier to achieving efficient carbon reduction and promoting carbon absorption. Breaking down this barrier is of paramount importance. Summary of the Invention
[0005] This application provides a data settlement and display method, device, and storage medium, which can avoid interference from other information unrelated to data settlement in the target transaction information, reduce the complexity of data processing in the streaming computing process, improve the settlement efficiency of carbon credits corresponding to each user transaction, and enable users' different types of transaction behaviors to reflect their environmental impact in a timely and quantitative manner through changes in carbon credits. This helps to promote users' environmentally friendly behavior, reduce carbon emissions, and promote sustainable development.
[0006] Other features and advantages of this application will become apparent from the following detailed description, or may be learned in part from practice of this application.
[0007] In a first aspect, embodiments of this application provide a data settlement method, including:
[0008] Obtain target transaction information; the target transaction information includes at least one target transaction field carrying a target behavior tag; perform streaming calculation on the target transaction field based on the target behavior tag to obtain at least one target carbon tag corresponding to the target transaction information and target consumption data corresponding to the target carbon tag; determine the target carbon credit variable of the target user corresponding to the target transaction information based on the at least one target carbon tag and the target consumption data corresponding to the target carbon tag; settle the total carbon credits of the target carbon account corresponding to the target user based on the target carbon credit variable.
[0009] Secondly, embodiments of this application provide a data display method, which includes: receiving a target carbon credit query instruction input by a target user; sending the target carbon credit query instruction to a server, so that the server responds to the target carbon credit query instruction and queries for a target carbon credit settlement result; receiving the target carbon credit settlement result returned by the server; and displaying the target carbon credit settlement result on a target-related page corresponding to the target carbon account; wherein the target carbon credit settlement result is obtained based on the data settlement method provided by the first aspect or any possible implementation of the first aspect.
[0010] Thirdly, embodiments of this application provide a data settlement apparatus, which includes:
[0011] A first acquisition module is used to acquire target transaction information, including at least one target transaction field carrying a target behavior tag; a streaming calculation module is used to perform streaming calculation on the target transaction field according to the target behavior tag to obtain at least one target carbon tag corresponding to the target transaction information and target consumption data corresponding to the target carbon tag; a first determination module is used to determine the target carbon credit variable of the target user corresponding to the target transaction information according to the at least one target carbon tag and the target consumption data corresponding to the target carbon tag; a settlement module is used to settle the total carbon credits of the target carbon account corresponding to the target user according to the target carbon credit variable.
[0012] Fourthly, embodiments of this application provide a data display device, which includes:
[0013] The first receiving module is used to receive a target carbon credit query instruction input by the target user; the sending module is used to send the target carbon credit query instruction to the server, so that the server responds to the target carbon credit query instruction and obtains the target carbon credit settlement result; the second receiving module is used to receive the target carbon credit settlement result returned by the server; the display module is used to display the target carbon credit settlement result on the target-related page corresponding to the target carbon account; the target carbon credit settlement result is obtained based on the data settlement method provided by the first aspect or any possible implementation of the first aspect.
[0014] Fifthly, embodiments of this application provide an electronic device, including: a processor and a memory; the processor is connected to the memory; the memory is used to store executable program code; the processor runs a program corresponding to the executable program code by reading the executable program code stored in the memory, so as to execute the first aspect of the embodiments of this application or any possible implementation of the first aspect or the method provided in the second aspect.
[0015] Sixthly, embodiments of this application provide a computer storage medium storing a plurality of instructions, which are adapted to be loaded by a processor and executed by the method steps provided by the first aspect or any possible implementation of the first aspect or the second aspect or any possible implementation of the second aspect of this application.
[0016] In one or more embodiments of this application, on the one hand, streaming computing technology enables real-time carbon label identification and corresponding consumption data determination for large amounts of transaction information, providing a foundation for subsequent carbon credit settlement and improving the settlement efficiency of carbon credits for each user transaction; on the other hand, by filtering target transaction information, the streaming computing process focuses primarily on target transaction fields with specific behavioral labels (target behavioral labels), avoiding interference from other information unrelated to data settlement in the target transaction information, reducing the complexity of data processing during streaming computing, further improving the settlement efficiency of carbon credits, and helping to reflect the impact of user transaction behavior on carbon emissions in a timely manner; furthermore, based on at least one target carbon label corresponding to the target transaction information and its corresponding target consumption data, the change in target carbon credits generated by the target user's current transaction behavior is determined, and then the total carbon credits of the target carbon account are settled, enabling different types of user transaction behavior to reflect their environmental impact in a timely and quantitative manner through carbon credit changes, which helps to promote users' environmentally friendly behavior, reduce carbon emissions, and promote sustainable development. Attached Figure Description
[0017] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0018] Figure 1 is a schematic diagram of the architecture of a data settlement system provided in an exemplary embodiment of this application;
[0019] Figure 2 is a flowchart illustrating a data settlement method provided in an exemplary embodiment of this application;
[0020] Figure 3 is a schematic diagram of the implementation process of streaming computing provided by an exemplary embodiment of this application;
[0021] Figure 4 is a schematic diagram of a process for determining a carbon integral variable provided in an exemplary embodiment of this application;
[0022] Figure 5 is a flowchart illustrating another data settlement method provided in an exemplary embodiment of this application;
[0023] Figure 6 is a flowchart illustrating another data settlement method provided in an exemplary embodiment of this application;
[0024] Figure 7 is a flowchart illustrating a carbon credit ranking query method provided in an exemplary embodiment of this application;
[0025] Figure 8 is a flowchart illustrating another data settlement method provided in an exemplary embodiment of this application;
[0026] Figure 9 is a flowchart illustrating a data display method provided in an exemplary embodiment of this application;
[0027] Figure 10 is a schematic diagram of the structure of a data settlement device provided in an exemplary embodiment of this application;
[0028] Figure 11 is a schematic diagram of a data display device provided in an exemplary embodiment of this application;
[0029] Figure 12 is a schematic diagram of the structure of an electronic device provided in an exemplary embodiment of this application. Detailed Implementation
[0030] The technical solutions in the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings.
[0031] The terms "first," "second," "third," etc., used in this specification, claims, and the foregoing drawings are used to distinguish different objects, not to describe a specific order. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or apparatus that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units not listed, or may optionally include other steps or units inherent to such processes, methods, products, or apparatus.
[0032] Next, please refer to Figure 1, which is a schematic diagram of the architecture of a data settlement system provided in an exemplary embodiment of this application. As shown in Figure 1, the data settlement system may include: a terminal 110 and a server 120. Wherein:
[0033] Terminal 110 includes one or more user terminals. A corresponding user-version application can be installed on terminal 110. This application allows users to register and log in to their respective accounts. Users can conduct online transactions through the terminal 110 based on the aforementioned user-version application and send the corresponding target transaction information to server 120. It is understood that terminal 110 can be a mobile phone, tablet computer, desktop computer, laptop computer, notebook computer, ultra-mobile personal computer (UMPC), handheld computer, netbook, personal digital assistant (PDA), wearable electronic device, etc., and this embodiment does not limit the scope of the application.
[0034] Optionally, the terminal 110 can also receive a target carbon credit query instruction input by the target user and send the target carbon credit query instruction to the server 120, so that the server 120 responds to the target carbon credit query instruction, queries and obtains the target carbon credit settlement result, then receives the target carbon credit settlement result returned by the server 120, and displays the target carbon credit settlement result on the target-related page corresponding to the target carbon account.
[0035] Server 120 can be the server corresponding to the user-version application used by the user for online transactions in terminal 110, used to perform services such as carbon credit settlement for transactions generated by the user in the user-version application. Server 120 can be a hardware server, virtual server, cloud server, etc., and this application embodiment does not limit it.
[0036] Specifically, after obtaining target transaction information from the order database, including at least one target transaction field carrying a target behavior tag, server 120 first performs streaming calculation on the target transaction field based on the target behavior tag to obtain at least one target carbon tag corresponding to the target transaction information and target consumption data corresponding to the target carbon tag; then, it determines the target carbon credit variable of the target user corresponding to the target transaction information based on at least one target carbon tag and the target consumption data corresponding to the target carbon tag; finally, it settles the total carbon credits of the target carbon account corresponding to the target user based on the target carbon credit variable.
[0037] Optionally, after receiving the target carbon credit query instruction sent by the terminal 110, the server 120 may also respond to the target carbon credit query instruction, query the corresponding target carbon credit settlement result, and return the target carbon credit settlement result to the terminal 110.
[0038] The network can be a medium that provides a communication link between terminal 110 and server 120, or it can be the Internet, which includes network devices and transmission media, and is not limited thereto. The transmission media can be a wired link, such as, but not limited to, coaxial cable, fiber optic cable, and Digital Subscriber Line (DSL), or a wireless link, such as, but not limited to, Wireless Fidelity (WIFI), Bluetooth, and mobile device networks.
[0039] It is understood that the number of terminals 110 and servers 120 in the data settlement system shown in Figure 1 is only an example. In a specific implementation, the data settlement system can contain any number of terminals 110 and servers 120, and this application embodiment does not specifically limit this. For example, but not limited to, terminal 110 can be a user terminal cluster composed of multiple user terminals, and server 120 can be a server cluster composed of multiple servers.
[0040] The following section, referring to Figure 1, describes a data settlement method provided by an embodiment of this application. Specifically, please refer to Figure 2, which is a flowchart illustrating a data settlement method provided by an exemplary embodiment of this application. As shown in Figure 2, the data settlement method includes the following steps:
[0041] S201, Obtain target transaction information, which includes at least one target transaction field carrying a target behavior tag.
[0042] Specifically, after a target user completes an online transaction using the target application on a terminal, the terminal sends the corresponding target transaction information to the server. The server can receive the target transaction information sent by the terminal. This target transaction information refers to the transaction information generated by the target user's online transaction within the target application. The target transaction information includes at least one target transaction field carrying a target behavior tag, which identifies the attribute of the target transaction field corresponding to the target transaction behavior. The target transaction information may also include, but is not limited to, fields corresponding to information such as target transaction type, target user information, target transaction time, and target transaction identifier.
[0043] For example, when the target transaction field represents the target product information of the transaction, the above-mentioned target behavior label may, but is not limited to, identify the target product identifier or target product type corresponding to the target product information; optionally, when the target product of the target user's transaction is a low-carbon product, the above-mentioned target behavior label may also identify the carbon credits corresponding to the target product. That is, when the target user selects to trade a target product that is a low-carbon product in the target application, the terminal can directly mark the low-carbon credits that can be generated by purchasing the target product together with the attribute information such as the target product identifier or target product type on the target transaction field corresponding to the target product information recorded in the target transaction information, so that after the server obtains the target transaction information, it can efficiently and accurately perform carbon credit settlement based on the attribute information marked in the above-mentioned target behavior label.
[0044] When the target transaction field represents the target transaction voucher information corresponding to the target transaction behavior, the aforementioned target behavior label may, but is not limited to, identify the type of target transaction voucher, such as, but not limited to, online transaction vouchers (i.e., no paper transaction voucher required), simplified paper vouchers, and ordinary paper vouchers. Optionally, when the target user selects a low-carbon transaction voucher (e.g., online transaction voucher, simplified paper voucher, etc.) as the target transaction voucher, the aforementioned target behavior label may also indicate the number of carbon credits corresponding to the target transaction voucher. That is, when the target user selects to use a low-carbon transaction voucher in the target application, the terminal can directly mark the low-carbon credits that can be generated by the target transaction voucher used in this transaction, along with the target transaction voucher type and other attribute information, on the target transaction field corresponding to the target transaction voucher information recorded in the target transaction information. This allows the server to efficiently and accurately settle carbon credits based on the information marked in the aforementioned target behavior label after obtaining the target transaction information. It is understood that when the target transaction voucher is a low-carbon transaction voucher, different types of target transaction vouchers result in different carbon credits marked in the corresponding target behavior label. For example, but not limited to, the carbon credits corresponding to online transaction vouchers are greater than those corresponding to simplified paper vouchers.
[0045] Optionally, the order database is used to store online transaction information for all users in the target application. After receiving the target transaction information sent by the terminal, the server first stores it in the order database. A message broker may be configured between the server's order database and the data processing system, but is not limited to this. This message broker is an independent software or service used to transmit messages between different systems or applications, such as, but not limited to, Apache Kafka, RabbitMQ, and ActiveMQ. The server may, but is not limited to, use the message broker to listen for target change information in the order database at preset time intervals (e.g., but not limited to, 1 second, 1 minute, etc.), and then read the corresponding target transaction information from the order database based on the target change information. For example, but not limited to, first parsing the target change information to extract key target information (e.g., but not limited to, target transaction identifier, target transaction type, etc.), and then constructing and executing the corresponding target database query statement based on the parsed key target information to read the corresponding target transaction information from the order database. The aforementioned target change information includes data change information related to online transactions in the target application that occurs in the order database, such as, but not limited to, new order creation information and historical order cancellation information. In other words, when the data in the order database changes, the server can read the newly added target transaction information in the order database.
[0046] Next, please refer to Figure 2. As shown in Figure 2, after obtaining the target transaction information in step S201, which includes at least one target transaction field carrying a target behavior tag, the data settlement method further includes:
[0047] S202, perform streaming calculation on the target transaction field based on the target behavior label to obtain at least one target carbon label corresponding to the target transaction information and the target consumption data corresponding to the target carbon label.
[0048] Specifically, the aforementioned target carbon label is a label representing low-carbon behavior in the transaction, used to quantify the environmental impact of the transaction. The aforementioned target consumption data refers to consumption-related data associated with the target carbon label, such as, but not limited to, transaction volume, transaction amount, and transaction type.
[0049] Optionally, after obtaining the target transaction information, the server can directly utilize streaming processing technology to perform real-time or near-real-time analysis on the target transaction fields within the target transaction information. For example, but not limited to, classifying the target transaction fields based on the target behavior tags they carry, and applying a preset algorithm to calculate the carbon footprint (i.e., target carbon label) corresponding to each target transaction field. For example, but not limited to, classifying the target transaction fields based on the attribute information marked in the target behavior tags, determining whether the target transaction field meets the labeling conditions for a target carbon label based on whether the target behavior tag is marked with carbon credits, and if so, determining the type of target carbon label corresponding to the target transaction field based on its type. Simultaneously, target transaction fields corresponding to the same type of target carbon label in the target transaction information can be integrated to obtain the target consumption data corresponding to that target carbon label.
[0050] Optionally, as shown in Figure 3, the implementation process of S202 above, which involves performing streaming calculations on the target transaction field based on the target behavior label to obtain at least one target carbon label corresponding to the target transaction information and the target consumption data corresponding to the target carbon label, may include, but is not limited to:
[0051] S301, label the target transaction field according to the target behavior label and preset rules to obtain the target labeling result corresponding to the target transaction field.
[0052] Specifically, the target labeling result is the result obtained after labeling the target transaction field, used to indicate whether the target consumption data corresponding to the target transaction field belongs to low-carbon behavior data. After obtaining the target transaction information, the target transaction fields (such as transaction description, product name, etc.) in each target transaction record of the target transaction information can be labeled according to preset rules based on the target behavior label. The above target labeling result can be binary (for example, "yes" or "1" indicates low-carbon behavior, that is, marking the target carbon label, "no" or "0" indicates non-low-carbon behavior, that is, marking the target non-low-carbon label or not marking the low-carbon label), or it can be a more granular classification, such as different levels of low-carbon degree (for example, "0" indicates non-low-carbon behavior, "1" indicates first-level low-carbon behavior, "2" indicates second-level low-carbon behavior, etc.).
[0053] Optionally, the process of S301 above, which involves labeling the target transaction field according to the target behavior label and a preset rule to obtain the target labeling result corresponding to the target transaction field, may include, but is not limited to: first, performing behavior recognition on the target behavior label to obtain the target behavior type corresponding to the target transaction field. For example, but not limited to, identifying whether the information marked in the target behavior label belongs to the low-carbon behavior type according to low-carbon behavior recognition rules or by using a low-carbon behavior recognition model, to obtain the target behavior type corresponding to the target transaction field. The aforementioned low-carbon behavior recognition rules may include, but are not limited to, whether the target behavior label is marked with low-carbon points or preset keywords corresponding to low-carbon behavior. The aforementioned low-carbon behavior recognition model may be trained based on multiple behavior labels that are known to be low-carbon behavior types. When the target behavior type is a low-carbon behavior type, the corresponding target transaction field will be labeled with a target carbon tag. Different low-carbon behavior types correspond to different target transaction fields, resulting in different types of target carbon tags. For example, when the low-carbon behavior type is low-carbon delivery, the target carbon tag can be a low-carbon delivery tag; when the low-carbon behavior type is a low-carbon transaction voucher, the target carbon tag can be a low-carbon transaction voucher tag; when the low-carbon behavior type is a low-carbon commodity transaction, the target carbon tag can be a low-carbon commodity tag; and when the low-carbon behavior type is a low-carbon service tool transaction, the target carbon tag can be a low-carbon service tool tag, and so on. When the target behavior type is a non-low-carbon behavior type, the corresponding target transaction field will be labeled with a target non-carbon tag.
[0054] In this embodiment, the target transaction field is directly labeled according to the target behavior label and preset rules to obtain the target labeling result corresponding to the target transaction field. This not only avoids the interference of irrelevant information in the target transaction field on the identification of low-carbon behavior and improves data processing efficiency, but also reduces the cost of manual judgment through automated labeling, ensures the consistency of labeling results, and avoids errors caused by human factors.
[0055] S302, Based on the target labeling results, filter the target transaction fields in the target transaction information to obtain the target labeling results as the specified transaction fields for labeling the target carbon tags.
[0056] Specifically, based on the target labeling results obtained in S301, the specified transaction fields labeled with the target carbon tag can be selected, thereby simplifying the subsequent data processing process. Only transaction fields related to low-carbon behavior are considered, providing an accurate data foundation for subsequent carbon credit settlement and improving the accuracy and efficiency of carbon credit settlement.
[0057] S303, determine the target consumption data corresponding to each target carbon tag based on at least one specified transaction field corresponding to each target carbon tag in the target transaction information.
[0058] Specifically, all specified transaction fields belonging to the same target carbon label in the target transaction information can be aggregated to form a complete transaction dataset corresponding to the target carbon label. Then, the integrated transaction dataset can be analyzed to extract consumption data related to the low-carbon behavior corresponding to the target carbon label, such as, but not limited to, consumption amount, consumption quantity, and consumption type.
[0059] Next, please refer to Figure 2. As shown in Figure 2, after performing streaming calculations on the target transaction field based on the target behavior label in S202 to obtain at least one target carbon label corresponding to the target transaction information and the target consumption data corresponding to the target carbon label, the data settlement method further includes:
[0060] S203, determine the target carbon credit variable for the target user corresponding to the target transaction information based on at least one target carbon label and the target consumption data corresponding to the target carbon label.
[0061] Specifically, the aforementioned target carbon credit variable represents the carbon credit value that a target user can obtain based on their current target transaction behavior. The server can determine the target user's carbon credit variable based on at least one target carbon label corresponding to the target transaction information and its corresponding target consumption data, applying preset credit calculation rules. These preset credit calculation rules can, but are not limited to, assign different carbon credits to different target carbon labels based on factors such as the environmental friendliness of the transaction, transaction volume, and transaction type. Thus, through carbon credit variable calculation, the user's environmentally friendly consumption behavior can be quantified, incentivizing users to adopt more sustainable consumption patterns.
[0062] Optionally, the aforementioned target transaction information may also include, but is not limited to, the target transaction type; the process of determining the target carbon credit variable for the target user corresponding to the target transaction information based on at least one target carbon label and the target consumption data corresponding to the target carbon label in step S203 may include, but is not limited to, determining the target carbon credit variable for the target user corresponding to the target transaction information based on at least one target carbon label, the target consumption data corresponding to the target carbon label, and the target transaction type. For example, but not limited to, first determining the value corresponding to the target carbon credit variable based on at least one target carbon label and the target consumption data corresponding to each target carbon label, and then determining the positive or negative attribute of the target carbon credit variable based on the target transaction type. When the aforementioned target transaction type is an order type, the target carbon credit variable is a positive value; when the aforementioned target transaction type is a cancellation type, the aforementioned target carbon credit variable is a negative value.
[0063] Understandably, when the target transaction information is the transaction information generated when the target user cancels an order, the target carbon credit variable value to be deducted by the target user can be determined first based on the specific cancellation transaction situation, that is, at least one target carbon label corresponding to the cancellation and the target consumption data corresponding to each target carbon label. Alternatively, all carbon credits of the order corresponding to the cancellation can be deducted directly. This application embodiment does not limit this.
[0064] Optionally, the aforementioned target consumption data may include, but is not limited to, at least one designated transaction field corresponding to the target carbon label, wherein the designated transaction field includes low-carbon transaction information of a designated transaction type. The designated transaction type is a transaction type identified as a designated low-carbon behavior. As shown in Figure 4, the implementation process of S203 above, which determines the target carbon credit variable of the target user corresponding to the target transaction information based on at least one target carbon label and the target consumption data corresponding to the target carbon label, may include, but is not limited to:
[0065] S401, perform carbon credit assessment on low-carbon transaction information according to the specified transaction type to obtain the specified carbon credit corresponding to the specified transaction field.
[0066] Specifically, the corresponding carbon credit assessment rules can be determined first based on the specified transaction type, and then the low-carbon transaction information can be assessed for carbon credits according to the carbon credit assessment rules to obtain the specified carbon credits corresponding to the specified transaction fields.
[0067] Optionally, the process of evaluating the carbon credits of low-carbon transaction information according to the specified transaction type in S401 above to obtain the specified carbon credits corresponding to the specified transaction field may include, but is not limited to, evaluating the specified carbon credits corresponding to the specified transaction field based on the type and / or quantity of each low-carbon commodity in the low-carbon transaction information when the specified transaction type is a low-carbon commodity transaction type. The aforementioned low-carbon commodities may include, but are not limited to, small portions and pre-defined commodities for participating in low-carbon behaviors, such as, but not limited to, coffee and beef. Different types of low-carbon commodities may correspond to different carbon credits. The specified carbon credits may be, but are not limited to, the carbon credits of the type of low-carbon commodity in the specified transaction field, or the product of the carbon credits of the type of low-carbon commodity and the corresponding quantity; this embodiment does not limit this.
[0068] When the designated transaction type is a low-carbon service tool transaction, the designated carbon credits corresponding to the designated transaction field are assessed based on the type and / or quantity of low-carbon service tools in the low-carbon transaction information. These low-carbon service tools may include, but are not limited to, tableware and packaging bags that can participate in low-carbon activities. For example, when the low-carbon service tool in the low-carbon transaction information is low-carbon tableware, the designated carbon credits will differ depending on the type and / or quantity of low-carbon tableware. For example, but not limited to, the designated carbon credits corresponding to a quantity of 0 low-carbon tableware are higher than those corresponding to a quantity not equal to 0, and the designated carbon credits corresponding to low-carbon tableware with higher environmental protection levels are higher than those corresponding to low-carbon tableware with lower environmental protection levels.
[0069] When the specified transaction type is a low-carbon transaction certificate, the environmental friendliness of the low-carbon transaction information is determined based on the type of low-carbon transaction certificate in the low-carbon transaction information, and the specified carbon credits corresponding to the specified transaction field are evaluated based on the environmental friendliness. The aforementioned low-carbon transaction certificates may include, but are not limited to, online transaction certificates and simplified paper transaction certificates, etc., with the environmental friendliness of online transaction certificates being greater than that of simplified paper transaction certificates. The environmental friendliness of the aforementioned low-carbon transaction information may be obtained by evaluation according to preset environmental assessment rules or using an environmental assessment model, and the aforementioned environmental assessment model may be trained based on transaction certificate types with known environmental friendliness.
[0070] When the designated transaction type is low-carbon delivery transaction, the designated carbon credits corresponding to the designated transaction field are assessed based on the number of participants in the group purchase and / or the delivery distance in the low-carbon transaction information. The aforementioned low-carbon delivery transaction type is used to characterize transactions where the delivery method is group purchase delivery. Different numbers of participants in the group purchase and / or delivery distances in the aforementioned low-carbon transaction information result in different designated carbon credits.
[0071] S402, determine the target carbon credit sub-variable corresponding to the target carbon label based on the specified carbon credits of each specified transaction field corresponding to the target carbon label.
[0072] Specifically, the aforementioned target carbon integral sub-variable is used to characterize the low-carbon performance of target users in the low-carbon behaviors corresponding to the target carbon label (e.g., but not limited to the amount of carbon emissions that can be reduced). For each target carbon label, the specified carbon integrals of all specified transaction fields corresponding to it are summarized to obtain the total carbon integral corresponding to the target carbon label, i.e., the target carbon integral sub-variable. This enables quantitative analysis of low-carbon transaction behaviors under the target carbon label and helps to understand the preferences and contributions of target users in different low-carbon behaviors.
[0073] S403, determine the target carbon credit variable of the target user corresponding to the target transaction information based on the target carbon credit sub-variable corresponding to at least one target carbon label.
[0074] Specifically, the target carbon credit sub-variables corresponding to all target carbon labels for the target transaction information can be summed to obtain the target carbon credit variable for the target user corresponding to the target transaction information. This target carbon credit variable is used to measure the overall low-carbon performance of the target user in this target transaction, such as, but not limited to, the amount of carbon emissions the target user can reduce in this transaction.
[0075] Next, please refer to Figure 2. As shown in Figure 2, after determining the target carbon credit variable of the target user corresponding to the target transaction information based on at least one target carbon label and the target consumption data corresponding to the target carbon label in S203 above, the data settlement method further includes:
[0076] S204, calculate the total carbon credits for the target user's corresponding target carbon account based on the target carbon credit variable.
[0077] Specifically, the total carbon credits in the target user's target carbon account can be updated based on the target carbon credit variable. For example, the target carbon credit variable can be directly summed with the total carbon credits in the target user's corresponding target carbon account to obtain the settled total target carbon credits. The aforementioned target carbon account is a dedicated account for recording the carbon credits corresponding to the target user's online transaction behavior. The total carbon credits in the aforementioned target carbon account represent the total amount of carbon credits accumulated by the target user in their target carbon account.
[0078] In this embodiment, on the one hand, streaming computing technology enables real-time carbon label identification and corresponding consumption data determination for large amounts of transaction information, providing a foundation for subsequent carbon credit settlement and improving the settlement efficiency of carbon credits for each user transaction. On the other hand, by filtering target transaction information, the streaming computing process focuses primarily on target transaction fields with specific behavioral labels (target behavioral labels), avoiding interference from other information unrelated to data settlement in the target transaction information, reducing the complexity of data processing during streaming computing, further improving the settlement efficiency of carbon credits, and helping to reflect the impact of user transaction behavior on carbon emissions in a timely manner. Furthermore, based on at least one target carbon label corresponding to the target transaction information and its corresponding target consumption data, the change in target carbon credits generated by the target user's current transaction behavior is determined, and then the total carbon credits of the target carbon account are settled. This allows different types of user transaction behavior to reflect their environmental impact in a timely and quantitative manner through carbon credit changes, helping to promote users' environmentally friendly behavior, reduce carbon emissions, and promote sustainable development.
[0079] Next, please refer to Figure 5, which is a flowchart illustrating another data settlement method provided by an exemplary embodiment of this application. Specifically, as shown in Figure 5, the data settlement method includes the following steps:
[0080] S501, Obtain target transaction information.
[0081] Specifically, the aforementioned target transaction information may include, but is not limited to, the target transaction type and target transaction identifier. The process for obtaining the aforementioned target transaction information is the same as that described in S201 above, and will not be repeated here.
[0082] S502, when the target transaction type is a cancellation type, determine whether there is a data settlement record for the target order information corresponding to the target transaction information.
[0083] Specifically, when the target transaction type is a cancellation type, the corresponding target order information can be determined first based on the target transaction identifier in the target transaction information, and then the corresponding data settlement record can be queried in the carbon credit database based on the target order information.
[0084] S503, if there is a corresponding data settlement record for the target order information, the total carbon credits of the target carbon account will be reduced by the historical carbon credits variable of the target order information recorded in the data settlement record to obtain the total target carbon credits after settlement.
[0085] Specifically, if the target order information has a corresponding data settlement record, it means that the target order information in the case of order cancellation has already undergone carbon credit settlement. In this case, the total carbon credits of the target carbon account can be directly deducted from the historical carbon credit variables of the target order information recorded in the data settlement record to obtain the total target carbon credits after settlement. This eliminates the need to repeatedly calculate the carbon credit variables for the same order, thereby improving the efficiency of carbon credit settlement in the case of order cancellation.
[0086] S504 If the target order information does not have a corresponding data settlement record, the total carbon credits of the target carbon account shall remain unchanged.
[0087] Specifically, if there is no corresponding data settlement record for the target order information, it means that the target order information in the case of order cancellation has not yet settled carbon credits or has not engaged in any low-carbon behavior. In other words, the target order information has not caused a change in the total carbon credits of the target carbon account. Therefore, the total carbon credits of the target carbon account can continue to be kept unchanged, thereby avoiding repeated low-carbon behavior identification for the same order, avoiding waste of server computing resources, and improving the efficiency of carbon credit settlement in the case of order cancellation.
[0088] Next, please refer to Figure 6, which is a flowchart illustrating another data settlement method provided by an exemplary embodiment of this application. Specifically, as shown in Figure 6, the data settlement method includes the following steps:
[0089] S601 receives the target redemption instruction, which carries the target redemption type selected by the target user and the total amount of carbon credits to be redeemed under the target redemption type.
[0090] Specifically, when a target user wants to redeem carbon credits under their target carbon account, they can specify the desired redemption type (such as, but not limited to, service redemption, discount redemption, or merchandise redemption) and the total amount of carbon credits to be redeemed under that type by clicking a button, selecting a drop-down menu item, or entering specific information. The terminal can receive the target redemption instruction entered by the target user through the corresponding redemption interface and send it to the server.
[0091] S602, in response to the target redemption instruction, performs point redemption according to the target redemption type and the total carbon points redemption amount, and obtains the target total carbon points after redemption and the target benefits information corresponding to the target redemption type.
[0092] Specifically, after receiving the target redemption instruction from the terminal, the server can first verify whether the total carbon credits in the target user's target carbon account are sufficient to meet the redemption request. If the total carbon credits are insufficient (less than the total carbon credit redemption amount), the server can send a corresponding prompt to the terminal, reminding the target user to replenish credits or choose other redemption options. If the total carbon credits are sufficient (greater than or equal to the total carbon credit redemption amount), the server can directly redeem credits based on the target redemption type and the total carbon credit redemption amount, obtaining the target total carbon credits after redemption and the target benefits information corresponding to the target redemption type.
[0093] When the target redemption type is a service redemption type, the target benefits information includes the target service information provided to the target user after redemption. That is, when the target redemption type is a service redemption, the carbon credit balance (total carbon credits) in the target user's account can be updated according to the total carbon credit redemption amount selected by the target user, and corresponding service redemption vouchers or access permissions can be generated, such as membership services, specific function experience services, etc.
[0094] When the target redemption type is a discount redemption type, the target benefits information includes the target discount information issued to the target user's corresponding target account after redemption. That is, when the target redemption type is a discount redemption, the carbon credit balance (total carbon credits) in the target user's account can be updated according to the total carbon credit redemption amount selected by the target user, and corresponding coupons, discount codes or points return and other discount information can be added to the target user's account. These discount information can be used by the target user in future shopping or service consumption.
[0095] When the target redemption type is a product redemption type, the target rights information includes the target product information after redemption. That is, if the target user chooses to redeem a product, the server will reserve or mark the corresponding target product from the inventory, update the carbon credit balance in the target carbon account, prepare the delivery or collection process for the target product, and generate the corresponding target product information.
[0096] Next, please refer to Figure 7, which is a flowchart illustrating a carbon credit ranking query method provided in an exemplary embodiment of this application. Specifically, as shown in Figure 7, the carbon credit ranking query method includes the following steps:
[0097] S701, obtain carbon credit information for each of the carbon accounts of multiple users, as well as user information for each of the multiple users.
[0098] Specifically, carbon credit information for each user's carbon account, along with user information, can be collected over a preset time period (e.g., but not limited to 00:00 to 01:00 daily) or at target time intervals (e.g., but not limited to daily, hourly, etc.) for historical time periods (e.g., before the collection time, or within one day, week, month, or year prior to the collection time). The carbon account can be a virtual account recording changes in a user's carbon credits, used to measure a user's contribution to low-carbon behavior. The carbon credit information may include, but is not limited to, detailed information such as the user's credit balance (total carbon credits), credit sources, and credit consumption. The user information may include, but is not limited to, the user's basic personal information, such as, but is not limited to, name, region, and contact information.
[0099] S702, returns carbon credit information to the carbon account offline table, and returns user information to the user offline table.
[0100] Specifically, the carbon credit information and user information collected in step S701 can be migrated to the carbon account offline table and the user offline table, respectively, thereby migrating the information collected in real time or dynamically to offline storage, ensuring the long-term preservation and traceability of the data, and providing a data foundation for offline data analysis.
[0101] S703, based on the carbon account offline table and the user offline table, determine the carbon credit offline ranking table for the respective carbon accounts of multiple users belonging to the same region.
[0102] Specifically, user information and their carbon credits can be filtered from the carbon account offline table and the user offline table to identify users belonging to the same region. Then, based on the filtered carbon credits information, the carbon credit ranking for each user is calculated, resulting in an offline carbon credit ranking table for each region.
[0103] S704 synchronizes the offline carbon credit ranking table to the real-time query engine.
[0104] Specifically, the offline carbon credit ranking table generated in S703 can be synchronized to a real-time query engine, such as, but not limited to, Elasticsearch and Solr, to ensure consistency between offline and real-time query engine data. This real-time query engine provides efficient real-time query services. Indexes can also be created for the offline carbon credit ranking table within the real-time query engine to improve subsequent query efficiency.
[0105] S705, upon receiving a target carbon credit ranking query instruction, responds by querying the real-time query engine based on the target user's target user information and / or target carbon account information to obtain the target carbon credit ranking information corresponding to the target user.
[0106] Specifically, the terminal can receive a target carbon credit ranking query command input by the target user through a user interface or API interface, and then send the command to the server. Upon receiving the command, the server can parse the target user information and / or target carbon account information from the command, using this as query conditions. The server then performs a query in the real-time query engine based on these conditions to obtain the target user's target carbon credit ranking information. Simultaneously, the server can return the query results to the target user's corresponding terminal, providing an instant carbon credit ranking query service and meeting the user's need to immediately understand their own carbon credit ranking.
[0107] Next, please refer to Figure 8, which is a flowchart illustrating another data settlement method provided by an exemplary embodiment of this application. Specifically, as shown in Figure 8, the data settlement method includes the following steps:
[0108] S801, Obtain target transaction information, which includes at least one target transaction field carrying a target behavior tag.
[0109] Specifically, S801 is the same as S201, and will not be repeated here.
[0110] S802, perform streaming calculation on the target transaction field based on the target behavior label to obtain at least one target carbon label corresponding to the target transaction information and the target consumption data corresponding to the target carbon label.
[0111] Specifically, S802 is the same as S202, and will not be repeated here.
[0112] S803, determine the target carbon credit variable for the target user corresponding to the target transaction information based on at least one target carbon label and the target consumption data corresponding to the target carbon label.
[0113] Specifically, S803 is the same as S203, and will not be repeated here.
[0114] S804, calculates the total carbon credits for the target user's corresponding target carbon account based on the target carbon credit variable.
[0115] Specifically, S804 is the same as S204, and will not be repeated here.
[0116] S805 updates the target carbon account table corresponding to the target carbon account based on the total target carbon credits after settlement.
[0117] Specifically, the target carbon account table stores basic information such as the target user identifier corresponding to the target carbon account, as well as an overview of the target carbon credits (e.g., but not limited to total carbon credits, number of carbon reductions, etc.). After the target transaction is completed and the corresponding carbon credits are settled, the total target carbon credits can be updated in the target carbon account table associated with the target carbon account. This ensures that the total carbon credit data in the target carbon account table accurately reflects the user's contribution to low-carbon behavior, and allows target users to view their total carbon credits at any time, enhancing their sense of participation and accomplishment.
[0118] S806, update the target carbon credit details table corresponding to the target carbon account based on at least one target carbon label, the target consumption data corresponding to the target carbon label, and the target carbon credit variable.
[0119] Specifically, the aforementioned target carbon credit details table stores the target details information involved in the current settlement process for the target carbon account. That is, a corresponding target carbon credit details table can be generated after each transaction, or a new table can be created daily or weekly at fixed intervals. After a user completes a transaction, the calculated carbon credit details, including at least one target carbon label, the target consumption data corresponding to the target carbon label, and the target carbon credit variables, are directly updated in the target carbon credit details table associated with the target carbon account. A target carbon account is stored under one target carbon account table, and this target carbon account table is associated with at least one target carbon credit details table. This table partitioning design avoids the problem of slow subsequent query speeds caused by excessively large amounts of data stored in a single table.
[0120] Optionally, please continue to refer to Figure 8. As shown in Figure 8, the method may also include, but is not limited to, the following:
[0121] S807 receives a target carbon credit query instruction, which carries the target query type specified by the target user.
[0122] Specifically, the terminal can receive a target carbon credit query command triggered by the target user through a user interface, API interface, or other means, and then send the target carbon credit query command to the server. After receiving the target carbon credit query command, the server can parse the command and obtain the target query type specified by the target user (e.g., but not limited to total carbon credit query, carbon credit details query, etc.).
[0123] S808, in response to the target carbon credit query instruction, if the target query type is the total carbon credit query type, queries the target carbon account table based on the target user information and / or target carbon account information corresponding to the target user to obtain the target total carbon credit; if the target query type is the carbon credit details query type, queries the target carbon credit details table based on the target user information and / or target carbon account information corresponding to the target user to obtain the target carbon credit details information.
[0124] Specifically, the server can respond to a target carbon credit query command by querying the corresponding database table according to the target query type and returning the query results. For example, when the target query type is a total carbon credit query, the server queries the target carbon account table based on the target user information and / or target carbon account information corresponding to the target user to obtain the target total carbon credits; when the target query type is a carbon credit details query, the server queries the target carbon credit details table based on the target user information and / or target carbon account information corresponding to the target user to obtain the target carbon credit details information. This provides an instant carbon credit query service, meeting users' needs to understand their carbon credit status at any time, and enhancing data transparency and credibility by providing detailed carbon credit details query services.
[0125] The following section uses terminal execution data display as an example to introduce a data display method provided by an exemplary embodiment of this application. Specifically, as shown in Figure 9, the data display method includes the following steps:
[0126] S901 receives the target carbon credit query command input by the target user.
[0127] Specifically, through the user interface of the target application displayed on the terminal, the target user can input or trigger a target carbon credit query command.
[0128] S902, the target carbon credit query instruction is sent to the server so that the server responds to the target carbon credit query instruction and obtains the target carbon credit settlement result.
[0129] Specifically, after receiving a target carbon credit query instruction from a target user, the terminal can send the instruction to the server. The server then responds to the instruction by performing a query based on the query type and / or the target user's information and / or target carbon account information carried in the instruction, thus obtaining the target carbon credit settlement result. This target carbon credit settlement result is obtained based on the aforementioned data settlement method.
[0130] S903 receives the target carbon credit settlement result returned by the server and displays the target carbon credit settlement result on the target-related page corresponding to the target carbon account.
[0131] Specifically, when the target query type is a total carbon credit query, the aforementioned target-related page is the target carbon account homepage, and the target carbon credit query result includes the target total carbon credits obtained by the server after the target transaction for the target user is completed, using the aforementioned data settlement method. When the target query type is a carbon credit details query, the aforementioned target-related page may, but is not limited to, be the target carbon account details page, and the aforementioned target carbon credit query result may, but is not limited to, include the target carbon credit details involved in the settlement process by the server after the target transaction for the target user is completed, using the aforementioned data settlement method.
[0132] To better understand the data settlement method provided in the above embodiments of this application, FIG10 exemplarily shows a schematic diagram of the structure of a data settlement device provided in an embodiment of this application. Specifically, as shown in FIG10, the data settlement device 1000 includes:
[0133] The first acquisition module 1010 is used to acquire target transaction information; the target transaction information includes at least one target transaction field carrying a target behavior tag.
[0134] The streaming computing module 1020 is used to perform streaming computing on the target transaction field based on the target behavior label to obtain at least one target carbon label corresponding to the target transaction information and target consumption data corresponding to the target carbon label.
[0135] The first determining module 1030 is used to determine the target carbon credit variable of the target user corresponding to the target transaction information based on the at least one target carbon label and the target consumption data corresponding to the target carbon label.
[0136] The settlement module 1040 is used to settle the total carbon credits of the target carbon account corresponding to the target user based on the above-mentioned target carbon credit variables.
[0137] In one possible implementation, the above-mentioned streaming computing module 1020 includes:
[0138] The labeling unit is used to label the target transaction field according to the target behavior label and preset rules to obtain the target labeling result corresponding to the target transaction field; the target labeling result is used to indicate whether the target consumption data corresponding to the target transaction field belongs to low-carbon behavior data.
[0139] The filtering unit is used to filter the target transaction field in the target transaction information according to the target labeling result, so as to obtain the specified transaction field of the target carbon labeling result.
[0140] The data determination unit is used to determine the target consumption data corresponding to each of the target carbon tags based on at least one specified transaction field corresponding to each target carbon tag in the target transaction information.
[0141] In one possible implementation, the above annotation unit is specifically used for:
[0142] Behavior recognition is performed on the above target behavior tags to obtain the target behavior type corresponding to the above target transaction field; if the above target behavior type is a low-carbon behavior type, the corresponding above target transaction field is labeled with a target carbon tag; if the above target transaction field corresponds to a different low-carbon behavior type, the type of above target carbon tag labeled is different; if the above target behavior type is a non-low-carbon behavior type, the corresponding above target transaction field is labeled with a target non-carbon tag.
[0143] In one possible implementation, the target consumption data includes at least one designated transaction field corresponding to the target carbon label; the designated transaction field includes low-carbon transaction information for a specified transaction type.
[0144] The aforementioned first determining module 1030 includes:
[0145] The carbon credit assessment unit is used to assess the carbon credit of the low-carbon transaction information according to the specified transaction type, and obtain the specified carbon credit corresponding to the specified transaction field.
[0146] The carbon integral sub-variable determination unit is used to determine the target carbon integral sub-variable corresponding to the target carbon label based on the specified carbon integral of each of the specified transaction fields corresponding to the target carbon label.
[0147] The carbon credit variable determination unit is used to determine the target carbon credit variable of the target user corresponding to the target transaction information based on the target carbon credit sub-variable corresponding to at least one of the target carbon tags mentioned above.
[0148] In one possible implementation, the aforementioned carbon credit assessment unit is specifically used for: assessing the specified carbon credits corresponding to the specified transaction field based on the type and / or quantity of each low-carbon commodity in the low-carbon transaction information when the specified transaction type is a low-carbon commodity transaction type; assessing the specified carbon credits corresponding to the specified transaction field based on the type and / or quantity of low-carbon service tools in the low-carbon transaction information when the specified transaction type is a low-carbon transaction voucher type; determining the environmental protection level corresponding to the low-carbon transaction information based on the type of low-carbon transaction voucher in the low-carbon transaction information, and assessing the specified carbon credits corresponding to the specified transaction field based on the environmental protection level when the specified transaction type is a low-carbon delivery transaction type; and assessing the specified carbon credits corresponding to the specified transaction field based on the number of participants in the group purchase and / or the delivery distance in the low-carbon transaction information when the specified transaction type is a low-carbon delivery transaction type.
[0149] In one possible implementation, the first determining module 1030 is specifically used for:
[0150] The target carbon credit variable for the target user corresponding to the target transaction information is determined based on at least one target carbon label, the target consumption data corresponding to the target carbon label, and the target transaction type. Wherein, when the target transaction type is an order type, the target carbon credit variable is a positive value; when the target transaction type is a cancellation type, the target carbon credit variable is a negative value.
[0151] In one possible implementation, the target transaction information further includes the target transaction type; the data settlement device 1000 further includes:
[0152] The judgment module is used to determine whether there is a data settlement record for the target order information corresponding to the above target transaction information when the above target transaction type is a cancellation type;
[0153] The settlement module 1040 is also used to: if there is a corresponding data settlement record for the target order information, deduct the historical carbon credit variable of the target order information recorded in the data settlement record from the total carbon credit of the target carbon account to obtain the total target carbon credit after settlement;
[0154] The control module is used to keep the total carbon credits of the target carbon account unchanged if there is no corresponding data settlement record for the target order information.
[0155] In one possible implementation, the data settlement device 1000 further includes:
[0156] The first receiving module is used to receive the target redemption instruction; the target redemption instruction carries the target redemption type selected by the target user and the total amount of carbon credits redeemed under the target redemption type.
[0157] The redemption module is used to respond to the aforementioned target redemption instruction, redeem points according to the aforementioned target redemption type and the aforementioned total carbon credit redemption amount, and obtain the target total carbon credits after redemption and the target benefits information corresponding to the aforementioned target redemption type; wherein, when the aforementioned target redemption type is a service redemption type, the aforementioned target benefits information includes the target service information provided to the aforementioned target user after redemption; when the aforementioned target redemption type is a discount redemption type, the aforementioned target benefits information includes the target discount information issued to the target account corresponding to the aforementioned target user after redemption; when the aforementioned target redemption type is a product redemption type, the aforementioned target benefits information includes the target product information after redemption.
[0158] In one possible implementation, the data settlement device 1000 further includes:
[0159] The second acquisition module is used to acquire carbon credit information of each user's corresponding carbon account and user information of each user.
[0160] The backflow module is used to backflow the aforementioned carbon credit information to the carbon account offline table, and to backflow the aforementioned user information to the user offline table;
[0161] The second determining module is used to determine the carbon credit offline ranking table of each carbon account of multiple users belonging to the same region based on the above carbon account offline table and the above user offline table.
[0162] The synchronization module is used to synchronize the aforementioned offline carbon credit ranking table to the real-time query engine;
[0163] The first query module is used to, upon receiving a target carbon credit ranking query instruction, respond to the aforementioned target carbon credit ranking query instruction by querying the aforementioned real-time query engine based on the target user information and / or target carbon account information of the aforementioned target user, and obtain the target carbon credit ranking information corresponding to the aforementioned target user.
[0164] In one possible implementation, the data settlement device 1000 further includes:
[0165] The first update module is used to update the target carbon account table corresponding to the above-mentioned target carbon account based on the total target carbon credits after settlement; the target carbon account table is used to store the target user identifier and target carbon credit overview information corresponding to the above-mentioned target carbon account.
[0166] The second update module is used to update the target carbon credit details table corresponding to the target carbon account based on at least one target carbon label, the target consumption data corresponding to the target carbon label, and the target carbon credit variable. The target carbon credit details table is used to store the target details information involved in the current settlement process for the target carbon account. Among them, one target carbon account table is stored under one target carbon account, and at least one target carbon credit details table is stored in association with the target carbon account table.
[0167] In one possible implementation, the data settlement device 1000 further includes:
[0168] The second receiving module is used to receive the target carbon credit query instruction; the target carbon credit query instruction carries the target query type specified by the target user.
[0169] The second query module is used to respond to the above-mentioned target carbon credit query instruction. When the target query type is the total carbon credit query type, it queries the target carbon account table based on the target user information and / or target carbon account information corresponding to the target user to obtain the target total carbon credit. When the target query type is the carbon credit details query type, it queries the target carbon credit details table based on the target user information and / or target carbon account information corresponding to the target user to obtain the target carbon credit details information.
[0170] In one possible implementation, the first acquisition module 1010 is specifically used for:
[0171] Use message middleware to monitor target change information in the order database; and read the corresponding target transaction information from the order database based on the target change information.
[0172] To better understand the data display method provided in the above embodiments of this application, FIG11 exemplarily illustrates a structural schematic diagram of a data display device provided in an embodiment of this application. Specifically, as shown in FIG11, the data display device 1100 includes:
[0173] The first receiving module 1110 is used to receive the target carbon credit query command input by the target user;
[0174] The sending module 1120 is used to send the above-mentioned target carbon credit query instruction to the server, so that the server responds to the above-mentioned target carbon credit query instruction and queries the target carbon credit settlement result.
[0175] The second receiving module 1130 is used to receive the target carbon credit settlement result returned by the server.
[0176] Display module 1140 is used to display the target carbon credit settlement result on the target-related page corresponding to the target carbon account; the target carbon credit settlement result is obtained based on the data settlement method described above.
[0177] The division of modules in the above-described data settlement device or data display device is for illustrative purposes only. In other embodiments, the data settlement device or data display device may be divided into different modules as needed to complete all or part of the functions of the above-described data settlement device or data display device. The implementation of each module in the data settlement device or data display device provided in this application embodiment can be in the form of a computer program. This computer program can run on a terminal or server. The program modules constituted by this computer program can be stored in the memory of the terminal or server. When the computer program is executed by a processor, it implements all or part of the steps of the data settlement method or data display method described in the embodiments of this application.
[0178] Please refer to Figure 12 next. Figure 12 is a schematic diagram of the structure of an electronic device provided in an exemplary embodiment of this application. As shown in Figure 12, the electronic device 1200 may include: at least one processor 1210, at least one network interface 1220, user interface 1230, memory 1240, and at least one communication bus 1250.
[0179] The communication bus 1250 can be used to connect and communicate with the various components mentioned above. The user interface 1230 may include a display screen and a camera; optional user interfaces may also include standard wired interfaces and wireless interfaces. The network interface 1220 includes a Bluetooth module, a Near Field Communication (NFC) module, a Wireless Fidelity (Wi-Fi) module, etc.
[0180] The processor 1210 may include one or more processing cores. The processor 1210 connects to various parts within the electronic device 1200 using various interfaces and lines. It executes various functions and processes data by running or executing instructions, programs, code sets, or instruction sets stored in the memory 1240, and by calling data stored in the memory 1240. Optionally, the processor 1210 may be implemented using at least one hardware form of Digital Signal Processing (DSP), Field-Programmable Gate Array (FPGA), or Programmable Logic Array (PLA). The processor 1210 may integrate one or more of the following: a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), and a modem. The CPU primarily handles the operating system, user interface, and applications; the GPU is responsible for rendering and drawing the content to be displayed on the screen; and the modem handles wireless communication. It is understood that the modem may also be implemented as a separate chip without being integrated into the processor 1210.
[0181] The memory 1240 may include random access memory (RAM) or read-only memory (ROM). Optionally, the memory 1240 may include a non-transitory computer-readable medium. The memory 1240 may be used to store instructions, programs, code, code sets, or instruction sets. The memory 1240 may include a program storage area and a data storage area. The program storage area may store instructions for implementing an operating system, instructions for at least one function (such as an acquisition function, a data settlement function, a data display function, etc.), and instructions for implementing the various method embodiments described above. The data storage area may store data involved in the various method embodiments described above. Optionally, the memory 1240 may also be at least one storage device located remotely from the aforementioned processor 1210. As shown in FIG12, the memory 1240, as a computer storage medium, may include an operating system, a network communication module, a user interface module, and application programs.
[0182] In some possible embodiments, if the electronic device 1200 is the data settlement device 1000 mentioned in the embodiment described in FIG10, then the processor 1210 can be used to call the data settlement application stored in the memory 1240 and specifically perform the following operations: obtain target transaction information; the target transaction information includes at least one target transaction field carrying a target behavior tag; perform streaming calculation on the target transaction field according to the target behavior tag to obtain at least one target carbon tag corresponding to the target transaction information and target consumption data corresponding to the target carbon tag; determine the target carbon credit variable of the target user corresponding to the target transaction information according to the at least one target carbon tag and the target consumption data corresponding to the target carbon tag; and settle the total carbon credits of the target carbon account corresponding to the target user according to the target carbon credit variable.
[0183] In some possible embodiments, when the processor 1210 performs the above-mentioned streaming calculation on the target transaction field according to the target behavior label to obtain at least one target carbon label corresponding to the target transaction information and the target consumption data corresponding to the target carbon label, it is specifically used to perform: labeling the target transaction field according to the target behavior label according to a preset rule to obtain the target labeling result corresponding to the target transaction field; the target labeling result is used to indicate whether the target consumption data corresponding to the target transaction field belongs to low-carbon behavior data; filtering the target transaction field in the target transaction information according to the target labeling result to obtain the specified transaction field for labeling the target carbon label; and determining the target consumption data corresponding to each target carbon label according to at least one specified transaction field corresponding to each target carbon label in the target transaction information.
[0184] In some possible embodiments, when the processor 1210 performs the above-mentioned annotation of the target transaction field according to the target behavior label and preset rules to obtain the target annotation result corresponding to the target transaction field, it is specifically used to perform: behavior recognition on the target behavior label to obtain the target behavior type corresponding to the target transaction field; if the target behavior type is a low-carbon behavior type, the corresponding target transaction field is labeled with a target carbon label; if the low-carbon behavior type corresponding to the target transaction field is different, the type of target carbon label is different; if the target behavior type is a non-low-carbon behavior type, the corresponding target transaction field is labeled with a target non-carbon label.
[0185] In some possible embodiments, the target consumption data includes at least one designated transaction field corresponding to the target carbon label; the designated transaction field includes low-carbon transaction information of a designated transaction type; when the processor 1210 executes the above-mentioned determination of the target carbon credit variable of the target user corresponding to the target transaction information based on the at least one target carbon label and the target consumption data corresponding to the target carbon label, it is specifically used to perform: carbon credit evaluation of the low-carbon transaction information based on the designated transaction type to obtain the designated carbon credit corresponding to the designated transaction field; determine the target carbon credit sub-variable corresponding to the target carbon label based on the designated carbon credit of each of the designated transaction fields corresponding to the target carbon label; and determine the target carbon credit variable of the target user corresponding to the target transaction information based on the target carbon credit sub-variable corresponding to the at least one target carbon label.
[0186] In some possible embodiments, when the processor 1210 performs the carbon credit assessment of the low-carbon transaction information according to the specified transaction type to obtain the specified carbon credit corresponding to the specified transaction field, it is specifically configured to perform the following: when the specified transaction type is a low-carbon commodity transaction type, assess the specified carbon credit corresponding to the specified transaction field according to the type and / or quantity of each low-carbon commodity in the low-carbon transaction information; when the specified transaction type is a low-carbon service tool transaction type, assess the specified carbon credit corresponding to the specified transaction field according to the type and / or quantity of low-carbon service tools in the low-carbon transaction information; when the specified transaction type is a low-carbon transaction voucher type, determine the environmental protection level corresponding to the low-carbon transaction information according to the type of low-carbon transaction voucher in the low-carbon transaction information, and assess the specified carbon credit corresponding to the specified transaction field according to the environmental protection level; when the specified transaction type is a low-carbon delivery transaction type, assess the specified carbon credit corresponding to the specified transaction field according to the number of people participating in group buying and / or the delivery distance in the low-carbon transaction information.
[0187] In some possible embodiments, the target transaction information further includes a target transaction type; when the processor 1210 executes the above-mentioned determination of the target carbon credit variable of the target user corresponding to the target transaction information based on the at least one target carbon label and the target consumption data corresponding to the target carbon label, it is specifically used to perform: determining the target carbon credit variable of the target user corresponding to the target transaction information based on the at least one target carbon label, the target consumption data corresponding to the target carbon label, and the target transaction type; wherein, when the target transaction type is an order type, the target carbon credit variable is a positive value; when the target transaction type is a cancellation type, the target carbon credit variable is a negative value.
[0188] In some possible embodiments, the processor 1210 further executes the target transaction information by including the target transaction type; after obtaining the target transaction information, it is also used to perform: if the target transaction type is a cancellation type, determine whether there is a data settlement record for the target order information corresponding to the target transaction information; if there is a corresponding data settlement record for the target order information, then deduct the historical carbon credit variable of the target order information recorded in the data settlement record from the total carbon credit of the target carbon account to obtain the settled total carbon credit; if there is no corresponding data settlement record for the target order information, then control the total carbon credit of the target carbon account to remain unchanged.
[0189] In some possible embodiments, the processor 1210 is further configured to: receive a target redemption instruction; the target redemption instruction carries the target redemption type selected by the target user and the total carbon credit redemption amount under the target redemption type; in response to the target redemption instruction, perform credit redemption according to the target redemption type and the total carbon credit redemption amount to obtain the target total carbon credits after redemption and the target benefits information corresponding to the target redemption type after redemption; wherein, when the target redemption type is a service redemption type, the target benefits information includes target service information provided to the target user after redemption; when the target redemption type is a discount redemption type, the target benefits information includes target discount information issued to the target account corresponding to the target user after redemption; when the target redemption type is a product redemption type, the target benefits information includes target product information after redemption.
[0190] In some possible embodiments, the processor 1210 is further configured to perform: obtaining carbon credit information for each carbon account of multiple users and user information for each user; returning the carbon credit information to the carbon account offline table and the user information to the user offline table; determining an offline carbon credit ranking table for each carbon account of multiple users belonging to the same region based on the carbon account offline table and the user offline table; synchronizing the offline carbon credit ranking table to the real-time query engine; and upon receiving a target carbon credit ranking query instruction, responding to the target carbon credit ranking query instruction by querying the real-time query engine based on the target user information and / or target carbon account information of the target user to obtain the target carbon credit ranking information corresponding to the target user.
[0191] In some possible embodiments, after the processor 1210 performs the above-mentioned settlement of the total carbon credits of the target carbon account corresponding to the target user based on the target carbon credit variable, it is further configured to perform: updating the target carbon account table corresponding to the target carbon account based on the settled target total carbon credits; the target carbon account table is used to store the target user identifier and target carbon credit overview information corresponding to the target carbon account; updating the target carbon credit detail table corresponding to the target carbon account based on the at least one target carbon tag, the target consumption data corresponding to the target carbon tag, and the target carbon credit variable; the target carbon credit detail table is used to store the target detail information involved in the current settlement process of the target carbon account; wherein, one target carbon account table is stored under one target carbon account, and at least one target carbon credit detail table is stored in association with the target carbon account table.
[0192] In some possible embodiments, the processor 1210 is further configured to: receive a target carbon credit query instruction; the target carbon credit query instruction carries a target query type specified by the target user; in response to the target carbon credit query instruction, if the target query type is a total carbon credit query type, query the target carbon account table according to the target user information and / or target carbon account information corresponding to the target user to obtain the target total carbon credits; if the target query type is a carbon credit detail query type, query the target carbon credit detail table according to the target user information and / or target carbon account information corresponding to the target user to obtain the target carbon credit detail information.
[0193] In some possible embodiments, when the processor 1210 performs the above-mentioned acquisition of target transaction information, it is specifically used to perform: using message middleware to listen for target change information occurring in the order database; and reading the corresponding target transaction information in the order database based on the target change information.
[0194] In some possible embodiments, if the electronic device 1200 is the data display device 1100 mentioned in the embodiment of FIG11 above, then the processor 1210 can be used to call the data display application stored in the memory 1240 and specifically perform the following operations: receiving a target carbon credit query instruction input by the target user; sending the target carbon credit query instruction to the server so that the server responds to the target carbon credit query instruction and queries the target carbon credit settlement result; receiving the target carbon credit settlement result returned by the server; displaying the target carbon credit settlement result on the target-related page corresponding to the target carbon account; the target carbon credit settlement result is obtained based on the above data settlement method.
[0195] This application also provides a computer-readable storage medium storing instructions that, when executed on a computer or processor, cause the computer or processor to perform one or more steps in the above embodiments. If the constituent modules of the above-described electronic device are implemented as software functional units and sold or used as independent products, they can be stored in the aforementioned computer-readable storage medium.
[0196] In the above embodiments, implementation can be achieved entirely or partially through software, hardware, firmware, or any combination thereof. When implemented using software, it can be implemented entirely or partially as a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted through the computer-readable storage medium. The computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, Digital Subscriber Line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium accessible to a computer or a data storage device such as a server or data center that integrates one or more available media. The available media may be magnetic media (e.g., floppy disks, hard disks, magnetic tapes), optical media (e.g., digital versatile discs (DVDs)), or semiconductor media (e.g., solid-state drives (SSDs)).
[0197] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. This program can be stored in a computer-readable storage medium, and when executed, it can include the processes of the embodiments of the methods described above. The aforementioned storage medium includes various media capable of storing program code, such as ROM, RAM, magnetic disks, or optical disks. Unless otherwise specified, the technical features of this embodiment and its implementation can be combined arbitrarily.
[0198] The embodiments described above are merely preferred embodiments of this application and are not intended to limit the scope of this application. Any modifications and improvements made to the technical solutions of this application by those skilled in the art without departing from the spirit of this application should fall within the protection scope defined by the claims.
[0199] The foregoing has described specific embodiments of this application. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims may be performed in a different order than that shown in the embodiments and may still achieve the desired results. Furthermore, the processes depicted in the drawings do not necessarily require the specific or sequential order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
Claims
1. A data settlement method, comprising: Once the target user completes an online transaction, obtain the corresponding target transaction information; The target transaction information includes at least one target transaction field carrying a target behavior tag; The target behavior label is used to identify the attribute of the target transaction field corresponding to the target transaction behavior; Based on the target behavior label, the target transaction field is calculated in real time to obtain at least one target carbon label corresponding to the target transaction information and the target consumption data corresponding to the target carbon label; the target carbon label is a label representing low-carbon behavior in the transaction and is used to quantify the environmental impact of the transaction. The target consumption data is obtained by integrating the target transaction fields corresponding to the same type of target carbon label in the target transaction information; the types of low-carbon behaviors corresponding to the target transaction fields are different, and the types of target carbon labels are different. Based on at least one of the factors of environmental friendliness, transaction volume, and transaction type, different carbon credits are assigned to different target carbon labels, and the target carbon credit variables of the target users corresponding to the target transaction information are determined according to the at least one target carbon label and the target consumption data corresponding to the target carbon label. The target carbon credit variable is used to measure the overall low-carbon performance of the target user in this target transaction; The total carbon credits for the target user's corresponding target carbon account are calculated based on the target carbon credit variable.
2. The method according to claim 1, wherein, The step of performing real-time streaming computation on the target transaction field based on the target behavior tag to obtain at least one target carbon tag corresponding to the target transaction information and target consumption data corresponding to the target carbon tag includes: The target transaction field is labeled according to the target behavior label and a preset rule to obtain the target labeling result corresponding to the target transaction field; the target labeling result is used to indicate whether the target consumption data corresponding to the target transaction field belongs to low-carbon behavior data; Based on the target labeling results, the target transaction fields in the target transaction information are filtered to obtain the target labeling results as the specified transaction fields for labeling the target carbon tags; The target consumption data corresponding to each target carbon tag is determined based on at least one specified transaction field corresponding to each target carbon tag in the target transaction information.
3. The method according to claim 2, wherein, The step of labeling the target transaction field according to the target behavior label and a preset rule to obtain the target labeling result corresponding to the target transaction field includes: The target behavior label is subjected to behavior recognition to obtain the target behavior type corresponding to the target transaction field; When the target behavior type is a low-carbon behavior type, the corresponding target transaction field will be labeled with a target carbon tag; If the target behavior type is a non-low-carbon behavior type, the corresponding target transaction field will be labeled with a target non-carbon tag.
4. The method according to claim 1, wherein, The target consumption data includes at least one designated transaction field corresponding to the target carbon label; the designated transaction field includes low-carbon transaction information for a specified transaction type. The step of determining the target carbon credit variable for the target user corresponding to the target transaction information based on the at least one target carbon label and the target consumption data corresponding to the target carbon label includes: The carbon credits of the low-carbon transaction information are evaluated according to the specified transaction type to obtain the specified carbon credits corresponding to the specified transaction field. The target carbon integral sub-variable corresponding to the target carbon label is determined based on the specified carbon integral of each specified transaction field corresponding to the target carbon label; The target carbon credit variable of the target user corresponding to the target transaction information is determined based on the target carbon credit sub-variable corresponding to the at least one target carbon label.
5. The method according to claim 4, wherein, The step of evaluating the low-carbon transaction information based on the specified transaction type to obtain the specified carbon credits corresponding to the specified transaction field includes: When the specified transaction type is a low-carbon commodity transaction type, the specified carbon credits corresponding to the specified transaction field are evaluated based on the type and / or quantity of each low-carbon commodity in the low-carbon transaction information. When the specified transaction type is a low-carbon service tool transaction type, the specified carbon credits corresponding to the specified transaction field are evaluated based on the type and / or quantity of low-carbon service tools in the low-carbon transaction information. When the specified transaction type is a low-carbon transaction certificate type, the environmental protection level corresponding to the low-carbon transaction information is determined according to the type of low-carbon transaction certificate in the low-carbon transaction information, and the specified carbon credit corresponding to the specified transaction field is evaluated according to the environmental protection level. When the specified transaction type is a low-carbon delivery transaction type, the specified carbon credits corresponding to the specified transaction field are evaluated based on the number of participants in the group purchase and / or the delivery distance in the low-carbon transaction information.
6. The method according to claim 1, wherein, The target transaction information also includes the target transaction type; determining the target carbon credit variable for the target user corresponding to the target transaction information based on the at least one target carbon label and the target consumption data corresponding to the target carbon label includes: The target carbon credit variable for the target user corresponding to the target transaction information is determined based on the at least one target carbon label, the target consumption data corresponding to the target carbon label, and the target transaction type. Wherein, when the target transaction type is an order type, the target carbon credit variable is a positive value; when the target transaction type is a canceled order type, the target carbon credit variable is a negative value.
7. The method according to claim 1, wherein, The target transaction information also includes the target transaction type; after obtaining the corresponding target transaction information, the method further includes: If the target transaction type is a cancellation type, determine whether there is a data settlement record for the target order information corresponding to the target transaction information; If the target order information has a corresponding data settlement record, then the total carbon credits of the target carbon account are deducted from the historical carbon credits variable of the target order information recorded in the data settlement record to obtain the total target carbon credits after settlement. If the target order information does not have a corresponding data settlement record, the total carbon credits of the target carbon account will remain unchanged.
8. The method according to claim 1, wherein, After calculating the total carbon credits of the target user's corresponding target carbon account based on the target carbon credit variable, the method further includes: Receive a target redemption instruction; the target redemption instruction carries the target redemption type selected by the target user and the total amount of carbon credits to be redeemed under the target redemption type; In response to the target redemption instruction, points are redeemed according to the target redemption type and the total carbon points redemption amount to obtain the target total carbon points after redemption and the target benefits information corresponding to the target redemption type. Wherein, when the target redemption type is a service redemption type, the target benefit information includes the target service information provided to the target user after redemption; when the target redemption type is a discount redemption type, the target benefit information includes the target discount information issued to the target account corresponding to the target user after redemption; when the target redemption type is a product redemption type, the target benefit information includes the target product information after redemption.
9. The method according to claim 1, wherein, After calculating the total carbon credits of the target user's corresponding target carbon account based on the target carbon credit variable, the method further includes: Obtain carbon credit information for each of the multiple users' respective carbon accounts, as well as user information for each of the multiple users; The carbon credit information is fed back to the carbon account offline table, and the user information is fed back to the user offline table; Based on the carbon account offline table and the user offline table, determine the carbon credit offline ranking table for each of the carbon accounts of multiple users belonging to the same region. Synchronize the offline carbon credit ranking table to the real-time query engine; Upon receiving a target carbon credit ranking query instruction, in response to the target carbon credit ranking query instruction, a query is performed in the real-time query engine based on the target user's target user information and / or target carbon account information to obtain the target carbon credit ranking information corresponding to the target user.
10. The method according to claim 1, wherein, After calculating the total carbon credits of the target user's corresponding target carbon account based on the target carbon credit variable, the method further includes: The target carbon account table corresponding to the target carbon account is updated based on the total target carbon credits after settlement; the target carbon account table is used to store the target user identifier and target carbon credit overview information corresponding to the target carbon account; The target carbon credit details table corresponding to the target carbon account is updated based on the at least one target carbon label, the target consumption data corresponding to the target carbon label, and the target carbon credit variable; the target carbon credit details table is used to store the target details information involved in the target carbon account during this settlement process; Each target carbon account stores a target carbon account table, and the target carbon account table is associated with at least one target carbon credit details table.
11. The method according to claim 10, wherein, After calculating the total carbon credits of the target user's corresponding target carbon account based on the target carbon credit variable, the method further includes: Receive a target carbon credit query instruction; the target carbon credit query instruction carries the target query type specified by the target user; In response to the target carbon credit query instruction, if the target query type is the total carbon credit query type, the target user information and / or target carbon account information corresponding to the target user are queried in the target carbon account table to obtain the target total carbon credits; if the target query type is the carbon credit details query type, the target user information and / or target carbon account information corresponding to the target user are queried in the target carbon credit details table to obtain the target carbon credit details information.
12. The method according to claim 1, wherein, The acquisition of the corresponding target transaction information includes: Use a message broker to monitor target changes in the order database; Based on the target change information, read the corresponding target transaction information from the order database.
13. A data display method, the method comprising: Receive the target carbon credit query command input by the target user; The target carbon credit query instruction is sent to the server, so that the server responds to the target carbon credit query instruction and retrieves the target carbon credit settlement result; Receive the target carbon credit settlement result returned by the server, and display the target carbon credit settlement result on the target-related page corresponding to the target carbon account; The target carbon credit settlement result is obtained based on the data settlement method described in any one of claims 1 to 12.
14. An electronic device, comprising: Processor and memory; The processor is connected to the memory; The memory is used to store executable program code; The processor runs a program corresponding to the executable program code stored in the memory to perform the steps of the method as described in any one of claims 1 to 13.
15. A computer storage medium storing a plurality of instructions adapted for loading by a processor and performing the method steps of any one of claims 1 to 13.