Business application rule generation method and related equipment

By combining a large language model and a retrieval-enhanced generation model with a pre-set knowledge base, tax declaration rules are automatically matched and generated, solving the problems of low accuracy and insufficient efficiency caused by manual compilation in existing technologies, and achieving efficient and accurate declaration rule generation.

CN119671755BActive Publication Date: 2026-06-30KINGDEE SOFTWARE(CHINA) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
KINGDEE SOFTWARE(CHINA) CO LTD
Filing Date
2024-10-23
Publication Date
2026-06-30

AI Technical Summary

Technical Problem

The existing methods for generating tax declaration rules rely on manual compilation and configuration, resulting in low accuracy and insufficient efficiency and timeliness.

Method used

By combining a large language model and a retrieval-enhanced generative model (RAG) with a pre-set knowledge base, the system automatically matches and generates declaration rules for target metadata entities related to changes in business policies, reducing human intervention.

Benefits of technology

It improved the accuracy and efficiency of application rules, reduced omissions and errors caused by manual configuration, and enhanced system response speed and the timeliness of business applications.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119671755B_ABST
    Figure CN119671755B_ABST
Patent Text Reader

Abstract

This application discloses a method, apparatus, computer device, computer-readable storage medium, and computer program product containing instructions or computer programs for generating business declaration rules, aiming to improve the accuracy, efficiency, and timeliness of business declaration rule generation. The method includes: acquiring target metadata entities related to changes in business policies; inputting the target metadata entities into a large model; and having the large model perform the following steps: determining initial declaration rule information from a preset knowledge base whose matching degree with the target metadata entities reaches a preset matching degree threshold; and outputting a first target declaration rule corresponding to the target metadata entities based on the initial declaration rule information. This application can be applied to various information management systems, such as Enterprise Resource Planning (ERP) systems, tax systems, financial systems, human resource systems, and supply chain systems.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of application rule generation, and more specifically, to a business application rule generation method, a business application rule generation device, a computer device, a computer-readable storage medium, and a computer program product containing instructions or computer programs. Background Technology

[0002] With the rapid development of information technology, business-related policies and regulations are being updated more and more frequently. For example, tax policies and regulations are frequently updated, and each update requires the regeneration of tax declaration rules.

[0003] The current method for generating tax filing rules involves professional delivery consultants developing the rules based on in-depth market research and legal studies, and then manually inputting them into the system line by line. However, the current method relies on manual compilation and configuration, which increases the probability of omissions and errors, resulting in low accuracy in generating business filing rules. Summary of the Invention

[0004] This application provides a method for generating business application rules, a device for generating business application rules, a computer device, a computer-readable storage medium, and a computer program product containing instructions or computer programs, which can generate business application rules while improving the accuracy, efficiency, and timeliness of business application rule generation.

[0005] Firstly, embodiments of this application provide a method for generating business application rules, including:

[0006] Retrieve the target metadata entities related to changes in business policies;

[0007] The target metadata entity is input into the large model, and the large model performs the following steps: determining the initial declaration rule information from the preset knowledge base that matches the target metadata entity to a preset matching degree threshold;

[0008] Based on the initial declaration rule information, the first target declaration rule corresponding to the target metadata entity is output.

[0009] Secondly, embodiments of this application provide a business application rule generation apparatus, comprising:

[0010] The acquisition unit is used to acquire target metadata entities related to changes in business policies;

[0011] The input unit is used to input the target metadata entity into the large model, and the large model performs the following steps: determining the initial declaration rule information from the preset knowledge base that matches the target metadata entity to a preset matching degree threshold;

[0012] The output unit is used to output the first target declaration rule corresponding to the target metadata entity based on the initial declaration rule information.

[0013] Thirdly, embodiments of this application provide a computer device, including:

[0014] Central processing unit, memory, input / output interfaces, wired or wireless network interfaces, and power supply;

[0015] The memory is either a short-term storage memory or a persistent storage memory;

[0016] The central processing unit is configured to communicate with the memory and execute instructions in the memory to perform the aforementioned business application rule generation method.

[0017] Fourthly, embodiments of this application provide a computer-readable storage medium, which includes instructions that, when executed on a computer, cause the computer to perform the aforementioned business application rule generation method.

[0018] Fifthly, embodiments of this application provide a computer program product containing instructions, which, when run on a computer, causes the computer to execute the aforementioned business declaration rule generation method.

[0019] As can be seen from the above technical solutions, the embodiments of this application have the following advantages: Firstly, it can obtain initial declaration rule information with a high degree of matching with the target metadata entity, and then generate a first target declaration rule based on this initial declaration rule information. Because the matching accuracy is high, the generated first target declaration rule has high accuracy. Secondly, the embodiments of this application generate business declaration rules based on a large model, eliminating the need for manual rule configuration and thus avoiding omissions or errors in manual configuration. In summary, the accuracy of business declaration rule generation in the embodiments of this application is high. Furthermore, generating business declaration rules through a large model avoids the tedious process of manual compilation and configuration in traditional methods, greatly reducing the cost and time required for compilation and configuration, making the process of generating business declaration rules faster. Therefore, the efficiency of business declaration rule generation is high. Moreover, due to reduced human intervention, the system's response speed is faster, and the generation of business declaration rules is not affected by delays in human operation. Therefore, the timeliness of business declaration rule generation is high. Attached Figure Description

[0020] Figure 1 This is a schematic diagram of the architecture of a business application rule generation system disclosed in an embodiment of this application;

[0021] Figure 2This is a flowchart illustrating a business application rule generation method disclosed in an embodiment of this application;

[0022] Figure 3 This is a schematic diagram of the tax interface of a tax website disclosed in an embodiment of this application;

[0023] Figure 4 This is a schematic diagram of a knowledge base development sub-interface disclosed in an embodiment of this application;

[0024] Figure 5 This application discloses a prompt word development sub-interface;

[0025] Figure 6 This is a schematic diagram illustrating a large model release process disclosed in an embodiment of this application;

[0026] Figure 7 This is a schematic diagram of a declaration item rule configuration list interface disclosed in an embodiment of this application;

[0027] Figure 8 This is a schematic diagram of a preset application rule display interface disclosed in an embodiment of this application;

[0028] Figure 9 This is a flowchart illustrating another method for generating business application rules disclosed in an embodiment of this application;

[0029] Figure 10 This is a schematic diagram of an application rules page disclosed in an embodiment of this application;

[0030] Figure 11 This is a flowchart illustrating another method for generating business application rules disclosed in an embodiment of this application;

[0031] Figure 12 This is a schematic diagram of the structure of a business application rule generation device disclosed in an embodiment of this application;

[0032] Figure 13 This is a schematic diagram of another business application rule generation device disclosed in an embodiment of this application;

[0033] Figure 14 This is a schematic diagram of the structure of a computer device disclosed in an embodiment of this application. Detailed Implementation

[0034] This application provides a method for generating business application rules, a device for generating business application rules, a computer device, a computer-readable storage medium, and a computer program product containing instructions or computer programs, which can generate business application rules while improving the accuracy, efficiency, and timeliness of business application rule generation.

[0035] Please see Figure 1 One architecture of the business application rule generation system 100 in this application embodiment includes:

[0036] The system includes a computer device (used for generating business application rules) 101 and a client 102. When generating business application rules, the computer device 101 can connect to the client 102. The computer device 101 can obtain target metadata entities related to changes in business policies, input these target metadata entities into a large model, and obtain the first target application rule corresponding to the target metadata entity output by the large model. If it is determined that the first target application rule does not exist in the preset business rule base, the computer device 101 can send the first target application rule to the client 102.

[0037] based on Figure 1 Please refer to the business application rule generation system shown. Figure 2 , Figure 2 This is a flowchart illustrating a business application rule generation method disclosed in an embodiment of this application. The method includes:

[0038] 201. Obtain the target metadata entity related to changes in business policies.

[0039] In this embodiment, when generating business application rules, target metadata entities related to changes in business policies can be obtained.

[0040] Specifically, computer equipment refers to high-performance computing devices used for storing, managing, and processing large amounts of data and providing services. It is responsible for receiving, processing, and storing business declaration rules and data related to business declarations. For example, computer equipment could be the server of a tax cloud platform. Specifically, target metadata entities refer to key information units reflecting changes in business policies. These are typically structured data containing important parameters, conditions, rule configurations, or attribute descriptions related to changes in business processes, serving as the foundational data support for generating business declaration rules. For example, target metadata entities could be project rule configuration information.

[0041] To be more specific, for example, when generating business declaration rules, seven items (target metadata entities) related to changes in individual income tax policies can be obtained, two of which are newly added items.

[0042] 202. Input the target metadata entity into the large model. The large model performs the following steps: Determine the initial declaration rule information from the preset knowledge base that matches the target metadata entity to a preset matching threshold.

[0043] After obtaining the target metadata entity related to the business policy change, the target metadata entity can be input into the large model. The large model performs the following steps: determine the initial declaration rule information from the preset knowledge base that matches the target metadata entity to a preset matching threshold.

[0044] Specifically, the large model refers to a large language model, which can be a large model using Retrieval-Augmented Generation (RAG). RAG technology is a supplement to the capabilities of the large model. By introducing a retrieval mechanism, it can query and integrate previously stored professional knowledge, such as tax regulations and case examples, during the generation process. This makes the generated rules closer to the actual situation and avoids errors or inaccuracies that may be caused by the lack of background knowledge in the large model.

[0045] Specifically, the preset knowledge base includes data retrieval rules and declaration calculation rules. More specifically, for example, it can determine initial declaration rules from the preset knowledge base that match the two newly added projects (target metadata entities) to a preset matching threshold.

[0046] 203. Output the first target declaration rule corresponding to the target metadata entity based on the initial declaration rule information.

[0047] After determining the initial declaration rule information from the preset knowledge base that matches the target metadata entity to a preset matching threshold, the first target declaration rule corresponding to the target metadata entity can be output based on the initial declaration rule information.

[0048] Specifically, based on the initial declaration rule information corresponding to these two new projects, the first target declaration rule corresponding to the target metadata entity can be output.

[0049] In this embodiment, initial declaration rule information with a high degree of matching with the target metadata entity can be obtained. Then, a first target declaration rule is generated based on the initial declaration rule information with a high degree of matching. Because the matching accuracy is high, the generated first target declaration rule has high accuracy. Secondly, this embodiment generates business declaration rules based on a large model, which does not require manual rule configuration, so there is no situation of omission or error in manual configuration. In summary, the accuracy of business declaration rule generation in this embodiment is high. Furthermore, generating business declaration rules through a large model avoids the tedious process of manual configuration of each rule in traditional methods, greatly reducing configuration costs and time required, and making the process of generating business declaration rules faster. Therefore, the efficiency of business declaration rule generation is high. Furthermore, due to the reduction of human intervention, the system response speed is faster, and the generation of business declaration rules is not affected by the lag of human operation. Therefore, the timeliness of business declaration rule generation is high.

[0050] In this embodiment of the application, when there is information about changes in business policies, the business application rule corresponding to the information about the changes in business policies can be determined by the method of "determining initial application rule information and outputting the first target application rule corresponding to the target metadata entity based on the initial application rule information". Specifically, there are multiple methods for determining the business application rule corresponding to the information about the changes in business policies. For example, the generated first target application rule can be directly used as the business application rule corresponding to the information about the changes in business policies, or the first target application rule can be further processed to obtain the business application rule corresponding to the information about the changes in business policies. Different processing methods can be selected according to different actual situations. Figure 2 The methods for generating business application rules are shown below, and three of them are described in detail below:

[0051] In this embodiment, the system is applied to computer equipment. When generating business application rules, it can obtain target metadata entities related to changes in business policies.

[0052] Specifically, for example, the computer equipment is the server of the tax cloud platform, the target metadata entity can be understood as the project rule configuration information, and the target website is the tax website.

[0053] The methods for obtaining target metadata entities related to changes in business policies may include, but are not limited to, the following two methods:

[0054] (1) Monitor changes in business policies in real time to obtain target metadata entities on a regular basis.

[0055] First, obtain real-time information on changes to the target website's business policies. Then, based on these changes, periodically obtain the business policy change documents and transform them to obtain the target metadata entity.

[0056] For example, a tax website may include information on changes in personal income tax policies. Previously, there were only five items, but now two new items have been added, making a total of seven items. Since rules for these seven items need to be generated, these two new items can be used as metadata entities.

[0057] Please see Figure 3 , Figure 3 This is a schematic diagram of the tax interface of a tax website disclosed in an embodiment of this application. Figure 3It is known that one can inquire about specific information regarding certain new policies on the website of the "×× Tax Administration Department" and receive corresponding responses. These responses include target metadata entities related to the policy changes. For example, an inquiry like "What are the criteria for defining ordinary and non-ordinary residential properties in ×× Province, ×× City, ×× District? Actual transaction price? Building area?" will yield a response like "The criteria for ordinary housing enjoying preferential policies in ×× Province are: a residential community building plot ratio of 1.0 or higher, a single unit internal building area of ​​120 square meters or less, or a single unit building area of ​​144 square meters or less, and an actual transaction price less than 1.44 times the average transaction price of housing on land of the same level." The metadata entities could be likened to "the criteria for ordinary housing, a residential community building plot ratio of 1.0 or higher, and a single unit internal building area of ​​120 square meters or less, or a single unit building area of ​​144 square meters or less."

[0058] It is worth mentioning that the target metadata entity can be obtained in real time and periodically, thus improving the timeliness, accuracy and efficiency of obtaining the target metadata entity.

[0059] (2) Determine the target metadata entity by determining whether the first ticket has the target business parameters.

[0060] First, periodically compare the business parameters of the first and second bills in the bill database. The creation time of the first bill is later than that of the second bill. If the first bill has the target business parameter and the second bill does not, then the target business parameter is used as the target metadata entity.

[0061] Specifically, a scan can be performed in the invoice database (such as invoices, vouchers, and other business data). Each invoice is compared with previous historical invoices in terms of various parameters (such as whether and how many of each item is the same, such as the commodity code) to determine whether there are invoices for new business. If there are invoices for new business, the new metadata entity corresponding to the invoices for new business is used as the target metadata entity.

[0062] More specifically, the second ticket can be used as a historical ticket. For example, the second ticket has five business parameters, and the first ticket has seven business parameters. Five of these business parameters are the same as those of the second ticket, while the other two business parameters are unique to the second ticket and do not exist in the second ticket. Therefore, the other two business parameters (target business parameters) can be used as target metadata entities.

[0063] It is worth mentioning that historical invoices can reflect existing reporting rules to some extent. When the first invoice contains a target business parameter that is not present in the historical invoice, it can be determined to some extent that the target business parameter is a target metadata entity related to policy changes. Therefore, determining whether the first invoice contains a target business parameter to identify the target metadata entity has certain reference value and can improve the efficiency and accuracy of obtaining target metadata entities related to policy changes from the target website.

[0064] After obtaining the target metadata entity related to the business policy change, the target metadata entity can be input into the large model.

[0065] Specifically, the large model refers to a large language model, which can be a large model using Retrieval-Augmented Generation (RAG). RAG technology is a supplement to the capabilities of the large model. By introducing a retrieval mechanism, it can query and integrate previously stored professional knowledge, such as tax regulations and case examples, during the generation process. This makes the generated rules closer to the actual situation and avoids errors or inaccuracies that may be caused by the lack of background knowledge in the large model.

[0066] After the target metadata entity is input into the large model, the large model performs the following steps: it determines the initial declaration rule information from the preset knowledge base that matches the target metadata entity to a preset matching threshold.

[0067] Specifically, the initial declaration rule information can be determined based on a preset matching algorithm (including text similarity algorithms, such as cosine similarity or BM25 algorithm, etc.) to determine the degree of matching with the target metadata entity that reaches the preset matching degree threshold.

[0068] The method for determining the initial declaration rule information that matches the target metadata entity to a preset matching threshold from the preset knowledge base can be as follows: First, determine the first declaration rule information that matches the target metadata entity to a preset matching threshold from the first knowledge base. The first declaration rule information includes basic data retrieval rule information and basic declaration calculation rule information related to the target metadata entity. Then, determine the second declaration rule information that matches the target metadata entity to a preset matching threshold from the second knowledge base. The second declaration rule information includes change data retrieval rule information and change declaration calculation rule information related to the target metadata entity. Finally, obtain the initial declaration rule information based on the first and second declaration rule information. The preset knowledge base includes the first knowledge base and the second knowledge base.

[0069] Specifically, before inputting the target metadata entities into the large model, the large model needs to be developed in advance. For large model development, a knowledge base can be developed in advance; that is, a rich and high-quality knowledge base can be pre-configured on the tax cloud platform. The knowledge base includes a static document knowledge base and a dynamic knowledge base (which allows real-time querying of business and other data via APIs). For more details, please refer to [link to relevant documentation]. Figure 4 , Figure 4 This is a schematic diagram of a knowledge base development sub-interface disclosed in an embodiment of this application. Figure 4 It is known that after logging into the tax cloud platform, users can enter the main interface for large model development and the sub-interface for knowledge base development in sequence. Then, in the sub-interface for knowledge base development, users can create or modify the declaration rule information for each declaration form category in the tax cloud data source knowledge base (such as the tax cloud data retrieval rule data source knowledge base).

[0070] More specifically, the basic data retrieval rules and basic declaration calculation rules mainly concern routine operations under conditions other than policy changes. Basic data retrieval rules involve how to extract data from the original data source and which fields are key declaration elements. Basic declaration calculation rules involve how to perform basic mathematical operations or logical judgments based on this data to form preliminary basic declaration rules. For example, basic declaration calculation rules might include calculation formulas for deducting personal tax exemptions for different income tiers, while basic data retrieval rules might include various data retrieval rules required when calculating based on these formulas. Change-based data retrieval rules involve data acquisition methods that may be affected by policy changes, such as adjustments to new tax rates or new tax deductions. These change-based rules describe how to modify or add data retrieval steps to reflect the new regulations when policies change. Change-based declaration calculation rules specifically address declaration strategies and calculation methods after policy changes. For example, calculation rules might involve how to apply preferential conditions under new policies and how to adjust existing tax exemption calculation formulas. In summary, the basic rules focus on general situations, while the variable rules are customized to address specific policy changes. Together, they ensure the integrity and compliance of the filing rules. When there are policy changes, the knowledge base can respond quickly and provide the latest filing guidance. It can provide a high-quality and rich tax knowledge base, improving the automation and accuracy of the filing process.

[0071] After determining the initial declaration rule information from the preset knowledge base that matches the target metadata entity to a preset matching threshold, the first target declaration rule corresponding to the target metadata entity can be output based on the initial declaration rule information.

[0072] Specifically, for example, if the target metadata entity is "Rule: ××; Name: Product Name; Export Business: No (determines whether it is 0%); Tax Business Classification: Invoice Provision; Collection Method: Determined based on tax rate; Tax Rate: 13%, directly output; Invoice Type determines whether it is a special VAT invoice or other invoices; Data Source: Sales Invoice Pool; Amount Field: Total Amount; Filtering Condition: Filtered based on the product name or product code of the invoice.", then the first target declaration rule output by the large model is "{rulename: Export Business, ruletype: aaa, rate: 13%, datasource: s im_vat invoice, amountfield: total amount, fi lter: {{id: 1, index: 1, fi lterfield: name, fi ltertype: equals, fi ltervalue: product name, logic: or}, {id: 2, index: 2, fi lterfield: number ...value: number, logic: number, logic: number}, {id: 2, index: 2, index: number, logic: number, logic: number}, {id: 2, index: number}, {id: 2, index: number}, {id: 2 "ltervalue:productnumber,logic:}}}" can generate and output the first target declaration rule corresponding to the target metadata entity.

[0073] It is understandable that when a target website contains information about policy changes, the reporting rules corresponding to the policy change information can be determined and output using the method of "determining the initial reporting rule information and outputting the first target reporting rule corresponding to the target metadata entity based on the initial reporting rule information." Specifically, the methods for determining and outputting the reporting rules corresponding to the policy change information may include, but are not limited to, the following three methods:

[0074] First, the large model matches and generates the first target declaration rule based on prompt words. The generated first target declaration rule can be directly used as the declaration rule corresponding to the policy change information. Alternatively, the first target declaration rule can be verified first, and the verification result can be used to determine whether the first target declaration rule can be directly used as the declaration rule corresponding to the policy change information, or whether other processing is required to generate the declaration rule corresponding to the policy change information.

[0075] Specifically, for large model development, prompt words can be developed in advance; please refer to [link / reference]. Figure 5 , Figure 5 This application discloses a prompt word development sub-interface, which is... Figure 5It is known that large model parameters can be configured, such as configuring a large model and configuring the model style of the large model (such as precision, etc.). Prompt words can be edited, such as "## It is known that the main table of the declaration form is tcci t_query_report, the header comparison start time field is skssqq with a value of #startDate, the end time field is skssqz with a value of #endDate, the organization field is org with a value of #orgid, the declaration form type field is type with a value of "prepayment declaration" = "qysdsjb" (string type), and the declaration form declaration status field is declarestatus with a value of "declared successfully" = "declared". Business table: {{table}}, Amount field: {{amount}}; ## Please output the following requirements using a query statement expression; ## 1, Format requirements: The expression is marked as a query statement by {M[]}, such as querying the latest period's accrual draft, draft status: audited tax summary table amount field: {M[select sumamount from tccit_calc_det_sjjt where org='#orgid'AND skssqq='#latestSkssqq'and skssqz='#latestSkssqz']};##2. Each query statement must include the org.skssqq.skssqz field condition;##3. It is necessary to first find the value of the id field from the main table of the declaration form, and then query the amount field based on the sbbid field value of the business table being equal to the id of the main table...”, and variables can also be set. After developing the prompt words, the large model can be orchestrated and released by combining the pre-developed knowledge base and pre-developed prompt words. Please refer to the following for details. Figure 6 , Figure 6 This is a schematic diagram illustrating a large model release process disclosed in an embodiment of this application. Figure 6 As can be seen, users can input tax-related information (such as tax assistant information) through the large model publishing interface. Then, based on the pre-developed knowledge base and prompts, the large model will execute tasks according to the preset orchestration steps. It is worth mentioning that this orchestration and publishing mechanism simplifies the process of generating and applying business declaration rules, and improves the efficiency of business declaration rule generation.

[0076] Please refer to the details. Figure 7 , Figure 7 This is a schematic diagram of a declaration item rule configuration list interface disclosed in an embodiment of this application. Figure 7 As can be seen, the declaration item rule configuration list interface includes the generated first target declaration rules. These first target declaration rules can be directly used as the declaration rules corresponding to the policy change information, or they can be further configured to obtain the declaration rules corresponding to the policy change information.

[0077] 1. The large model matches and generates based on prompt words, and directly uses the generated first target declaration rule as the declaration rule corresponding to the policy change information.

[0078] Specifically, the first prompt word can be obtained first and input into the large model. The first prompt word is used to characterize the demand characteristics of generating declaration rules. Then, based on the first prompt word, the first declaration rule information that matches the target metadata entity to a preset matching degree threshold is determined from the preset knowledge base. The first declaration rule information is the initial declaration rule information. Finally, based on the first prompt word and the initial declaration rule information, the first target declaration rule corresponding to the target metadata entity is generated and output.

[0079] To be more specific, for example, the first prompt could be "generate declaration rules in a preset format based on metadata entities." It's worth noting that using prompts can improve the accuracy and efficiency of matching and generating business declaration rules.

[0080] 2. The large model is based on prompt words for matching and generation. If the first target declaration rule is not qualified, the first target declaration rule will be matched and generated again for prompt words to generate the declaration rule corresponding to the policy change information.

[0081] Specifically, the first prompt word can be obtained first and input into the large model. The first prompt word is used to characterize the demand characteristics of generating declaration rules. Then, based on the first prompt word, the first declaration rule information that matches the target metadata entity to a preset matching degree threshold is determined from the preset knowledge base. The first declaration rule information is the initial declaration rule information. Finally, based on the first prompt word and the initial declaration rule information, the first target declaration rule corresponding to the target metadata entity is generated.

[0082] After generating the first target declaration rule corresponding to the target metadata entity based on the first prompt word and the initial declaration rule information, the first target declaration rule can be verified according to preset standard conditions to obtain the verification result. If the first target declaration rule does not meet the preset standard conditions, a second prompt word is obtained. The second prompt word is a prompt word determined based on the verification result and the first target declaration rule. Then, based on the second prompt word, the second declaration rule information that matches the target metadata entity to a preset matching degree threshold is determined from the preset knowledge base. Finally, based on the second prompt word and the second declaration rule information, the second target declaration rule corresponding to the target metadata entity is generated.

[0083] More specifically, the preset standard conditions include, but are not limited to, requirements on format. For example, if the first prompt is "generate the declaration rule in the target format based on metadata entities", and the verification finds that the format is incorrect, then the corresponding second prompt is generated: "convert the format of the first target declaration rule to the target format".

[0084] It is worth mentioning that the first target declaration rule can be verified, and a more targeted second prompt word can be determined based on the verification result and the first target declaration rule. The large model can then use the second prompt word to perform further targeted matching and generation of declaration rules. Therefore, by verifying and using prompt words twice, the illusion problem of the large model can be solved, and the accuracy and efficiency of the matching and generation of declaration rules can be improved.

[0085] Second, based on the specific matching of the target rule name and the preset application rules in the preset business rule library (including the first target application rule that meets the preset saving conditions), determine whether further configuration of differential configuration items is required to generate application rules corresponding to the policy change information.

[0086] Specifically, the matching between the target rule name and the preset application rules in the preset business rule library can be determined based on text similarity algorithms (including cosine similarity, Jaccard similarity, or Levenshtein distance, etc.). The preset saving conditions can refer to situations where the first target application rule is relatively common and can be pushed to the preset business rule library, or other reasonable preset saving conditions.

[0087] 1. If a highly matching preset declaration rule can be found, no further configuration of the difference configuration items is required. The highly matching preset declaration rule can be directly used as the declaration rule corresponding to the policy change information.

[0088] Specifically, a rule query request can be obtained first. The rule query includes the name of the target rule. Then, the similarity between the name of the preset declaration rule in the preset business rule library and the name of the target rule can be determined. The preset declaration rules include the first target declaration rule that meets the preset storage conditions. If there is a first preset declaration rule with a similarity that reaches the first preset similarity threshold, then the first preset declaration rule is used as the third preset declaration rule corresponding to the rule query request. The third preset declaration rule is the declaration rule corresponding to the information of policy change.

[0089] More specifically, the method of obtaining a rule query request can be either the rule query request generated by the server of the tax cloud platform after the user enters the target rule name in the query interface, or the rule query request sent by the client (tenant) obtained by the server of the tax cloud platform.

[0090] To be more specific, for example, if the target rule name is "Individual Income Tax Handling Fee Refund", then the configured rule filtering conditions are: the summary is "Individual Income Tax Handling Fee Refund", and the configured matching method field is "Exact Similarity Matching". This will match highly matching declaration rules corresponding to "Individual Income Tax Handling Fee Refund" and "Individual Income Tax Refund" (the first preset declaration rules with similarity reaching the first preset similarity threshold). Then, the declaration rules corresponding to "Individual Income Tax Handling Fee Refund" and "Individual Income Tax Refund" can be directly used as the third preset declaration rules corresponding to the rule query request.

[0091] For another example, please refer to [link / reference]. Figure 8 , Figure 8 This is a schematic diagram of a preset application rule display interface disclosed in an embodiment of this application. Figure 8 It can be seen that the target rule name is "AAA Value-Added Tax Special Invoice", and the preset declaration rule display interface includes multiple data retrieval rules.

[0092] 2. If a highly matched preset declaration rule cannot be found, but a moderately matched preset declaration rule can be found, further configuration of the differential configuration items for the moderately matched preset declaration rule is required to obtain the declaration rule corresponding to the policy change information.

[0093] Specifically, a rule query request can be obtained first, which includes the name of the target rule. Then, the similarity between the name of the preset declaration rule in the preset business rule library and the name of the target rule can be determined. The preset declaration rules include the first target declaration rule that meets the preset storage conditions. If there is no first preset declaration rule with a similarity reaching the first preset similarity threshold, but there is a second preset declaration rule with a similarity reaching the second preset similarity threshold, then after obtaining the configuration information of the difference configuration item, a third preset declaration rule corresponding to the rule query request can be generated based on the configuration information and the second preset declaration rule. The configuration information is the information determined based on the similarity between the second preset declaration rule and the second preset declaration rule, and the third preset declaration rule is the declaration rule corresponding to the policy change information.

[0094] To be more specific, for example, if the target rule is named "Individual Income Tax Handling Fee Refund", and only the preset declaration rule "Reinvestment Tax Refund" with a moderate match (the second preset declaration rule with a similarity reaching the second preset similarity threshold) can be matched, then further configuration of the differential configuration items of the preset declaration rule "Reinvestment Tax Refund" is required to obtain the declaration rule corresponding to the policy change information.

[0095] (1) If a highly matched preset declaration rule cannot be matched, but a moderately matched preset declaration rule can be matched, then the moderately matched preset declaration rule will be further configured with different configuration items through manual configuration in order to obtain the declaration rule corresponding to the policy change information.

[0096] Specifically, a rule retrieval request can be obtained first, which includes the name of the target rule. Then, the similarity between the name of the preset declaration rule in the preset business rule library and the name of the target rule can be determined. The preset declaration rules include the first target declaration rule that meets the preset storage conditions. If there is no first preset declaration rule with a similarity reaching the first preset similarity threshold, but there is a second preset declaration rule with a similarity reaching the second preset similarity threshold, the configuration information of the difference configuration items can be obtained through manual configuration. Then, based on the configuration information and the second preset declaration rule, the third preset declaration rule corresponding to the rule query request can be generated. The configuration information is the information determined based on the similarity between the second preset declaration rule and the second preset declaration rule. The third preset declaration rule is the declaration rule corresponding to the policy change information.

[0097] To be more specific, for example, if the target rule is named "Personal Income Tax Handling Fee Refund", and only the preset declaration rule "Reinvestment Tax Refund" with a moderate match (the second preset declaration rule with a similarity reaching the second preset similarity threshold) can be matched, then the configuration information of the difference configuration items (such as the configuration information of the other two items) can be obtained through manual configuration. Then, based on the configuration information and the second preset declaration rule, the third preset declaration rule corresponding to the rule query request can be generated. The configuration information is the information determined based on the similarity between the second preset declaration rule and the second preset declaration rule, and the third preset declaration rule is the declaration rule corresponding to the policy change information.

[0098] (2) If a highly matched preset declaration rule cannot be matched, but a moderately matched preset declaration rule can be matched, the large model will configure the differential configuration items of the moderately matched preset declaration rule through prompt words to obtain the declaration rule corresponding to the policy change information.

[0099] Specifically, a rule query request can be obtained first, which includes the name of the target rule. Then, the similarity between the name of the preset declaration rule in the preset business rule library and the name of the target rule can be determined. The preset declaration rules include the first target declaration rule that meets the preset storage conditions. If there is no first preset declaration rule with a similarity reaching the first preset similarity threshold, but there is a second preset declaration rule with a similarity reaching the second preset similarity threshold, the large model can further configure the difference configuration items of the second preset declaration rule through prompt words to generate the third preset declaration rule corresponding to the rule query request. The configuration information is based on the information determined by the similarity between the second preset declaration rule and the second preset declaration rule. The third preset declaration rule is the declaration rule corresponding to the policy change information.

[0100] To be more specific, for example, if the target rule is named "Personal Income Tax Handling Fee Refund", and only the preset declaration rule "Reinvestment Tax Refund" with a moderate match (the second preset declaration rule with a similarity reaching the second preset similarity threshold) can be matched, then the large model can use prompt words, such as "Add two more items to the preset declaration rule "Reinvestment Tax Refund" to generate a new declaration rule", to further configure the differential configuration items of the preset declaration rule "Reinvestment Tax Refund" to obtain the declaration rule corresponding to the policy change information.

[0101] It is worth mentioning that in this embodiment of the application, when there is a policy change, the corresponding declaration rules can be generated in a timely manner. Under normal circumstances, these rules are saved in a preset business rule library. When a user needs to use the declaration rules corresponding to the new policy, they can search for them in the preset business rule library using a query tool. Since users usually cannot remember the complete name of each declaration rule in the preset business rule library, but can only remember the approximate name, after obtaining the name of the target rule, the semantic retrieval query method can quickly find the preset declaration rules with high similarity. Therefore, compared with the method of manually searching one by one, the semantic retrieval query method can improve the efficiency and accuracy of declaration rule query.

[0102] Secondly, the preset business rule base does not include all application rules corresponding to new policies (policy changes). There may be various reasons why the preset business rule base does not include application rules corresponding to policy changes. For example, if the generated application rules do not meet the preset standard conditions (format, etc.), they will not be saved to the preset business rule base. Or, if the system malfunctions, application rules that meet the preset standard conditions will not be saved to the preset business rule base. Or, the system has not yet had time to generate application rules corresponding to policy changes, so the preset business rule base naturally does not include application rules corresponding to policy changes. However, even if a semantic search query based on the target rule name does not find a preset application rule with high similarity (high matching), it is possible to obtain the application rule corresponding to the policy change based on the preset application rules with medium similarity (medium matching) that can be found at present, combined with the manual configuration of the difference configuration items and / or the remedial method generated by the large model matching. Therefore, the method of further configuring the difference configuration items of the medium matching preset application rules to obtain the application rules corresponding to the policy change information can achieve a high overall effect that balances rule search efficiency, rule search accuracy, rule generation efficiency, and rule generation accuracy.

[0103] Third, based on Natural Language Processing (NLP) technology, keywords with high similarity (matching degree) to target metadata are searched in the preset knowledge base. The keywords are understood and reasoned to construct the first target declaration rule corresponding to the target metadata entity.

[0104] Specifically, based on the similarity (matching degree) algorithm, keywords with high similarity (matching degree) to the target metadata can be searched in the preset knowledge base to identify potential initial declaration rule clues (initial declaration rule information). Then, based on the initial declaration rule clues, NLP is used to understand the meaning of these initial declaration rule clues in order to generate and output declaration rules (first target declaration rules) that are closely related to the target metadata.

[0105] It is worth mentioning that by using NLP to understand and parse natural language text, identify key information, and then automatically construct suitable reporting rules, the workload and time cost of manual intervention are greatly reduced.

[0106] After obtaining the first target declaration rule output by the large model, it can be determined whether to send the first target declaration rule to the client, and the specific implementation method for sending the first target declaration rule to the client, based on whether the first target declaration rule exists in the preset business rule base.

[0107] Specifically, if the first target declaration rule does not exist in the preset business rule base, then the first target declaration rule will be sent to the client. Please refer to [link to relevant documentation]. Figure 9 , Figure 9 This is a flowchart illustrating another method for generating business application rules disclosed in an embodiment of this application. Figure 9 It is known that the official website of the tax administration department can be monitored. When there are changes in information, the system can prompt the information changes. After confirming the collection of the latest documents, the latest data is collected to generate rules through a large language model. Then the system verifies whether there are differences between the rules and historical data. If there are differences (i.e., the first target declaration rule does not exist in the preset business rule library), the update can be confirmed.

[0108] Specifically, the methods for sending the first target declaration rules to the client may include, but are not limited to, the following two methods:

[0109] (1) Directly send the first target declaration rules to all authorized clients.

[0110] The first target declaration rule is sent to the target client, which has the necessary permissions.

[0111] It is worth mentioning that the rules can be sent directly to authorized clients, allowing them to apply the new reporting rules without additional confirmation, saving time and improving the efficiency of business process execution.

[0112] (2) First, send a rule difference notification to the client, and only send the first target declaration rule to the client that returns the update request.

[0113] If the first target declaration rule does not exist in the preset business rule library, a rule difference notification is sent to the target client. After receiving the update request corresponding to the rule difference notification returned by the target client, the first target declaration rule is sent to the target client. The rule difference notification is used to indicate that the first target declaration rule does not exist in the preset business rule library.

[0114] Specifically, monitoring tools can be used to monitor documents on the official website of the tax administration department in real time. If the documents have been changed, a pop-up prompt will appear asking, "There is a policy change. Confirm whether to collect the latest policy?" After the user clicks to confirm collection, the latest tax policy content can be collected through a web crawler system. The system will then generate rule content (in JSON format) using a large language model and send a callback to the tax system. The tax system can then parse the JSON data, query the project rule table, and perform precise rule matching (i.e., determine whether the first target declaration rule does not exist in the preset business rule library). If there is a discrepancy, a discrepancy notification will be sent, asking, "A rule needs to be changed. Do you want to update?" After the user clicks to confirm the update, the latest rule data will be updated into the database.

[0115] It's worth mentioning that the latest rule data is only updated into the database after the user clicks to confirm the update. This allows for manual review of the model to ensure the accuracy of the generated rules. Furthermore, allowing users to confirm the data update themselves before it is updated can avoid disputes arising from the system automatically updating user data.

[0116] Understandably, the first target declaration rules can be sent to the client via methods such as API (Application Programming Interface).

[0117] After obtaining the first target declaration rule output by the large model, the first target declaration rule can be converted into a dynamic document object and rendered on the page using a self-developed deserialization tool.

[0118] Specifically, the first target declaration rules can be converted using a self-developed deserialization tool to obtain form objects. The generated form objects constitute the basic document of the declaration rules. The rule data can be structured to facilitate display and operation on web pages, and can be further used for business processing or report creation.

[0119] Please refer to the details. Figure 10 , Figure 10 This is a schematic diagram of an application rules page disclosed in an embodiment of this application. Figure 10 As can be seen, the declaration rules page displays revenue rules, which include various data retrieval rules. The rules page has a "Save as preset declaration rule" button. After clicking this button, the user can save the revenue rule to the preset business rule library.

[0120] It is worth mentioning that, in order to facilitate understanding of the unique features or improvements of the business declaration rule generation method in this application embodiment, the business declaration rule generation method in this application embodiment will be compared with existing business declaration rule generation methods below. Please refer to the following description for details:

[0121] The existing process for generating business declaration rules involves an implementation consultant logging into the tax cloud platform, summarizing the rules based on research findings, and then manually configuring the declaration rules. More specifically, this requires the delivery consultant to analyze and summarize the rules based on the research results, and then manually configure them into the system one by one. After delivery, if the client's business or regulations change, and rules need to be added or modified, the delivery consultant needs to re-enter the system or someone familiar with the client's system needs to perform the operation. This is inconvenient for tax and finance personnel who use the system daily, and it can easily lead to them abandoning the system and directly submitting declarations through the tax bureau's system, which is detrimental to the system's future renewal fees.

[0122] Therefore, existing methods for generating business declaration rules rely on manual compilation and input. When configuring each rule manually, the probability of omissions and errors is high, resulting in low accuracy. Furthermore, when changes in business or regulations require extensive rule adjustments, manual configuration is necessary, leading to high costs and low efficiency. Moreover, these methods are inconvenient for tax and finance personnel who use the system daily, potentially leading to them abandoning the system and submitting declarations directly through the tax bureau's system. This hinders future system renewals. In other words, due to low efficiency and delayed human intervention, the timeliness of business declaration rule generation is low.

[0123] The process of the business declaration rule generation method in this application embodiment is as follows: First, a large model is developed, including a pre-built knowledge base, writing prompt words, developing custom operations, task orchestration, and publishing assistant. After the large model is developed, the target metadata entity can be obtained through natural language input and / or scanning tax-related data to obtain change data. Then, text similarity retrieval is performed to generate rule code (JSON), which is finally converted into a Sky Form dynamic object. For specific implementation details, please refer to [link to specific implementation details]. Figure 11 , Figure 11 This is a flowchart illustrating another method for generating business application rules disclosed in an embodiment of this application. Figure 11 The description outlines two implementation options. Option 1: Implementation consultants log into the tax cloud platform and use the AI ​​assistant to access pre-set statements for convenient interaction. They input their research findings into the large model, which then translates the statements and automatically generates declaration rules. Option 2: The tax cloud platform can schedule tasks to scan tax-related data. If business changes are identified based on the scan results, the large model automatically generates declaration rules, which take effect after review.

[0124] It is understood that the business declaration rule generation method in this application embodiment also includes Scheme 3. Scheme 3 provides a scenario: when a user needs to manually add a rule, the name entered by the user can be vectorized, and the rule corresponding to the most similar name can be found through similarity. The system automatically copies the rule content. That is to say, when the user actually configures the rule, he only needs to enter the name, and the rule with the highest name similarity will be automatically brought out. The large model interface is called to match the rule with the highest name similarity in the pre-made rule library. Secondly, the difference configuration items can also be configured to obtain the declaration rule required by the user.

[0125] It is understandable that, compared with existing business application rule generation methods, the business application rule generation method of this application embodiment generates a first target application rule with higher accuracy, higher efficiency, and higher timeliness, and can achieve an overall effect that balances rule search efficiency, rule search accuracy, rule generation efficiency, and rule generation accuracy.

[0126] In this embodiment, initial declaration rule information with a high degree of matching with the target metadata entity can be obtained. Then, a first target declaration rule is generated based on the initial declaration rule information with a high degree of matching. Because the matching accuracy is high, the accuracy of the generated first target declaration rule is high. Secondly, this embodiment generates business declaration rules based on a large model, which does not require manual rule configuration. Therefore, there is no situation of omission or error in manual configuration. In summary, the accuracy of business declaration rule generation in this embodiment is high. Furthermore, generating business declaration rules through a large model avoids the tedious process of manual compilation and configuration in traditional methods, greatly reducing the cost and time required for compilation and configuration. The process of generating business declaration rules is faster, so the efficiency of business declaration rule generation is high. Furthermore, due to the reduction of human intervention, the system response speed is faster, and the generation of business declaration rules is not affected by the lag of human operation. Therefore, the timeliness of business declaration rule generation is high. In addition, it can achieve an overall effect of high rule search efficiency, rule search accuracy, rule generation efficiency, rule generation accuracy, and rule generation timeliness.

[0127] It is understandable that, in addition to the method of generating business declaration rules through a large model as described above, there are also methods that generate rules by parsing strings in code, or other reasonable methods, which are not limited here.

[0128] The above describes the business declaration rule generation method in the embodiments of this application. The following describes the business declaration rule generation apparatus in the embodiments of this application. Please refer to [link / reference]. Figure 12 One embodiment of the business declaration rule generation device in this application includes:

[0129] Acquisition unit 1201 is used to acquire target metadata entities related to changes in business policies;

[0130] Input unit 1202 is used to input the target metadata entity into the large model, and the large model performs the following steps: determining the initial declaration rule information from the preset knowledge base that matches the target metadata entity to a preset matching degree threshold;

[0131] The output unit 1203 is used to output the first target declaration rule corresponding to the target metadata entity based on the initial declaration rule information.

[0132] In this embodiment, initial declaration rule information with a high degree of matching with the target metadata entity can be obtained. Then, a first target declaration rule is generated based on the initial declaration rule information with a high degree of matching. Because the matching accuracy is high, the generated first target declaration rule has high accuracy. Secondly, this embodiment generates business declaration rules based on a large model, which does not require manual rule configuration, so there is no situation of omission or error in manual configuration. In summary, the accuracy of business declaration rule generation in this embodiment is high. Furthermore, generating business declaration rules through a large model avoids the tedious process of manual compilation and configuration in traditional methods, greatly reducing the cost and time required for compilation and configuration, and making the process of generating business declaration rules faster. Therefore, the efficiency of business declaration rule generation is high. Furthermore, due to the reduction of human intervention, the system response speed is faster, and the generation of business declaration rules is not affected by the lag of human operation. Therefore, the timeliness of business declaration rule generation is high.

[0133] The business declaration rule generation device in this application embodiment is described in detail below. Please refer to [link / reference]. Figure 13 Another embodiment of the business declaration rule generation device in this application includes:

[0134] Acquisition unit 1301 is used to acquire target metadata entities related to changes in business policies;

[0135] Input unit 1302 is used to input the target metadata entity into the large model, and the large model performs the following steps: determining the initial declaration rule information from the preset knowledge base that matches the target metadata entity to a preset matching degree threshold;

[0136] Output unit 1303 is used to output the first target declaration rule corresponding to the target metadata entity based on the initial declaration rule information.

[0137] The input unit 1302 is specifically used to determine, from the first knowledge base, first declaration rule information whose matching degree with the target metadata entity reaches a preset matching degree threshold, the first declaration rule information including basic data retrieval rule information and basic declaration calculation rule information related to the target metadata entity; and to determine, from the second knowledge base, second declaration rule information whose matching degree with the target metadata entity reaches a preset matching degree threshold, the second declaration rule information including change data retrieval rule information and change declaration calculation rule information related to the target metadata entity; and to obtain the initial declaration rule information based on the first declaration rule information and the second declaration rule information. The preset knowledge base includes a first knowledge base and a second knowledge base.

[0138] The acquisition unit 1301 is further configured to acquire a first prompt word and input the first prompt word into the large model, wherein the first prompt word is used to characterize the requirement characteristics for generating the declaration rules;

[0139] The input unit 1302 is specifically used to determine, based on the first prompt word, a first declaration rule information that matches the target metadata entity to a preset matching degree threshold from the preset knowledge base, wherein the first declaration rule information is the initial declaration rule information;

[0140] The output unit 1303 is specifically used to output the first target declaration rule corresponding to the target metadata entity based on the first prompt word and the initial declaration rule information.

[0141] The business application rule generation device also includes:

[0142] The verification unit 1304 is used to verify the first target declaration rule according to preset standard conditions and obtain the verification result;

[0143] The acquisition unit 1301 is further configured to obtain a second prompt word if the first target declaration rule does not meet the preset standard conditions, wherein the second prompt word is a prompt word determined based on the verification result and the first target declaration rule;

[0144] The input unit 1302 is further configured to determine, based on the second prompt word, second declaration rule information from the preset knowledge base that matches the target metadata entity to a preset matching degree threshold.

[0145] The output unit 1303 is further configured to output the second target declaration rule corresponding to the target metadata entity based on the second prompt word and the second declaration rule information.

[0146] The acquisition unit 1301 is specifically used to acquire the business policy changes of the target website in real time, acquire the business policy change documents periodically based on the business policy changes, and convert the business policy change documents to obtain the target metadata entity, and / or periodically compare the business parameters of the first bill and the second bill in the bill database. The creation time of the first bill is later than the creation time of the second bill. If the first bill has the target business parameters and the second bill does not have the target business parameters, then the target business parameters are used as the target metadata entity. The target business parameters are business parameters related to the business policy changes.

[0147] The business application rule generation device further includes: a determination unit 1305 and a generation unit 1306;

[0148] The acquisition unit 1301 is further configured to acquire a rule query request, wherein the rule query request includes the target rule name;

[0149] The determining unit 1305 is used to determine the similarity between the name of the preset declaration rule in the preset business rule base and the name of the target rule, wherein the preset declaration rule is a declaration rule that meets the preset storage conditions;

[0150] The determining unit 1305 is further configured to, if there is a first preset declaration rule in the preset business rule base with a similarity reaching a first preset similarity threshold, use the first preset declaration rule as the declaration rule corresponding to the rule query request;

[0151] The generation unit 1306 is configured to, if there is no first preset declaration rule in the preset business rule base with a similarity reaching a first preset similarity threshold, and there is a second preset declaration rule with a similarity reaching a second preset similarity threshold, then after obtaining the configuration information of the difference configuration item, generate the declaration rule corresponding to the rule query request based on the configuration information and the second preset declaration rule, wherein the first preset similarity threshold is greater than the second preset similarity threshold, and the configuration information of the difference configuration item is information determined based on the similarity between the second preset declaration rule and the second preset declaration rule.

[0152] The business application rule generation device also includes:

[0153] The sending unit 1307 is configured to send the first target declaration rule to the target client if the first target declaration rule does not exist in the preset business rule library; and / or send a rule difference notification to the target client if the first target declaration rule does not exist in the preset business rule library. After receiving the update request corresponding to the rule difference notification returned by the target client, the first target declaration rule is sent to the target client. The rule difference notification is used to indicate that the first target declaration rule does not exist in the preset business rule library.

[0154] In this embodiment, the units in the business application rule generation device perform the operations as described above. Figure 2 The operation of the business application rule generation device in the illustrated embodiment will not be described in detail here.

[0155] Please refer to the following: Figure 14 One embodiment of the computer device 1400 in this application includes:

[0156] Central processing unit 1401, memory 1405, input / output interface 1404, wired or wireless network interface 1403, and power supply 1402.

[0157] Memory 1405 is either a short-term storage memory or a persistent storage memory;

[0158] The central processing unit 1401 is configured to communicate with the memory 1405 and execute instructions stored in the memory 1405 to perform the aforementioned operations. Figure 2 The method in the illustrated embodiment.

[0159] This application also provides a computer-readable storage medium, which includes instructions that, when executed on a computer, cause the computer to perform the aforementioned actions. Figure 2 The method in the illustrated embodiment.

[0160] This application also provides a computer program product containing instructions, which, when run on a computer, causes the computer to perform the aforementioned... Figure 2 The method in the illustrated embodiment.

[0161] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.

[0162] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.

[0163] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection between apparatuses or units through some interfaces, and may be electrical, mechanical, or other forms.

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

[0165] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0166] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

Claims

1. A method for generating business application rules, characterized in that, The method includes: Obtain the target metadata entity related to changes in business policies; the target metadata entity is structured data reflecting changes in business policies, including at least one of business parameters, conditions, rule configurations, and attribute descriptions; Input the target metadata entity into the large model; Obtain the first prompt word and input it into the large model. The first prompt word is used to characterize the requirement characteristics for generating declaration rules. The large model then performs the following steps: Based on the first prompt word, a first declaration rule information is determined from the preset knowledge base that matches the target metadata entity to a preset matching degree threshold. The first declaration rule information is the initial declaration rule information. Based on the first prompt word and the initial declaration rule information, output the first target declaration rule corresponding to the target metadata entity; The target metadata entity for obtaining information related to changes in business policies includes: Real-time monitoring of changes in the target website's business policies; Based on the aforementioned changes in business policies, business policy change documents are periodically obtained and transformed to obtain the target metadata entity; and / or Periodically compare the business parameters of the first and second bills in the bill database, where the creation time of the first bill is later than that of the second bill; If the first ticket has target business parameters, and the second ticket does not have the target business parameters, then the target business parameters are used as the target metadata entity. The target business parameters are business parameters related to changes in business policies. After outputting the first target declaration rule corresponding to the target metadata entity based on the first prompt word and the initial declaration rule information, the method further includes: The first target declaration rule is verified according to preset standard conditions, and the verification result is obtained; If the first target declaration rule does not meet the preset standard conditions, a second prompt word is obtained. The second prompt word is a prompt word determined based on the verification result and the first target declaration rule. Based on the second prompt word, second declaration rule information that matches the target metadata entity to a preset matching degree threshold is determined from the preset knowledge base; Based on the second prompt word and the second declaration rule information, the second target declaration rule corresponding to the target metadata entity is output.

2. The method according to claim 1, characterized in that, The preset knowledge base includes a first knowledge base and a second knowledge base. The initial declaration rule information determined from the preset knowledge base that matches the target metadata entity to a preset matching threshold includes: First declaration rule information is determined from the first knowledge base that matches the target metadata entity to a preset matching degree threshold. The first declaration rule information includes basic data retrieval rule information and basic declaration calculation rule information related to the target metadata entity. The second declaration rule information is determined from the second knowledge base to have a matching degree with the target metadata entity that reaches a preset matching degree threshold. The second declaration rule information includes change data retrieval rule information and change declaration calculation rule information related to the target metadata entity. The initial application rule information is obtained based on the first application rule information and the second application rule information.

3. The method according to any one of claims 1 to 2, characterized in that, After outputting the first target declaration rule corresponding to the target metadata entity based on the initial declaration rule information, the method further includes: Obtain a rule query request, wherein the rule query request includes the target rule name; Determine the similarity between the name of the preset declaration rule in the preset business rule base and the name of the target rule, wherein the preset declaration rule is a declaration rule that meets the preset storage conditions; If there is a first preset declaration rule in the preset business rule base with a similarity reaching the first preset similarity threshold, then the first preset declaration rule will be used as the declaration rule corresponding to the rule query request. If there is no first preset declaration rule in the preset business rule base with a similarity reaching the first preset similarity threshold, but there is a second preset declaration rule with a similarity reaching the second preset similarity threshold, then after obtaining the configuration information of the difference configuration item, the declaration rule corresponding to the rule query request is generated based on the configuration information and the second preset declaration rule. The first preset similarity threshold is greater than the second preset similarity threshold, and the configuration information of the difference configuration item is information determined based on the similarity between the target rule name and the second preset declaration rule.

4. The method according to any one of claims 1 to 2, characterized in that, The method further includes: If the first target declaration rule does not exist in the preset business rule base, the first target declaration rule will be sent to the target client. and / or If the preset business rule base does not contain the first target declaration rule, a rule difference notification is sent to the target client. After receiving the update request corresponding to the rule difference notification returned by the target client, the first target declaration rule is sent to the target client. The rule difference notification is used to indicate that the preset business rule base does not contain the first target declaration rule.

5. A business application rule generation device, characterized in that, include: The acquisition unit is used to acquire target metadata entities related to changes in business policies; The target metadata entity is structured data reflecting changes in business policies, including at least one of business parameters, conditions, rule configurations, and attribute descriptions; An input unit is used to input the target metadata entity into a large model, obtain a first prompt word, and input the first prompt word into the large model. The first prompt word is used to characterize the requirement characteristics for generating declaration rules. The large model performs the following steps: based on the first prompt word, it determines first declaration rule information from a preset knowledge base that matches the target metadata entity to a preset matching degree threshold. The first declaration rule information is the initial declaration rule information. The output unit is used to output the first target declaration rule corresponding to the target metadata entity based on the first prompt word and the initial declaration rule information; The acquisition unit is specifically used to acquire the changes in the business policies of the target website in real time, acquire the business policy change documents periodically based on the changes in the business policies, and convert the business policy change documents to obtain the target metadata entity. And / or periodically compare the business parameters of the first and second bills in the bill database. The creation time of the first bill is later than that of the second bill. If the first bill has a target business parameter and the second bill does not have the target business parameter, then the target business parameter is used as the target metadata entity. The target business parameter is a business parameter related to changes in business policies. After outputting the first target declaration rule corresponding to the target metadata entity based on the first prompt word and the initial declaration rule information, the method further includes: The business application rule generation device further includes: a verification unit and a determination unit; The verification unit is used to verify the first target declaration rule according to preset standard conditions and obtain the verification result; The acquisition unit is further configured to obtain a second prompt word if the first target declaration rule does not meet the preset standard conditions, wherein the second prompt word is a prompt word determined based on the verification result and the first target declaration rule; The determining unit is used to determine, based on the second prompt word, second declaration rule information from the preset knowledge base that matches the target metadata entity to a preset matching degree threshold. The output unit is further configured to output the second target declaration rule corresponding to the target metadata entity based on the second prompt word and the second declaration rule information.

6. A computer device, characterized in that, include: Central processing unit and memory; The memory is either a short-term storage memory or a persistent storage memory; The central processing unit is configured to communicate with the memory and execute instructions in the memory to perform the method according to any one of claims 1 to 4.

7. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes instructions that, when executed on a computer, cause the computer to perform the method as described in any one of claims 1 to 4.

8. A computer program product comprising instructions or a computer program, characterized in that, When the computer program product is run on a computer, it causes the computer to perform the method as described in any one of claims 1 to 4.

Citation Information

Patent Citations

  • CN117057937A

  • CN118378099A