Model construction method and apparatus
Patent Information
- Application Number
- PCT/CN2024/087523
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2024-03-04
- Filing Date
- 2024-04-12
- Publication Date
- 2025-10-02
AI Technical Summary
Due to complex financial products and business needs, constantly adjusted calculation rules, and massive and diverse data, existing actuarial models have chaotic and redundant model structures, a lot of repetitive code, are difficult to maintain and update, and have low work efficiency.
The inheritance relationship between classes is visualized through the hierarchical relationship of the class tree nodes, and new nodes can be quickly created under the target node by adding controls through subclasses, realizing visual inheritance, simplifying the model structure, and reducing repetitive code.
It effectively simplifies the model structure, reduces 50%-80% of code and variable modifications, reduces the probability of modeling errors, and improves the efficiency of model maintenance and updating.
Smart Images

Figure CN2024087523_02102025_PF_FP_ABST
Abstract
Description
Model building method and device
[0001] This application claims priority to Chinese patent application number 202410240306.8, filed on March 4, 2024, entitled “Model Building Method and Device.” The entire content of this Chinese patent application is incorporated by reference into this application. Technical Field
[0002] The embodiments of the present application relate to the field of computer technology, and in particular to a model building method, apparatus, computer equipment, and computer-readable storage medium. Background Art
[0003] Actuarial models are used to assess risk and calculate associated costs to support insurance, investment, and other financial decisions. However, complex financial products and business requirements, constantly changing calculation rules, and massive amounts of diverse data present multiple challenges for actuarial modeling. These challenges can lead to disorganized and redundant models, a large amount of repetitive code, difficulty in maintenance and updates, and reduced efficiency.
[0004] It should be noted that the above content is not necessarily prior art, nor is it intended to limit the scope of patent protection of this application.
[0005] Summary of the Invention
[0006] The embodiments of the present application provide a model building method, apparatus, computer device, and computer-readable storage medium to solve or alleviate one or more technical problems raised above.
[0007] One aspect of an embodiment of the present application provides a model construction method for visually displaying and creating inheritance relationships between classes through the hierarchical relationship of class tree nodes, so as to create a model using a visual tree structure in a visual environment; the method includes:
[0008] Display the model configuration interface configured with a tree-like control;
[0009] In response to selecting the class tree control, an interface for displaying a class tree is displayed, wherein the class tree includes a plurality of nodes, each node corresponds to a class, and is configured with a subclass adding control;
[0010] In response to selecting a subclass adding control of a target node, displaying a first subclass adding interface for receiving class information;
[0011] According to the received class information, an updated class tree is displayed on the interface, wherein the updated class tree includes a newly added node located one level below the target node, and the class corresponding to the newly added node inherits from the class corresponding to the target node.
[0012] Another aspect of the embodiments of the present application provides a model building device, the device comprising:
[0013] A first display module is used to display a model configuration interface configured with a tree-like control;
[0014] a second display module, configured to display an interface for displaying a class tree in response to selection of the class tree control, wherein the class tree includes a plurality of nodes, each node corresponds to a class, and is configured with a subclass adding control;
[0015] a third display module, configured to display a first subclass adding interface for receiving class information in response to selecting a subclass adding control of a target node;
[0016] The fourth display module is used to display the updated class tree according to the received class information, wherein the updated class tree includes a new node located at a level below the target node, and the class corresponding to the new node inherits from the class corresponding to the target node.
[0017] Another aspect of an embodiment of the present application provides a computer device, including:
[0018] at least one processor; and
[0019] a memory communicatively coupled to the at least one processor;
[0020] Wherein: the memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method described above.
[0021] Another aspect of an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer instructions, and when the computer instructions are executed by a processor, the method described above is implemented.
[0022] The above technical solution adopted in the embodiments of the present application may have the following advantages:
[0023] A model configuration interface including a class tree control is displayed on the terminal. Selecting the class tree control can trigger the display of an interface for displaying the class tree. Among them, the class tree can be composed of multiple nodes, and each node corresponds to a class. The node is configured with a subclass adding control. When the subclass adding control of the target node is selected, the first subclass adding interface for receiving class information is triggered (configurable class code input box, class name input box and confirmation control). The user can select OK after entering the class code and class name. The class tree after the new node is updated can be displayed through the interface. The new node is located at the next level of the target node, and the class corresponding to the new node inherits from the class corresponding to the target node. It can be seen that the embodiment of the present application can visualize the inheritance relationship between the various classes through the hierarchical relationship of the class tree nodes, and quickly create a new node (subclass) under the target node (parent class) through the subclass adding control to achieve visual inheritance, so that the model structure is simplified and repetitive code is reduced. For example, in life insurance, critical illness insurance products belong to traditional insurance products. New nodes (such as critical illness insurance products) can redefine some variables after inheriting the target node (such as traditional insurance products), thereby building a critical illness insurance model based on the existing traditional insurance model. Critical illness insurance products can directly inherit most of the variables and tables that are not related to critical illness in traditional insurance products without definition. They only need to redefine individual variables and tables related to critical illness, omitting a large amount of if else code in traditional insurance products. This can reduce the overall code, variable and table modifications by 50%-80%, greatly reducing the probability of modeling errors. Any modification to a subclass does not affect the code, variables and tables of its parent class, which is equivalent to encapsulating and isolating the relevant variable code under the parent class. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] The accompanying drawings illustrate exemplary embodiments and constitute a part of the specification. Together with the description of the specification, they serve to explain exemplary implementation of the embodiments. The illustrated embodiments are for illustrative purposes only and do not limit the scope of the claims. Throughout the drawings, the same reference numerals designate similar, but not necessarily identical, elements.
[0025] FIG1 schematically shows a flow chart of a model building method according to Embodiment 1 of the present application;
[0026] FIG2 schematically shows a model configuration interface according to the first embodiment of the present application;
[0027] FIG3 schematically shows an interface according to the first embodiment of the present application;
[0028] FIG4 schematically illustrates a subclass adding control, a deleting control, and an editing control of a node according to the first embodiment of the present application;
[0029] FIG5 schematically shows a first subcategory adding interface according to the first embodiment of the present application;
[0030] FIG6 schematically shows an editing interface according to the first embodiment of the present application;
[0031] FIG7 schematically shows a new class creation interface according to the first embodiment of the present application;
[0032] FIG8 schematically shows a class tree selection box according to the first embodiment of the present application;
[0033] FIG9 schematically shows a second subcategory adding interface according to the first embodiment of the present application;
[0034] FIG10 schematically shows a variable management interface according to the first embodiment of the present application;
[0035] FIG11 schematically shows a variable creation interface according to the first embodiment of the present application;
[0036] FIG12 schematically shows a first-level dependency interface according to the first embodiment of the present application;
[0037] FIG13 schematically shows a first-level dependency interface according to the first embodiment of the present application;
[0038] FIG14 schematically shows a secondary dependency interface according to the first embodiment of the present application;
[0039] FIG15 schematically shows a secondary dependency interface according to the first embodiment of the present application;
[0040] FIG16 schematically shows a secondary dependency interface according to the first embodiment of the present application;
[0041] FIG17 schematically shows a secondary dependency interface according to the first embodiment of the present application;
[0042] FIG18 schematically shows a secondary dependency interface according to the first embodiment of the present application;
[0043] FIG19 schematically shows a block diagram of a model building device according to the second embodiment of the present application; and
[0044] Figure 20 schematically shows a hardware architecture diagram of a computer device according to Example 3 of the present application. DETAILED DESCRIPTION
[0045] In order to make the purpose, technical solutions and advantages of this application more clear, the present application is further described in detail below with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are only used to explain this application and are not intended to limit this application. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.
[0046] It should be noted that the descriptions of "first", "second", etc. in the embodiments of the present application are for descriptive purposes only and should not be understood as indicating or implying their relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" or "second" may explicitly or implicitly include at least one of such features. In addition, the technical solutions between the various embodiments can be combined with each other, but this must be based on the fact that they can be implemented by ordinary technicians in this field. When the combination of technical solutions is contradictory or cannot be implemented, it should be deemed that such a combination of technical solutions does not exist and is not within the scope of protection required by this application.
[0047] In the description of this application, it should be understood that the numerical labels before the steps do not indicate the order in which the steps are executed. They are only used to facilitate the description of this application and to distinguish each step. Therefore, they cannot be understood as limitations on this application.
[0048] To facilitate those skilled in the art to understand the technical solutions provided in the embodiments of the present application, the following describes the relevant technologies:
[0049] Actuarial models can be used to assess risks and calculate related costs to support insurance, investment, and other financial decisions. However, complex financial products and business requirements, constantly adjusting calculation rules, and massive amounts of diverse data pose multiple challenges to the original actuarial modeling based on procedural and structured programming. This leads to chaotic and redundant structures in actuarial models, large amounts of repetitive code, difficulty in maintenance and updating, and reduced work efficiency. Although general object-oriented programming can solve the related problems of chaotic structures and complex variable reference relationships, its difficulty is too high for modelers without many years of programming experience, and there is a lack of a visual environment to properly understand the relationships between different modules of the model.
[0050] To this end, embodiments of this application provide a technical solution for model building in an actuarial system. This solution visualizes the inheritance relationships between classes through the hierarchical relationships of class tree nodes, and implements visual inheritance by quickly creating new nodes (subclasses) under the target node (parent class) using subclass add controls. This simplifies the model structure, reduces repetitive code, facilitates model updates and maintenance, and improves work efficiency. See below for details.
[0051] The technical solutions of the present application are described below through a number of embodiments. It should be noted that these embodiments can be implemented in a variety of different forms and should not be construed as being limited to the embodiments described herein.
[0052] Example 1
[0053] FIG1 schematically shows a flow chart of a model building method according to the first embodiment of the present application.
[0054] As shown in FIG1 , the model building method may include steps S100 to S106 , wherein:
[0055] Step S100: Displaying a model configuration interface configured with a tree-like control.
[0056] Step S102 : in response to selecting the class tree control, displaying an interface for displaying a class tree, wherein the class tree includes a plurality of nodes, each node corresponds to a class, and is configured with a subclass adding control.
[0057] Step S104 : in response to selecting the subclass adding control of the target node, displaying a first subclass adding interface for receiving class information.
[0058] Step S106 , displaying an updated class tree on the interface according to the received class information, wherein the updated class tree includes a newly added node located one level below the target node, and the class corresponding to the newly added node inherits from the class corresponding to the target node.
[0059] The model building method provided in this embodiment displays a model configuration interface including a class tree control on the terminal. Selecting the class tree control can trigger the display of an interface for displaying the class tree. Among them, the class tree can be composed of multiple nodes, and each node corresponds to a class. The node is configured with a subclass adding control. When the subclass adding control of the target node is selected, it triggers the display of the first subclass adding interface including a class code input box, a class name input box and a confirmation control. The user can select OK after entering the class code and class name. The class tree after the new node is updated can be displayed through the interface. The new node is located at the next level of the target node, and the class corresponding to the new node inherits from the class corresponding to the target node. It can be seen that the embodiment of the present application can visualize the inheritance relationship between the various classes through the hierarchical relationship of the class tree nodes, and quickly create a new node (subclass) under the target node (parent class) through the subclass adding control to realize visual inheritance, so that the model structure is simplified and repetitive code is reduced. For example, in life insurance, critical illness insurance products belong to traditional insurance products. New nodes (such as critical illness insurance products) can redefine some variables after inheriting the target node (such as traditional insurance products), thereby building a critical illness insurance model based on the existing traditional insurance model. Critical illness insurance products do not need to be defined and can directly inherit most of the variables and tables that are not related to critical illness in traditional insurance products. They only need to redefine individual variables and tables related to critical illness, omitting a large amount of if else code in traditional insurance products. The overall code, variable and table modifications can be reduced by 50%-80%, greatly reducing the probability of modeling errors. Any modification to a subclass (such as a critical illness product) does not affect the code, variables and tables of its parent class (such as a traditional insurance product), which is equivalent to encapsulating and isolating the relevant variable code under the parent class.
[0060] The following describes in detail each step in steps S100 to S106 and other optional steps in conjunction with FIG. 1 .
[0061] Step S100: displaying a configuration interface of a tree-like control model.
[0062] Take the construction of an actuarial model as an example: an actuarial model may involve different types of insurance products, risk factors, investment strategies, and so on. To better model these, object-oriented programming can be employed. Specifically, the actuarial model is broken down into multiple classes, each responsible for a specific function. However, large-scale projects such as actuarial calculations often involve a large number of classes, and the relationships between these classes are complex, which can easily lead to problems such as a chaotic and redundant actuarial model structure. Therefore, to optimize the structure of the actuarial model, embodiments of the present application utilize a visual model configuration interface to construct and manage the actuarial model.
[0063] Exemplarily, the model configuration interface is displayed on the user terminal. The model configuration interface can customize various controls according to actual needs, which is convenient for flexible configuration and adjustment of the actuarial model. As shown in Figure 2, the model configuration interface can be used for the construction of multiple models. Taking the illustrated model "LIAB_SSL_v2" as an example, the model configuration interface can also provide a corresponding hierarchical menu, the first-level menu of which may include controls such as "Design", "Product", "Data" and "Output", and the second-level menu may include controls such as "Class (class tree control)" and "Variable (variable control)". It can be seen that the hierarchical menu can be used for the design, product, data and output of the model LIAB_SSL_v2. Organizing multiple controls in a hierarchical structure through a hierarchical menu can effectively improve the efficiency of model construction.
[0064] Step S102 : in response to selecting the class tree control, displaying an interface for displaying a class tree, wherein the class tree includes a plurality of nodes, each node corresponds to a class, and is configured with a subclass adding control.
[0065] As shown in Figure 3, when the class tree control (Class) is selected, the display interface can be triggered. The interface can be used to maintain and display the class tree, including but not limited to the addition, deletion and modification of the class tree, and the addition, deletion and modification of nodes in the class tree. Among them, there can be multiple class trees, each class tree includes multiple nodes, and each node corresponds to a class. Therefore, the inheritance relationship between each class can be visually displayed through the hierarchical relationship of the nodes in the class tree. For example: the scenario class tree is used to assume various scenarios. The class corresponding to its root node is Mortality Scenario (mortality scenario), and the class corresponding to the node under the root node, Base Mortality Scenario (basic mortality scenario), is a subclass that inherits Mortality Scenario. For example, a product class tree can be used to represent the products involved in an actuarial model. Its root node corresponds to the class Product. The node below the root node corresponds to the class Long Term Life Product, which is a subclass of Product. This node can also have multiple nodes below it, corresponding to the classes Participating Life Product and Traditional Life Product, both of which inherit from the class Long Term Life Product. This embodiment divides the actuarial model into multiple class trees and uses a tree structure to visually display the inheritance relationships between the classes, making the entire model structure clearer and easier to manage and maintain.
[0066] As shown in FIG4 , each node may also be configured with a subclass adding control, which may be used to create a subclass of the class corresponding to the node, and to update and maintain the class tree. An exemplary solution is provided below.
[0067] Step S104 : in response to selecting the subclass adding control of the target node, displaying a first subclass adding interface for receiving class information.
[0068] The target node can be any node in any class tree displayed on the interface. When the subclass add control for the target node is selected, the first subclass add interface will be triggered. As shown in Figure 5, this first subclass add interface can be displayed in a floating layer above the interface or displayed within the interface. The first subclass add interface includes at least a class code input box, a class name input box, and a confirmation control.
[0069] Users can edit the class code in the class code input box and edit the class name in the class name input box. The class code can be a synonym for the class name.
[0070] Step S106 , displaying an updated class tree on the interface according to the received class information, wherein the updated class tree includes a newly added node located one level below the target node, and the class corresponding to the newly added node inherits from the class corresponding to the target node.
[0071] When the control is confirmed to be selected, a class is created based on the received class code and class name, and the interface is updated to display a class tree including the newly added node. The newly added node is located one level below the target node, and can intuitively show that the class corresponding to the newly added node inherits from the class corresponding to the target node. As can be seen, this embodiment achieves visual inheritance by quickly creating a new node (child class) under the target node (parent class), which can effectively simplify the model structure and reduce repetitive code.
[0072] The above embodiment describes how to implement visual inheritance and simplify the model structure by adding a new node under the target node in the class tree. More exemplary solutions for optimizing the model structure will be provided below.
[0073] In an optional embodiment, each node is also configured with a delete control; the method further includes: in response to the delete control of the selected target node, if the target node has no next-level node, displaying the class tree after deleting the target node on the interface; if the target node has a next-level node, displaying an alarm message on the interface.
[0074] As shown in Figure 4, each node can also be configured with a delete control. When the delete control of the target node is selected, it is necessary to check whether the target node has a next-level node. If the target node does not have a next-level node, it means that it is a terminal node (leaf node), and the corresponding class is not used to derive other classes. Therefore, directly deleting the target node and its corresponding class will not affect other classes. After the deletion is completed, the class tree after deleting the target node is displayed on the interface. If the target node has a next-level node, it means that the class corresponding to the target node has subclasses. Directly deleting the target node and its corresponding class will destroy the inheritance relationship, dependency relationship, etc., thereby causing model errors. Therefore, when the target node has a next-level node, an alarm message can be triggered to prompt that there are other nodes under the target node. The user can cancel the deletion or choose to continue deleting the target node and all its child nodes to reduce errors.
[0075] In this embodiment, the nodes of the class tree and their corresponding classes are deleted by configuring a delete control, and the rationality of the deletion operation is confirmed according to the tree structure during the deletion process to reduce the damage to the inheritance relationship and ensure the stability of the model structure.
[0076] In an optional embodiment, each node is also configured with an editing control, and the method further includes: in response to selecting the editing control of the target node, displaying an editing interface, the editing interface is used to update the target node and the class corresponding to the target node, the editing interface including a class code modification box, a class name modification box, an adjustment control and a first save control; receiving the latest class code and class name through the class code modification box and the class name modification box; in response to selecting the adjustment control, determining whether the target node is a terminal node; in response to selecting the first save control, displaying the class tree after updating the target node on the interface.
[0077] As shown in Figure 4, each node can also be configured with an edit control (Edit). Selecting the edit control for the target node triggers the display of the editing interface. As shown in Figure 6, the editing interface may include a class code edit box, a class name edit box, an adjustment control, and a first save control. The class code edit box and the class name edit box are used to receive the latest class code and class name, and the adjustment control is used to determine whether the target node is a terminal node. When the adjustment control (Is Terminal) is enabled, the target node is a terminal node, and the class corresponding to the target node cannot be used to derive other classes, meaning that the target node has no next-level nodes. In this case, selecting the first save control displays the updated class tree for the target node on the interface, and the updated subclass add control for the target node is set to uncheckable, meaning that other classes cannot inherit the class corresponding to the target node. When the adjustment control is disabled, the target node is no longer a terminal node, and the class corresponding to the target node can be used to derive other classes, and the target node can have next-level nodes. In this case, selecting the first save control displays the updated class tree for the target node on the interface, and the updated subclass add control for the target node is set to checkable, allowing the creation of subclasses that inherit the target node's class.
[0078] In this embodiment, whether a class can be inherited can be flexibly adjusted by configuring the editing control, so as to promote code reuse or achieve stricter encapsulation.
[0079] In some embodiments, as shown in FIG5 , the first subclass adding interface may further include an adjustment control (Is Terminal) for determining whether the added subclass can be inherited by other classes.
[0080] In an optional embodiment, the interface includes a creation control, and the method further includes: in response to selecting the creation control, displaying a new class creation interface, the new class creation interface including a class code input box, a class name input box and a second save control; receiving the class code and class name of the new class through the class code input box and the class name input box respectively; in response to selecting the second save control, displaying a new class tree on the interface, the root node of the new class tree corresponding to the created new class.
[0081] As shown in Figure 3, the interface can also include a creation control. When the creation control is selected, the new class creation interface is triggered to be displayed. As shown in Figure 7, the new class creation interface includes a class code input box, a class name input box and a second save control. Among them, the class code modification box and the class name modification box are used to receive the class code and class name of the new class, and the second save control is used to trigger the creation of a new class and a new class tree. After selecting the second save control, the new class tree is displayed on the interface, and the root node of the new class tree represents the new class created. Subsequently, other nodes can be created under the root node as required, so that the created new class can be inherited by other classes to improve code reusability.
[0082] In this embodiment, a new class and a new class tree can be created by creating a control, which not only adds methods and properties to the model but also ensures the simplicity of the model structure, facilitating subsequent management and maintenance.
[0083] The above examples illustrate how to optimize the model structure and reduce code reuse by building an actuarial model using multiple class trees. In practical applications, inheritance can lead to tight coupling and complex hierarchies. To further optimize the model structure, a loose coupling approach can be adopted. An exemplary solution is provided below.
[0084] In an optional embodiment, the new class creation interface also includes a first association control, and the method also includes: in response to selecting the first association control, displaying a class tree selection box; determining the target class tree through the class tree selection box; in response to selecting a second save control, displaying a new class tree on the interface, and the new class tree is associated with the target class tree.
[0085] As shown in Figure 7, the new class creation interface can also include a first association control (Is Trait). When the first association control is selected, a class tree selection box (Of Class) is displayed, as shown in Figure 8. Click the class tree selection box to display a class tree list. The class tree list includes all class trees displayed on the interface, that is, the class trees currently possessed by the model. The target class tree is determined through the class tree list. After the second save control is selected, a new class tree is displayed on the interface. The new class tree is associated with the target class tree and can use the functions of the target class tree while ensuring flexibility and encapsulation.
[0086] In this embodiment, the newly created class tree is associated with the existing class tree through composition rather than direct inheritance, which provides greater flexibility and is not limited by a single inheritance hierarchy. This loose coupling makes it easier to modify and expand the model and further improves code reuse.
[0087] In an optional embodiment, the model building method may further include: in response to selecting a subclass adding control of any node in the new class tree, displaying a second subclass adding interface, the second subclass adding interface including a class code input box, a class name input box, a confirmation control and a second association control; determining one or more nodes in the target class tree through the association control; receiving the class code and the class name through the class code input box and the class name input box respectively; in response to selecting the confirmation control, updating the new class tree on the interface, wherein the updated new class tree includes a newly added node, and the class corresponding to the newly added node is associated with the class corresponding to one or more nodes in the target class tree.
[0088] Exemplarily, when any node in the new class tree is selected, the second subclass adding interface is triggered to be displayed. As shown in Figure 9, the second subclass adding interface includes a class code input box, a class name input box, a confirmation control and a second association control. Clicking the second association control triggers the display of the node list of the target class tree. Select one or more nodes in the node list, and receive the class code and class name through the class code input box and the class name input box respectively. After confirming that the control is selected, the new class tree is updated and displayed on the interface. The updated new class tree includes a newly added node, and the class corresponding to the newly added node is associated with the class corresponding to one or more nodes of the selected target class tree.
[0089] In this embodiment, the subclass created by the new class tree associated with the target class tree can also be associated with the class corresponding to any node in the target class tree, further realizing code reuse and ensuring the simplicity and stability of the model structure.
[0090] The above example demonstrates how combining and associating two class trees can further optimize the model structure and reduce code reuse. In practical applications, actuarial models often involve numerous classes, variables, and functions, which can easily lead to conflicts and errors. To ensure model stability, this can be avoided through methods such as unique naming. An exemplary solution is provided below.
[0091] In an optional embodiment, the model configuration interface also includes a variable control, and the method further includes: in response to selecting a variable control, displaying a variable management interface configured with a variable addition control, the variable management interface being used to display multiple variables corresponding to the class tree of the interface; in response to selecting a variable addition control, displaying a variable creation interface, the variable creation interface including a variable definition area, a multiple definition control and a third save control; receiving variable information through the variable definition area; in response to selecting the multiple definition control, displaying a class tree selection box to determine one or more target class trees through the class tree selection box; in response to selecting the third save control, displaying a newly added variable carrying the variable information on the variable management interface, the newly added variable corresponding to the one or more target class trees.
[0092] Exemplarily, as shown in Figure 2, the model configuration interface may also include a variable control. Select the variable control to trigger the display of the variable management interface. As shown in Figure 10, the variable creation interface includes a variable definition area, a multiple definition control and a third save control. Among them, the variable definition area includes a variable name input box, a variable type input box, and a description information input box, which are used to receive the variable name, variable type and description information (variable information) to create variables. Select the multiple definition space to display the class tree selection box (Classes). Click the class tree selection box to trigger the display of the class tree list. Determine one or more target class trees through the class tree list. When the third save control is selected, a new variable carrying variable information is displayed in the variable management interface, and the new variable corresponds to the selected one or more target class trees. That is, a reasonable scope is determined for the new variable, which effectively alleviates the conflict.
[0093] In this embodiment, selecting a target scope for a variable when creating the variable can effectively reduce conflicts.
[0094] In some embodiments, the model configuration interface may also include a Basic information control (Basic). When selected, this control triggers the display of a Basic information interface, which displays basic information about the model. The Basic information interface includes: Model Name, Description, Start of Projection, Primary Class, Output Class, Assumption Class, and Scenario Class. Each piece of information can be modified using the drop-down menu or text box provided in the Basic information interface.
[0095] In some embodiments, the model configuration interface may also include a field control (MP Field) and a table control (Table). The field control can be used to clean data, removing unnecessary fields from the data and reducing model processing pressure. The table control can be used to manage various data tables involved in the actuarial model, such as disease incidence tables, mortality tables, cash value tables, etc., to support related actuarial calculations.
[0096] In some embodiments, the model configuration interface may also include a dependency control (Dependency). When the dependency control is selected, the dependency analysis interface may be triggered to display. As shown in Figure 11, the dependency analysis interface is configured with a variable selection box, a product selection box, a hypothesis selection box, and a scenario selection box. The variable selection box can be used to arbitrarily select variables for the actuarial model. After selecting the target variable and selecting the product, hypothesis, and scenario for the target variable, the dependency analysis interface displays the dependency relationship between the target variable and other variables, as shown in Figure 11. Because specific product classes, hypothesis classes, and scenario classes have been selected for the target variable, the dependency relationship of the target variable can be uniquely determined. When the selected product class, hypothesis class, or scenario class changes, the dependency relationship of the target variable may change accordingly. In this embodiment, the dependency relationship can be precisely located, enabling visual analysis, making it easier to understand the model structure and the relationship between variables. Several exemplary embodiments are provided below.
[0097] In an optional embodiment, the model configuration interface may further include a dependency control. The method may further include: in response to selecting the dependency control, displaying a first-level dependency interface for receiving a target variable and a class associated with the target variable; and displaying a dependency graph corresponding to the target variable on the first-level dependency interface based on the target variable and the associated class; wherein the dependency graph includes a dependency tree for displaying variables associated with the target variable.
[0098] As shown in Figure 12, the model configuration interface can also configure a dependency control (Dependency). Clicking this dependency control triggers the display of the first-level dependency interface. As shown in Figure 12, the first-level dependency interface can be configured with multiple selection boxes for the user to select a specific variable (target variable) and a specific class (the class associated with the target variable). After the user selects the target variable and the associated class, the first-level dependency interface can automatically display the dependency graph corresponding to the target variable. The dependency graph can be a dependency tree to more clearly display the variables associated with the target variable through a tree structure. In an optional embodiment, the variables associated with the target variable can be variables referenced by the target variable and / or variables that reference the target variable. The following uses the target variable pv_risk_carr_pp as an example, and is explained in conjunction with Figure 12: After selecting the target variable pv_risk_carr_pp, associated classes can be selected to uniquely determine the target variable's dependencies. For example, in Figure 12, the target variable is associated with the product class (PROD), hypothesis class (ASMP), and scenario class (MORT-SCEN). Depending on the selected association class, the target variable's dependencies will also vary. Based on the selected target variable and associated class, the first-level dependency interface automatically generates and displays the dependencies corresponding to the target variable, including variables that reference the target variable (pv_risk_carr_if) and variables referenced by the target variable (disc_fac_m, max_proj_t, etc.).
[0099] In this embodiment, by configuring the first-level dependency interface, the dependency graph corresponding to the target variable is automatically loaded and displayed after receiving the target variable and associated class selected by the user, which helps to visually understand the relationship between the variables in the model so as to perform code optimization and refactoring.
[0100] In an optional embodiment, the method may further include: in response to selecting any variable associated with the target variable, updating and displaying a dependency graph corresponding to the selected variable on the first-level dependency interface.
[0101] For example, by clicking any variable (pv_risk_carr_if) in the dependency graph corresponding to the target variable pv_risk_carr_pp, the first-level dependency interface updates to display the dependency graph corresponding to pv_risk_carr_if, as shown in Figure 13. From the updated dependency graph, it can be quickly determined that the variable pv_risk_carr_if references the variables pv_risk_carr_pp and no_pols_if. The variable no_pols_if can be configured with a special flag to indicate that it has multiple definitions. Furthermore, the variable pv_risk_carr_if is not referenced by any other variables.
[0102] In this embodiment, by clicking on a variable in the target variable dependency graph, the first-level dependency interface can automatically generate and display the dependency graph corresponding to the selected variable to quickly analyze and determine the reference relationship between the selected variable and other variables in the model.
[0103] The dependency graph in the above embodiment only displays variables that have a direct reference relationship with the target variable or selected variable (the previous and / or next level in the dependency tree). When analyzing a large number of variables, this dependency graph requires searching one level at a time, resulting in low analysis efficiency and less intuitive analysis results. To address these issues, further exemplary embodiments are provided below.
[0104] In an optional embodiment, the dependency interface may also be configured with a switch control. The method further includes: in response to selecting the switch control, displaying a secondary dependency interface, the secondary dependency interface being used to display a dependency graph corresponding to the target variable, the dependency graph including a dependency tree and a dependency graph, the dependency tree and the dependency graph being used to display variables associated with the target variable; in response to selecting any variable in the dependency tree or the dependency graph, displaying the code associated with the selected variable in a layer above the selected variable.
[0105] As shown in Figures 12 and 13, a toggle control can be configured in the upper right corner of the first-level dependency interface. The position of the toggle control can be freely configured based on actual needs. Clicking the toggle control triggers the display of the second-level dependency interface. As shown in Figure 14, the second-level dependency interface can be used to simultaneously display the dependency tree and dependency graph corresponding to the target variable. Alternatively, the first display control (Dependency View) and the second display control (Reference View) can be set to switch between displaying the dependency tree and dependency graph on the second-level dependency interface. The dependency tree displays the variables associated with the target variable in a tree-like structure. The dependency graph displays the variables associated with the target variable in a mesh-like structure using connections between nodes. Nodes can be arranged in a circular pattern to make the dependency graph clearer and more intuitive. As shown in Figure 15, the dependency graph can also distinguish different types of variables (Variable, Table, ModelPoint, sysv) using different colored nodes. ModelPoint can be policy information data, such as sex and age. Sysv can be system variables, such as time.
[0106] In some cases, dependency graphs can more intuitively display the complex reference relationships between a large number of variables in a model than dependency trees. For example, as shown in Figure 16, a variable at one level in the dependency tree references a variable with the same name, and this variable appears at different levels of the dependency tree. As shown in Figure 15, in the dependency graph, these variables with the same name are displayed as two nodes, each connected to a different node, which more clearly reflects the reference relationship between the variables.
[0107] To better analyze and determine the reference relationships between variables, when a user selects a variable in the dependency tree or dependency graph, the code corresponding to the variable can be displayed above the selected variable. For example, when the user hovers the mouse over a variable in the dependency tree (as shown in Figures 17 and 18), the corresponding code can be displayed above the variable, allowing users to quickly verify whether the variable's dependency relationship is correct.
[0108] In this embodiment, a secondary dependency interface for displaying dependency trees and dependency graphs is configured to provide a more intuitive display of reference relationships between variables. When a user selects a variable, the corresponding code is displayed, allowing verification of dependency relationships, analysis of individual variable dependencies, code optimization, and performance improvement.
[0109] In an optional embodiment, the method may further include: in response to selecting any variable in the dependency graph, updating the dependency graph in the secondary dependency interface when the dependency graph does not fully display the dependency of the selected variable; wherein the updating includes: supplementing the display of variables associated with the selected variable in the dependency tree by adding a tree structure, and / or supplementing the display of variables associated with the selected variable in the dependency graph by adding a mesh structure.
[0110] As shown in Figure 18, click on any variable in the dependency graph (taking the dependency tree as an example). If the dependency relationship of the variable is not fully displayed, the dependency tree will add a new tree structure to supplement the display of the associated variables that are not displayed, such as expanding the reference relationship between variables to the next level or the previous level. This operation is performed for each variable whose dependency relationship is not fully displayed, and the dependency tree can be gradually expanded until there are no undisplayed previous and next levels for any variable. At this point, the complete reference relationship between variables can be obtained through the dependency tree, which improves the efficiency and display effect of the variable reference relationship analysis. It should be noted that the dependency tree and the dependency graph can be configured to be interrelated. After the dependency tree is fully expanded, when switching to the dependency graph, the expanded complete dependency graph can also be displayed immediately, so that unnecessary operation steps can be reduced and the analysis efficiency and display effect can be further improved.
[0111] In this embodiment, by selecting a variable, the reference relationship between each variable and other variables can be automatically displayed, and the dependency tree or dependency graph can be gradually expanded and improved to obtain a more complete and effective variable reference relationship, thereby improving the application efficiency of the model.
[0112] In some embodiments, as shown in FIG17 , a loading control (Auto Load) can also be configured in the secondary dependency interface. Clicking the loading control is equivalent to automatically performing a click operation on each variable that does not fully display the dependency relationship, and the dependency tree or dependency graph can be gradually expanded until any variable has no undisplayed previous or next levels or any node has no associated nodes. In this embodiment, by configuring the loading control, the dependency tree and dependency graph can be automatically expanded, thereby improving the efficiency of obtaining variable reference relationships.
[0113] In some embodiments, the secondary dependency interface may further include a zoom-in control and a zoom-out control for dynamically adjusting the size of the dependency graph. The secondary dependency interface may further include a return control for undoing or restoring a click operation.
[0114] Example 2
[0115] Figure 19 schematically shows a block diagram of a model building device according to the second embodiment of the present application. The device can be divided into one or more program modules, one or more program modules are stored in a storage medium and executed by one or more processors to complete the embodiment of the present application. The program module referred to in the embodiment of the present application refers to a series of computer-readable instruction segments that can perform specific functions. The following description will specifically introduce the functions of each program module in this embodiment. As shown in Figure 19, the device 1000 may include: a first display module 1100, a second display module 1200, a third display module 1300 and a fourth display module 1400, wherein:
[0116] A first display module 1100 is used to display a model configuration interface configured with a tree-like control;
[0117] A second display module 1200 is configured to display an interface for displaying a class tree in response to selection of the class tree control, wherein the class tree includes a plurality of nodes, each node corresponds to a class, and is configured with a subclass adding control;
[0118] The third display module 1300 is configured to display a first subclass adding interface for receiving class information in response to selecting a subclass adding control of a target node;
[0119] The fourth display module 1400 is used to display an updated class tree on the interface according to the received class information. The updated class tree includes a new node located one level below the target node, and the class corresponding to the new node inherits from the class corresponding to the target node.
[0120] As an optional embodiment, each node is further configured with a deletion control; the apparatus 1000 is further configured to:
[0121] In response to selecting a delete control of a target node, if the target node has no next-level nodes, displaying a class tree after deleting the target node on the interface;
[0122] In the case that the target node has a node at the next level, an alarm message is displayed on the interface.
[0123] As an optional embodiment, each node is further configured with an editing control, and the apparatus 1000 is further configured to:
[0124] In response to selecting the edit control of the target node, an edit interface is displayed, wherein the edit interface is used to update the target node and the class corresponding to the target node, and the edit interface includes a class code modification box, a class name modification box, an adjustment control, and a first save control;
[0125] Receive the latest class code and class name through the class code modification box and class name modification box;
[0126] In response to selecting the first adjustment control, determining whether the target node is a terminal node;
[0127] In response to selecting the first save control, the class tree after updating the target node is displayed on the interface.
[0128] As an optional embodiment, the interface for displaying the class tree includes a creation control, and the apparatus 1000 is further configured to:
[0129] In response to selecting the creation control, a new class creation interface is displayed, wherein the new class creation interface includes a class code input box, a class name input box, and a second save control;
[0130] Receive the class code and class name of the new class through the class code input box and class name input box respectively;
[0131] In response to selecting the second save control, a new class tree is displayed on the interface, wherein a root node of the new class tree corresponds to the created new class.
[0132] As an optional embodiment, the new class creation interface further includes a first associated control, and the apparatus 1000 is further configured to:
[0133] In response to selecting the first associated control, displaying a class tree selection box;
[0134] Determine the target class tree through the class tree selection box;
[0135] In response to selecting the second save control, a new class tree is displayed on the interface, wherein the new class tree is associated with the target class tree.
[0136] As an optional embodiment, the apparatus 1000 is further configured to:
[0137] In response to selecting a subclass adding control of any node in the new class tree, displaying a second subclass adding interface, the second subclass adding interface including a class code input box, a class name input box, a confirmation control, and a second association control;
[0138] Determine one or more nodes in the target class tree through the associated control;
[0139] Receive the class code and class name through the class code input box and class name input box respectively;
[0140] In response to selecting a confirmation control, the new class tree is updated on the interface, wherein the updated new class tree includes a newly added node, and a class corresponding to the newly added node is associated with a class corresponding to one or more nodes in the target class tree.
[0141] As an optional embodiment, the model configuration interface includes a variable control, and the apparatus 1000 is further configured to:
[0142] In response to selecting a variable control, displaying a variable management interface configured with a variable adding control, the variable management interface being used to display a plurality of variables corresponding to the class tree of the interface;
[0143] In response to selecting the variable adding control, displaying a variable creation interface, the variable creation interface including a variable definition area, a multiple definition control, and a third save control;
[0144] Receive variable information through the variable definition area;
[0145] In response to selecting the multiple definition control, displaying a class tree selection box to determine one or more target class trees through the class tree selection box;
[0146] In response to selecting the third save control, a newly added variable carrying the variable information is displayed on the variable management interface, where the newly added variable corresponds to the one or more target class trees.
[0147] As an optional embodiment, the model configuration interface further includes a dependency control, and the apparatus 1000 is further configured to:
[0148] In response to selecting the dependency control, displaying a primary dependency interface, wherein the primary dependency interface is used to receive a target variable and a class associated with the target variable;
[0149] Displaying a dependency graph corresponding to the target variable on the first-level dependency interface according to the received target variable and the associated class;
[0150] The dependency graph includes a dependency tree, and the dependency tree is used to display variables associated with the target variable.
[0151] As an optional embodiment, the variables associated with the target variable include variables referenced by the target variable and / or variables that reference the target variable.
[0152] As an optional embodiment, the apparatus 1000 is further configured to:
[0153] In response to selecting any variable associated with the target variable, the dependency graph corresponding to the selected variable is updated and displayed on the first-level dependency interface.
[0154] As an optional embodiment, the dependency relationship interface is configured with a switch control, and the apparatus 1000 is further configured to:
[0155] In response to selecting the switch control, a secondary dependency interface is displayed, wherein the secondary dependency interface is used to display a dependency graph corresponding to the target variable, wherein the dependency graph includes a dependency tree and a dependency graph, and the dependency tree and the dependency graph are used to display variables associated with the target variable;
[0156] In response to selecting any variable in the dependency tree or the dependency graph, code associated with the selected variable is displayed on an upper layer of the selected variable.
[0157] As an optional embodiment, the apparatus 1000 is further configured to:
[0158] In response to selecting any variable in the dependency graph, if the dependency graph does not fully display the dependency of the selected variable, updating the dependency graph on the secondary dependency interface;
[0159] The updating includes: supplementing the display of variables associated with the selected variable in the dependency tree by adding a tree structure, and / or supplementing the display of variables associated with the selected variable in the dependency graph by adding a mesh structure.
[0160] Example 3
[0161] Figure 20 schematically shows a hardware architecture diagram of a computer device 10000 suitable for implementing the model building method according to Example 3 of the present application. In some embodiments, the computer device 10000 can be a terminal device such as a smart phone, a wearable device, a tablet computer, a personal computer, a vehicle-mounted terminal, a game console, a virtual device, a workbench, a digital assistant, a set-top box, a robot, etc. In other embodiments, the computer device 10000 can be a rack server, a blade server, a tower server or a cabinet server (including an independent server, or a server cluster composed of multiple servers), etc. As shown in Figure 20, the computer device 10000 includes but is not limited to: a memory 10010, a processor 10020, and a network interface 10030 that can communicate with each other through a system bus. Among them:
[0162] The memory 10010 includes at least one type of computer-readable storage medium, including flash memory, a hard disk, a multimedia card, a card-type memory (e.g., SD or DX memory), random access memory (RAM), static random access memory (SRAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), programmable read-only memory (PROM), magnetic storage, a magnetic disk, an optical disk, etc. In some embodiments, the memory 10010 may be an internal storage module of the computer device 10000, such as a hard disk or memory of the computer device 10000. In other embodiments, the memory 10010 may also be an external storage device of the computer device 10000, such as a plug-in hard disk equipped on the computer device 10000, a smart media card (SMC), a secure digital (SD) card, a flash card, etc. Of course, the memory 10010 may also include both the internal storage module of the computer device 10000 and its external storage device. In this embodiment, the memory 10010 is generally used to store the operating system and various application software installed on the computer device 10000, such as the program code of the model building method, etc. In addition, the memory 10010 can also be used to temporarily store various data that have been output or will be output.
[0163] In some embodiments, the processor 10020 may be a central processing unit (CPU), a controller, a microcontroller, a microprocessor, or other chips. The processor 10020 is generally used to control the overall operation of the computer device 10000, such as performing control and processing related to data interaction or communication with the computer device 10000. In this embodiment, the processor 10020 is used to execute program code stored in the memory 10010 or process data.
[0164] The network interface 10030 may include a wireless network interface or a wired network interface. The network interface 10030 is generally used to establish a communication link between the computer device 10000 and other computer devices. For example, the network interface 10030 is used to connect the computer device 10000 to an external terminal via a network, and to establish a data transmission channel and a communication link between the computer device 10000 and the external terminal. The network may be a wireless or wired network such as an intranet, the Internet, the Global System of Mobile Communications (GSM), Wideband Code Division Multiple Access (WCDMA), a 4G network, a 5G network, Bluetooth, or Wi-Fi.
[0165] It should be noted that FIG. 20 only shows a computer device having components 10010 - 10030 , but it should be understood that it is not required to implement all of the components shown, and more or fewer components may be implemented instead.
[0166] In this embodiment, the model building method stored in the memory 10010 can also be divided into one or more program modules and executed by one or more processors (such as processor 10020) to complete the embodiment of the present application.
[0167] Example 4
[0168] An embodiment of the present application also provides a computer-readable storage medium having computer-readable instructions stored thereon, wherein when the computer-readable instructions are executed by a processor, the steps of the model building method in the embodiment are implemented.
[0169] In this embodiment, the computer-readable storage medium includes a flash memory, a hard disk, a multimedia card, a card-type memory (e.g., SD or DX memory), a random access memory (RAM), a static random access memory (SRAM), a read-only memory (ROM), an electrically erasable programmable read-only memory (EEPROM), a programmable read-only memory (PROM), a magnetic memory, a magnetic disk, an optical disk, etc. In some embodiments, the computer-readable storage medium may be an internal storage unit of a computer device, such as a hard disk or memory of the computer device. In other embodiments, the computer-readable storage medium may also be an external storage device of the computer device, such as a plug-in hard disk equipped on the computer device, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card, etc. Of course, the computer-readable storage medium may also include both an internal storage unit of the computer device and its external storage device. In this embodiment, the computer-readable storage medium is generally used to store an operating system and various application software installed on the computer device, such as the program code of the model building method in the embodiment. In addition, the computer-readable storage medium may also be used to temporarily store various types of data that have been output or are to be output.
[0170] Obviously, those skilled in the art should understand that the modules or steps of the above-mentioned embodiments of the present application can be implemented using general-purpose computer devices. They can be concentrated on a single computer device or distributed on a network composed of multiple computer devices. Alternatively, they can be implemented using program codes executable by the computer device, so that they can be stored in a storage device and executed by the computer device. In some cases, the steps shown or described can be performed in a different order than herein, or they can be made into individual integrated circuit modules, or multiple modules or steps therein can be made into a single integrated circuit module for implementation. Thus, the embodiments of the present application are not limited to any specific combination of hardware and software.
[0171] It should be noted that the above are only preferred embodiments of the present application and do not limit the scope of patent protection of the present application. Any equivalent structure or equivalent process transformation made using the contents of the description and drawings of this application, or directly or indirectly applied in other related technical fields, are also included in the scope of patent protection of the present application.
Claims
1. A model building method, characterized in that: The method is used to visually display and create inheritance relationships between classes through the hierarchical relationship of class tree nodes, so as to create a model with a visual tree structure in a visual environment; the method includes: Display the model configuration interface configured with a tree-like control; In response to selecting the class tree control, an interface for displaying a class tree is displayed, wherein the class tree includes a plurality of nodes, each node corresponds to a class, and is configured with a subclass adding control; In response to selecting a subclass adding control of a target node, displaying a first subclass adding interface for receiving class information; According to the received class information, an updated class tree is displayed on the interface, wherein the updated class tree includes a newly added node located one level below the target node, and the class corresponding to the newly added node inherits from the class corresponding to the target node.
2. The method according to claim 1, characterized in that Each node is also configured with a deletion control; the method further includes: In response to selecting a delete control of a target node, if the target node has no next-level nodes, displaying a class tree after deleting the target node on the interface; In the case that the target node has a node at the next level, an alarm message is displayed on the interface.
3. The method according to claim 1, characterized in that Each node is further configured with an editing control, and the method further comprises: In response to selecting the edit control of the target node, an edit interface is displayed, wherein the edit interface is used to update the target node and the class corresponding to the target node, and the edit interface includes a class code modification box, a class name modification box, an adjustment control, and a first save control; Receive the latest class code and class name through the class code modification box and class name modification box; In response to selecting the first adjustment control, determining whether the target node is a terminal node; In response to selecting the first save control, the class tree after updating the target node is displayed on the interface.
4. The method according to claim 1, wherein The interface includes creating a control, and the method further includes: In response to selecting the creation control, displaying a new class creation interface, the new class creation interface including a class code input box, a class name input box and a second save control; Receive the class code and class name of the new class through the class code input box and class name input box respectively; In response to selecting the second save control, a new class tree is displayed on the interface, wherein a root node of the new class tree corresponds to the created new class.
5. The method according to claim 4, characterized in that The new class creation interface further includes a first associated control, and the method further includes: In response to selecting the first associated control, displaying a class tree selection box; Determine the target class tree through the class tree selection box; In response to selecting the second save control, a new class tree is displayed on the interface, wherein the new class tree is associated with the target class tree.
6. The method according to claim 5, characterized in that The method further comprises: In response to selecting a subclass adding control of any node in the new class tree, displaying a second subclass adding interface, the second subclass adding interface including a class code input box, a class name input box, a confirmation control, and a second association control; Determine one or more nodes in the target class tree through the associated control; Receive the class code and class name through the class code input box and class name input box respectively; In response to selecting a confirmation control, the new class tree is updated on the interface, wherein the updated new class tree includes a newly added node, and a class corresponding to the newly added node is associated with a class corresponding to one or more nodes in the target class tree.
7. The method according to claim 1, characterized in that The model configuration interface includes a variable control, and the method further includes: In response to selecting a variable control, a variable management interface configured with a variable adding control is displayed. Used to display a plurality of variables corresponding to the class tree of the interface; In response to selecting the variable adding control, displaying a variable creation interface, the variable creation interface including a variable definition area, a multiple definition control, and a third save control; Receive variable information through the variable definition area; In response to selecting the multiple definition control, displaying a class tree selection box to determine one or more target class trees through the class tree selection box; In response to selecting the third save control, a newly added variable carrying the variable information is displayed on the variable management interface, where the newly added variable corresponds to the one or more target class trees.
8. The method according to claim 1, characterized in that The model configuration interface further includes a dependency control, and the method further includes: In response to selecting the dependency control, displaying a primary dependency interface, wherein the primary dependency interface is used to receive a target variable and a class associated with the target variable; Displaying a dependency graph corresponding to the target variable on the first-level dependency interface according to the received target variable and the associated class; The dependency graph includes a dependency tree, and the dependency tree is used to display variables associated with the target variable.
9. The method according to claim 8, characterized in that The dependency interface is configured with a switch control, and the method further includes: In response to selecting the switch control, a secondary dependency interface is displayed, wherein the secondary dependency interface is used to display a dependency graph corresponding to the target variable, wherein the dependency graph includes a dependency tree and a dependency graph, and the dependency tree and the dependency graph are used to display variables associated with the target variable; In response to selecting any variable in the dependency tree or the dependency graph, code associated with the selected variable is displayed on an upper layer of the selected variable.
10. The method according to claim 8, characterized in that The method further comprises: In response to selecting any variable in the dependency graph, if the dependency graph does not fully display the dependency of the selected variable, updating the dependency graph on the secondary dependency interface; The updating includes: supplementing the display of variables associated with the selected variable in the dependency tree by adding a tree structure, and / or supplementing the display of variables associated with the selected variable in the dependency graph by adding a mesh structure.
11. A model building device, characterized in that: The device comprises: A first display module is used to display a model configuration interface configured with a tree-like control; a second display module, configured to display an interface for displaying a class tree in response to selection of the class tree control, wherein the class tree includes a plurality of nodes, each node corresponds to a class, and is configured with a subclass adding control; a third display module, configured to display a first subclass adding interface for receiving class information in response to selecting a subclass adding control of a target node; The fourth display module is used to display the updated class tree according to the received class information, wherein the updated class tree includes a new node located at a level below the target node, and the class corresponding to the new node inherits from the class corresponding to the target node.
12. A computer device, characterized in that: The computer device is used to visually display and create inheritance relationships between classes through the hierarchical relationship of class tree nodes, so as to create a model with a visual tree structure in a visual environment, and includes: at least one processor; and a memory communicatively coupled to the at least one processor; wherein: The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the following operations: Display the model configuration interface configured with a tree-like control; In response to selecting the class tree control, an interface for displaying a class tree is displayed, wherein the class tree includes a plurality of nodes, each node corresponds to a class, and is configured with a subclass adding control; In response to selecting a subclass adding control of a target node, displaying a first subclass adding interface for receiving class information; According to the received class information, an updated class tree is displayed on the interface, wherein the updated class tree includes a newly added node located one level below the target node, and the class corresponding to the newly added node inherits from the class corresponding to the target node.
13. The computer device according to claim 12, wherein: Each node is further configured with a deletion control; the at least one processor is further capable of performing the following operations: In response to selecting a delete control of a target node, if the target node has no next-level nodes, displaying a class tree after deleting the target node on the interface; In the case that the target node has a node at the next level, an alarm message is displayed on the interface.
14. The computer device according to claim 12, wherein: Each node is further configured with an editing control, and the at least one processor is further capable of performing the following operations: In response to selecting the edit control of the target node, an edit interface is displayed, wherein the edit interface is used to update the target node and the class corresponding to the target node, and the edit interface includes a class code modification box, a class name modification box, an adjustment control, and a first save control; Receive the latest class code and class name through the class code modification box and class name modification box; In response to selecting the first adjustment control, determining whether the target node is a terminal node; In response to selecting the first save control, the class tree after updating the target node is displayed on the interface.
15. The computer device according to claim 12, wherein: The interface includes a creation control, and the at least one processor is further capable of performing the following operations: In response to selecting the creation control, displaying a new class creation interface, the new class creation interface including a class code input box, a class name input box and a second save control; Receive the class code and class name of the new class through the class code input box and class name input box respectively; In response to selecting the second save control, a new class tree is displayed on the interface, wherein a root node of the new class tree corresponds to the created new class.
16. The computer device according to claim 15, wherein: The new class creation interface further includes a first associated control, and the at least one processor is further capable of performing the following operations: In response to selecting the first associated control, displaying a class tree selection box; Determine the target class tree through the class tree selection box; In response to selecting the second save control, a new class tree is displayed on the interface, wherein the new class tree is associated with the target class tree.
17. The computer device according to claim 16, wherein: The at least one processor is further capable of performing the following operations: In response to selecting a subclass adding control of any node in the new class tree, displaying a second subclass adding interface, the second subclass adding interface including a class code input box, a class name input box, a confirmation control, and a second association control; Determine one or more nodes in the target class tree through the associated control; Receive the class code and class name through the class code input box and class name input box respectively; In response to selecting a confirmation control, the new class tree is updated on the interface, wherein the updated new class tree includes a newly added node, and a class corresponding to the newly added node is associated with a class corresponding to one or more nodes in the target class tree.
18. The computer device according to claim 12, wherein: The model configuration interface includes a variable control, and the at least one processor is further capable of performing the following operations: In response to selecting a variable control, displaying a variable management interface configured with a variable adding control, the variable management interface being used to display a plurality of variables corresponding to the class tree of the interface; In response to selecting the variable adding control, displaying a variable creation interface, the variable creation interface including a variable definition area, a multiple definition control, and a third save control; Receive variable information through the variable definition area; In response to selecting the multiple definition control, displaying a class tree selection box to determine one or more target class trees through the class tree selection box; In response to selecting the third save control, a newly added variable carrying the variable information is displayed on the variable management interface, The newly added variables correspond to the one or more target class trees.
19. The computer device according to claim 12, wherein: The model configuration interface further includes a dependency control, and the at least one processor is further capable of performing the following operations: In response to selecting the dependency control, displaying a primary dependency interface, wherein the primary dependency interface is used to receive a target variable and a class associated with the target variable; Displaying a dependency graph corresponding to the target variable on the first-level dependency interface according to the received target variable and the associated class; The dependency graph includes a dependency tree, and the dependency tree is used to display variables associated with the target variable.
20. A computer-readable storage medium, characterized in that The computer-readable storage medium stores computer instructions, which implement the method according to any one of claims 1 to 10 when executed by a processor.