Index rule generation method and device, electronic equipment and storage medium
By dynamically combining custom indicator templates and parameters to generate indicator rules, the problem of reduced configurability caused by increased regulatory demands in the financial system has been solved, enabling rapid response and flexible generation of regulatory rules.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- CHINA CONSTRUCTION BANK
- Filing Date
- 2022-11-28
- Publication Date
- 2026-06-05
AI Technical Summary
In existing technologies, when facing increasing regulatory demands, financial systems require technical personnel to implement new regulatory rules through extensive programming, which reduces the system's configurability and response speed.
By customizing and combining indicator templates and parameters, flexible indicator rules can be generated. By using a predefined template library to call appropriate indicator templates and parameters, indicator rules can be dynamically generated, reducing the need for manual programming.
It improves the system's flexibility and configurability, enables rapid response to regulatory requirements, reduces the programming workload for technical personnel, and increases the system's response speed.
Smart Images

Figure CN116090867B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of data processing technology, and in particular to a method, apparatus, electronic device and storage medium for generating indicator rules. Background Technology
[0002] In the financial business sector, a series of functions are needed to monitor transaction behavior and achieve oversight of financial-related businesses, in response to potential operational risks in the financial system, regulatory requirements from regulatory agencies, and specific customer needs.
[0003] In existing technologies, the system sets up regulatory objects, establishes the relationship between regulatory rules and regulatory objects, generates regulatory tasks that the regulatory objects need to perform, and obtains regulatory results through the execution of regulatory tasks. Among these, different regulatory rules correspond to different implementation logics, meaning that for each regulatory rule, technical personnel need to perform a lot of programming based on regulatory requirements to implement it.
[0004] However, the above methods are insufficient to cope with the increasing regulatory requirements. If new regulatory requirements are proposed, technical personnel need to implement the new requirement logic through programming, which makes the system slow to respond to regulatory requirements and reduces the configurability of the system. Summary of the Invention
[0005] This application provides an indicator rule generation method, apparatus, electronic device, and storage medium, which can freely combine indicator templates and template parameters to form different rule logics. Through custom combinations, it provides a configurable indicator rule implementation method, improving the system's flexibility, configurability, and response speed to regulatory requirements.
[0006] Firstly, this application provides a method for generating indicator rules, the method comprising:
[0007] The system acquires the business scenario requirements and the regulatory data needed for those requirements, and calls the corresponding indicator template from a predefined template library based on those requirements. Each indicator template is configured with at least one indicator parameter, and each indicator parameter corresponds to an executable code statement.
[0008] Determine whether the indicator parameters corresponding to the indicator template meet the requirements of the business scenario.
[0009] If so, in response to the user's first operation of setting indicator parameters, the code statements corresponding to the indicator parameters are concatenated to generate the first operation logic of indicator rules, and the indicator rules are generated based on the first operation logic and the regulatory data.
[0010] If not, in response to the second operation of setting indicator parameters by the user, the target indicator parameters that meet the requirements of the business scenario are obtained from the predefined template library, the code statements corresponding to the target indicator parameters are concatenated to generate the second operation logic of the indicator rules, and the indicator rules are generated based on the second operation logic and the regulatory data.
[0011] Optionally, the process involves acquiring business scenario requirements and the regulatory data needed for those requirements, and then calling the corresponding indicator templates from a predefined template library based on those requirements, including:
[0012] Obtain business scenario requirements and initial regulatory data, and perform calculations on the initial regulatory data to obtain the calculation results;
[0013] The calculation result is compared with the regulatory threshold corresponding to the business scenario requirement to determine the regulatory data required for the business scenario requirement.
[0014] Based on the business scenario requirements, determine the data type corresponding to the regulatory data, and based on the data type, determine the field codes corresponding to the indicator templates;
[0015] The corresponding indicator template is called from the predefined template library using the field code.
[0016] Optionally, in response to the user's first operation of setting indicator parameters, the first calculation logic for generating indicator rules is generated by concatenating the code statements corresponding to the indicator parameters, including:
[0017] In response to the first operation of the user selecting an indicator parameter and assigning a value to the user-selected indicator parameter, a first parameter range of the indicator parameter is generated.
[0018] Obtain the parameter name of the indicator parameter, call the code statement corresponding to the indicator parameter from the parameter table based on the parameter name, and concatenate the first parameter range and the code statement to generate the first operation logic of the indicator rule.
[0019] Optionally, the indicator rules are generated based on the first calculation logic and the regulatory data, including:
[0020] The regulatory data is processed based on the first calculation logic to obtain a regulatory prompt result;
[0021] Determine whether the regulatory prompt result meets the preset requirements;
[0022] If so, then indicator rules are generated based on the first calculation logic and the indicator parameters.
[0023] Optionally, in response to the second operation of setting indicator parameters by the user, target indicator parameters that meet the requirements of the business scenario are obtained from a predefined template library, and the second calculation logic of the indicator rules is generated by concatenating the code statements corresponding to the target indicator parameters, including:
[0024] In response to the parameter information of the user-input indicator parameter and the second operation of assigning a value to the user-input indicator parameter, a second parameter range of the indicator parameter is generated;
[0025] Based on the parameter information, a first indicator parameter that meets the requirements of the business scenario is found from the indicator parameters corresponding to the indicator template, and a second indicator parameter that meets the requirements of the business scenario is obtained from the predefined template library based on the parameter information and the first indicator parameter.
[0026] The first indicator parameter and the second indicator parameter are summarized to obtain the target indicator parameter corresponding to the business scenario requirements;
[0027] Obtain the parameter name of the target indicator parameter, call the code statement corresponding to the target indicator parameter from the parameter table based on the parameter name, and concatenate the second parameter range and the code statement to generate the second operation logic of the indicator rule.
[0028] Optionally, the method further includes:
[0029] Obtain the initialization information corresponding to the indicator rule, and configure the corresponding execution indicator template and execution template parameters based on the initialization information;
[0030] An execution script is generated based on the execution indicator template and the execution template parameters, and the execution script is used to perform the regulatory task to obtain the regulatory result.
[0031] Optionally, the method further includes:
[0032] When it is determined that the regulatory results do not meet the regulatory requirements, abnormal data is found in the regulatory data, and alarm information is generated based on the abnormal data. The alarm information is then visualized to remind the user that there is an operational abnormality.
[0033] Secondly, this application also provides an indicator rule generation apparatus, the apparatus comprising:
[0034] The calling module is used to obtain the business scenario requirements and the regulatory data required by the business scenario requirements, and to call the corresponding indicator template from the predefined template library based on the business scenario requirements; the indicator template is configured with at least one indicator parameter; each indicator parameter corresponds to an executable code statement;
[0035] The judgment module is used to determine whether the indicator parameters corresponding to the indicator template meet the requirements of the business scenario.
[0036] The first generation module is used to respond to the user's first operation of setting indicator parameters when the indicator parameters corresponding to the indicator template meet the business scenario requirements, and to concatenate the code statements corresponding to the indicator parameters to generate the first operation logic of indicator rules, and generate indicator rules based on the first operation logic and the regulatory data.
[0037] The second generation module is used to, when the indicator parameters corresponding to the indicator template do not meet the business scenario requirements, respond to the second operation of the user setting indicator parameters, obtain the target indicator parameters that meet the business scenario requirements from the predefined template library, concatenate the code statements corresponding to the target indicator parameters, generate the second operation logic of the indicator rules, and generate the indicator rules based on the second operation logic and the regulatory data.
[0038] Thirdly, this application also provides an electronic device, including: a processor, and a memory communicatively connected to the processor;
[0039] The memory stores computer-executed instructions;
[0040] The processor executes computer execution instructions stored in the memory to implement the method as described in any one of the first aspects.
[0041] Fourthly, this application also provides a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, are used to implement the method as described in any one of the first aspects.
[0042] Fifthly, this application also provides a computer program product, including program code, which, when a computer runs the computer program, performs the method as described in any one of the first aspects.
[0043] In summary, this application provides a method, apparatus, electronic device, and storage medium for generating indicator rules. It can acquire business scenario requirements and the regulatory data needed for those requirements, and further, call the corresponding indicator template from a predefined template library based on the business scenario requirements. Then, it determines whether the indicator parameters corresponding to the indicator template meet the business scenario requirements. If yes, it responds to the user's first operation of setting indicator parameters and concatenates the code statements corresponding to the indicator parameters to generate the first calculation logic for indicator rules. Further, it generates indicator rules based on the first calculation logic and regulatory data. If no, it responds to the user's second operation of setting indicator parameters, obtains the target indicator parameters that meet the business scenario requirements from the predefined template library, and generates the indicator rules based on the target... The code statements corresponding to the indicator parameters are concatenated to generate the second operation logic of the indicator rules. Further, indicator rules are generated based on the second operation logic and regulatory data. The indicator template is configured with at least one indicator parameter; each indicator parameter corresponds to an executable code statement; the code statement corresponding to each indicator parameter is pre-programmed, eliminating the need for technical personnel to perform adaptive programming for each indicator rule. Simply calling the appropriate indicator parameter can form the required indicator rule. In this way, templates and indicator template parameters can be freely combined to form different rule logics. Through custom combinations, a configurable indicator rule implementation method is provided, improving the system's flexibility, configurability, and response speed to regulatory needs. Attached Figure Description
[0044] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.
[0045] Figure 1 This is a schematic diagram of an application scenario provided by an embodiment of this application;
[0046] Figure 2 A flowchart illustrating an indicator rule generation method provided in an embodiment of this application;
[0047] Figure 3 A flowchart illustrating a process for generating custom indicator rules, provided as an embodiment of this application;
[0048] Figure 4 A flowchart illustrating the execution of a custom indicator rule is provided for an embodiment of this application;
[0049] Figure 5 A schematic diagram of an index rule generation device provided in an embodiment of this application;
[0050] Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application.
[0051] The accompanying drawings illustrate specific embodiments of this application, which will be described in more detail below. These drawings and descriptions are not intended to limit the scope of the concept in any way, but rather to illustrate the concept of this application to those skilled in the art through reference to particular embodiments. Detailed Implementation
[0052] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numbers in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.
[0053] To facilitate a clear description of the technical solutions in the embodiments of this application, the terms "first" and "second" are used in the embodiments of this application to distinguish identical or similar items with essentially the same function and purpose. For example, "first device" and "second device" are merely used to distinguish different devices and do not limit their order of execution. Those skilled in the art will understand that the terms "first" and "second" do not limit the quantity or execution order, and that "first" and "second" do not necessarily imply that they are different.
[0054] It should be noted that, in this application, the terms "exemplary" or "for example" are used to indicate that something is being described as an example, illustration, or illustration. Any embodiment or design described as "exemplary" or "for example" in this application should not be construed as being more preferred or advantageous than other embodiments or design solutions. Specifically, the use of terms such as "exemplary" or "for example" is intended to present the relevant concepts in a concrete manner.
[0055] In this application, "at least one" means one or more, and "more than one" means two or more. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can mean: A alone, A and B simultaneously, or B alone, where A and B can be singular or plural. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. "At least one of the following" or similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one of a, b, or c can mean: a, b, c, ab, ac, bc, or abc, where a, b, and c can be single or multiple.
[0056] In financial transactions, the system provides a series of functions to supervise transaction behavior. It can generate regulatory tasks for the regulated objects by mapping regulatory rules to them, and obtain regulatory results through the execution of regulatory tasks to fulfill regulatory requirements.
[0057] In one possible implementation, the system sets up the regulatory objects, establishes the association between regulatory rules and the regulatory objects, generates the regulatory tasks that the regulatory objects need to perform, and obtains the regulatory results through the execution of the regulatory tasks. In this case, different regulatory rules correspond to different implementation logics, that is, for each regulatory rule, technical personnel need to perform a lot of programming based on regulatory requirements to implement it.
[0058] However, the aforementioned implementation methods for regulatory rules employ different implementation logics for different regulatory rules. While different parameter values can be customized for the same regulatory rule, this approach requires code implementation for each individual rule, and the regulatory result changes depending on the parameter values. Therefore, this method struggles to cope with increasing regulatory requirements. If new regulatory needs are proposed, technical personnel must implement the new logic through extensive programming, making the system slow to respond to regulatory demands and reducing its configurability.
[0059] To address the aforementioned issues, this application provides a method for generating indicator rules. This method determines suitable templates based on acquired business scenario requirements and the regulatory data needed for those requirements. These templates are pre-processed to visualize the commonalities of different types of regulatory data, creating various indicator templates for each type of regulatory data and business scenario requirement. Each template is configured with corresponding indicator parameters. Furthermore, it is determined whether the configured indicator parameters meet the business scenario requirements. If they do, the corresponding code statements are dynamically invoked based on the operations of business personnel to generate indicator rules. If not, the required indicator parameters for that business scenario requirement are obtained, and the corresponding code statements are dynamically invoked to generate indicator rules. Thus, by providing a templated category of indicator rules combined with personalized indicator template parameters, a solution for manually configuring indicator rules is provided. This addresses the issue of implementing different indicator rules that would otherwise require extensive programming, improving the system's speed of responding to different needs and enhancing the system's configurability.
[0060] The embodiments of this application will now be described in conjunction with the accompanying drawings. Figure 1 This is a schematic diagram illustrating an application scenario provided by an embodiment of this application. The indicator rule generation method provided in this application can be applied to, for example... Figure 1The application scenario shown includes: terminal device 101, business processing platform 102, and display device 103 corresponding to business processing platform 102. Specifically, business processing platform 102 can obtain business scenario requirements and the regulatory data required by those requirements from terminal device 101. Furthermore, business processing platform 102 can call corresponding indicator templates from the rule base based on business scenario requirements. These indicator templates are configured with multiple indicator parameters, which can be displayed on display device 103. Business personnel can manually select the combination of indicator templates and indicator template parameters through touch operation on display device 103 to form corresponding indicator rules. In this way, through this custom rule method, indicator rules for different regulatory requirements of the same category can be quickly implemented.
[0061] Furthermore, by combining the formed indicator rules with the regulated objects, the regulatory tasks that the regulated objects need to perform are generated. By performing the regulatory tasks, the regulatory results can be obtained and displayed on the display device 103 for business personnel to view.
[0062] The indicator template is formed in advance by obtaining the commonalities of a series of regulatory rules and concretizing these commonalities. Each type of indicator template has a series of indicator template parameters, which can be adapted to its corresponding indicator template.
[0063] It should be noted that the number of terminal devices 101 may be more than one. This application embodiment does not specifically limit the number and type of terminal devices 101. The business processing platform 102 can be understood as a system that executes the indicator rule generation method provided in this application embodiment.
[0064] The technical solutions of this application will be described in detail below with reference to specific embodiments. These specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments. The embodiments of this application will be described below with reference to the accompanying drawings.
[0065] Figure 2 This is a flowchart illustrating an indicator rule generation method provided in an embodiment of this application, as shown below. Figure 2 As shown, the indicator rule generation method includes the following steps:
[0066] S201. Obtain the business scenario requirements and the regulatory data required by the business scenario requirements, and call the corresponding indicator template from the predefined template library based on the business scenario requirements; the indicator template is configured with at least one indicator parameter; each indicator parameter corresponds to an executable code statement.
[0067] In this embodiment, regulatory data can refer to data to be monitored due to trading activities, such as data on the buying and selling of a certain portfolio of stocks. This embodiment does not specifically limit this. Indicator parameters can refer to parameters associated with an indicator template, representing a personalized configuration of a classification rule. Therefore, the range of selectable indicator template parameters is consistent for the same indicator template. However, for different classification rules, different indicator templates are used, resulting in different indicator parameters. Each indicator parameter is closely associated with its indicator template, meaning that corresponding logical processing of the indicator parameter can be performed under the indicator template.
[0068] The regulatory data can be stored in multiple data tables, each with a join relationship, such as Table1t1 and Table2t2. The join relationship includes, but is not limited to, join, left join, etc. The required data tables include, but are not limited to, table t1 (Table1 t1) and table t2 (Table2t2). In practical applications, multiple different data tables can be joined as needed. The table includes not only data tables but also, but also, but is not limited to, views that can obtain data. This application embodiment does not specifically limit this.
[0069] A predefined template library can refer to a database used to store indicator templates, indicator parameters, and the code statements for each indicator parameter. This predefined template library stores the data information and data association information required for the implementation of indicator rules based on various data tables. For example, the indicator template data table stores the processor information and indicator template name corresponding to each indicator template, and the processor information refers to the code statements corresponding to each indicator template; the indicator template parameter table stores the indicator parameter information that can be selected by the indicator template; and the custom indicator rule configuration table stores the template information and parameter information used to configure the indicator rules.
[0070] It should be noted that the data tables in the predefined template library include, but are not limited to, the data tables mentioned above. These data tables are used by the processor to provide data when loading the initialization information related to the indicator rules. Specifically, the data in the data tables are related. For example, the corresponding indicator template can be found in the indicator template data table based on the indicator template name, or the corresponding indicator template can be found in the indicator template data table based on the business scenario requirements. Each business scenario requirement corresponds to an indicator template. This application embodiment does not make specific limitations on this.
[0071] In this step, the regulatory data required for the business scenario can be obtained through steps such as acquiring the data to be monitored, processing the monitoring data, and comparing the processing results with the set thresholds. The step of acquiring the data to be monitored is a step with classification characteristics. Specifically, by sorting out the data information, data sources, and business scenarios used in the step of acquiring the data to be monitored, the data information is processed, that is, the acquired data is subjected to certain logical processing. Furthermore, the processing results are compared with the set thresholds to obtain the regulatory data. For example, if it is necessary to calculate that the proportion of a certain portfolio of stocks accounts for 10% of the total portfolio assets, the data corresponding to the portfolio of stocks accounting for 10% of the total portfolio assets is obtained, and it is determined whether the obtained data meets the requirements of the business scenario. If it does, the corresponding regulatory data is obtained.
[0072] Understandably, the indicator templates are pre-built, each with at least one indicator parameter, and each template can be applied to the same type of indicator rules. When configuring indicator rules, the corresponding indicator template and its index parameters can be directly called. The process of pre-building indicator templates can involve the system categorizing all required rules into broad categories, and then template-izing the rules to obtain indicator templates. The indicator rule categorization is based on the templates, and the following scenarios are considered when categorizing the rules:
[0073] 1. Using the same data source in the system indicates that the data source for obtaining the data is the same data table or the same view.
[0074] 2. Whether the data types used in the rules are the same, including but not limited to the business meaning of the data and the type of data in the database.
[0075] 3. Are the business scenarios corresponding to the rules similar? For example, for bonds invested in an asset portfolio, there are regulatory requirements for rating. The rating can be divided into bond rating, issuer rating, guarantor rating, etc. The data sources for different ratings are different, but they have the same application scenario, namely the regulatory scenario of credit rating for bonds in a portfolio. If the corresponding rules are similar, then the regulatory scenario can be divided into the same template in the system.
[0076] By considering the above three scenarios, we can achieve the templated processing of rules, that is, extract the commonalities of the rules and visualize the commonalities to obtain a series of indicator templates for indicator rules.
[0077] S202. Determine whether the indicator parameters corresponding to the indicator template meet the requirements of the business scenario.
[0078] In this step, the same indicator template may include multiple selectable indicator parameters, and not all indicator parameters will be enabled or meet the needs of the business scenario. Therefore, it is necessary to determine whether the corresponding indicator parameters in the indicator template meet the needs of the business scenario.
[0079] S203. If so, in response to the first operation of the user setting indicator parameters, the first operation logic of the indicator rule is generated by concatenating the code statements corresponding to the indicator parameters, and the indicator rule is generated based on the first operation logic and the regulatory data.
[0080] In this embodiment of the application, the first operation may refer to a series of operations performed by business personnel after determining the indicator template, such as selecting indicator parameters and assigning values to the indicator parameters.
[0081] For example, taking the supervision of specific asset management products with limited liquidity as an example, the limited liquidity refers to the fact that the redemption date of the product is more than 10 days away. The process of configuring indicator rules for specific asset management products with limited liquidity includes: determining a suitable indicator template based on the needs of the business scenario. The determination of a suitable indicator template is based on the data required by the business scenario, that is, determining the indicator template of the indicator rules based on the holding data of the specific asset management product.
[0082] Once the indicator template is determined, it also determines that the entire rule will obtain the data to be monitored from the position data tables of each combination. Further, the indicator template is configured, that is, the rule's calculation logic and thresholds are determined. The calculation logic and thresholds are the indicator parameters and their values selected by the business personnel on the display interface, respectively. Then, the corresponding code statements for the indicator parameters are dynamically concatenated. During the dynamic concatenation of the code statements, the logic of this parameter segment is incorporated. Further, the first calculation logic of the indicator rule is generated, and the position data is processed based on this first calculation logic. If the processing result meets the regulatory requirements, the indicator rule is generated based on the selected indicator parameters and the first calculation logic.
[0083] The selected indicator parameters may include: security type (this parameter will limit the scope of specific asset management products subject to regulation, i.e., by setting the parameter value, it will be determined which securities will be subject to liquidity restrictions), term unit (this parameter will take different logical data based on the rule according to trading days, years, days, and months. The current rule requires the judgment of liquidity restrictions based on trading days, so the parameter value is set to trading days), and maximum number of days for redemption (this indicator parameter represents the liquidity restriction threshold. The rule requires the regulation of products whose redemption date is 10 trading days away from the current day, so the threshold can be set to 10. Data exceeding the threshold will be obtained for notification), etc.
[0084] It should be noted that the embodiments of this application do not specifically limit the indicator parameters selected by the user based on the first operation under different business scenario requirements; the above are merely illustrative examples.
[0085] S204. If not, in response to the second operation of setting indicator parameters by the user, the target indicator parameters that meet the requirements of the business scenario are obtained from the predefined template library, the code statements corresponding to the target indicator parameters are concatenated to generate the second operation logic of the indicator rules, and the indicator rules are generated based on the second operation logic and the regulatory data.
[0086] In this embodiment of the application, the second operation may refer to the business personnel performing a series of operations to input indicator parameters and assign values to the indicator parameters. The input indicator parameters may be the parameter information, parameter name, etc. of the input indicator parameters, which makes it easier to find the corresponding target indicator parameters from the predefined template library.
[0087] In this step, taking the WHERE condition in an SQL statement as an example, the code statement corresponding to the target indicator parameter is concatenated. That is, the SQL is dynamically assembled, and different indicator parameters are added based on the second operation of the business personnel. The second operation logic of the indicator rule is generated. The second operation logic is the logic for processing the indicator parameter. For example, the isNotNull tag is used to determine whether the indicator parameter is enabled. After it is determined that the indicator parameter is enabled, the business personnel perform the second operation on the display interface, and then obtain the target indicator parameter, such as #CS_GZCS_1#, that meets the needs of the business scenario from the predefined template library. Based on the parameter value set by the business personnel for #CS_GZCS_1# on the interface, the execution logic of the target indicator parameter will be brought in when the SQL is dynamically concatenated.
[0088] The #CS_GZCS_1# parameter value set in the interface represents the threshold for setting regulatory requirements. If business personnel do not configure this parameter in the interface, the code for executing logic will not be included in the SQL statement.
[0089] It should be noted that different business scenarios require different logic, so it may be necessary to add indicator parameters for auxiliary processing. This application does not specifically limit the added indicator parameters; the above is just an example. In this way, by dynamically concatenating SQL statements, different indicator parameters can be added to the indicator template. When business personnel configure different indicator parameters for the indicator template, different indicator rule logics can be implemented, and the monitoring results can be obtained by executing the concatenated SQL statements.
[0090] Therefore, this application provides a method for generating indicator rules. This method involves acquiring business scenario requirements and the regulatory data needed for those requirements, and further, calling the corresponding indicator template from a predefined template library based on those requirements. It then determines whether the indicator parameters corresponding to the indicator template meet the business scenario requirements. If yes, it responds to the user's first operation of setting indicator parameters and concatenates the code statements corresponding to the indicator parameters to generate the first operational logic for indicator rules. Further, it generates indicator rules based on the first operational logic and the regulatory data. If no, it responds to the user's second operation of setting indicator parameters, retrieves the target indicator parameters that meet the business scenario requirements from the predefined template library, and generates the indicator rules based on the code statements corresponding to the target indicator parameters. The code statements are concatenated to generate the second operation logic of the indicator rules. Further, based on the second operation logic and regulatory data, indicator rules are generated. The indicator template is configured with at least one indicator parameter; each indicator parameter corresponds to an executable code statement. The code statement corresponding to each indicator parameter is pre-programmed, eliminating the need for technicians to perform adaptive programming for each indicator rule. Simply calling the appropriate indicator parameter can form the required indicator rule. In this way, templates and indicator template parameters can be freely combined to form different rule logics. Through custom combinations, a configurable indicator rule implementation method is provided, improving the system's flexibility, configurability, and response speed to regulatory needs.
[0091] For example, Figure 3 This application provides a flowchart illustrating the generation of custom indicator rules, as shown in the embodiments below. Figure 3 As shown, by selecting a suitable indicator template, the indicator template provides personalized indicator template parameters (indicator parameters). The indicator template parameters correspond to the indicator template, and different indicator templates have different indicator template parameters. Furthermore, business personnel select indicator template parameters that conform to the indicator rules under the template. Correspondingly, business personnel can add indicator template parameters according to new needs (business scenario needs) to form custom indicator rules. As the number of template parameters increases, indicator templates and indicator template parameters can be freely combined to form more indicator rules that meet the conditions.
[0092] Therefore, this application enables custom configuration of indicator rules, eliminating the need for extensive manual hard coding of regulatory rule logic. Instead, users only need to manually select indicator templates and their parameters for configuration, or business personnel can add new indicator template parameters to provide more combinations. Adding new indicator template parameters often requires only a small amount of programming, and the resulting new indicator templates and corresponding rules can be reused without any subsequent processing. This allows for rapid response to needs and improves the system's functionality.
[0093] Optionally, the process involves acquiring business scenario requirements and the regulatory data needed for those requirements, and then calling the corresponding indicator templates from a predefined template library based on those requirements, including:
[0094] Obtain business scenario requirements and initial regulatory data, and perform calculations on the initial regulatory data to obtain the calculation results;
[0095] The calculation result is compared with the regulatory threshold corresponding to the business scenario requirement to determine the regulatory data required for the business scenario requirement.
[0096] Based on the business scenario requirements, determine the data type corresponding to the regulatory data, and based on the data type, determine the field codes corresponding to the indicator templates;
[0097] The corresponding indicator template is called from the predefined template library using the field code.
[0098] In this embodiment of the application, the initial regulatory data may refer to all the data to be monitored generated by the transaction behavior. Since the amount of initial regulatory data is large, it is not necessary to obtain all the data to be monitored when performing regulatory tasks. Therefore, the initial regulatory data is processed to obtain regulatory data that meets the needs of the business scenario.
[0099] In this step, the data to be monitored can be obtained, relevant calculations can be performed on the obtained data, and then the calculation results can be compared with the set regulatory thresholds. By judging whether the set threshold requirements are met, the regulatory data required to meet the regulatory requirements in the transaction behavior can be determined. For example, the regulatory data is the data with the investment date being the 20th of each month.
[0100] It should be noted that the display method of the regulatory results corresponding to a certain type of regulatory rule is consistent. This makes the result fields obtained by running a type of regulatory rule also have commonalities. By analyzing the commonalities, the data type of the required data and the field code returned can be determined. The field code is represented by a SQL statement that retrieves the corresponding field from a specific table or view, such as t1.column1, t2.column2, etc.
[0101] Specifically, based on business scenario requirements, the data type corresponding to regulatory data can be determined, and the field code corresponding to the indicator template can be determined based on the data type. This field code is the common field in the template. These common fields are defined according to the result fields in the code statement corresponding to the indicator template, and can be added as needed. Furthermore, the corresponding indicator template can be called from the predefined template library using the field code.
[0102] Because indicator templates are diverse, their configured indicator parameters are also diverse. Therefore, this application embodiment can determine the indicator template to be called based on the regulatory data required by the business scenario and the data type corresponding to the regulatory data, find the appropriate indicator template, and improve the accuracy of the call. The indicator template is formed by the visualization of the common points (data type) in the major categories of extraction rules.
[0103] Optionally, in response to the user's first operation of setting indicator parameters, the first calculation logic for generating indicator rules is generated by concatenating the code statements corresponding to the indicator parameters, including:
[0104] In response to the first operation of the user selecting an indicator parameter and assigning a value to the user-selected indicator parameter, a first parameter range of the indicator parameter is generated.
[0105] Obtain the parameter name of the indicator parameter, call the code statement corresponding to the indicator parameter from the parameter table based on the parameter name, and concatenate the first parameter range and the code statement to generate the first operation logic of the indicator rule.
[0106] In this step, the parameter table is a table that stores the code statements corresponding to the indicator parameters in advance. The parameter table also stores the parameter names of the indicator parameters. That is, the code statements corresponding to the indicator parameters can be called from the parameter table based on the parameter names. The number of parameter tables can be more than one. This application embodiment does not make a specific limitation on this.
[0107] It should be noted that, in this embodiment of the application, dynamic relationships can also be added to the data table as needed. The relationships can be defined according to the logical rules for obtaining data from the indicator template. Different templates have different processing rules and different ways of obtaining data.
[0108] Optionally, if the first operation corresponds to a user operation without selection or setting, the logic code will not be dynamically concatenated. Instead, the indicator rules corresponding to the indicator template can be directly called, i.e., the indicator rules corresponding to the indicator template are pre-stored in the predefined template library.
[0109] Therefore, the embodiments of this application can provide a way to establish regulatory rules manually, which greatly shortens the manual programming process. For each indicator template, it provides suitable indicator parameters. Due to the diversity of indicator parameters, it can realize the personalized configuration of regulatory rules. By selecting different indicator parameters, different implementation logics of the same type of indicator rules can be realized. That is, the same indicator template can correspond to different calculation logics.
[0110] Optionally, the indicator rules generated based on the first calculation logic and the regulatory data include:
[0111] The regulatory data is processed based on the first calculation logic to obtain a regulatory prompt result;
[0112] Determine whether the regulatory prompt result meets the preset requirements;
[0113] If so, then indicator rules are generated based on the first calculation logic and the indicator parameters.
[0114] In this application embodiment, the preset requirement may refer to meeting the regulatory requirements corresponding to different business scenarios, that is, the data corresponding to the transaction behavior can be monitored to determine whether it is the processing result required by the business scenario.
[0115] In this step, after business personnel complete the custom configuration of the indicator parameters corresponding to the indicator template through the interface, they can perform regulatory processing on the regulatory data based on the first calculation logic. For example, violation data can be obtained according to the following calculation logic: the securities product belongs to the range containing the securities type parameter value, and the redemption date of the securities product is more than 10 trading days away from the current trading day. The violation data is the regulatory prompt result. Further, it is determined whether the regulatory prompt result meets the regulatory requirements. If it does, indicator rules are generated based on the first calculation logic and the selected indicator parameters. Correspondingly, the regulatory prompt result can also be displayed on the display interface to prompt business personnel and achieve the regulatory requirements.
[0116] Optionally, if the regulatory prompt result does not meet the preset requirements, the obtained result data is equivalent to the result data that does not meet the regulatory requirements. Accordingly, this application can also write other rule-compliant judgment logic using SQL statements as needed to determine whether the regulatory prompt result meets the preset requirements. This application embodiment does not specifically limit this.
[0117] Therefore, the embodiments of this application can use computational logic to preprocess regulatory data to determine whether the requirements are met, thereby improving the accuracy of the generated indicator rules.
[0118] Optionally, in response to the second operation of setting indicator parameters by the user, target indicator parameters that meet the requirements of the business scenario are obtained from a predefined template library, and the second calculation logic of the indicator rules is generated by concatenating the code statements corresponding to the target indicator parameters, including:
[0119] In response to the parameter information of the user-input indicator parameter and the second operation of assigning a value to the user-input indicator parameter, a second parameter range of the indicator parameter is generated;
[0120] Based on the parameter information, a first indicator parameter that meets the requirements of the business scenario is found from the indicator parameters corresponding to the indicator template, and a second indicator parameter that meets the requirements of the business scenario is obtained from the predefined template library based on the parameter information and the first indicator parameter.
[0121] The first indicator parameter and the second indicator parameter are summarized to obtain the target indicator parameter corresponding to the business scenario requirements;
[0122] Obtain the parameter name of the target indicator parameter, call the code statement corresponding to the target indicator parameter from the parameter table based on the parameter name, and concatenate the second parameter range and the code statement to generate the second operation logic of the indicator rule.
[0123] In this embodiment, the parameter information may include the attributes of the indicator parameter, the name of the indicator parameter, or keywords in the indicator parameter, that is, the user knows the general content or meaning of the indicator parameter. Based on the parameter information, the indicator parameter name and indicator parameter stored in the parameter table can be determined. The indicator parameter name and indicator parameter stored in the parameter table are unique. This embodiment does not limit the specific content corresponding to the parameter information.
[0124] In this step, to enable custom configuration of indicator templates and indicator parameters, SQL logic can be written for each indicator template. This involves storing basic information such as the processor information and indicator template name for each template in the indicator template data table, as shown in Table 1. The processor information refers to the code statement executed by the indicator template, which is an SQL logic code statement, such as the SQL logic code statement corresponding to processor A. Similarly, for indicator template parameters, the corresponding indicator template parameter information is stored in the indicator template parameter table through pre-written logic processing code, as shown in Table 2. Furthermore, a relationship is established between the two tables, linking the indicator templates and indicator parameters.
[0125] Table 1 Indicator Template Data Table
[0126] Template Name Template processor name A Processor A B Processor B C Processor C
[0127] Table 2 Indicator Template Parameter Table
[0128] Template Name Template parameter name A a, b, c B a, c, d C a, c
[0129] Different templates may have different indicator parameters, or they may have the same indicator parameters. The different indicator parameters are developed for the unique characteristics of each indicator template, while the same indicator parameters are developed for the commonalities between the templates.
[0130] Specifically, when business personnel configure indicator parameters on the interface, if they select template A, there are three selectable parameters: a, b, and c; if they select template B, there are three selectable parameters: a, c, and d; and if they select template C, there are two selectable parameters: a and c. Business personnel can freely combine and select indicator templates and template parameters to complete different regulatory rule configurations. For example, if template A is determined based on business scenario requirements, and the business personnel select parameters b and c (the first indicator parameters) from the template's selectable parameters on the interface, but parameters b and c are insufficient to meet the business scenario requirements, then in response to the user's input to search for b, c, and d, parameter d (the second indicator parameter) can be called from template B. Parameters b, c, and d are then summarized to obtain the target indicator parameter. Furthermore, based on the parameter names corresponding to parameters b, c, and d, the code statements corresponding to the target indicator parameter are called from the parameter table, and the code statements are concatenated based on the business personnel's assignment operations to generate the second calculation logic of the indicator rule.
[0131] Furthermore, after the business completes the configuration on the interface, it uses the second calculation logic and target indicator parameters to generate indicator rules. The template information, parameter information, etc. used by the indicator rules will be stored in the custom indicator rule configuration table, as shown in Table 3. In the subsequent processing of regulatory tasks, the information corresponding to the updated template A can be obtained from the custom indicator rule configuration table.
[0132] Table 3 Custom Indicator Rule Configuration Table
[0133] Rule Name Rule template name Rule parameter name Rule 1 Template A b, c, d Rule 2 Template B a, c, d
[0134] It should be noted that when selecting indicator template parameters, business personnel can configure them according to the regulatory rules achieved by the business scenario requirements. Not all indicator parameters need to be used; business personnel can choose the required indicator parameters themselves.
[0135] Therefore, the embodiments of this application can manually add indicator rules that meet the requirements by manually configuring indicator templates and indicator template parameters. That is, when adding new indicator rules of the same type, no code modification is required. The code statements corresponding to the added indicator parameters can be used directly, which reduces the rule logic that technical personnel previously had to complete through hard coding, reduces the coupling between codes, and improves flexibility.
[0136] Optionally, the method further includes:
[0137] Obtain the initialization information corresponding to the indicator rule, and configure the corresponding execution indicator template and execution template parameters based on the initialization information;
[0138] An execution script is generated based on the execution indicator template and the execution template parameters, and the execution script is used to perform the regulatory task to obtain the regulatory result.
[0139] In this embodiment of the application, the initialization information may refer to the SQL logic corresponding to the concatenation of indicator rules. By initializing each indicator rule, the supervision task can be processed.
[0140] For example, Figure 4 This application provides a flowchart illustrating the execution of custom indicator rules, as shown in the embodiments of the present application. Figure 4 As shown, when executing a custom indicator rule task, the processor can load the initialization information corresponding to the custom indicator rule (i.e., indicator rule) from the relevant data table. With this initialization information, the indicator template and indicator template parameters can be assembled according to the configuration to generate the corresponding SQL script. The SQL script is an indicator rule adapted to the monitored object. Furthermore, when the loaded SQL indicator rule is applied to the monitored object, the monitoring task can be executed, and the monitoring result can be generated after the monitoring task is executed.
[0141] It should be noted that since the system has already established the association between indicator rules and regulatory objects, regulatory tasks can be executed based on the execution script for the generated regulatory objects. The association logic between the two will not be elaborated here.
[0142] Therefore, the embodiments of this application can perform task supervision, enabling the system to respond quickly to market supervision requirements and improving the timeliness of the system in responding to regulatory needs.
[0143] Optionally, the method further includes:
[0144] When it is determined that the regulatory results do not meet the regulatory requirements, abnormal data is found in the regulatory data, and alarm information is generated based on the abnormal data. The alarm information is then visualized to remind the user that there is an operational abnormality.
[0145] In this embodiment of the application, the alarm information may refer to information used to remind users that the regulatory results do not meet the regulatory requirements. For example, the regulatory requirement is that there are securities holdings in the asset portfolio and the redemption date of the securities is less than 10 days. However, the abnormal data in the regulatory data is that there are securities holdings in the asset portfolio and the redemption date of the securities is more than 10 days. Then, an alarm information is generated based on the abnormal data, and relevant prompts are given to the business personnel.
[0146] The method of visually displaying alarm information to remind users is not specifically limited in this embodiment. It can be sent to the user's terminal device in the form of SMS or displayed directly on the corresponding display device of the system.
[0147] Therefore, the embodiments of this application can generate alarm prompts for anomalies encountered during the supervision process, making it convenient for users to detect anomalies in a timely manner and reduce losses caused by risks.
[0148] In the foregoing embodiments, the indicator rule generation method provided by the embodiments of this application has been described. To implement the functions of the methods provided by the embodiments of this application, the electronic device serving as the execution subject may include hardware structures and / or software modules, implementing the above functions in the form of hardware structures, software modules, or a combination of hardware structures and software modules. Whether a particular function is executed in the form of hardware structures, software modules, or a combination of hardware structures and software modules depends on the specific application and design constraints of the technical solution.
[0149] For example, Figure 5 This is a schematic diagram of the structure of an index rule generation device provided in an embodiment of this application, as shown below. Figure 5 As shown, the device includes: a calling module 510, a judging module 520, a first generation module 530, and a second generation module 540; wherein, the calling module 510 is used to obtain business scenario requirements and the regulatory data required by the business scenario requirements, and to call the corresponding indicator template from the predefined template library based on the business scenario requirements; the indicator template is configured with at least one indicator parameter; each indicator parameter corresponds to an executable code statement;
[0150] The judgment module 520 is used to determine whether the indicator parameters corresponding to the indicator template meet the requirements of the business scenario.
[0151] The first generation module 530 is used to respond to the first operation of the user setting the indicator parameters when the indicator parameters corresponding to the indicator template meet the business scenario requirements, concatenate the code statements corresponding to the indicator parameters to generate the first operation logic of the indicator rules, and generate the indicator rules based on the first operation logic and the regulatory data.
[0152] The second generation module 540 is used to, when the indicator parameters corresponding to the indicator template do not meet the business scenario requirements, respond to the second operation of the user setting indicator parameters, obtain the target indicator parameters that meet the business scenario requirements from the predefined template library, concatenate the code statements corresponding to the target indicator parameters, generate the second operation logic of the indicator rules, and generate the indicator rules based on the second operation logic and the regulatory data.
[0153] Optionally, the calling module 510 is specifically used for:
[0154] Obtain business scenario requirements and initial regulatory data, and perform calculations on the initial regulatory data to obtain the calculation results;
[0155] The calculation result is compared with the regulatory threshold corresponding to the business scenario requirement to determine the regulatory data required for the business scenario requirement.
[0156] Based on the business scenario requirements, determine the data type corresponding to the regulatory data, and based on the data type, determine the field codes corresponding to the indicator templates;
[0157] The corresponding indicator template is called from the predefined template library using the field code.
[0158] Optionally, the first generation module 530 includes a splicing unit and a first generation unit; the splicing unit is used for:
[0159] In response to the first operation of the user selecting an indicator parameter and assigning a value to the user-selected indicator parameter, a first parameter range of the indicator parameter is generated.
[0160] Obtain the parameter name of the indicator parameter, call the code statement corresponding to the indicator parameter from the parameter table based on the parameter name, and concatenate the first parameter range and the code statement to generate the first operation logic of the indicator rule.
[0161] Optionally, the first generation unit is used for:
[0162] The regulatory data is processed based on the first calculation logic to obtain a regulatory prompt result;
[0163] Determine whether the regulatory prompt result meets the preset requirements;
[0164] If so, then indicator rules are generated based on the first calculation logic and the indicator parameters.
[0165] Optionally, the second generation module 540 is specifically used for:
[0166] In response to the parameter information of the user-input indicator parameter and the second operation of assigning a value to the user-input indicator parameter, a second parameter range of the indicator parameter is generated;
[0167] Based on the parameter information, a first indicator parameter that meets the requirements of the business scenario is found from the indicator parameters corresponding to the indicator template, and a second indicator parameter that meets the requirements of the business scenario is obtained from the predefined template library based on the parameter information and the first indicator parameter.
[0168] The first indicator parameter and the second indicator parameter are summarized to obtain the target indicator parameter corresponding to the business scenario requirements;
[0169] Obtain the parameter name of the target indicator parameter, call the code statement corresponding to the target indicator parameter from the parameter table based on the parameter name, and concatenate the second parameter range and the code statement to generate the second operation logic of the indicator rule.
[0170] Optionally, the device further includes an execution module, the execution module being configured to:
[0171] Obtain the initialization information corresponding to the indicator rule, and configure the corresponding execution indicator template and execution template parameters based on the initialization information;
[0172] An execution script is generated based on the execution indicator template and the execution template parameters, and the execution script is used to perform the regulatory task to obtain the regulatory result.
[0173] Optionally, the device further includes an alarm module, the alarm module being used for:
[0174] When it is determined that the regulatory results do not meet the regulatory requirements, abnormal data is found in the regulatory data, and alarm information is generated based on the abnormal data. The alarm information is then visualized to remind the user that there is an operational abnormality.
[0175] The specific implementation principle and effects of the indicator rule generation device provided in this application embodiment can be found in the relevant descriptions and effects of the above embodiments, and will not be elaborated further here.
[0176] This application also provides a schematic diagram of the structure of an electronic device. Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application, such as... Figure 6 As shown, the electronic device may include: a processor 601 and a memory 602 communicatively connected to the processor; the memory 602 stores a computer program; the processor 601 executes the computer program stored in the memory 602, causing the processor 601 to perform the method described in any of the above embodiments.
[0177] The memory 602 and the processor 601 can be connected via bus 603.
[0178] This application also provides a computer-readable storage medium storing computer program execution instructions, which, when executed by a processor, are used to implement the methods described in any of the foregoing embodiments of this application.
[0179] This application also provides a chip for executing instructions, which is used to perform the methods described in any of the foregoing embodiments executed by an electronic device as described in any of the foregoing embodiments of this application.
[0180] This application also provides a computer program product, which includes program code. When a computer runs the computer program, the program code executes the method described in any of the foregoing embodiments of this application as executed by an electronic device.
[0181] The collection, storage, use, processing, transmission, provision, and disclosure of financial data or user data involved in the technical solution of this application all comply with the provisions of relevant laws and regulations and do not violate public order and good morals.
[0182] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of modules is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple modules 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 through some interfaces; the indirect coupling or communication connection between apparatuses or modules may be electrical, mechanical, or other forms.
[0183] The modules described as separate components may or may not be physically separate. The components shown as modules 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 modules can be selected to implement the solution of this embodiment according to actual needs.
[0184] Furthermore, the functional modules in the various embodiments of this application can be integrated into one processing unit, or each module can exist physically separately, or two or more modules can be integrated into one unit. The unit composed of the above modules can be implemented in hardware or in the form of hardware plus software functional units.
[0185] The integrated modules implemented as software functional modules described above can be stored in a computer-readable storage medium. These software functional modules, stored in a storage medium, include several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) or processor to execute some steps of the methods described in the various embodiments of this application.
[0186] It should be understood that the aforementioned processor can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), etc. A general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in the application can be directly manifested as being executed by a hardware processor, or executed by a combination of hardware and software modules within the processor.
[0187] The memory may include high-speed random access memory (RAM) or non-volatile memory (NVM), such as at least one disk storage device, and may also be a USB flash drive, external hard drive, read-only memory, disk or optical disc, etc.
[0188] The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. Buses can be categorized as address buses, data buses, control buses, etc. For ease of illustration, the buses shown in the accompanying drawings are not limited to a single bus or a single type of bus.
[0189] The aforementioned storage media can be implemented from any type of volatile or non-volatile storage device or a combination thereof, such as Static Random-Access Memory (SRAM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Erasable Programmable Read-Only Memory (EPROM), Programmable Read-Only Memory (PROM), Read-Only Memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk. The storage media can be any available medium accessible to general-purpose or special-purpose computers.
[0190] An exemplary storage medium is coupled to a processor, enabling the processor to read information from and write information to the storage medium. Alternatively, the storage medium can be an integral part of the processor. Both the processor and the storage medium can reside in an Application Specific Integrated Circuit (ASIC). Alternatively, the processor and storage medium can exist as discrete components in an electronic device or host device.
[0191] The above description is merely a specific implementation of the embodiments of this application, but the protection scope of the embodiments of this application is not limited thereto. Any changes or substitutions within the technical scope disclosed in the embodiments of this application should be covered within the protection scope of the embodiments of this application. Therefore, the protection scope of the embodiments of this application should be determined by the protection scope of the claims.
Claims
1. A method for generating indicator rules, characterized in that, The method includes: The system acquires the business scenario requirements and the regulatory data required for those requirements, and calls the corresponding indicator template from the predefined template library based on those requirements. Each indicator template is configured with at least one indicator parameter. Each indicator parameter corresponds to an executable code statement. The predefined template library is a database used to store indicator templates, indicator parameters, and the code statements for each indicator parameter. Determine whether the indicator parameters corresponding to the indicator template meet the requirements of the business scenario. If so, in response to the user's first operation of setting indicator parameters, the code statements corresponding to the indicator parameters are concatenated to generate the first operation logic of indicator rules, and the indicator rules are generated based on the first operation logic and the regulatory data. If not, in response to the second operation of setting indicator parameters by the user, the target indicator parameters that meet the requirements of the business scenario are obtained from the predefined template library, the code statements corresponding to the target indicator parameters are concatenated to generate the second operation logic of the indicator rules, and the indicator rules are generated based on the second operation logic and the regulatory data. In response to the second operation of setting indicator parameters by the user, the target indicator parameters that meet the requirements of the business scenario are obtained from the predefined template library. Based on the code statements corresponding to the target indicator parameters, the second calculation logic of the indicator rules is generated by concatenating them, including: In response to the parameter information of the user-input indicator parameter and the second operation of assigning a value to the user-input indicator parameter, a second parameter range of the indicator parameter is generated; Based on the parameter information, a first indicator parameter that meets the requirements of the business scenario is found from the indicator parameters corresponding to the indicator template, and a second indicator parameter that meets the requirements of the business scenario is obtained from the predefined template library based on the parameter information and the first indicator parameter. The first indicator parameter and the second indicator parameter are summarized to obtain the target indicator parameter corresponding to the business scenario requirements; Obtain the parameter name of the target indicator parameter, call the code statement corresponding to the target indicator parameter from the parameter table based on the parameter name, and concatenate the second parameter range and the code statement to generate the second operation logic of the indicator rule.
2. The method according to claim 1, characterized in that, Obtain the business scenario requirements and the regulatory data needed for those requirements, and call the corresponding indicator templates from the predefined template library based on the business scenario requirements, including: Obtain business scenario requirements and initial regulatory data, and perform calculations on the initial regulatory data to obtain the calculation results; The calculation result is compared with the regulatory threshold corresponding to the business scenario requirement to determine the regulatory data required for the business scenario requirement. Based on the business scenario requirements, determine the data type corresponding to the regulatory data, and based on the data type, determine the field codes corresponding to the indicator templates; The corresponding indicator template is called from the predefined template library using the field code.
3. The method according to claim 1, characterized in that, In response to the user's first operation of setting indicator parameters, the first calculation logic for generating indicator rules is generated by concatenating the code statements corresponding to the indicator parameters, including: In response to the first operation of the user selecting an indicator parameter and assigning a value to the user-selected indicator parameter, a first parameter range of the indicator parameter is generated. Obtain the parameter name of the indicator parameter, call the code statement corresponding to the indicator parameter from the parameter table based on the parameter name, and concatenate the first parameter range and the code statement to generate the first operation logic of the indicator rule.
4. The method according to claim 3, characterized in that, Based on the first computational logic and the regulatory data, indicator rules are generated, including: The regulatory data is processed based on the first calculation logic to obtain a regulatory prompt result; Determine whether the regulatory prompt result meets the preset requirements; If so, then indicator rules are generated based on the first calculation logic and the indicator parameters.
5. The method according to any one of claims 1-4, characterized in that, The method further includes: Obtain the initialization information corresponding to the indicator rule, and configure the corresponding execution indicator template and execution template parameters based on the initialization information; An execution script is generated based on the execution indicator template and the execution template parameters, and the execution script is used to perform the regulatory task to obtain the regulatory result.
6. The method according to claim 5, characterized in that, The method further includes: When it is determined that the regulatory results do not meet the regulatory requirements, abnormal data is found in the regulatory data, and alarm information is generated based on the abnormal data. The alarm information is then visualized to remind the user that there is an operational abnormality.
7. An indicator rule generation device, characterized in that, The device includes: The calling module is used to obtain the business scenario requirements and the regulatory data required by the business scenario requirements, and to call the corresponding indicator template from the predefined template library based on the business scenario requirements; the indicator template is configured with at least one indicator parameter; each indicator parameter corresponds to an executable code statement; wherein, the predefined template library is a database used to store indicator templates, indicator parameters, and the code statement for each indicator parameter; The judgment module is used to determine whether the indicator parameters corresponding to the indicator template meet the requirements of the business scenario. The first generation module is used to respond to the user's first operation of setting indicator parameters when the indicator parameters corresponding to the indicator template meet the business scenario requirements, and to concatenate the code statements corresponding to the indicator parameters to generate the first operation logic of indicator rules, and generate indicator rules based on the first operation logic and the regulatory data. The second generation module is used to, when the indicator parameters corresponding to the indicator template do not meet the business scenario requirements, respond to the second operation of the user setting indicator parameters, obtain the target indicator parameters that meet the business scenario requirements from the predefined template library, concatenate the code statements corresponding to the target indicator parameters, generate the second operation logic of the indicator rules, and generate the indicator rules based on the second operation logic and the regulatory data. The second generation module is specifically used for: In response to the parameter information of the user-input indicator parameter and the second operation of assigning a value to the user-input indicator parameter, a second parameter range of the indicator parameter is generated; Based on the parameter information, a first indicator parameter that meets the requirements of the business scenario is found from the indicator parameters corresponding to the indicator template, and a second indicator parameter that meets the requirements of the business scenario is obtained from the predefined template library based on the parameter information and the first indicator parameter. The first indicator parameter and the second indicator parameter are summarized to obtain the target indicator parameter corresponding to the business scenario requirements; Obtain the parameter name of the target indicator parameter, call the code statement corresponding to the target indicator parameter from the parameter table based on the parameter name, and concatenate the second parameter range and the code statement to generate the second operation logic of the indicator rule.
8. An electronic device, characterized in that, include: A processor, and a memory communicatively connected to the processor; The memory stores computer-executed instructions; The processor executes computer execution instructions stored in the memory to implement the method as described in any one of claims 1-6.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions, which, when executed by a processor, are used to implement the method as described in any one of claims 1-6.
10. A computer program product, characterized in that, Includes program code that, when the computer runs the computer program, performs the method as described in any one of claims 1-6.