首页 / 专利库 / 软件 / 建模语言 / Methods, systems and computer program products for web services access of analytical models

Methods, systems and computer program products for web services access of analytical models

阅读:1012发布:2020-11-20

专利汇可以提供Methods, systems and computer program products for web services access of analytical models专利检索,专利查询,专利分析的服务。并且Accessing an analytical model is provided by invoking the analytical model hosted by an analytic engine through a web services interface to the analytic engine. Invocation of the analytical model through the web services interface may be independent of the analytic engine hosting the analytical model. Furthermore, the analytical model may be a predictive model markup language (PMML) model. Invoking the analytical model may be provided by creating a set of tables utilized to store model information and parsing a PMML modeling language representation of the analytical model to populate the set of tables. A web services signature is generated for the analytical model based on the populated set of tables.,下面是Methods, systems and computer program products for web services access of analytical models专利的具体信息内容。

That which is claimed is:1. A method of accessing an analytical model, comprising: providing a web services abstraction of the analytical model so as to allow invocation of the analytical model hosted by an analytic engine through a web services interface to the analytic engine. 2. The method of claim 1, further comprising invoking the analytical model through the web services interface independent of the analytic engine hosting the analytical model. 3. The method of claim 1, wherein the analytical model is a predictive model markup language (PMML) model. 4. The method of claim 3, wherein providing a web services abstraction comprises automatically generating a web services abstraction of the analytical model. 5. The method of claim 4, wherein automatically generating comprises: creating a set of tables utilized to store model information; parsing a PMML modeling language representation of the analytical model to populate the set of tables; and generating a web services signature for the analytical model based on the populated set of tables. 6. The method of claim 5, wherein creating a set of tables comprises: creating a model table; creating a mining field table associated with the model table; and creating physical model tables. 7. The method of claim 6, wherein the physical model tables include a cluster model table, a tree model table and/or a neural network model table. 8. The method of claim 6, wherein the model table contains model identification, model name, model type, model class and attributes fields; wherein the mining field table contains model id, mining field name, optype, outlier, value, usage type, minimum value and maximum value fields; and wherein the physical model tables each include a model name field and a model field. 9. The method of claim 8, wherein parsing a PMML modeling language representation of the analytical model to populate the set of tables comprises extracting information from the PMML modeling language representation to populate the model table and the mining input constraints table. 10. The method of claim 9, wherein extracting information further comprises: parsing elements with a model tag to extract the model type and storing the model type in the model type field of the model table; and parsing elements with the model tag to extract attributes and storing the attributes in the attributes field of the model table. 11. The method of claim 10, wherein extracting information further comprises: aggregating values from a value attribute to store a list of candidates if an optype is categorical; and parsing a univariate stats field for minimum and maximum values if an optype of a value attribute is continuous. 12. The method of claim 9, wherein generating a web services signature comprises: importing mining models to respective ones of the physical model tables; generating a Java bean to wrap around an invocation statement associated with invocation of the analytical model based on the populated tables; generating a web services document based on the generated Java bean; and publishing the generated web service document. 13. The method of claim 12, wherein generating a Java bean comprises carrying out the following for a model in the model table: querying the model and model input constraint tables to retrieve parameters to be applied to the analytical model; generating a Java bean method to serve as a signature for the analytical model, the signature including a list of the retrieved parameters; generating validation logic for inputs based on model constraints; and generating an invocation statement to invoke the analytical model and retrieve results of invocation of the analytical model. 14. A system for accessing an analytic model, comprising: a predictive model markup language (PMML) interrogator configured to parse a PMML file associated with the analytical model and populate tables with information about the analytical model; a bean creator configured to generate a Java bean to wrap an invocation statement that invokes the analytical model based on the populated tables; and a bean to web services circuit configured to transform the Java bean to a web services document so as to allow the analytical model to be invoked by a user of a web services interface. 15. The system of claim 14, wherein the tables populated by the PMML interrogator comprise: a model table; and a mining field table associated with the model table. 16. The system of claim 15, wherein tables with information about the analytical model also include physical model tables and wherein the physical model tables include a cluster model table, a tree model table and/or a neural network model table. 17. The system of claim 15, wherein the model table contains model identification, model name, model type, model class and attributes fields; wherein the mining field table contains model id, mining field name, optype, outlier, value, usage type, minimum value and maximum value fields; and wherein tables with information about the analytical model also include physical model tables and wherein the physical model tables each include a model name field and a model field. 18. The system of claim 17, wherein the PMML interrogator is further configured to extract information from the PMML file to populate the model table and the mining input constraints table. 19. The system of claim 18, wherein the PMML interrogator is further configured to parse elements with a model tag to extract the model type, to store the model type in the model type field of the model table and to parse the element with the model tag to extract attributes and storing the attributes in the attributes field of the model table. 20. The system of claim 19, wherein the PMML interrogator is further configured to aggregate values from a value attribute to store a list of candidates if an optype is categorical and to parse a univariate stats field for minimum and maximum values if an optype of a value attribute is continuous. 21. The system of claim 16, wherein the bean creator is further configured to import mining models to respective ones of the physical model tables. 22. The system of claim 21, wherein the bean creator is further configured to query the model and model input constraint tables to retrieve parameters to be applied to the analytical model, to generate a Java bean method to serve as a signature for the analytical model, the signature including a list of the retrieved parameters, to generate validation logic for inputs based on model constraints, to generate an invocation statement to invoke the analytical model and to retrieve results of invocation of the analytical model. 23. A system for accessing a analytical model, comprising: an analytic engine configured to host the analytical model; and means for providing a web services abstraction of the analytical model so as to allow invocation of the analytical model through a web services interface. 24. The system of claim 23, wherein the analytical model is a predictive model markup language (PMML) model and wherein the means for providing a web services abstraction comprises: means for creating a set of tables utilized to store model information; means for parsing a PMML modeling language representation of the analytical model to populate the set of tables; and means for generating a web services signature for the analytical model based on the populated set of tables. 25. A computer program product for accessing an analytical model through a web services interface, comprising: a computer readable medium having computer readable program code embodied therein, the computer readable program product comprising: computer readable program code configured to create a set of tables utilized to store model information; computer readable program code configured to parse a modeling language representation of the analytical model to populate the set of tables; and computer readable program code configured to generate a web services signature for the analytical model based on the populated set of tables.

说明书全文

FIELD OF THE INVENTION

&null;0001&null; The present invention relates to data warehouses and more particularly to the analysis of data warehouses.

BACKGROUND OF THE INVENTION

&null;0002&null; With increases in the use of computers to collect and store data and with increases in computer based transactions, such as over the Internet, there has been a proliferation of databases containing large amounts of historical data commonly referred to as &null;data warehouses.&null; For example, as more and more data is collected regarding consumer purchase and/or shopping habits, this data may be stored in a data warehouse for subsequent analysis. Other uses of data warehouses include, for example, data warehouses of genetic or other scientific data.

&null;0003&null; While the particular data may vary for different data warehouses, in general, data warehouses are databases of historical data that may utilize a &null;star-schema&null; database structure. A data warehouse is typically present to users through a multi-dimensional hypercube and provides an ad hoc query environment. Furthermore, the data warehouse will, typically, contain a large amount of data and have a complex structure.

&null;0004&null; Analytical models, such as predictive analytical models are conventionally used to analyze data in a data warehouse. Scoring of records against a predictive model, for example, may be provided by a scoring engine. Such application of a predictive model to a database record may be provided, for example, through the use of a Predictive Model Markup Language (PMML) file that defines the application of a model to data. However, invocation of these PMML files is typically platform and/or system dependent such that the necessary operations to invoke a predictive model in one platform and/or system may not function to invoke the predictive model in a different platform and/or system. Thus, models and/or PMML files may be platform and/or system specific, which may reduce the ability to provide best-practices models that may be deployed across different platforms and/or systems.

&null;0005&null; For example, conventionally, to score a record using DB2 Intelligent Miner for Scoring, a DB2 environment is typically needed to utilize the User Defined Function (UDF)/User Defined Type (UDT) information and apply that information to specific data. Thus, if a DB2 environment is unavailable to a user, scoring of a record may be impossible for that user.

&null;0006&null; Furthermore, with conventional models and scoring, there is typically no validation mechanism to check the input parameter(s) provided to the model or scoring engine. Accordingly, erroneous results could be returned that may cause undesirable actions to occur.

SUMMARY OF THE INVENTION

&null;0007&null; Embodiments of the present invention provide methods, systems, and computer program products for accessing an analytical model by providing a web services abstraction of the analytical model so as to allow invocation of the analytical model hosted by an analytic engine through a web services interface to the analytic engine. Invocation of the analytical model through the web services interface may be independent of the analytic engine hosting the analytical model. Furthermore, the analytical model may be a predictive model markup language (PMML) model.

&null;0008&null; In particular embodiments of the present invention, the web services abstraction may be automatically generated by creating a set of tables utilized to store model information and parsing a PMML modeling language representation of the analytical model to populate the set of tables. A web services signature is then generated for the analytical model based on the populated set of tables.

&null;0009&null; In further embodiments of the present invention, the set of tables created includes a model table, a mining field table associated with the model table and physical model tables. The physical model tables may include a cluster model table, a tree model table and/or a neural network model table. The model table may contain model identification, model name, model type, model class and attributes fields. The mining field table may contain model id, mining field name, optype, outlier, value, usage type, minimum value, maximum value and active fields. The physical model tables may each include model name and model fields.

&null;0010&null; In additional embodiments of the present invention, parsing the PMML modeling language representation of the analytical model to populate the set of tables includes extracting information from the PMML modeling language representation to populate the model table and the mining input constraints table. The information may be extracted by parsing elements with a model tag to extract the model type and storing the model type in the model type field of the model table and parsing the element with the model tag to extract attributes and storing the attributes in the attributes field of the model table. Extraction of the information may also include aggregating values from a value attribute to store a list of candidates if an optype is categorical and parsing a field for minimum and maximum values if an optype of a value attribute is continuous.

&null;0011&null; In particular embodiments of the present invention, generating a web services signature is provided by importing mining models to respective ones of the physical model tables, generating a Java bean to wrap around an invocation statement associated with invocation of the analytical model based on the populated tables, generating a web services document based on the generated Java bean and publishing the generated web service document. Generation of a Java bean may be provided by, for each model in the model table, querying the model and model input constraint tables to retrieve parameters to be applied to the analytical model. A Java bean method is generated to serve as a signature for the analytical model, the signature including a list of the retrieved parameters. Validation logic is generated for inputs based on model constraints. An invocation statement, such as an apply SQL statement, is generated to invoke the analytical model and retrieve results of invocation of the analytical model.

&null;0012&null; In still other embodiments of the present invention, a system for accessing an analytic model is provided that includes a predictive model markup language (PMML) interrogator configured to parse a PMML file associated with the analytical model and populate tables with information about the analytical model. A bean creator is configured to generate a Java bean to wrap an invocation statement, such as a SQL statement, that invokes the analytical model based on the populated tables. A bean to web services circuit is configured to transform the Java bean to a web services document so as to allow the analytical model to be invoked by a web services interface.

&null;0013&null; The tables populated by the PMML interrogator may include a model table and a mining field table associated with the model table. Physical model tables may also be provided and may include a cluster model table, a tree model table and/or a neural network model table. The model table may contain model identification, model name, model type, model class and attributes fields. The mining field table may contain model id, mining field name, optype, outlier, value, usage type, minimum value, maximum value and active fields. The physical model tables may each include a model name field and a model field.

&null;0014&null; In further embodiments of the present invention, the PMML interrogator is further configured to extract information from the PMML file to populate the model table and the mining input constraints table. The PMML interrogator may be configured to parse elements with a model tag to extract the model type, to store the model type in the model type field of the model table, parse the element with the model tag to extract attributes and to store the attributes in the attributes field of the model table. The PMML interrogator may be further configured to aggregate values from a value attribute to store a list of candidates if an optype is categorical and to parse a field for minimum and maximum values if an optype of a value attribute is continuous.

&null;0015&null; In additional embodiments of the present invention, the bean creator is further configured to import mining models to respective ones of the physical model tables. The bean creator may also be configured to query the model and model input constraint tables to retrieve parameters to be applied to the analytical model, generate a Java bean method to serve as a signature for the analytical model, the signature including a list of the retrieved parameters, generate validation logic for inputs based on model constraints, to generate an invocation statement, such as an apply SQL statement, to invoke the analytical model and to retrieve results of invocation of the analytical model.

&null;0016&null; As will further be appreciated by those of skill in the art, while described above primarily with reference to method aspects, the present invention may be embodied as methods, apparatus/systems and/or computer program products.

BRIEF DESCRIPTION OF THE DRAWINGS

&null;0017&null; FIG. 1 is a block diagram of a data processing system suitable for use in embodiments of the present invention;

&null;0018&null; FIG. 2 is a more detailed block diagram of a system according to embodiments of the present invention;

&null;0019&null; FIGS. 3A and 3B are block diagrams of web services systems according to embodiments of the present invention;

&null;0020&null; FIG. 4 is flowchart illustrating operations according to embodiments of the present invention;

&null;0021&null; FIG. 5 is a flowchart illustrating operations for PMML parsing according to further embodiments of the present invention;

&null;0022&null; FIG. 6 is a flowchart illustrating operations for web services generation according to embodiments of the present invention;

&null;0023&null; FIG. 7 is a flowchart illustrating operations for Java bean generation according to embodiments of the present invention;

&null;0024&null; FIG. 8 is a diagram of table structures suitable for use in embodiments of the present invention;

&null;0025&null; FIG. 9 is a listing of exemplary XML from a PMML file; and

&null;0026&null; FIG. 10 is a diagram of a populated table structure for illustrating embodiments of the present invention.

DETAILED DESCRIPTION OF THE INVENTION

&null;0027&null; The present invention now will be described more fully hereinafter with reference to the accompanying drawings, in which illustrative embodiments of the invention are shown. This invention may, however, be embodied in many different forms and should not be construed as limited to the embodiments set forth herein; rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the invention to those skilled in the art. Like numbers refer to like elements throughout.

&null;0028&null; As will be appreciated by those of skill in the art, the present invention may be embodied as a method, data processing system, or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects all generally referred to herein as a &null;circuit&null; or &null;module.&null; Furthermore, the present invention may take the form of a computer program product on a computer-usable storage medium having computer-usable program code embodied in the medium. Any suitable computer readable medium may be utilized including hard disks, CD-ROMs, optical storage devices, a transmission media such as those supporting the Internet or an intranet, or magnetic storage devices.

&null;0029&null; Computer program code for carrying out operations of the present invention may be written in an object oriented programming language such as Java&null;, Smalltalk or C&null;&null;. However, the computer program code for carrying out operations of the present invention may also be written in conventional procedural programming languages, such as the &null;C&null; programming language. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer. In the latter scenario, the remote computer may be connected to the user's computer through a local area network (LAN) or a wide area network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet Service Provider).

&null;0030&null; The present invention is described below with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and/or block diagrams, and combinations of blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions/acts specified in the flowchart and/or block diagram block or blocks.

&null;0031&null; These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function/act specified in the flowchart and/or block diagram block or blocks.

&null;0032&null; The computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions that execute on the computer or other programmable apparatus provide steps for implementing the functions/acts specified in the flowchart and/or block diagram block or blocks.

&null;0033&null; Various embodiments of the present invention will now be described with reference to the figures. FIG. 1 illustrates an exemplary embodiment of a data processing system 130 suitable for use in accordance with embodiments of the present invention. The data processing system 130 typically includes input device(s) 132 such as a keyboard or keypad, a display 134, and a memory 136 that communicate with a processor 138. The data processing system 130 may further include a speaker 144, and an I/O data port(s) 146 that also communicate with the processor 138. The I/O data ports 146 can be used to transfer information between the data processing system 130 and another computer system or a network. These components may be conventional components, such as those used in many conventional data processing systems, which may be configured to operate as described herein.

&null;0034&null; FIG. 2 is a block diagram of data processing systems that illustrates systems, methods, and computer program products in accordance with embodiments of the present invention. The processor 138 communicates with the memory 136 via an address/data bus 248. The processor 138 can be any commercially available or custom microprocessor. The memory 136 is representative of the overall hierarchy of memory devices containing the software and data used to implement the functionality of the data processing system 130. The memory 136 can include, but is not limited to, the following types of devices: cache, ROM, PROM, EPROM, EEPROM, flash memory, SRAM, and DRAM.

&null;0035&null; As shown in FIG. 2, the memory 136 may include several categories of software and data used in the data processing system 130: the operating system 252; the application programs 254; the input/output (I/O) device drivers 258; and the data 256. As will be appreciated by those of skill in the art, the operating system 252 may be any operating system suitable for use with a data processing system, such as OS/2, AIX or System390 from International Business Machines Corporation, Armonk, N.Y., Windows95, Windows98, Windows2000 or WindowsXP from Microsoft Corporation, Redmond, Wa., Unix or Linux. The I/O device drivers 258 typically include software routines accessed through the operating system 252 by the application programs 254 to communicate with devices such as the I/O data port(s) 146 and certain memory 136 components. The application programs 254 are illustrative of the programs that implement the various features of the data processing system 130 and preferably include at least one application which supports operations according to embodiments of the present invention. Finally, the data 256 represents the static and dynamic data used by the application programs 254, the operating system 252, the I/O device drivers 258, and other software programs that may reside in the memory 136.

&null;0036&null; As is further seen in FIG. 2, the application programs 254 may include an analytical model broker module 260 according to embodiments of the present invention. The analytical model broker module 260 may provide a web services abstraction of analytical models that may be used to invoke the analytical models through a web services interface/system. The data portion 256 of memory 136, as shown in the embodiments of FIG. 2, may include PMML model information 262 that may be used to provide web services access to analytical models by the analytical model broker module 260 as described herein.

&null;0037&null; While the present invention is illustrated, for example, with reference to the analytical model broker module 260 being an application program in FIG. 2, as will be appreciated by those of skill in the art, other configurations may also be utilized while still benefitting from the teachings of the present invention. For example, the analytical model broker module 260 may also be incorporated into the operating system 252 or other such logical division of the data processing system 130. Thus, the present invention should not be construed as limited to the configuration of FIG. 2 but is intended to encompass any configuration capable of carrying out the operations described herein.

&null;0038&null; Furthermore, while the analytical model broker module 260 is illustrated in a single data processing system, as will be appreciated by those of skill in the art, such functionality may be distributed across one or more data processing systems. Thus, the present invention should not be construed as limited to the configuration illustrated in FIGS. 1 and 2 but may be provided by other arrangements and/or division of function between data processing systems.

&null;0039&null; FIGS. 3A and 3B are block diagrams of systems incorporating an analytical model broker 260 according to embodiments of the present invention. As illustrated in FIGS. 3A and 3B, embodiments of the present invention may provide a client 316 access to a model engine 314 through web services 312. The web services 312 may, for example, be provided by a WebSphere Application Server from International Business Machines, Armonk, N.Y., or other such web services systems known to those of skill in the art. The model engine 314 may, for example, be a data mining and/or scoring engine that may score, rank and/or classify data records. For example, the model engine 314 may be DB2 Intelligent Mining Scoring Engine from International Business Machines, Armonk, N.Y.

&null;0040&null; As is further illustrated in FIG. 3A, a PMML file 302, which may be generated by the model engine 314 or otherwise provided, is parsed by a PMML interrogator 300 to extract information about the analytical model reflected in the PMML file. The information stored in the PMML file may be stored in an XML or other such mark-up language format. The extracted information may be stored in tables 306 that contain information about the model, such as input parameters, permissible ranges, model identifiers, types and names and the like. Furthermore, the tables 306 may also include a copy of the model itself, for example, stored as a binary large object (BLOB).

&null;0041&null; The bean creator 308 utilizes information in the tables 306 to generate a Java bean 309 that wraps a database invocation statement, such as an SQL statement, that invokes the model. The bean creator 308 may, for example, generate parameter lists and validation logic for inputs so as to provide input validation through the web services 312. The bean 309 created by the bean creator 308 is transformed by the bean to web services transformer 310 that packages the created Java bean for deployment through the web services 312. For example, a Java bean may be transformed by the WebSphere Studio Application Developler (WSAD) from International Business Machines, Armonk, N.Y., to provide web services description language (WSDL) and deployment descriptor files. WSAD may also package the Java bean into Java 2 Enterprise Edition (J2EE) compliant web application archive (WAR) file or enterprise archive (EAR) file to be deployed by a web application server.

&null;0042&null; As seen in FIG. 3B, when the client 316 accesses the web services 312 to invoke the model, the created bean 309 is accessed with information from the client 316 so as to invoke the model with the model engine 314. The model engine 314 accesses the physical table of the tables 306 to obtain the model and executes the model. The physical table may be directly and/or indirectly accessed by the model engine 314.

&null;0043&null; FIG. 4 illustrates operations of an analytical model broker 260 according to embodiments of the present invention. As seen in FIG. 4, tables, such as the tables 306 of FIG. 3, are created that store PMML model information (block 400). FIG. 8 illustrates exemplary tables the may be created according to particular embodiments of the present invention. In particular, a Model Table, a Mining Field Table and physical model tables may be created to store information from the PMML file. As illustrated in FIG. 8, the Model Table may include the following fields (columns):

&null;0044&null; Model Id: the unique id to identify the model;

&null;0045&null; Model Name: the unique name of the model;

&null;0046&null; Model Type: the type of the model;

&null;0047&null; Model Class: the class type of the model; and

&null;0048&null; Attibutes: the unique attributes belonging to the model.

&null;0049&null; The Mining Field Table may include the following fields (columns):

&null;0050&null; Model id: the unique id to identify the model (Foreign key to Model Table);

&null;0051&null; Mining Field Name: mining data input parameter;

&null;0052&null; Optype: the mining data type;

&null;0053&null; Outlier: the type and treatment of the outlier;

&null;0054&null; Value: the categorical values;

&null;0055&null; Usage Type: the usage type of this mining field; it can be, for example, active, predicted or supplementary;

&null;0056&null; MinValue: the minimum value for the mining field; and

&null;0057&null; MaxValue: the maximum value for the mining field.

&null;0058&null; Different physical model tables may be provided for differing types of models. For example, as illustrated in FIG. 8, a Clustering Model Table may be provided that includes fields (columns):

&null;0059&null; Model Name: the name of the model (Foreign key to Model Table); and

&null;0060&null; Model: the model content in BLOB format.

&null;0061&null; Similarly, a Tree Model table and a Neural Network Model table may also be provided that include Model Name and Model fields (columns).

&null;0062&null; As is further seen in FIG. 8, the Model Id may be a key for the Model Table and a foreign key FK for the Mining Field Table. The Model Name field of the Model Table may be a foreign key FK for the physical tables, such as the Clustering Model table, the Tree Model table and the Neural Network Model table.

&null;0063&null; Returning to FIG. 4, a PMML file is parsed, for example, by the PMML Interrogator 300 of FIG. 3, to populate model attributes into the created tables (block 410). An example of a PMML file is illustrated in FIG. 9 and the corresponding populated tables are illustrated in FIG. 10. A web services signature is created for the model based on the populated tables (block 420), for example, by the bean creator 308 and bean to web services transformer 310 of FIG. 3. For example, such a web services signature may be used by the client 316 to invoke the analytical model, where access to the analytic engine 314 hosting the model is provided through the web services 312.

&null;0064&null; FIG. 5 illustrates operations of particular embodiments of the present invention for parsing and extracting PMML model information from the PMML model file at block 410 of FIG. 4. In extracting PMML model information from the PMML model file, some of the information may be directly mapped to fields of the Model Table and the Mining Field Table while other information is generated based on information in the PMML model file. Table 1 illustrates a mapping between PMML model file information and entries in the exemplary Model Table and Mining Field Table.

1

TABLE 1

PMML to Table Mapping

PMML DTD

Table.column

%Model.modelName

Model.Model_name

%Model

Model.Model_type

%Model.modelClass

Model.Model_class

%Model.attributes

Model.Attributes

DataField.name

Mining Field.Mining_Field_name

DataField.optype

Mining Field.optType

Can be in one of the following:

( categorical &null; ordinal &null; continuous)

%Model.MiningField.outliers

Mining Field.Outlier

DataField.value

Mining Field.Value

%Model.MiningField.usageType

Mining Field.Usage_type

UnivariateStats.field.NumericInfo.

Mining Field.MinValue

minimum

UnivariateStats.field.NumericInfo.

Mining Field.MaxValue

maximum

&null;0065&null; Of the PMML information, each of the PMML data directly maps to the corresponding table except for % Model, % Model.attributes and DataField.value. The entries corresponding to this PMML information are generated as the PMML model file is parsed. Operations for such parsing and generation are illustrated in FIG. 5.

&null;0066&null; As seen in FIG. 5, a PMML attribute/element is extracted from the PMML file (block 500). If the PMML attribute/element corresponds to PMML information that is directly mapped to a corresponding table field (block 502), the extracted value is stored in the corresponding table (block 516). For example, the PMML file is parsed for the % Model.MiningField.usageType field and that information is directly mapped to the Usage Type field of the Mining Field Table. Thus, the Usage Type may be active, supplementary, predicted or not specified. If more elements/attributes are present (block 518), the next element/attribute is extracted from the PMML file (block 500) and operations continue with block 502. Otherwise, parsing of the PMML file and population of the tables is complete.

&null;0067&null; If the PMML attribute/element does not correspond to PMML information that is directly mapped to a corresponding table field (block 502), it is determined if the tag of the extracted PMML attribute/element ends in &null;Model&null; (block 504). If the tag of the extracted PMML attribute/element ends in &null;Model&null; (block 504), the PMML attribute/element is parsed to extract the model type (block 506). Candidates for the model type may include, for example, any of the following model types: TreeModel, NeuralNetwork, ClusteringModel, RegressionModel, GeneralRegressionModel, AssociationModel. Furthermore, attributes associated with the element are parsed to extract attributes other than modelName and modelClass (block 506). The model type is stored in the Model Type field of the Model Table and the other attributes are stored in the Attribute field of the Model Table (block 516). If more elements/attributes are present (block 518), the next element/attribute is extracted from the PMML file (block 500) and operations continue with block 502. Otherwise, parsing of the PMML file and population of the tables is complete.

&null;0068&null; If the tag does not end in &null;Model&null; (block 504), the value of DataField.optype is also evaluated and, if equal to &null;Categorical&null; (block 508), then the values from Value attribute are aggregated to form a list of candidate values (block 510). The aggregated candidate values are stored in the Value field of the Mining Field Table (block 516). If more elements/attributes are present (block 518), the next element/attribute is extracted from the PMML file (block 500) and operations continue with block 502. Otherwise, parsing of the PMML file and population of the tables is complete.

&null;0069&null; If the value of DataField.optype is not &null;Categorical&null; (block 508), but is equal to &null;Continuous&null; (block 512), then the UnivariateStats field is parsed to retrieve the minimum and maximum values (block 514). The minimum and maximum values are stored in the respective min and max value fields of the Mining Field Table (block 516). If more elements/attributes are present (block 518), the next element/attribute is extracted from the PMML file (block 500) and operations continue with block 502. Otherwise, parsing of the PMML file and population of the tables is complete. If the value of DataField.optype is not equal to &null;Continuous&null; (block 512), operations proceed to block 518 as described above.

&null;0070&null; An example of populated tables as a result of the parsing illustrated in FIG. 5 is seen in FIG. 10. The tables in FIG. 10 were populated based on the example PMML file of FIG. 9. In the example PMML file illustrated in FIG. 9, ClusteringModel, numberOfCluster&null;9 will be stored in the appropriate fields as illustrated in the populated tables of FIG. 10. Furthermore, Income field has an optype of continuous, so the minimum value of 2 and the maximum value of 198170 are extracted and stored in the Mining Field Table fields of MinVal and MaxVal. The Color field has an optype of categorical, so the candidate values of blue, pink, etc. are stored in the Value field of the Mining Field Table. Additional parsing and population of the tables is also illustrated by FIGS. 9 and 10.

&null;0071&null; FIG. 6 illustrates operations for the generation of a web services signature as reflected in block 420 of FIG. 4 according to particular embodiments of the present invention. As seen in FIG. 6, the analytical models, such as mining models, are imported to the model field of their respective physical tables (block 600). For example, the mining models may be imported as a binary large object (BLOB) of the model. In particular, the Store Procedure provided with DB2 Intelligent Mining Scoring may be used to import the model into its corresponding model table. For example, the Store Procedure may be used to insert into IDMMX.ClusterModels values as follows:

&null;0072&null; (&null;DemoBankingPMML&null;, IDMMX.DM_impClusFileE(&null;C:&null;imv6.1&null;PMMLTOOL&null;profile&null;bankcluster.xml&null;,&null;is o-8859-1&null;));

&null;0073&null; A Java bean is also generated to wrap around an invocation statement, such as a SQL select statement, that invokes the analytical model (block 610). Operations according to particular embodiments of the present invention for generating the Java bean are illustrated in further in FIG. 7. As seen in FIG. 7, the Model Table and the Mining Field Table are queried to retrieve parameters for the model (block 700). A Java bean method is generated with the parameters list retrieved from the tables to serve as a signature for the model (block 702). Validation logic for inputs is generated based on the model constraints retrieved from the Mining Field Table and incorporated in the Java bean (block 704). For example, validation logic may be provided to confirm that values for a field are between the minVal and maxVal values or that an input is one of a number of enumerated candidates for a categorical optype. An invocation statement, such as an apply SQL statement, is also generated and incorporated in the Java bean that will invoke the model and apply the set of data to a model to score/rank/classify the set of data and retrieve the results (block 706).

&null;0074&null; In the example illustrated in FIGS. 8-10, the following Java code may be generated to provide the Java bean:

2

Public class BankingClusterModel

&null;

public BankingClusterModel( )

&null;

&null;

public ScoreResult score(type, age, siblings, income,

product)

&null;

//assume that product &null;&null;null, the SQL generated will be

similar to the following

Validate the input parameter value

SQL query&null;&null;

with clusterView( clusterResult ) as

(

select IDMMX.DM_applyClusModel( c.model ,

IDMMX.DM_applData(

IDMMX.DM_applData(

IDMMX.DM_applData(

IDMMX.DM_applData(

&null;colour&null;, &null;&null;type &null;&null;),

&null;AGE&null;, &null;&null;age&null;&null;),

&null;SIBLINGS&null;, &null;&null;siblings &null;&null;),

&null;INCOME&null;, &null;&null;income &null;&null;))

from IDMMX.clustermodels c where

c.modelname&null;&null;DemoBankingPMML&null;

)

select IDMMX.DM_getClusterID( clusterResult ),

IDMMX.DM_getClusScore( clusterResult )

from clusterView where IDMMX.DM_getClusScore(

clusterResult )>0.7;&null;

execute SQL statement......

&null;

&null;

&null;0075&null; Returning to FIG. 6, a web services document is generated from the Java bean and published (block 620). In particular, as discussed above, WSAD may be used to generate a set of WSDL and Deployment Descriptor file. WSAD can also package the Java Bean into J2EE compliant WAR file or EAR file to be deployed to a Web Application Server. The WSDL and Deployment Descriptor file are provided to a web services system, such as the web services 312.

&null;0076&null; Thus, as illustrated in FIGS. 1 through 10, a PMML file may be transformed into Web Services so there is no platform, language and/or database dependency between the client application and the scoring engine. Moreover, a set of input parameter validation rules may be derived from the model and stored. At run time, Web Service can programmatically and systematically validate the input value and type to limit or prevent invalid inputs and, accordingly, erroneous results. Particular embodiments of the present invention may be particularly well suited to e-commerce, business-to-business (B2B) and/or business-to-customer (B2C) environments where a user can invoke a Web Service to score/rank/classify a record by applying a set of data to the model previously harvested from a mining engine. Embodiments of the present invention may also provide an e-utility center where a center service provider can serve differing types of mining models so that scoring information can be shared and distributed over the network and/or enterprise.

&null;0077&null; Embodiments of the present invention may create a framework that may increase the exploitation of mining and analytic intellectual capital by enabling easier utilization of analytic services across a broad range of business applications. An environment may be created where mining experts can be employed to develop best-practices industry models without being required to participate in every analytic deployment. An e-Utility approach to analytic models may facilitate integrated real-time analytics where models can be invoked real-time from, for example, operational WebSphere applications and business processes. Furthermore, embodiments of the present invention may allow a model generated to be ubiquitously scored and may reduce or eliminate cross-platform or cross-language limitations for applying models, based on the nature of Web Services. Embodiments of the present invention may also provide a central repository to validate the data type, range, and value for the parameters checking when Web Services are invoked. Embodiments of the present invention could also be utilized to produce a list of statistics on models based on their type, attributes, and values, etc. through, for example, evaluation of the tables generated through parsing of the PMML files.

&null;0078&null; The flowcharts and block diagrams of FIGS. 1 through 10 illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flow charts or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the blocks may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be understood that each block of the block diagrams and/or flowchart illustrations, and combinations of blocks in the block diagrams and/or flowchart illustrations, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.

&null;0079&null; In the drawings and specification, there have been disclosed typical illustrative embodiments of the invention and, although specific terms are employed, they are used in a generic and descriptive sense only and not for purposes of limitation, the scope of the invention being set forth in the following claims.

高效检索全球专利

专利汇是专利免费检索,专利查询,专利分析-国家发明专利查询检索分析平台,是提供专利分析,专利查询,专利检索等数据服务功能的知识产权数据服务商。

我们的产品包含105个国家的1.26亿组数据,免费查、免费专利分析。

申请试用

分析报告

专利汇分析报告产品可以对行业情报数据进行梳理分析,涉及维度包括行业专利基本状况分析、地域分析、技术分析、发明人分析、申请人分析、专利权人分析、失效分析、核心专利分析、法律分析、研发重点分析、企业专利处境分析、技术处境分析、专利寿命分析、企业定位分析、引证分析等超过60个分析角度,系统通过AI智能系统对图表进行解读,只需1分钟,一键生成行业专利分析报告。

申请试用

QQ群二维码
意见反馈