CN107818501B - Actuarial method and device - Google Patents

Actuarial method and device Download PDF

Info

Publication number
CN107818501B
CN107818501B CN201710124381.8A CN201710124381A CN107818501B CN 107818501 B CN107818501 B CN 107818501B CN 201710124381 A CN201710124381 A CN 201710124381A CN 107818501 B CN107818501 B CN 107818501B
Authority
CN
China
Prior art keywords
language file
data
file
actuarial
calculation
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201710124381.8A
Other languages
Chinese (zh)
Other versions
CN107818501A (en
Inventor
江鹏凯
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Ping An Medical Health Technology Service Co Ltd
Original Assignee
Ping An Medical and Healthcare Management Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ping An Medical and Healthcare Management Co Ltd filed Critical Ping An Medical and Healthcare Management Co Ltd
Priority to CN201710124381.8A priority Critical patent/CN107818501B/en
Publication of CN107818501A publication Critical patent/CN107818501A/en
Application granted granted Critical
Publication of CN107818501B publication Critical patent/CN107818501B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/21Design, administration or maintenance of databases
    • G06F16/215Improving data quality; Data cleansing, e.g. de-duplication, removing invalid entries or correcting typographical errors
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/248Presentation of query results

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • Business, Economics & Management (AREA)
  • General Engineering & Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Finance (AREA)
  • Accounting & Taxation (AREA)
  • Development Economics (AREA)
  • Economics (AREA)
  • Quality & Reliability (AREA)
  • Marketing (AREA)
  • Strategic Management (AREA)
  • Technology Law (AREA)
  • General Business, Economics & Management (AREA)
  • Computational Linguistics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention relates to a actuarial method. The actuarial method comprises the following steps: acquiring a to-be-processed actuarial task, wherein the actuarial task comprises a language file and an index to be output; acquiring basic data having a mapping relation with the language file; calculating the basic data according to the operation logic defined in the language file; and generating report data corresponding to the indexes. According to the actuarial method and the actuarial device, the actuarial calculation is carried out by setting the language file, so that the calculation efficiency can be improved; by setting the mapping relation between the language file and the basic data, the precision flexibility can be improved.

Description

Actuarial method and device
Technical Field
The present invention relates to the field of information processing technologies, and in particular, to a method and an apparatus for performing a actuarial operation.
Background
The method is simple and accurate, and is based on the basic principle of economics, and various scientific and effective methods of modern mathematics, statistics, finance, law and the like are applied to analyze, evaluate, manage and the like the future risks in various economic activities, so that the method is the basis for realizing steady operation of modern insurance, finance and investment.
In the traditional actuarial method, after basic data are obtained, a fixed calculation mode is designed directly according to a target obtained by required calculation, and the basic data are calculated according to the designed calculation mode to obtain a final calculation result. This conventional approach to actuarial is not very flexible in terms of the utilization and calculation of the underlying data.
Disclosure of Invention
In view of the above, it is necessary to provide a calculation method and apparatus capable of improving flexibility of use and calculation of basic data.
A method of actuarial, the method comprising:
acquiring a to-be-processed actuarial task, wherein the actuarial task comprises a language file and an index to be output;
acquiring basic data having a mapping relation with the language file;
calculating the basic data according to the operation logic defined in the language file;
and generating report data corresponding to the indexes.
In one embodiment, the method further comprises:
acquiring original data;
and carrying out data cleaning on the original data to generate basic data.
In one embodiment, before the step of obtaining the to-be-processed actuarial task, the method further includes:
acquiring a calculation task generation request, wherein the calculation task generation request comprises a calculation model;
obtaining a DSL file defined in the actuarial model;
checking the information in the DSL file, and generating a language file after the information passes the checking;
and acquiring an index to be output, and generating a calculation task according to the language file and the index to be output.
In one embodiment, the step of calculating the basic data according to the operation logic defined in the language file comprises:
detecting whether the language file comprises a dependency label, if so, detecting whether the language file comprises the dependency label
Reading the file identification in the dependent tag;
acquiring a dependent language file corresponding to the file identifier and basic data having a mapping relation with the dependent language file;
and calculating the basic data according to the operation logic defined in the language file and the operation logic defined in the dependent language file.
In one embodiment, after the step of generating the report data corresponding to the index, the method further includes:
and generating a report display diagram according to the report data.
A actuarial apparatus, the apparatus comprising:
the calculation task acquisition module is used for acquiring a calculation task to be processed, wherein the calculation task comprises a language file and an index to be output; acquiring basic data having a mapping relation with the language file;
the computing module is used for computing the basic data according to the operation logic defined in the language file;
and the report data generation module is used for generating report data corresponding to the indexes.
In one embodiment, the apparatus further comprises:
the basic data processing module is used for acquiring original data; and carrying out data cleaning on the original data to generate basic data.
In one embodiment, the apparatus further comprises:
the calculation task generation module is used for acquiring a calculation task generation request, and the calculation task generation request comprises a calculation model; obtaining a DSL file defined in the actuarial model; checking the information in the DSL file, and generating a language file after the information passes the checking; and acquiring an index to be output, and generating a calculation task according to the language file and the index to be output.
In one embodiment, the calculation module is further configured to detect whether the language file includes a dependent tag, and if so, read a file identifier in the dependent tag; acquiring a dependent language file corresponding to the file identifier and basic data having a mapping relation with the dependent language file; and calculating the basic data according to the operation logic defined in the language file and the operation logic defined in the dependent language file.
In one embodiment, the apparatus further comprises:
and the display module is used for generating a report display diagram according to the report data.
According to the actuarial method and the actuarial device, the language file and the index to be output are set, the mapping relation between the language file and the basic data is set, the mapped basic data is calculated according to the operation logic defined in the language file, and the report data corresponding to the index is generated. The calculation efficiency can be improved by setting the language file to perform the calculation of the actuarial. By setting the mapping relation between the language file and the basic data, the precision flexibility can be improved.
Drawings
FIG. 1 is a diagram of an application environment of a actuarial method in one embodiment;
FIG. 2 is an internal block diagram of a server in one embodiment;
FIG. 3 is a schematic flow diagram of a method of actuarial in one embodiment;
FIG. 4 is a schematic flow diagram that illustrates the steps of actuarial task generation in one embodiment;
FIG. 5 is a flowchart illustrating the steps of computing underlying data according to the operational logic defined in the language file in one embodiment;
FIG. 6 is a schematic diagram of the structure of a actuarial device in one embodiment;
FIG. 7 is a schematic view showing the structure of a actuarial apparatus in another embodiment;
FIG. 8 is a schematic view showing the structure of a actuarial apparatus in still another embodiment;
fig. 9 is a schematic view showing the structure of a actuarial device in still another embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
The actuarial method provided by the embodiment of the invention can be applied to the application environment shown in fig. 1. Referring to fig. 1, a terminal 110 may be connected to a server 120 through a corresponding network and transmit a calculation task to be processed, including a language file, to the server 120. After receiving the to-be-processed actuarial task, the server can acquire a language file corresponding to the actuarial task at the proxy, and generate report data corresponding to the index according to the data identifier, the operation logic and the to-be-output index defined in the language file.
In one embodiment, server 120 includes a data processing server 121, a actuary model design server 122, and an actuary engine server 123. The data processing server 121 is configured to acquire and store data related to the actuarial business, and perform cleansing on the stored data. The data may be for interacting with a terminal used by a data operator, generating or receiving data uploaded by the terminal. Actuarial model design server 122 is configured to provide a UI interface (User interface) to define an actuarial model for actuarial personnel. The actuarial model is composed of one or more DSL (domain-specific language) files, stored in the DSL library, and finally input to the actuarial engine server 123. The actuarial model design server 122 is also used for defining actuarial models and establishing mapping relations between the defined actuarial models and the basic data. The actuarial engine server 123 is configured to obtain the defined DSL file from the actuarial model design server 122, and based on the basic data obtained from the data processing server 121 and having a mapping relationship with the DSL file, process the basic data according to the information described in the DSL file, and generate an actuarial result. The actuarial result can be corresponding report data.
Fig. 2 is a schematic diagram of an internal structure of the server in one embodiment. The server includes a processor, a non-volatile storage medium, an internal memory, and a network interface connected by a system bus. Wherein the non-volatile storage medium of the server stores an operating system, a database, and a actuarial device. The database stores basic data, DSL files, language files and other data. The actuarial device is used for realizing an actuarial method. The processor of the server is used for providing calculation and control capacity and supporting the operation of the whole server. The internal memory of the server provides an environment for the operation of a actuarial device in a non-volatile storage medium, and the internal memory may store computer-readable instructions that, when executed by a processor, cause the processor to perform an actuarial method. The network interface of the server is used for communicating with external user terminals and auditing terminals through network connection. The server may be implemented as a stand-alone server or as a server cluster consisting of a plurality of servers.
Those skilled in the art will appreciate that the architecture shown in fig. 2 is a block diagram of only a portion of the architecture associated with the subject application, and does not constitute a limitation on the servers to which the subject application applies, as a particular server may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
FIG. 3 is a flow diagram illustrating a method of actuarial in one embodiment. This embodiment is illustrated by applying the method to the server shown in fig. 2. Referring to fig. 3, the actuarial method specifically includes the following steps:
step S302, a calculation task to be processed is obtained, and the calculation task comprises a language file and an index to be output.
In this embodiment, the to-be-processed actuarial tasks may be preset in a specified path, the server may periodically query whether the actuarial tasks exist in the path, and when a plurality of to-be-processed actuarial tasks exist, the actuarial task with the earliest generation time and/or processing priority may be obtained according to one or more factors such as the generation time and processing priority of each actuarial task. Wherein, each actuarial task is set with a state label, the processing progress of the actuarial task can be obtained according to the state label, and the processing progress comprises waiting processing, processing neutralization processing completion and the like.
The actuarial task comprises a language file and an index to be output. The language file and the index may be one or more. The index to be output can be defined in the language file, and can also be the index uploaded by the terminal. The index is certain data which needs to be obtained by calculation, and one index may need to be calculated by depending on one or more language files to obtain a final result. The language file is an intermediate language file that the server can understand and execute. The Language file may be any one or more predetermined Language files such as XML (Extensible Markup Language), json (javascript Object notification), pb (protocol buffers), etc., and one Language file describes a minimum reusable logic package. The language file can be generated by corresponding conversion of the DSL file or directly written by a developer. The DSL language used in the DSL document is a service user-defined language specification, and a DSL document may be compiled into multiple language documents, for example, into an XML intermediate language document, according to differences between DSL compilers.
In one embodiment, a task queue may be provided in the server, and the actuarial tasks may be stored in the corresponding task queue. The server detects whether a to-be-processed actuarial task exists in the task queue at regular time or according to a certain frequency, acquires one or more actuarial tasks according to a preset scheduling strategy, distributes the acquired actuarial tasks to a thread pool, and carries out actuarial operation processing on the threads in an idle state. The scheduling strategy comprises serial scheduling, parallel scheduling or serial-parallel hybrid scheduling. The server is provided with a plurality of thread pools, and each thread pool can be in an idle or running intermediate state.
Specifically, a task scheduling module (Dispatcher) in the actuary engine server acquires a task from the queue and distributes the task to an idle thread in the thread pool according to a scheduling policy.
Step S304, acquiring basic data having a mapping relation with the language file.
In this embodiment, a mapping relationship is set between the language file and one or more pieces of basic data, so that corresponding basic data can be obtained according to the mapping relationship. The base data may be stored in a server context (context) container and stored in the form of a data table. The context container is positioned in the data processing server, and the actuarial model design server establishes the mapping relation between each language file and the basic data table according to the mapping instruction sent by the terminal. Specifically, a parsing module (Resolver) in the server unpacks the calculation task, receives the language file, and maps the language file into an "execution unit" memory model. An execution unit (IExecutable) is an abstraction of an action unit that an engine can run, and the execution unit can call concrete basic data for calculation.
Further, the basic data may be divided into local basic data and national basic data. For example, the basic data is population data, and may be divided into regional population data and population data integrated into national population data. The population data may further include the number of born populations per year, the number of populations per age and/or age group, the birth rate per year, the integrated fertility rate, and the like.
Step S306, calculating the basic data according to the operation logic defined in the language file.
The language file defines the corresponding operation logic and the operation parameters to be used, and the operation parameters can be one or more specific data in the basic data and data of one or more field types. The server can obtain corresponding data from the basic data and calculate according to the operation logic defined in the language file.
Specifically, the actuarial engine server can analyze whether a preset keyword exists in the language file, acquire an operation parameter defined in the keyword, and query and acquire data corresponding to the operation parameter from the mapped basic data table. One or more of operation parameters, operation logics and the like can be respectively defined in the keywords.
For example, the following segment of language is defined in the language file:
Figure BDA0001238013290000061
Figure BDA0001238013290000071
the server can read operation parameters between the pair of keywords, wherein the parameters are population number, frequent population number and population category. Data with defined fields of "population number", "number of standing population" and "population category" are queried and obtained from the mapped basic data table.
For another example, the language file defines the following language:
Figure BDA0001238013290000072
the server can read operation parameters and operation logic between the pair of keywords, the operation logic is respectively defined in the keywords < exp > and </exp >, the exp4j can be specifically called to analyze expressions in the keywords < exp > and </exp >, the calculation is carried out, the calculated result is stored in TLS (Thread Local Storage, TLS), and the result is a temporary result.
Step S308, report data corresponding to the indexes is generated.
In this embodiment, the indicator may be defined in a language file. Likewise, may be defined within a certain pair of keywords. The server can obtain the index from the pair of keywords and generate the report data corresponding to the index according to the calculation result.
The actuarial engine server can obtain the execution units according to an actuator module (execution) arranged in the actuarial engine server and call the execution units in sequence until a calculation result is obtained and Output to an Output module (Output). The output module receives the calculation result of the actuator and caches the calculation result in the memory, the calculation result is periodically and quantitatively refreshed to the external cache, and the report data corresponding to the index is generated according to the result.
For example, the following segment of language is defined in the language file:
Figure BDA0001238013290000081
the server can read the defined output index between the keywords, and generates corresponding report data after calculating the index data. The report form refers to a set of indexes which can be displayed on the terminal interface.
In this embodiment, by setting the language file and the index to be output, and setting the mapping relationship between the language file and the basic data, the mapped basic data is calculated according to the operation logic defined in the language file, and the report data corresponding to the index is generated. The calculation efficiency can be improved by setting the language file to perform the calculation of the actuarial. By setting the mapping relation between the language file and the basic data, the precision flexibility can be improved.
In one embodiment, the above-mentioned actuarial method further comprises: acquiring original data; and carrying out data cleaning on the original data to generate basic data.
In this embodiment, if the original data is the data required to be used in the above-mentioned calculation process, the process is executed before the above-mentioned step S302. Otherwise, the data cleansing process may be performed before or after any of the above steps, or in parallel.
Raw data refers to data without any processing. The data processing server can access the related data website and acquire the data on the data website as the original data. Data uploaded by a terminal of a data operator may also be received as raw data.
Data cleansing includes data desensitization, data checking and data transformation. Wherein data desensitization is used to encrypt sensitive data in the original data. For example, the data includes an identification number of the individual, and the identification number may be encrypted. The data check is used for inquiring whether dirty data exists in the original data or not and deleting the dirty data so as to eliminate the influence of the dirty data on the calculation result. The server sets a dirty data judgment method for each type of data, and detects whether the data is dirty data according to a preset judgment method. For example, a character length range or a numerical value size range of each type of data may be set, and when the character length of a certain type of data is not within a preset range or the numerical value size is not within a preset size range, the data is determined to be dirty data. The data verification is a process of uniformly converting data with a plurality of different expression modes into the same preset expression mode.
The server sets a corresponding expression mode for each type of data, and when detecting that certain type of data is inconsistent with the set expression mode, the server can convert the data into the set expression mode according to the conversion relation between the expression mode of the type of data and the set expression mode. For example, the data is medicine data, codes used in different regions for the same medicine are different, the server can set the coding mode of the medicine data, and the detected coding mode and the set different data are converted into the correspondingly set codes according to the corresponding conversion relation, so that uniform codes are formed.
And after the original data is cleaned, storing the cleaned data as basic data.
In the embodiment, the basic data is generated by cleaning the data, so that the basic data can be conveniently called and calculated subsequently, and the convenience and the efficiency of actuarial are further improved.
In one embodiment, the above-mentioned actuarial method further comprises the step of actuarial task generation. As shown in fig. 4, the steps specifically include:
step S402, acquiring a calculation task generation request, wherein the calculation task generation request comprises a calculation model.
In this embodiment, the actuarial model design server may receive an actuarial task generation request sent by the user terminal, where the actuarial task generation request includes an actuarial model. Furthermore, the system also comprises a user identification, so that the corresponding user identity can be uniquely identified according to the user identification. For example, the server may send a actuarial model design interface to the user terminal, and when the user terminal receives a trigger on a control representing task creation on the interface, a actuarial task generation request is generated and sent to the server.
Specifically, the task generation request is received by an execution controller (RunController) in the actuarial model design server. The execution controller is a system inlet and a controller for running the actuarial engine and is used for driving the engine to execute, inquiring the progress and the like. The execution controller, upon receiving the actuarial task generation request, creates a new actuarial task and updates the actuarial task to 'started'. And the RunController collects relevant parameters, indexes, calculation conditions and the like of the calculation tasks created at this time. The parameters, the indexes, the calculation conditions and the like can be set in the calculation model, for example, the interface includes a specific calculation model and the parameters, the indexes, the calculation conditions and the like involved, and after the user terminal detects information such as the parameters, the indexes, the calculation conditions and the like input at a preset position, the information is packaged into the calculation task generation request. Such as the parameter "year basis"; the index is 'year of prediction', and the actuarial condition is 'whether an intermediate calculation result (snapshot) needs to be observed or not' (snapshot).
Step S404, a DSL file defined in the actuarial model is obtained.
One or more DSL files are typically defined in the actuarial model. The DSL file is a language specification which is specially defined by the server for the service user and is more friendly to the service personnel. In particular, a design controller (design controller) in the actuary model design server, which is the portal of the design system in the actuary model design server, may be used to support the customer design DSL rules.
In one embodiment, DSL pick-up rules may be defined in the actuarial model, and a DSL pick-up module (DSLFetcher) in the actuarial model design server may retrieve the relevant DSL file from an associated database/file repository based on the DSL pick-up rules. The DSL pick-up rules include file identification and/or lot identification of the targeted DSL. The file identification may be used to uniquely identify the corresponding DSL file or language file, and the batch is used to identify the generated intermediate data from the corresponding DSL file and/or language file. The same DSL or language file can be processed according to different actuations to generate a plurality of intermediate data, and the server can set corresponding batches for the intermediate data. The intermediate data may be index data corresponding to other actuarial tasks. Specific actuarial rules are defined in the DSL file such that a final indicator can be calculated from one or more DSL files.
The index DSL file represents the DSL file to which the information in the actuarial model directly points, one or more dependent DSL files can be set in each DSL file, and the convenience for designing the actuarial model can be improved by setting the dependent DSL files. Where dependent on a DSL file refers to a DSL file referenced by another DSL file. The target DSL file may have set therein the file identity and/or lot of the dependent DSL file to be referenced.
The DSLFetcher may analyze the index DSL file to obtain the dependent DSL file defined therein, and further analyze the obtained dependent DSL file to detect whether the dependent DSL file is also defined in the dependent DSL file until all the dependent DSL files are obtained.
Wherein the server may update the status of the created actuarial task to "checking DSL" while in the process of acquiring the DSL file.
Step S406, the information in the DSL file is verified, and after the verification is passed, a language file is generated.
In this embodiment, the actuarial model design server is further provided with a DSL compiling module (dslcompier), and the dslcompier may determine that conversion is not required according to the output DSL file picked up by the DSLFetcher (for example, the DSL file is already saved as a file in a corresponding intermediate language). And compiles (converts) it into a language file recognizable by the actuarial engine server. If the DSL file is directly the preset language file, the DSLCompiler directly returns without any operation. Otherwise, the dslcompier may perform syntax checking, lexical checking, and compiling to generate language files for each DSL file. It is checked whether the fields defined in each DSL file comply with the respective definition requirements, and whether the mandatory fields are present, etc.
And if the verification is not passed, updating the state to be 'task failure', and returning a result of the generation failure of the actuarial task to the user terminal. And if the verification is passed, generating a corresponding language file according to the obtained DSL file. Specifically, the language file may be an XML language file.
Step S408, obtaining the index to be output, and generating a calculation task according to the language file and the index to be output.
In this embodiment, the index to be output may be set in the language file, and in the process of creating the task, prompt information for inputting the index may be sent to the user terminal, and the index input by the corresponding user and sent by the user terminal may be acquired. And finally generating a calculation task according to the index and the created language file, and updating a corresponding state to be 'task creation completion'. Meanwhile, the created actuarial task can be placed in a task queue, so that a Dispatcher in the actuarial engine server acquires the actuarial task from the queue, distributes the actuarial task to an idle thread of a thread pool according to a set scheduling strategy (serial, parallel and mixed), and processes the actuarial task.
In this embodiment, a DSL file is defined in the actuary model, a language file is generated according to the DSL file, and an actuary task is generated according to the language file and an index to be output. The convenience of generating the actuarial tasks can be further improved as the DSL file is more friendly for the service personnel and the language file is defined as an intermediate language file that is more friendly for machine parsing to perform.
In one embodiment, as shown in fig. 5, the step of calculating the basic data according to the operation logic defined in the language file comprises:
step 502, detecting whether the current language file includes a dependency label. If yes, go to step 504; otherwise, step 508 is performed.
In this embodiment, the server may detect each language file. For each language file, whether a dependency tag is defined in the language file is detected respectively.
At step 504, the file identification and/or the lot in the dependent tag is read.
The dependent language file or intermediate data referenced by the language file is defined in the dependent tag. The language-dependent file can be determined by the file identification, and the intermediate data can be intermediate data generated by other language files and can be represented by the file identification of the corresponding language file and the batch thereof.
Step 506, obtaining the dependent language file corresponding to the file identification and/or the batch and the basic data and/or the intermediate data having the mapping relation with the dependent language file.
Wherein the batch is mapped with intermediate data that can be generated for the corresponding language file. Specifically, for an XML language file, the dependency tag may be set to a < Require > tag. The parser in the actuary engine server may be configured to parse the execution units defined in the XML language file in order, and if a < Require > tag is encountered, recursively parse its dependent XML language file contents. And analyzing whether the dependent XML language file also has the dependent XML language file or not until all the dependent XML language files are completely acquired, reading each language file and the execution units in the dependent language file, and acquiring the basic data and/or the intermediate data corresponding to the execution units.
Step 508, detecting whether each language file is detected completely, if so, executing step 510, otherwise, executing step 502.
After the currently detected language file is detected, a next language file can be obtained, and step 502 is executed for the next language file. When all the language files are executed, step 510 is executed.
And 510, calculating the basic data and the intermediate data according to the operation logic defined in the language file and the dependent language file.
In one embodiment, the server may detect whether the intermediate data has been generated, acquire the intermediate data if the intermediate data has been generated, otherwise, suspend the actuarial calculation until the actuarial calculation of the actuarial task is resumed after the intermediate data is detected to have been generated.
In this embodiment, the language file may further include a dependency tag, the corresponding dependency XML language file is obtained according to the dependency tag, and then calculation is performed according to the defined operation logic and the corresponding basic data in each language file and the dependency language file thereof, which may further improve the convenience of the operation of the actuarial engine.
In one embodiment, after the step of generating report data corresponding to the index, the method further includes: and generating a report display diagram according to the report data.
In this embodiment, the server may receive a display instruction for the report initiated by the user terminal, where the display instruction includes the related report data and the display form. The server can integrate the data of the report header and the report body through coordinates according to the corresponding display form; and rendering the relevant display information of the report according to the rendering processing mode corresponding to the display form, and completing the display of the report data.
In this embodiment, the data display is performed on the report, so that the user can more intuitively obtain the corresponding actuarial result.
FIG. 6 is a schematic diagram of a construction of a actuarial device in one embodiment. As shown in fig. 6, a actuarial apparatus, which runs on a server, includes: a actuarial task obtaining module 602, a calculating module 604 and a report data generating module 606. Wherein:
a calculation task obtaining module 602, configured to obtain a calculation task to be processed, where the calculation task includes a language file and an index to be output; and acquiring basic data having a mapping relation with the language file.
And the calculation module 604 is used for calculating the basic data according to the operation logic defined in the language file.
And a report data generating module 606, configured to generate report data corresponding to the index.
In one embodiment, as shown in FIG. 7, another actuarial device is provided, the device further comprising:
a basic data processing module 608, configured to obtain raw data; and carrying out data cleaning on the original data to generate basic data.
In one embodiment, as shown in fig. 8, there is provided a further actuarial apparatus, the apparatus further comprising:
the actuarial task generating module 610 is configured to obtain an actuarial task generating request, where the actuarial task generating request includes an actuarial model; obtaining a DSL file defined in a actuarial model; checking the information in the DSL file, and generating a language file after the information passes the checking; and acquiring an index to be output, and generating a calculation task according to the language file and the index to be output.
In one embodiment, the calculation module 604 is further configured to detect whether the language file includes a dependent tag, and if yes, read a file identifier in the dependent tag; acquiring a dependent language file corresponding to the file identifier and basic data having a mapping relation with the dependent language file; and calculating the basic data according to the operation logic defined in the language file and the operation logic defined in the dependent language file.
In one embodiment, as shown in fig. 9, there is provided a further actuarial apparatus, the apparatus further comprising:
and the display module 612 is used for generating a report display diagram according to the report data.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by a computer program, which can be stored in a non-volatile computer-readable storage medium, and can include the processes of the embodiments of the methods described above when the program is executed. The storage medium may be a magnetic disk, an optical disk, a Read-Only Memory (ROM), or the like.
The technical features of the embodiments described above may be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the embodiments described above are not described, but should be considered as being within the scope of the present specification as long as there is no contradiction between the combinations of the technical features.
The above-mentioned embodiments only express several embodiments of the present invention, and the description thereof is more specific and detailed, but not construed as limiting the scope of the invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the inventive concept, which falls within the scope of the present invention. Therefore, the protection scope of the present patent shall be subject to the appended claims.

Claims (8)

1. A method of actuarial, the method comprising:
acquiring a to-be-processed actuarial task, wherein the actuarial task comprises a language file and an index to be output;
acquiring basic data having a mapping relation with the language file;
calculating the basic data according to the operation logic defined in the language file;
generating report data corresponding to the indexes;
before the step of obtaining the actuarial task to be processed, the method further comprises the following steps:
acquiring a calculation task generation request, wherein the calculation task generation request comprises a calculation model, the calculation model comprises parameters, indexes and calculation conditions, the calculation model is formed by combining one or more DSL files and is stored in a DSL library, and a mapping relation is established between the calculation model and basic data;
obtaining a DSL file defined in the actuarial model;
checking the information in the DSL file, and generating a language file after the information passes the checking, wherein the language file is an xml language file;
acquiring an index to be output, and generating a calculation task according to the language file and the index to be output;
the step of computing the base data according to the operational logic defined in the language file includes:
detecting whether the language file comprises dependency tags and/or batches, if so, detecting whether the language file comprises dependency tags and/or batches
Reading the file identification and/or the batch in the dependent tag;
acquiring a dependent language file corresponding to the file identifier and basic data and/or intermediate data having a mapping relation with the dependent language file;
and calculating the basic data and/or the intermediate data according to the operation logic defined in the language file and the dependent language file.
2. The method of claim 1, further comprising:
acquiring original data;
and carrying out data cleaning on the original data to generate basic data.
3. The method according to any one of claims 1 to 2, further comprising, after the step of generating report data corresponding to the index:
and generating a report display diagram according to the report data.
4. A actuarial device, the device comprising:
the calculation task acquisition module is used for acquiring a calculation task to be processed, wherein the calculation task comprises a language file and an index to be output; acquiring basic data having a mapping relation with the language file;
the computing module is used for computing the basic data according to the operation logic defined in the language file;
the report data generation module is used for generating report data corresponding to the indexes;
the device further comprises:
the system comprises a calculation task generation module, a calculation task generation module and a calculation module, wherein the calculation task generation request comprises a calculation model, the calculation model comprises parameters, indexes and calculation conditions, the calculation model is formed by combining one or more DSL files and is stored in a DSL library, and a mapping relation is established between the calculation model and basic data; obtaining a DSL file defined in the actuarial model; checking the information in the DSL file, and generating a language file after the information passes the checking, wherein the language file is an xml language file; acquiring an index to be output, and generating a calculation task according to the language file and the index to be output;
the calculation module is further used for detecting whether the language file comprises a dependency label and/or a batch, and if so, reading a file identifier and/or a batch in the dependency label; acquiring a dependent language file corresponding to the file identifier and basic data and/or intermediate data having a mapping relation with the dependent language file; and calculating the basic data and/or the intermediate data according to the operation logic defined in the language file and the operation logic defined in the dependent language file.
5. The apparatus of claim 4, further comprising:
the basic data processing module is used for acquiring original data; and carrying out data cleaning on the original data to generate basic data.
6. The apparatus of any of claims 4 to 5, further comprising:
and the display module is used for generating a report display diagram according to the report data.
7. A computer device comprising a memory, a processor and a computer program stored on said memory and executable on said processor, characterized in that said processor implements the steps of the method according to any of claims 1 to 3 when executing said program.
8. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 3.
CN201710124381.8A 2017-03-03 2017-03-03 Actuarial method and device Active CN107818501B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710124381.8A CN107818501B (en) 2017-03-03 2017-03-03 Actuarial method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710124381.8A CN107818501B (en) 2017-03-03 2017-03-03 Actuarial method and device

Publications (2)

Publication Number Publication Date
CN107818501A CN107818501A (en) 2018-03-20
CN107818501B true CN107818501B (en) 2021-01-08

Family

ID=61600885

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710124381.8A Active CN107818501B (en) 2017-03-03 2017-03-03 Actuarial method and device

Country Status (1)

Country Link
CN (1) CN107818501B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112052256A (en) * 2020-09-02 2020-12-08 平安资产管理有限责任公司 Multi-version request returning method and device, computer equipment and readable storage medium
CN112579586A (en) * 2020-12-23 2021-03-30 平安普惠企业管理有限公司 Data processing method, device, equipment and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101122853A (en) * 2007-09-12 2008-02-13 ***通信集团福建有限公司 Configurable data gathering method
CN101159968A (en) * 2007-11-19 2008-04-09 河北全通通信有限公司 GSM mobile network extension calculating method
CN101187864A (en) * 2007-11-21 2008-05-28 浪潮集团山东通用软件有限公司 Method for exhibiting abstraction and integration for interface
CN101714238A (en) * 2003-06-13 2010-05-26 欧比克商务咨询有限公司 Basic service processing system and basic service processing program
CN103631969A (en) * 2013-12-20 2014-03-12 北京中电普华信息技术有限公司 Generation method and device of report data

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1318954C (en) * 2004-02-07 2007-05-30 华为技术有限公司 Method for imjplementing report forms showing
CN1632794A (en) * 2004-12-27 2005-06-29 中国科学院软件研究所 Method for mapping XML type to RDB table
US9183321B2 (en) * 2006-10-16 2015-11-10 Oracle International Corporation Managing compound XML documents in a repository
CN101122899B (en) * 2007-09-18 2011-01-05 杭州华三通信技术有限公司 Report generation method and device
CN101271475B (en) * 2008-04-02 2011-05-18 北京邮电大学 Commercial intelligent system
CN101957774B (en) * 2010-09-21 2013-12-25 用友软件股份有限公司 Service operation modeling method and device
CN103092890A (en) * 2011-11-08 2013-05-08 苏州中茵泰格科技有限公司 System and method for automatic generation and sending of reports
CN102708161B (en) * 2012-04-24 2014-01-15 清华大学 Modeling method of data logic model utilizing public conceptual sets
CN105760172A (en) * 2016-03-02 2016-07-13 浪潮软件集团有限公司 Statement generation method based on itext

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101714238A (en) * 2003-06-13 2010-05-26 欧比克商务咨询有限公司 Basic service processing system and basic service processing program
CN101122853A (en) * 2007-09-12 2008-02-13 ***通信集团福建有限公司 Configurable data gathering method
CN101159968A (en) * 2007-11-19 2008-04-09 河北全通通信有限公司 GSM mobile network extension calculating method
CN101187864A (en) * 2007-11-21 2008-05-28 浪潮集团山东通用软件有限公司 Method for exhibiting abstraction and integration for interface
CN103631969A (en) * 2013-12-20 2014-03-12 北京中电普华信息技术有限公司 Generation method and device of report data

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
太保精算采集***设计与实现;张皓;《中国优秀硕士学位论文全文数据库 信息科技辑》;20150315(第3期);第I140-725页 *

Also Published As

Publication number Publication date
CN107818501A (en) 2018-03-20

Similar Documents

Publication Publication Date Title
US10789054B2 (en) Methods, systems, apparatuses and devices for facilitating change impact analysis (CIA) using modular program dependency graphs
CN102279790B (en) Distributed debugging method and system
US10318595B2 (en) Analytics based on pipes programming model
CN110795455A (en) Dependency relationship analysis method, electronic device, computer device and readable storage medium
CN109542966B (en) Data fusion method and device, electronic equipment and computer readable medium
CN111797157B (en) Data processing method, system, electronic equipment and storage medium
US11422817B2 (en) Method and apparatus for executing instructions including a blocking instruction generated in response to determining that there is data dependence between instructions
CN108776696B (en) Node configuration method and device, storage medium and electronic equipment
CN112800095A (en) Data processing method, device, equipment and storage medium
JP6419081B2 (en) Transform generation system
CN110765750B (en) Report data input method and terminal equipment
CN107797823B (en) Business rule management method and device, storage medium and computer equipment
US20200057635A1 (en) Information processing apparatus, information processing method and program
CN110866029A (en) sql statement construction method, device, server and readable storage medium
CN111813635A (en) Monitoring method, system and device for intelligent contracts of block chains
CN107818501B (en) Actuarial method and device
CN103186463A (en) Method and system for determining testing range of software
CN112148566B (en) Method and device for monitoring computing engine, electronic equipment and storage medium
CN113434542B (en) Data relationship identification method and device, electronic equipment and storage medium
CN113886443A (en) Log processing method and device, computer equipment and storage medium
CN114005498A (en) Clinical test data logic checking method and device, equipment and storage medium
US9064042B2 (en) Instrumenting computer program code by merging template and target code methods
CN111460021A (en) Data export method and device
WO2015055373A2 (en) Case-based reasoning
CN111277464A (en) Internet of things equipment connection testing method and device and computer readable storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
REG Reference to a national code

Ref country code: HK

Ref legal event code: DE

Ref document number: 1250272

Country of ref document: HK

GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right

Effective date of registration: 20220525

Address after: 518048 China Aviation Center 2901, No. 1018, Huafu Road, Huahang community, Huaqiang North Street, Futian District, Shenzhen, Guangdong Province

Patentee after: Shenzhen Ping An medical and Health Technology Service Co.,Ltd.

Address before: Room 12G, Area H, 666 Beijing East Road, Huangpu District, Shanghai 200001

Patentee before: PING AN MEDICAL AND HEALTHCARE MANAGEMENT Co.,Ltd.

TR01 Transfer of patent right