CN112799647A - Business personnel-oriented rule engine adapter device identification method - Google Patents

Business personnel-oriented rule engine adapter device identification method Download PDF

Info

Publication number
CN112799647A
CN112799647A CN202110388683.2A CN202110388683A CN112799647A CN 112799647 A CN112799647 A CN 112799647A CN 202110388683 A CN202110388683 A CN 202110388683A CN 112799647 A CN112799647 A CN 112799647A
Authority
CN
China
Prior art keywords
rule
data
defining
dsl
sdk
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.)
Granted
Application number
CN202110388683.2A
Other languages
Chinese (zh)
Other versions
CN112799647B (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.)
Sichuan XW Bank Co Ltd
Original Assignee
Sichuan XW Bank 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 Sichuan XW Bank Co Ltd filed Critical Sichuan XW Bank Co Ltd
Priority to CN202110388683.2A priority Critical patent/CN112799647B/en
Publication of CN112799647A publication Critical patent/CN112799647A/en
Application granted granted Critical
Publication of CN112799647B publication Critical patent/CN112799647B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/20Software design
    • G06F8/22Procedural
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/31Programming languages or programming paradigms
    • G06F8/315Object-oriented languages
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/38Creation or generation of source code for implementing user interfaces

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Computing Systems (AREA)
  • Stored Programmes (AREA)

Abstract

The invention belongs to the technical field of communication, and particularly relates to a method for identifying a rule engine adapter device facing business personnel, which comprises the following steps: step 1, defining an interface message format based on DSL; step 2, defining a client SDK based on Java language; step 3, defining a rule design interface based on HTML; step 4, defining JSON-DSL logic; and 5, defining rule metadata storage and display logic. The invention not only meets the requirements of developers on-line simulation test, version control and real-time change of rule models without modifying codes, but also meets the characteristics of simple operation and seamless integration with a service system of service personnel through the conversion of the adapter.

Description

Business personnel-oriented rule engine adapter device identification method
Technical Field
The invention belongs to the technical field of communication, and particularly relates to a method for identifying a rule engine adapter device facing business personnel.
Background
The rule engine is developed by an inference engine, is a component embedded in an application program, and realizes the separation of business decisions from application program codes and the writing of the business decisions by using a predefined semantic module. Data input is received, business rules are interpreted, and business decisions are made according to the business rules.
The rules engine mainly includes several main categories of RETE algorithm, DSL, expression, etc. Among them, the rule engine based on the RETE algorithm is currently the most widely used one with better execution efficiency. It is an efficient pattern matching algorithm to implement a generative rule system, RETE can be divided into two parts: rule compilation and runtime execution. The rule compiling refers to a process of generating the inference network according to rule integration, and the running execution refers to a process of sending data into the inference network for screening. The RETE algorithm-based rule designer sacrifices part of interface friendliness in the aspects of powerful function, flexible change and interface friendliness, is a simple and easy-to-use rule designer when facing developers who understand the technology, but is abstract when facing business personnel, so that the business personnel are difficult to use the rule engine and difficult to seamlessly dock with a business system.
Disclosure of Invention
The invention provides a method for identifying a rule engine adapter device facing business personnel, which aims to solve the problems that the business personnel are difficult to use the rule engine and difficult to seamlessly joint with a business system.
A method for identifying a business person-oriented rule engine adapter device comprises the following steps:
step 1: defining the interface message format of DSL, and defining the attributes including a rule variable library, an operator, a variable type, a data type and a message structure element;
step 2: defining a client side SDK based on java language, and defining conversion logic comprising an RPC protocol, an embedded WEB container, JSON and DSL, wherein the SDK is interacted with a rule engine server side;
and step 3: defining a rule design interface based on HTML, wherein the definition comprises an interface style, a data form, a message format and a message transmission mode;
and 4, step 4: loading the SDK containing the lightweight WEB container into a service system, and accessing and using a rule designer in the SDK by service personnel through an HTTP link;
and 5: defining a mapping logic of JSON data and DSL messages in an SDK packet of a client, and converting input rule data into messages in a DSL format so as to facilitate a rule engine server to identify and construct a rule model;
step 6: and defining the mapping logic of JSON data and JAVA class objects in the client side SDK package, wherein the mapping logic is used for storing input data according to fields, and is convenient for a front end HTML interface to display stored rule data.
Compared with the prior art, the invention has the beneficial effects that: 1. the invention can be used as an adapting device of a universal rule engine designer, meets the requirements of developers on-line simulation test, version control and rule model real-time change without modifying codes, and also meets the characteristics of simple operation and seamless integration with a service system for service personnel through the conversion of an adapter.
2. The invention can seamlessly embed the rule engine interface into the service system management background, provides a form type rule design interface, facilitates the online real-time creation and change of rules by service personnel, and provides a monitoring interface for the execution state of the rules.
Drawings
FIG. 1 is a flow chart of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Referring to fig. 1, the method for identifying a business-oriented rule engine adapter device according to the present invention includes the following steps:
step 1: defining the interface message format of DSL, and defining the attributes including a rule variable library, an operator, a variable type, a data type and a message structure element; rule metadata such as rule-set, rule, import-variable-library, etc., also including count, avg, sum, max, and, or, etc.;
an interface is designed by defining rules facing WEB forms and is used for converting a complex graphical data interface into a more concise DSL interface;
step 2: defining a client side SDK based on java language, and defining conversion logic comprising an RPC protocol, an embedded WEB container, JSON and DSL, wherein the SDK is interacted with a rule engine server side;
business personnel generally carry out business operation and management through a business management system, and the design of business rules is also defined as a part of business operation; the rule engines of most banks as a shared basic platform can be commonly used by a plurality of business systems, the rule engines and the business systems can also be responsible for different departments, and the seamless connection between the rule designer and the business systems directly influences the fluency of business personnel using the rule engines; and step 2, the client side SDK based on the java language is defined, and because the SDK comprises the lightweight WEB container, the rule designer can be directly used and can be seamlessly connected to the service system as long as the SDK is loaded into the service system, and the service system does not need to consider the problems of rule designer integration and deployment.
And step 3: defining a rule design interface based on HTML, wherein the definition comprises an interface style, a data form, a message format and a message transmission mode;
and 4, step 4: the SDK containing the lightweight WEB container is loaded into a service system, and service personnel access and use a rule designer in the SDK through an HTTP link.
The rule designer interface based on the HTML form is deployed in an embedded WEB container in the client side SDK, and the rule designer can be accessed and used through an HTTP link as long as the service system loads the SDK. The design has two main purposes, namely, the rule designer can be seamlessly embedded into a business system, and business personnel can use the rule designer conveniently; and secondly, extra deployment of a service system or code level embedding rule designers are avoided, and the purpose of instant use is achieved. And the business personnel can operate more simply by defining a rule design interface based on HTML.
And 5: defining a mapping logic of JSON data and DSL messages in an SDK packet of a client, and converting input rule data into messages in a DSL format so as to facilitate a rule engine server to identify and construct a rule model;
rule data input by business personnel from an HTML rule designer is packaged in a universal JSON format on a front-end page, but a DSL message interface is provided by a rule engine server, and the JSON format needs to be converted into DSL and then submitted to the rule engine server. The client side SDK undertakes the message conversion work from JSON to DSL. The design is mainly to avoid exposing some technical details of the rule engine to the business system, and the business system only needs to use the rule designer without paying attention to internal implementation details.
Step 6: and defining the mapping logic of JSON data and JAVA class objects in the client side SDK package, wherein the mapping logic is used for storing input data according to fields, and is convenient for a front end HTML interface to display stored rule data.
The rule designer based on HTML provides the capability of creating rules, and needs to consult and change the rules, and when creating the rules, the rule engine server side constructs the rule factors into a rule model and then stores the whole rule model into a relational database. If business personnel want to consult or change the rule model, the complex rule model needs to be parsed into a series of rule factors. Thus, in order for the rule designer to easily review and alter the rule model, there are two parallel paths during rule creation, as depicted in step 5: one is that after the rule factor is constructed into a rule model, the whole rule model is stored in a relational database for subsequent rule service invocation; the other path is that as described in step 6, the rule factors input by the service personnel are directly stored in the relational database, the service personnel consult the rules and directly read the original rule factors, and when the rules are changed, the data of the two paths need to be changed at the same time.
In the step 1, according to the rule engine modeling requirement based on the RETE algorithm, the rule variables, data and computation logic are expressed as messages in the DSL format, and the message categories include, but are not limited to, rule-set, rule, import-variable-library rule metadata and count, avg, sum, max, and or operators.
In the step 2, the rule design interface used by the service-oriented personnel is packaged in the client SDK, and the rule design interface is operated by an embedded web container; the data input from the rule design interface is converted into a message in a DSL format by JSON and DSL conversion logic, and then is transmitted to the rule engine server by an RPC protocol.
In the step 3, the HTML-based rule design interface is customized according to actual service requirements, so that a client can directly access the interface after starting, and can conveniently embed the interface into a service management system in a link form, code intrusion on an original system cannot be caused, and the plug-and-play mode is very convenient.
In the step 5, the data of the front-end rule design interface is transmitted to the client side SDK in the JSON format, and after the data is processed through JSON-to-DSL logic in the SDK, the rule data is finally transmitted to the rule engine server side in the DSL format through the RPC protocol to construct the rule model.
In the step 6, the front-end rule design interface needs to display the existing rule data in the database besides inputting the data; therefore, the original data in the front-end JSON format is converted into Java objects in the client SDK, and then the Java objects are stored in a relational database according to fields and used for displaying a front-end rule design interface; the rule data displayed by the front end is simpler.
It will be evident to those skilled in the art that the invention is not limited to the details of the foregoing illustrative embodiments, and that the present invention may be embodied in other specific forms without departing from the spirit or essential attributes thereof. The present embodiments are therefore to be considered in all respects as illustrative and not restrictive, the scope of the invention being indicated by the appended claims rather than by the foregoing description, and all changes which come within the meaning and range of equivalency of the claims are therefore intended to be embraced therein. Any reference sign in a claim should not be construed as limiting the claim concerned.
Furthermore, it should be understood that although the present description refers to embodiments, not every embodiment may contain only a single embodiment, and such description is for clarity only, and those skilled in the art should integrate the description, and the embodiments may be combined as appropriate to form other embodiments understood by those skilled in the art.

Claims (8)

1. A business person-oriented rule engine adapter device identification method is characterized in that: the method comprises the following steps:
step 1: defining the interface message format of DSL, and defining the attributes including a rule variable library, an operator, a variable type, a data type and a message structure element;
step 2: defining a client side SDK based on java language, and defining conversion logic comprising an RPC protocol, an embedded WEB container, JSON and DSL, wherein the SDK is interacted with a rule engine server side;
and step 3: defining a rule design interface based on HTML, wherein the definition comprises an interface style, a data form, a message format and a message transmission mode;
and 4, step 4: the SDK containing the lightweight WEB container is loaded into a service system, and service personnel access and use a rule designer in the SDK through an HTTP link.
2. A method of identifying a business-worker-oriented rules engine adaptor apparatus as claimed in claim 1, wherein: further comprising the step 5: and defining a mapping logic of JSON data and DSL messages in the SDK packet of the client, and converting the input rule data into the messages in the DSL format, so that the rule engine server can conveniently identify and construct a rule model.
3. A method of identifying a business-worker-oriented rules engine adaptor apparatus as claimed in claim 1, wherein: further comprising the step 6: and defining the mapping logic of JSON data and JAVA class objects in the client side SDK package, wherein the mapping logic is used for storing input data according to fields, and is convenient for a front end HTML interface to display stored rule data.
4. A method of identifying a business-worker-oriented rules engine adaptor apparatus as claimed in claim 1, wherein: the specific method of the step 1 is as follows: according to the rule engine modeling requirement based on RETE algorithm, rule variables, data and computational logic are expressed as messages in DSL format, and the message class content comprises rule-set, rule, import-variable-library rule metadata and count, avg, sum, max, and or operators.
5. A method of identifying a business-worker-oriented rules engine adaptor apparatus as claimed in claim 1, wherein: the step 2 comprises the following specific steps: packaging a rule design interface used by service personnel in a client SDK, and operating the rule design interface by using an embedded web container; the data input from the rule design interface is converted into a message in a DSL format by JSON and DSL conversion logic, and then is transmitted to the rule engine server by an RPC protocol.
6. A method of identifying a business-worker-oriented rules engine adaptor apparatus as claimed in claim 1, wherein: in the step 3, the rule design interface is customized according to actual business requirements.
7. A method of identifying a business-worker-oriented rules engine adaptor apparatus as claimed in claim 2, wherein: the specific method of the step 5 is as follows: and the data of the front-end rule design interface is transmitted to the client side SDK in a JSON format, and after the data is subjected to logic processing of converting JSON to DSL in the SDK, the rule data is finally transmitted to the rule engine server side in a DSL format through an RPC protocol to construct a rule model.
8. A method of identifying a business-worker-oriented rules engine adaptor apparatus as claimed in claim 3, wherein: the specific method of the step 6 is as follows: and converting the original data in the front-end JSON format into Java objects in the client SDK, and storing the Java objects in a relational database according to fields.
CN202110388683.2A 2021-04-12 2021-04-12 Business personnel-oriented rule engine adapter device identification method Active CN112799647B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110388683.2A CN112799647B (en) 2021-04-12 2021-04-12 Business personnel-oriented rule engine adapter device identification method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110388683.2A CN112799647B (en) 2021-04-12 2021-04-12 Business personnel-oriented rule engine adapter device identification method

Publications (2)

Publication Number Publication Date
CN112799647A true CN112799647A (en) 2021-05-14
CN112799647B CN112799647B (en) 2021-11-23

Family

ID=75816925

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110388683.2A Active CN112799647B (en) 2021-04-12 2021-04-12 Business personnel-oriented rule engine adapter device identification method

Country Status (1)

Country Link
CN (1) CN112799647B (en)

Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101470882A (en) * 2007-12-24 2009-07-01 阿里巴巴集团控股有限公司 Dynamic service regulation application method, system and apparatus
CN104020997A (en) * 2014-06-13 2014-09-03 中国民航信息网络股份有限公司 Extensible graphical rule application system
US20150293764A1 (en) * 2014-04-10 2015-10-15 Omprakash VISVANATHAN Method and system to compose and execute business rules
US20160070560A1 (en) * 2011-12-30 2016-03-10 Pegasystems Inc. System and method for updating or modifying an application without manual coding
CN106101090A (en) * 2016-06-07 2016-11-09 中国建设银行股份有限公司 Operational approach and rule engine system for regulation engine
CN106990967A (en) * 2017-04-05 2017-07-28 百融(北京)金融信息服务股份有限公司 The data processing method of regulation engine
US10033611B1 (en) * 2015-02-06 2018-07-24 HCA Holdings, Inc. Transaction lifecycle management
CN109144374A (en) * 2018-09-27 2019-01-04 范若愚 Method for processing business, system and relevant device based on visualization regulation engine
CN109783151A (en) * 2017-11-10 2019-05-21 北京京东尚科信息技术有限公司 The method and apparatus of rule change
CN110554894A (en) * 2018-05-31 2019-12-10 阿里巴巴集团控股有限公司 Interface description file, processing method and device of application program and electronic equipment
CN111698255A (en) * 2020-06-15 2020-09-22 南京领行科技股份有限公司 Service data transmission method, device and system
CN112559808A (en) * 2020-12-17 2021-03-26 北京百度网讯科技有限公司 Data processing method and device and electronic equipment

Patent Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101470882A (en) * 2007-12-24 2009-07-01 阿里巴巴集团控股有限公司 Dynamic service regulation application method, system and apparatus
US20160070560A1 (en) * 2011-12-30 2016-03-10 Pegasystems Inc. System and method for updating or modifying an application without manual coding
US20150293764A1 (en) * 2014-04-10 2015-10-15 Omprakash VISVANATHAN Method and system to compose and execute business rules
CN104020997A (en) * 2014-06-13 2014-09-03 中国民航信息网络股份有限公司 Extensible graphical rule application system
US10033611B1 (en) * 2015-02-06 2018-07-24 HCA Holdings, Inc. Transaction lifecycle management
CN106101090A (en) * 2016-06-07 2016-11-09 中国建设银行股份有限公司 Operational approach and rule engine system for regulation engine
CN106990967A (en) * 2017-04-05 2017-07-28 百融(北京)金融信息服务股份有限公司 The data processing method of regulation engine
CN109783151A (en) * 2017-11-10 2019-05-21 北京京东尚科信息技术有限公司 The method and apparatus of rule change
CN110554894A (en) * 2018-05-31 2019-12-10 阿里巴巴集团控股有限公司 Interface description file, processing method and device of application program and electronic equipment
CN109144374A (en) * 2018-09-27 2019-01-04 范若愚 Method for processing business, system and relevant device based on visualization regulation engine
CN111698255A (en) * 2020-06-15 2020-09-22 南京领行科技股份有限公司 Service data transmission method, device and system
CN112559808A (en) * 2020-12-17 2021-03-26 北京百度网讯科技有限公司 Data processing method and device and electronic equipment

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
AMER ALI: ""Schematron-based Semantic Constraints Specification Framework and Validation Rules Engine for JSON"", 《2019 SOUTHEASTCON》 *
朱会兵: ""基于Drools的信息管理与决策***的研究与实现"", 《中国优秀硕士学位论文全文数据库 信息科技辑》 *
王世春: ""面向银行信贷的规则引擎***设计与实现"", 《中国优秀硕士学位论文全文数据库 经济与管理科学辑》 *

Also Published As

Publication number Publication date
CN112799647B (en) 2021-11-23

Similar Documents

Publication Publication Date Title
CN108885545B (en) Tools and methods for real-time dataflow programming languages
US9324025B2 (en) Automating natural-language interactions between an expert system and a user
JP5689361B2 (en) Method, program, and system for converting a part of graph data into a data structure that is an image of a homomorphic map
CN109271403A (en) A kind of operating method of data query, device, medium and electronic equipment
CN113312113A (en) Dynamic configuration method, device, equipment and storage medium of business rule information
CN115509522A (en) Interface arranging method and system for low-code scene and electronic equipment
Ataei et al. NeoMycelia: A software reference architecturefor big data systems
Moin et al. Supporting AI engineering on the IoT edge through model-driven TinyML
CN112799647B (en) Business personnel-oriented rule engine adapter device identification method
CN115392443B (en) Pulse neural network application representation method and device of brain-like computer operating system
CN111596905A (en) Method, device, storage medium and terminal for generating java object
Paulheim et al. Mapping pragmatic class models to reference ontologies
CN110175917A (en) The device and method of parameterized graphicsization processing
CN114757124B (en) CFD workflow modeling method and device based on XML, computer and storage medium
Hallé et al. Model checking data-aware workflow properties with CTL-FO+
Ribarić et al. Model-Driven engineering of rules for web services
Yau et al. Specification, decomposition and agent synthesis for situation-aware service-based systems
Uifălean et al. From BPMN models to labelled property graphs
CN112363716A (en) Method, system and device for dynamically assembling evaluation model
Wang et al. Evaluating formalisms for modular ontologies in distributed information systems
US7606785B1 (en) Concurrent a-box and t-box generation for use in web ontology language (OWL) database and knowledge base construction
Subburaj et al. Intelligent agent software development using AUML and the Descartes specification language
US20230021412A1 (en) Techniques for implementing container-based software services
Shu et al. Investigating visualization ontologies
KR102406725B1 (en) Data Interoperability Method and Data Interoperability System

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
GR01 Patent grant
GR01 Patent grant