CN110826911B - Big data-based decision method, equipment and medium - Google Patents

Big data-based decision method, equipment and medium Download PDF

Info

Publication number
CN110826911B
CN110826911B CN201911076168.XA CN201911076168A CN110826911B CN 110826911 B CN110826911 B CN 110826911B CN 201911076168 A CN201911076168 A CN 201911076168A CN 110826911 B CN110826911 B CN 110826911B
Authority
CN
China
Prior art keywords
expression
decision
hierarchical
expressions
level
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
CN201911076168.XA
Other languages
Chinese (zh)
Other versions
CN110826911A (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.)
Nanjing Xinghuan Intelligent Technology Co ltd
Original Assignee
Nanjing Xinghuan Intelligent Technology 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 Nanjing Xinghuan Intelligent Technology Co ltd filed Critical Nanjing Xinghuan Intelligent Technology Co ltd
Priority to CN201911076168.XA priority Critical patent/CN110826911B/en
Publication of CN110826911A publication Critical patent/CN110826911A/en
Application granted granted Critical
Publication of CN110826911B publication Critical patent/CN110826911B/en
Priority to PCT/CN2020/120787 priority patent/WO2021088605A1/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
    • G06Q10/00Administration; Management
    • G06Q10/06Resources, workflows, human or project management; Enterprise or organisation planning; Enterprise or organisation modelling
    • G06Q10/063Operations research, analysis or management
    • G06Q10/0637Strategic management or analysis, e.g. setting a goal or target of an organisation; Planning actions based on goals; Analysis or evaluation of effectiveness of goals
    • G06Q10/06375Prediction of business process outcome or impact based on a proposed change
    • 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/245Query processing
    • G06F16/2458Special types of queries, e.g. statistical queries, fuzzy queries or distributed queries

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Human Resources & Organizations (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Educational Administration (AREA)
  • Economics (AREA)
  • Entrepreneurship & Innovation (AREA)
  • General Physics & Mathematics (AREA)
  • Strategic Management (AREA)
  • Tourism & Hospitality (AREA)
  • Probability & Statistics with Applications (AREA)
  • Operations Research (AREA)
  • Marketing (AREA)
  • General Business, Economics & Management (AREA)
  • Game Theory and Decision Science (AREA)
  • Development Economics (AREA)
  • Fuzzy Systems (AREA)
  • Mathematical Physics (AREA)
  • Quality & Reliability (AREA)
  • Software Systems (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The embodiment of the invention discloses a decision method, equipment and a medium based on big data. The method comprises the following steps: extracting a decision expression included in the big data decision request; the decision expression is decomposed step by step according to operation levels to obtain a plurality of level expressions respectively corresponding to the operation levels; determining decision contribution of each level expression according to historical decision result data matched with each level expression and decision attributes of logic operators of the level expressions connected with the same operation level; obtaining an adjusted expression according to the decision contribution degree; and according to the operation sequence of the adjusted expression, acquiring service data in real time, filling the service data into the corresponding sub-expression, and calculating to obtain a calculation result matched with the big data decision request. The embodiment of the invention can adjust the decision expression and optimize the execution sequence of the decision expression, thereby reducing the acquisition and calculation of service data and improving the decision efficiency.

Description

Big data-based decision method, equipment and medium
Technical Field
Embodiments of the present invention relate to decision execution technologies, and in particular, to a big data based decision method, device, and medium.
Background
In the fields of banks, securities, e-commerce, transportation and the like, complex decision logic is often available, that is, a combination of a plurality of logic expressions (decision expressions) is available. Also meaning queries involving a large number of business data. And the calculation and acquisition of the service data are the most time-consuming in the decision making process. The computation of the service data requires an additional Central Processing Unit (CPU). The acquisition process of the service data requires network or local Input/Output (I/O) interaction, which affects the delay of the decision.
In the decision execution process in the prior art, all service data of a decision expression are acquired first and then substituted into the decision expression to perform logic judgment, so that the execution result (decision result) of the decision expression is obtained. The function is to ensure the correctness of the execution result, but the service data which is decisive for the execution result of the decision expression may only occupy a small set of all the service data. Otherwise, the calculation and acquisition operations of invalid service data are meaningless operations, which wastes system resources and increases the delay of decision execution.
Disclosure of Invention
Embodiments of the present invention provide a big data-based decision method, device, and medium, so as to improve decision efficiency, reduce waste of system resources, and reduce delay in decision execution.
In a first aspect, an embodiment of the present invention provides a big data-based decision method, including:
when a big data decision request is detected, extracting a decision expression included in the big data decision request, wherein the decision expression comprises a plurality of sub expressions connected by a logic operator, the sub expressions comprise a plurality of service data to be filled and calculated, the service data are connected by a relational operator, the decision expression comprises at least one number-including group, and the bracket group is used for determining an operation level corresponding to the decision expression;
identifying bracket group insertion positions of the decision expressions, and decomposing the decision expressions step by step according to operation levels according to the bracket group insertion positions to obtain a plurality of level expressions respectively corresponding to the operation levels, wherein the level expressions comprise at least one sub-expression;
determining decision contribution of each level expression according to historical decision result data matched with each level expression and decision attributes of logic operators of the level expressions connected with the same operation level;
adjusting the positions of the expressions of each level in the decision expression according to the decision contribution degrees of the expressions of each level in the same operation level to obtain an adjusted expression;
and acquiring service data from the database in real time according to the operation sequence of the adjusted expression, filling the service data into the corresponding sub-expression, and calculating to obtain a calculation result matched with the big data decision request.
In a second aspect, embodiments of the present invention also provide a computer device, including a processor and a memory, the memory storing instructions that, when executed, cause the processor to:
when a big data decision request is detected, extracting a decision expression included in the big data decision request, wherein the decision expression comprises a plurality of sub expressions connected by a logic operator, the sub expressions comprise a plurality of service data to be filled and calculated, the service data are connected by a relational operator, the decision expression comprises at least one number-including group, and the bracket group is used for determining an operation level corresponding to the decision expression;
identifying bracket group insertion positions of the decision expressions, and decomposing the decision expressions step by step according to operation levels according to the bracket group insertion positions to obtain a plurality of level expressions respectively corresponding to the operation levels, wherein the level expressions comprise at least one sub-expression;
determining decision contribution of each level expression according to historical decision result data matched with each level expression and decision attributes of logic operators of the level expressions connected with the same operation level;
adjusting the positions of the expressions of each level in the decision expression according to the decision contribution degrees of the expressions of each level in the same operation level to obtain an adjusted expression;
and acquiring service data from the database in real time according to the operation sequence of the adjusted expression, filling the service data into the corresponding sub-expression, and calculating to obtain a calculation result matched with the big data decision request.
In a third aspect, an embodiment of the present invention further provides a storage medium, where the storage medium is configured to store instructions for performing:
when a big data decision request is detected, extracting a decision expression included in the big data decision request, wherein the decision expression comprises a plurality of sub expressions connected by a logic operator, the sub expressions comprise a plurality of service data to be filled and calculated, the service data are connected by a relational operator, the decision expression comprises at least one number-including group, and the bracket group is used for determining an operation level corresponding to the decision expression;
identifying bracket group insertion positions of the decision expressions, and decomposing the decision expressions step by step according to operation levels according to the bracket group insertion positions to obtain a plurality of level expressions respectively corresponding to the operation levels, wherein the level expressions comprise at least one sub-expression;
determining decision contribution of each level expression according to historical decision result data matched with each level expression and decision attributes of logic operators of the level expressions connected with the same operation level;
adjusting the positions of the expressions of each level in the decision expression according to the decision contribution degrees of the expressions of each level in the same operation level to obtain an adjusted expression;
and acquiring service data from the database in real time according to the operation sequence of the adjusted expression, filling the service data into the corresponding sub-expression, and calculating to obtain a calculation result matched with the big data decision request.
The technical scheme of the embodiment of the invention comprises the steps of decomposing a decision expression step by step according to operation levels to obtain a plurality of level expressions corresponding to the operation levels respectively, wherein the level expressions comprise at least one sub-expression, then determining the decision contribution degree of each level expression according to historical decision result data matched with each level expression and the decision attribute of a logic operator connecting the level expressions of the same operation level, adjusting the position of each level expression in the decision expression according to the decision contribution degree of each level expression in the same operation level to obtain an adjusted expression, acquiring service data from a database in real time according to the operation sequence of the adjusted expression, filling the service data into the corresponding sub-expression for calculation to obtain a calculation result matched with a big data decision request, and decomposing a complex decision expression step by step, and the decision contribution of each level is counted according to the historical decision result data, the positions of the expressions of each level in the decision expressions can be adjusted according to the sequence of the decision contribution of the expressions of each level from large to small, and the execution sequence of the decision expressions is optimized, so that the acquisition and calculation of service data are reduced, the decision efficiency is improved, the waste of system resources is reduced, and the delay of decision execution is reduced.
Drawings
Fig. 1a is a flowchart of a big data-based decision method according to an embodiment of the present invention;
FIG. 1b is a diagram illustrating a decision expression according to an embodiment of the present invention;
fig. 1c is a schematic diagram of a hierarchy after progressive decomposition of a decision expression according to an embodiment of the present invention;
FIG. 1d is a diagram of a contribution statistical table according to an embodiment of the present invention;
fig. 1e is a schematic diagram of an adjusted contribution degree statistical table according to an embodiment of the present invention;
FIG. 1f is a schematic diagram of a decision optimization scheme according to an embodiment of the present invention;
fig. 2 is a flowchart of a big data-based decision method according to a second embodiment of the present invention;
fig. 3 is a flowchart of a big data-based decision method according to a third embodiment of the present invention;
fig. 4 is a flowchart of a big data-based decision method according to a fourth embodiment of the present invention;
fig. 5 is a schematic structural diagram of a big data-based decision device according to a fifth embodiment of the present invention;
fig. 6 is a schematic structural diagram of a computer device according to a sixth embodiment of the present invention.
Detailed Description
The present invention will be described in further detail with reference to the accompanying drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the invention and are not limiting of the invention. It should be further noted that, for the convenience of description, only some of the structures related to the present invention are shown in the drawings, not all of the structures.
Before discussing exemplary embodiments in more detail, it should be noted that some exemplary embodiments are described as processes or methods depicted as flowcharts. Although a flowchart may describe the operations (or steps) as a sequential process, many of the operations can be performed in parallel, concurrently or simultaneously. In addition, the order of the operations may be re-arranged. The process may be terminated when its operations are completed, but may have additional steps not included in the figure. The processes may correspond to methods, functions, procedures, subroutines, and the like.
The term "big data decision request" as used herein is an operation request for requesting to substitute service data into a decision expression for logic judgment to obtain a calculation result of the decision expression. The big data decision request comprises a decision expression.
The term "business data" as used herein is data that is computationally processed according to a particular business rule based on historical user behavior data. Such as: the amount of the user's transaction on the day; the user's IP addresses of the three most common logins in the last month. The business data is stored in a database.
The term "decision expression" as used herein is a combination of 1 or more logic expressions (e.g., transaction number of the day > -3), i.e., a logic expression of a complex combination. Such as: and (the IP of the user login is not in the IP list of the first three of the historical common logins) and (the operation time of the user is in a sensitive time period), if the matching is carried out, the user behavior is determined to be risky, and if the matching is not matched, no risk exists. The decision expression comprises a plurality of sub-expressions connected by logical operators, the sub-expressions comprise a plurality of service data to be filled and calculated and connected by relational operators, the decision expression comprises at least one number-including group, and the bracket group is used for determining the operation level corresponding to the decision expression.
The term "bracketed group insertion location" as used herein is the location of each bracketed group in the decision expression.
The term "operation hierarchy" as used herein is a priority of operations.
The term "hierarchical expression" as used herein is a sub-expression that is decomposed into corresponding operation levels.
The term "historical decision result data" as used herein is data related to the computed results that match each big data decision request entered by the user, including the result values corresponding to the decision expressions in each big data decision request. The result value is a calculation result value obtained by substituting the service data into the expression for calculation. The resulting value is true or false.
The term "decision attribute" as used herein is a logical decision rule corresponding to a logical operator. The logical operators include: and logical operators and or logical operators. The decision attribute corresponding to the logical operator is false logic. If the false logic is true and one operand is false, the logical expression reaches an end condition. The decision attribute corresponding to the OR logic operator is true logic. If true logic is true and one operand is true, then the logical expression reaches an end condition.
The term "decision contribution" as used herein is the quantitative value of the target decision result data for which the result value matches the decision attribute of the logical operator of the hierarchical expression, of the target decision result data corresponding to each hierarchical expression.
The term "hierarchy operator" as used herein is a logical operator included in each operation hierarchy.
The term "decision" used herein is to substitute the service data into a decision expression, and execute the result to obtain a decision result (match/mismatch). The term "decision system" as used herein is a system that configures decision expressions, runs decisions.
For ease of understanding, the main inventive concepts of the embodiments of the present invention are briefly described.
In the decision execution process in the prior art, all service data of a decision expression are acquired first and then substituted into the decision expression to perform logic judgment, so that the execution result (decision result) of the decision expression is obtained.
In the prior art, all service data of a decision expression are acquired first and then substituted into the decision expression for logic judgment, so that the correctness of an execution result can be ensured functionally, but the service data which plays a role in determining the execution result of the decision expression may only occupy a small set of all the service data. Otherwise, the calculation and acquisition operations of invalid service data are meaningless operations, which wastes system resources and increases the delay of decision execution. The execution of the decision expression is a variable process, i.e. different results are obtained by substituting different service data.
One simple optimization is: and after all the service data are obtained, substituting the service data into the fixed order (such as from left to right or from right to left) of the decision expression for execution, and when an ending condition is met, terminating the execution of a subsequent expression. This approach can be improved somewhat, but only marginally (since the query and acquisition of the traffic data is the most performance-consuming factor in the decision).
The inventor considers whether the execution of the next decision can be predicted by a method or not, acquires the service data as less as possible, substitutes a decision expression to avoid unnecessary performance expense and quickly decides response aiming at the problems that the calculation and the acquisition operation of invalid service data cause system resource waste and increase the delay of decision execution in the prior art.
Based on the above thought, the inventor creatively proposes that the decision expression included in the big data decision request is extracted, the decision expression is decomposed step by step according to the operation levels to obtain a plurality of level expressions respectively corresponding to the operation levels, the level expressions include at least one sub-expression, then determining the decision contribution degree of each level expression according to the historical decision result data matched with each level expression and the decision attribute of the logic operator of the level expression connected with the same operation level, and adjusting the positions of the expressions in each level in the decision expression according to the decision contribution of the expressions in each level in the same operation level to obtain an adjusted expression, and acquiring service data from the database in real time according to the operation sequence of the adjusted expression, filling the service data into the corresponding sub-expression, and calculating to obtain a calculation result matched with the big data decision request. The method has the advantages that the complex decision expressions are decomposed step by step, the decision contribution degree of each level is counted according to the historical decision result data, then the positions of the various level expressions in the decision expressions are adjusted according to the sequence from large to small of the decision contribution degree of the various level expressions, the execution sequence of the decision expressions is optimized, accordingly, the acquisition and calculation of business data are reduced, the decision efficiency is improved, and the execution of the decision is optimized to the maximum extent.
Example one
Fig. 1a is a flowchart of a big data-based decision method according to an embodiment of the present invention. The embodiment of the present invention is applicable to the case of optimizing decision execution, and the method can be executed by a big data-based decision device provided by the embodiment of the present invention, and the device can be implemented in a software and/or hardware manner, and can be generally integrated in a computer device. As shown in fig. 1a, the method of the embodiment of the present invention specifically includes:
step 101, when a big data decision request is detected, extracting a decision expression included in the big data decision request.
The decision expression comprises a plurality of sub-expressions connected by a logic operator, the sub-expressions comprise a plurality of service data to be filled and calculated and connected by a relational operator, the decision expression comprises at least one number-including group, and the bracket group is used for determining an operation level corresponding to the decision expression.
The big data decision request comprises a decision expression. And the big data decision request is used for requesting to substitute the service data into the decision expression for logic judgment so as to obtain a calculation result of the decision expression. And when the big data decision request is detected, extracting a decision expression included in the big data decision request. The decision expression is a combination of 1 or more logic expressions (for example, the number of transactions on the day > is 3), that is, a logic expression of a complex combination. The decision expression comprises a plurality of sub-expressions joined by logical operators, the sub-expressions comprising a plurality of business data to be populated computations joined by relational operators. The logical operators include: and logical operators and or logical operators.
Fig. 1b is a schematic diagram of a decision expression according to an embodiment of the present invention. Fig. 1b shows a complex combinational logic expression, i.e. a decision expression. The decision expression is: (con1and con2 and con3) and (con4or con5 or con6) or ((con7and con8) and (con9or con 10)). The decision expression contains a complex nesting of brackets, complex combinations with the logical operator "and" or "logical operator". The sub-expressions con1, con2, etc. include a plurality of business data to be populated into computations connected by relational operators. con1 includes business data A and business data B to be populated computed connected by the relational operator ">". con1 includes traffic data C, traffic data D, and traffic data E to be filled with computations connected by relational operators "<".
And 102, identifying bracket group insertion positions of the decision expressions, and decomposing the decision expressions step by step according to the bracket group insertion positions according to operation levels to obtain a plurality of level expressions respectively corresponding to the operation levels, wherein the level expressions comprise at least one sub-expression.
And identifying the bracket group insertion position of the decision expression, and decomposing the decision expression step by step according to the bracket group insertion position, wherein the decision expression is decomposed step by step and is decomposed step by step. The hierarchical expression of each level can be restored into the hierarchical expression of the upper level through the combination of the logical operators (the logical operator "and" or ") and the logical operator" or ".
Fig. 1c is a schematic diagram of a hierarchy after splitting a decision expression according to an embodiment of the present invention. Taking the decision expression of fig. 1a as an example, the hierarchy after splitting is shown in fig. 1 c.
Optionally, the step-by-step decomposition of the decision expression according to the bracket group insertion position according to the operation levels is performed to obtain a plurality of level expressions corresponding to the plurality of operation levels, and the step-by-step decomposition may include: acquiring a hierarchy operator from the logic operator according to an operation hierarchy determined by the bracket group insertion position of the decision expression, and obtaining a plurality of hierarchy expressions corresponding to a plurality of operation hierarchies respectively according to the hierarchy operator; and restoring the combination of the hierarchical expressions of all the subsequent operation levels corresponding to the hierarchical expression of the previous operation level to obtain the hierarchical expression of the previous operation level.
Optionally, obtaining a hierarchy operator from the logical operator according to an operation level determined by the bracket group insertion position of the decision expression, and obtaining a plurality of hierarchy expressions corresponding to the plurality of operation levels according to the hierarchy operator, may include: acquiring a current processing expression in a current processing expression set, wherein an initial value of the current processing expression set is a decision expression; judging whether a logic operator is included in the current processing expression; if yes, acquiring a highest level operational character matched with the processing expression in each logic operator according to the bracket insertion position of the current processing expression; decomposing the current processing expression into a plurality of hierarchical expressions of a next operation level which take the current processing expression as a hierarchical expression of a previous operation level according to the position of the operator of the highest level in the current processing expression, and adding all the hierarchical expressions of the next operation level into the current processing expression set; otherwise, determining to finish the processing of the current processing expression; and returning to execute the operation of acquiring one current processing expression in the current processing expression set until the processing of all the current processing expressions in the current processing expression set is completed.
And 103, determining the decision contribution degree of each hierarchical expression according to the historical decision result data matched with each hierarchical expression and the decision attribute of the logic operator of the hierarchical expression connected with the same operation level.
According to historical decision result data matched with each level expression and decision attributes of logic operators of the level expressions connected with the same operation level, carrying out contribution degree statistics on each level expression, and determining the decision contribution degree of each level expression.
Obtaining a set amount of historical decision result data matched with the decision expressions, traversing each level expression from low level to up according to the sequence of operation levels, screening target decision result data corresponding to each level expression, wherein the target decision result data comprises at least two result values, and then obtaining the amount value of the target decision result data matched with the decision attributes according to the decision attributes of the logic operational characters connected with the level expressions, wherein the amount value is used as the decision contribution degree corresponding to the level expressions.
Optionally, determining the decision contribution of each hierarchical expression according to the historical decision result data matched with each hierarchical expression and the decision attribute of the logic operator of the hierarchical expression connected to the same operation level may include: obtaining historical decision result data of a set number matched with the decision expression; sequentially acquiring a plurality of hierarchical expressions of a next operation level belonging to the same hierarchical expression of a previous operation level according to the sequence of the operation levels; screening target decision result data corresponding to the hierarchical expression of each next operation level in the historical decision result data, wherein the target decision result data comprise at least two result values; acquiring a quantity value of target decision result data of which the result value is matched with the decision attribute according to the decision attribute of the logic operator of the hierarchical expression connecting a plurality of subsequent operation levels, wherein the quantity value is used as a decision contribution degree corresponding to the hierarchical expression of each subsequent operation level; and returning to execute the operation of sequentially acquiring the hierarchical expressions of a plurality of next operation levels belonging to the hierarchical expression of the same previous operation level according to the sequence of the operation levels until the processing of all the hierarchical expressions is completed.
Optionally, the logical operators include: and logical operators and or logical operators; the decision attribute corresponding to the logical operator is false logic and the decision attribute corresponding to the or logical operator is true logic.
For the hierarchical expressions on both sides of the AND logical operator (and), if the result value is false (false), the contribution +1 is given. Namely, the quantity value of the target decision result data with the result value being false is obtained and is used as the decision contribution degree corresponding to the hierarchical expression.
Hierarchical expressions for both sides of an OR logical operator (or): if the decision result is true (true), the contribution degree is + 1. Namely, the quantitative value of the target decision result data with the result value being true is obtained and is used as the decision contribution degree corresponding to the hierarchical expression.
Optionally, obtaining the historical decision result data of the set number of matching decision expressions may include: and acquiring a set amount of historical decision result data matched with the user attributes according to the user attributes of the decision expression.
Fig. 1d is a schematic diagram of a contribution statistical table according to an embodiment of the present invention. Taking the decision expression shown in fig. 1a as an example, after performing stepwise decomposition to obtain a plurality of hierarchical expressions shown in fig. 1c, determining the decision contribution of each hierarchical expression according to 200 historical decision result data, and obtaining a contribution statistical table shown in fig. 1 d.
And step 104, adjusting the positions of the expressions in each level in the decision expression according to the decision contribution degrees of the expressions in each level in the same operation level to obtain an adjusted expression.
And according to the operation level, traversing from the lower level to the upper level, and adjusting the level expression with the large contribution degree to the front of the decision expression, namely to the position where the decision expression is executed preferentially. Expressions on both sides of the logical operator can only change position and cannot be replaced by other expressions.
Optionally, the adjusting the position of each level expression in the decision expression according to the decision contribution of each level expression in the same operation level to obtain an adjusted expression may include: sequentially acquiring a plurality of hierarchical expressions of a next operation level belonging to the same hierarchical expression of a previous operation level according to the sequence of the operation levels; adjusting the sequence of the hierarchical expressions of the plurality of next operation levels in the hierarchical expression of the previous operation level according to the sequence of the decision contribution degrees of the hierarchical expressions of the plurality of next operation levels from large to small; and returning to execute the operation of sequentially acquiring the hierarchical expressions of a plurality of next operation levels belonging to the hierarchical expression of the same previous operation level according to the sequence of the operation levels until the adjustment of the decision expression is completed to obtain the adjusted expression.
Optionally, adjusting the order of the hierarchical expressions of the multiple subsequent operation levels in the hierarchical expression of the previous operation level according to the order of the decision contribution degrees of the hierarchical expressions of the multiple subsequent operation levels from large to small may include: and adjusting the sequence of the hierarchical expressions of the plurality of subsequent operation levels in the hierarchical expression of the previous operation level according to the sequence from large to small of the decision contribution degrees of the hierarchical expressions of the plurality of subsequent operation levels and the type of the logic operator connecting the hierarchical expressions of the plurality of subsequent operation levels.
Fig. 1e is a schematic diagram of an adjusted contribution degree statistical table according to an embodiment of the present invention. According to the decision contribution degree in the contribution degree statistical table shown in fig. 1d, the positions of the expressions of each hierarchy in the decision expression shown in fig. 1a are adjusted, so as to obtain the adjusted contribution degree statistical table shown in fig. 1e and the adjusted expression. The expression after adjustment is: ((con8 and con7) and (con9or con10)) or (con5 or con4or con6) and (con1and con3and con 2).
And 105, acquiring service data from the database in real time according to the operation sequence of the adjusted expression, filling the service data into the corresponding sub-expression, and calculating to obtain a calculation result matched with the big data decision request.
In a specific embodiment, according to the operation sequence of the adjusted expression, obtaining the service data from the database in real time, and filling the service data in the corresponding sub-expression for calculation to obtain a calculation result matched with the big data decision request, which may include: and acquiring service data from the database in real time in a single-thread mode according to the operation sequence of the adjusted expression, filling the service data into the corresponding sub-expression, and calculating until a calculation ending condition is met so as to obtain a calculation result matched with the big data decision request.
And acquiring service data from the database in real time according to the operation sequence of the adjusted expression from left to right in a single-thread mode in sequence, filling the service data into the corresponding sub-expressions for calculation until a calculation ending condition is met, and obtaining a calculation result matched with the big data decision request. Therefore, a simple serial rule is adopted for calculation, and a calculation result matched with the big data decision request is obtained.
In another embodiment, according to the operation sequence of the adjusted expression, acquiring the service data from the database in real time, and filling the service data in the corresponding sub-expression for calculation to obtain a calculation result matched with the big data decision request, which may include: and acquiring a plurality of hierarchical expressions belonging to the same operation level according to the operation sequence of the adjusted expressions, establishing a plurality of threads matched with the hierarchical expressions, acquiring service data from a database in real time in a multithread parallel processing mode, filling the service data into corresponding sub-expressions for calculation until a calculation ending condition is met, and obtaining a calculation result matched with the big data decision request.
According to the operation level, traversing from the level height to the bottom, acquiring a plurality of level expressions belonging to the same operation level, establishing a plurality of threads matched with the level expressions, acquiring service data from a database in real time in a multithreading parallel processing mode, filling the service data into corresponding sub-expressions, and calculating until a calculation ending condition is met so as to obtain a calculation result matched with a big data decision request. Therefore, a complex parallel rule is adopted for calculation, and a calculation result matched with the big data decision request is obtained.
Fig. 1f is a schematic diagram of a decision optimization scheme according to an embodiment of the present invention. As shown in fig. 1f, the decision optimization scheme specifically includes:
step 1, splitting the decision expression and dividing the hierarchy.
And 2, carrying out contribution statistics on each level expression according to historical decision result data matched with each level expression and decision attributes of logic operators of the level expressions connected with the same operation level.
And 3, traversing from the lower level to the upper level according to the operation level, and adjusting the level expression with the large contribution degree to the front of the decision expression, namely, to the position where the decision expression is preferentially executed.
And 4, acquiring service data in real time according to the operation sequence of the adjusted expression, filling the service data into the corresponding sub-expression, and calculating to obtain a calculation result matched with the adjusted expression.
The behavior of the user is usually regular. The contribution degree counted based on the historical decision result data can represent the behavior of the user under most conditions. Therefore, in most cases, the adjusted expression obtained by the big data-based decision method provided by the embodiment of the invention can be finished by only executing a small part of logic expression judgment logic. The query and the acquisition of unnecessary business data are reduced, and the execution of meaningless expressions is reduced.
The embodiment of the invention provides a decision method based on big data, which comprises the steps of decomposing a decision expression step by step according to operation levels to obtain a plurality of level expressions corresponding to the operation levels respectively, wherein the level expressions comprise at least one sub-expression, then determining the decision contribution degree of each level expression according to historical decision result data matched with each level expression and the decision attribute of a logic operator of the level expression connected with the same operation level, adjusting the position of each level expression in the decision expression according to the decision contribution degree of each level expression in the same operation level to obtain an adjusted expression, acquiring service data from a database in real time according to the operation sequence of the adjusted expression to be filled in the corresponding sub-expression for calculation so as to obtain a calculation result matched with a big data decision request, the complex decision expressions can be decomposed step by step, the decision contribution degree of each level can be counted according to historical decision result data, the positions of the level expressions in the decision expressions can be adjusted according to the sequence from large to small of the decision contribution degree of the level expressions, and the execution sequence of the decision expressions is optimized, so that the acquisition and calculation of service data are reduced, the decision efficiency is improved, the waste of system resources is reduced, and the delay of decision execution is reduced.
Example two
Fig. 2 is a flowchart of a big data-based decision method according to a second embodiment of the present invention. In this embodiment of the present invention, the step-by-step decomposition of the decision expression according to the operation levels according to the bracket group insertion position may be performed to obtain a plurality of level expressions corresponding to the plurality of operation levels, where the step-by-step decomposition may include: acquiring a hierarchy operator from the logic operator according to an operation hierarchy determined by the bracket group insertion position of the decision expression, and obtaining a plurality of hierarchy expressions corresponding to a plurality of operation hierarchies respectively according to the hierarchy operator; and restoring the combination of the hierarchical expressions of all the subsequent operation levels corresponding to the hierarchical expression of the previous operation level to obtain the hierarchical expression of the previous operation level.
As shown in fig. 2, the method of the embodiment of the present invention specifically includes:
step 201, when a big data decision request is detected, extracting a decision expression included in the big data decision request.
The decision expression comprises a plurality of sub-expressions connected by a logic operator, the sub-expressions comprise a plurality of service data to be filled and calculated and connected by a relational operator, the decision expression comprises at least one number-including group, and the bracket group is used for determining an operation level corresponding to the decision expression.
Step 202, according to the operation level determined by the bracket group insertion position of the decision expression, obtaining a level operator from the logic operator, and according to the level operator, obtaining a plurality of level expressions corresponding to the plurality of operation levels respectively.
And restoring the combination of the hierarchical expressions of all the subsequent operation levels corresponding to the hierarchical expression of the previous operation level to obtain the hierarchical expression of the previous operation level.
The operation level is the priority of the operation. As described in fig. 1c, for a decision expression: (con1and con2 and dcon3) and (con4or con5 or con6) or ((con7and con8) and (con9or con10)), the operation level is determined according to the bracket group insertion position of the decision expression. The operation level is divided into a first level, a second level and a third level from high to low. The hierarchical operator is obtained among the logical operators according to the operation hierarchy.
Hierarchical operators for a level include: "and" between sub-expressions (con1and con2 and con3) and (con4orcon5 or con6) "and" or "between sub-expressions (con4or con5 or con6) and ((con7and con8) and (con9or con 10)).
Hierarchical operators of the second level include: "and" between sub-expression con1and sub-expression con2, "and" between sub-expression con2 and sub-expression con3, "or" between sub-expression con4 and sub-expression con5, "or" between sub-expression con5 and sub-expression con6, "and" between sub-expressions (con7and con8) and (con9or con 10).
Hierarchical operators of three levels include: "and" between sub-expression con7and sub-expression con8, "or" between sub-expression con9 and sub-expression con 10.
Obtaining a first-level hierarchy expression corresponding to a first-level operation hierarchy according to a first-level hierarchy operator: (con1 andcon2 and con3), (con4or con5 or con6), (con7and con8) and (con9or con 10)).
And obtaining a secondary level expression corresponding to the secondary operation level according to the secondary level operator. A secondary level expression corresponding to a primary level expression (con1and con2 and con 3): con1, con2, con 3; a secondary level expression corresponding to the primary level expression (con4or con5 or con 6): con4, con5, con 6; a secondary hierarchical expression corresponding to the primary hierarchical expressions ((con7and con8) and (con9or con 10)): (con7 andcon8), (con9or con 10).
And obtaining a three-level hierarchy expression corresponding to the three-level operation hierarchy according to the three-level hierarchy operator. A three-level hierarchical expression corresponding to the two-level hierarchical expressions (con7and con 8): con7, con 8; a three-level hierarchical expression corresponding to the two-level hierarchical expression (con9or con 10): con9, con 10.
Optionally, obtaining a hierarchy operator from the logical operator according to an operation level determined by the bracket group insertion position of the decision expression, and obtaining a plurality of hierarchy expressions corresponding to the plurality of operation levels according to the hierarchy operator, may include: acquiring a current processing expression in a current processing expression set, wherein an initial value of the current processing expression set is a decision expression; judging whether a logic operator is included in the current processing expression; if yes, acquiring a highest level operational character matched with the processing expression in each logic operator according to the bracket insertion position of the current processing expression; decomposing the current processing expression into a plurality of hierarchical expressions of a next operation level which take the current processing expression as a hierarchical expression of a previous operation level according to the position of the operator of the highest level in the current processing expression, and adding all the hierarchical expressions of the next operation level into the current processing expression set; otherwise, determining to finish the processing of the current processing expression; and returning to execute the operation of acquiring one current processing expression in the current processing expression set until the processing of all the current processing expressions in the current processing expression set is completed.
And step 203, determining the decision contribution degree of each level expression according to the historical decision result data matched with each level expression and the decision attribute of the logic operator of the level expression connected with the same operation level.
And 204, adjusting the positions of the expressions in each level in the decision expression according to the decision contribution degrees of the expressions in each level in the same operation level to obtain an adjusted expression.
And step 205, acquiring service data from the database in real time according to the operation sequence of the adjusted expression, filling the service data into the corresponding sub-expression, and calculating to obtain a calculation result matched with the big data decision request.
The embodiment of the invention provides a big data-based decision method, which is characterized in that a hierarchy operator is obtained from a logic operator according to an operation hierarchy determined by a bracket group insertion position of a decision expression, a plurality of hierarchy expressions respectively corresponding to a plurality of operation hierarchies are obtained according to the hierarchy operator, and a complex decision expression can be decomposed step by step.
EXAMPLE III
Fig. 3 is a flowchart of a big data-based decision method according to a third embodiment of the present invention. In this embodiment of the present invention, determining the decision contribution of each hierarchical expression according to the historical decision result data matched with each hierarchical expression and the decision attribute of the logical operator of the hierarchical expression connected to the same operation level may include: obtaining historical decision result data of a set number matched with the decision expression; sequentially acquiring a plurality of hierarchical expressions of a next operation level belonging to the same hierarchical expression of a previous operation level according to the sequence of the operation levels; screening target decision result data corresponding to the hierarchical expression of each next operation level in the historical decision result data, wherein the target decision result data comprise at least two result values; acquiring a quantity value of target decision result data of which the result value is matched with the decision attribute according to the decision attribute of the logic operator of the hierarchical expression connecting a plurality of subsequent operation levels, wherein the quantity value is used as a decision contribution degree corresponding to the hierarchical expression of each subsequent operation level; and returning to execute the operation of sequentially acquiring the hierarchical expressions of a plurality of next operation levels belonging to the hierarchical expression of the same previous operation level according to the sequence of the operation levels until the processing of all the hierarchical expressions is completed.
As shown in fig. 3, the method of the embodiment of the present invention specifically includes:
step 301, when a big data decision request is detected, extracting a decision expression included in the big data decision request.
The decision expression comprises a plurality of sub-expressions connected by a logic operator, the sub-expressions comprise a plurality of service data to be filled and calculated and connected by a relational operator, the decision expression comprises at least one number-including group, and the bracket group is used for determining an operation level corresponding to the decision expression.
Optionally, the logical operators include: and logical operators and or logical operators.
Step 302, identifying the bracket group insertion position of the decision expression, and decomposing the decision expression step by step according to the bracket group insertion position according to the operation levels to obtain a plurality of level expressions corresponding to the operation levels respectively, wherein the level expressions comprise at least one sub-expression.
And step 303, obtaining historical decision result data of a set number matched with the decision expressions.
Optionally, obtaining the historical decision result data of the set number of matching decision expressions may include: and acquiring a set amount of historical decision result data matched with the user attributes according to the user attributes of the decision expression.
And presetting the user attribute of the decision expression. And identifying the users corresponding to the decision expression and the historical decision result data through the user attributes. Therefore, historical decision result data of the same user can be obtained according to the user attributes of the decision expression.
And step 304, sequentially acquiring a plurality of hierarchical expressions of a next operation level belonging to the same hierarchical expression of a previous operation level according to the sequence of the operation levels.
Step 305, screening target decision result data corresponding to the hierarchical expression of each subsequent operation level in the historical decision result data, wherein the target decision result data comprises at least two result values.
Where the result value is true or false.
Step 306, according to the decision attributes of the logical operators connecting the hierarchical expressions of a plurality of subsequent operation levels, obtaining the quantity value of the target decision result data with the result value matched with the decision attributes as the decision contribution degree corresponding to the hierarchical expression of each subsequent operation level.
Wherein the decision attribute corresponding to the logical operator is false logic and the decision attribute corresponding to the or logical operator is true logic.
For the hierarchical expressions on both sides of the AND logical operator (and), if the result value is false (false), the contribution +1 is given. Namely, the quantity value of the target decision result data with the result value being false is obtained and is used as the decision contribution degree corresponding to the hierarchical expression.
Hierarchical expressions for both sides of an OR logical operator (or): if the decision result is true (true), the contribution degree is + 1. Namely, the quantitative value of the target decision result data with the result value being true is obtained and is used as the decision contribution degree corresponding to the hierarchical expression.
And 307, returning to execute the operation of sequentially obtaining the hierarchical expressions of a plurality of next operation levels belonging to the hierarchical expression of the same previous operation level according to the sequence of the operation levels until the processing of all the hierarchical expressions is completed.
And finishing the processing of all the hierarchical expressions and determining the decision contribution degree of each hierarchical expression.
As shown in fig. 1d, the contribution degree statistical table has the contribution degree of each level expression, i.e. the decision contribution degree of each level expression. The contribution degree of the first-level expression (con1and con2 and con3) is 59, that is, the quantitative value of the target decision result data of which the result value corresponding to the first-level expression (con1and con2 and con3) is true is 59.
And 308, adjusting the positions of the expressions in each level in the decision expression according to the decision contribution degrees of the expressions in each level in the same operation level to obtain an adjusted expression.
Step 309, according to the operation sequence of the adjusted expression, acquiring the service data from the database in real time, and filling the service data into the corresponding sub-expression for calculation so as to obtain a calculation result matched with the big data decision request.
The embodiment of the invention provides a big data-based decision method, which comprises the steps of sequentially obtaining a plurality of next operation level hierarchical expressions of the hierarchical expression belonging to the same previous operation level according to the sequence of operation levels, then screening target decision result data corresponding to the hierarchical expression of each next operation level in historical decision result data, wherein the target decision result data comprise at least two result values, obtaining a quantitative value of the target decision result data with the result value matched with the decision attribute according to the decision attribute of a logic operator connecting the hierarchical expressions of the plurality of next operation levels, using the quantitative value as the decision contribution degree corresponding to the hierarchical expression of each next operation level, and counting the decision contribution degree of each level according to the historical decision result data.
Example four
Fig. 4 is a flowchart of a big data-based decision method according to a fourth embodiment of the present invention. In this embodiment of the present invention, the adjusting the position of each hierarchical expression in the decision expression according to the decision contribution of each hierarchical expression in the same operation level to obtain an adjusted expression may include: sequentially acquiring a plurality of hierarchical expressions of a next operation level belonging to the same hierarchical expression of a previous operation level according to the sequence of the operation levels; adjusting the sequence of the hierarchical expressions of the plurality of next operation levels in the hierarchical expression of the previous operation level according to the sequence of the decision contribution degrees of the hierarchical expressions of the plurality of next operation levels from large to small; and returning to execute the operation of sequentially acquiring the hierarchical expressions of a plurality of next operation levels belonging to the hierarchical expression of the same previous operation level according to the sequence of the operation levels until the adjustment of the decision expression is completed to obtain the adjusted expression.
As shown in fig. 4, the method of the embodiment of the present invention specifically includes:
step 401, when a big data decision request is detected, extracting a decision expression included in the big data decision request.
The decision expression comprises a plurality of sub-expressions connected by a logic operator, the sub-expressions comprise a plurality of service data to be filled and calculated and connected by a relational operator, the decision expression comprises at least one number-including group, and the bracket group is used for determining an operation level corresponding to the decision expression.
Step 402, identifying bracket group insertion positions of the decision expressions, and decomposing the decision expressions step by step according to the bracket group insertion positions according to operation levels to obtain a plurality of level expressions respectively corresponding to the operation levels, wherein the level expressions comprise at least one sub-expression.
And step 403, determining decision contribution of each hierarchical expression according to the historical decision result data matched with each hierarchical expression and the decision attribute of the logic operator of the hierarchical expression connected with the same operation level.
And step 404, sequentially acquiring a plurality of hierarchical expressions of a next operation level of the hierarchical expressions belonging to the same previous operation level according to the sequence of the operation levels.
Optionally, the hierarchical expressions of a plurality of next operation levels belonging to the hierarchical expression of the same previous operation level are sequentially obtained from high to low according to the operation levels.
And 405, adjusting the sequence of the hierarchical expressions of the plurality of next operation levels in the hierarchical expression of the previous operation level according to the sequence of the decision contribution degrees of the hierarchical expressions of the plurality of next operation levels from large to small.
Optionally, adjusting the order of the hierarchical expressions of the multiple subsequent operation levels in the hierarchical expression of the previous operation level according to the order of the decision contribution degrees of the hierarchical expressions of the multiple subsequent operation levels from large to small may include: and adjusting the sequence of the hierarchical expressions of the plurality of subsequent operation levels in the hierarchical expression of the previous operation level according to the sequence from large to small of the decision contribution degrees of the hierarchical expressions of the plurality of subsequent operation levels and the type of the logic operator connecting the hierarchical expressions of the plurality of subsequent operation levels.
The decision expression of fig. 1a is adjusted according to the decision contribution degree in the contribution degree statistical table shown in fig. 1d, so as to obtain the adjusted contribution degree statistical table shown in fig. 1e and the adjusted expression.
And adjusting the sequence of the hierarchical expressions of the plurality of subsequent operation levels in the hierarchical expression of the previous operation level according to the sequence from large to small of the decision contribution degrees of the hierarchical expressions of the plurality of subsequent operation levels and the type of the logic operator connecting the hierarchical expressions of the plurality of subsequent operation levels.
The decision expression is adjusted to be, according to the order of decision contributions of the level-one hierarchical expressions (con1and con2 and con3), (con4or con5 or con6), (con7and con8) and (con9or con10)) from large to small, and the logical operator "and" of the hierarchical expression connecting (con1and con2 and con3) and (con4or con5 or con6), and the logical operator "or" of the hierarchical expression connecting (con4or con5 or con6) and ((con7and con8) and (con9or con 10): ((con7and con8) and (con9or con10)) or (con4orcon5 or con6) and (con1and con2 and con 3).
According to a secondary level expression corresponding to a primary level expression (con1and con2 and con 3): the decision contributions of con1, con2 and con3 are in descending order, and the logical operator "and" connecting the hierarchical expressions of con1, con2 and con3, interchanging the positions of con2 and con3, so as to obtain the adjusted first-level hierarchical expression (con1and con3and con 2).
According to the secondary level expression corresponding to the primary level expression (con4or con5 or con 6): the decision contributions of con4, con5 and con6 are in the order from large to small, and the logical operator "or" connecting the hierarchical expressions of con4, con5 and con6 is used to interchange the positions of con4 and con5, so as to obtain an adjusted first-level hierarchical expression (con5 or con4orcon 6).
According to the three-level hierarchical expression corresponding to the two-level hierarchical expressions (con7and con 8): the decision contributions of con7and con8 are in descending order, and the logical operator "and" connecting "the hierarchical expressions of con7and con8 adjusts the order of con7and con8 in the secondary hierarchical expression (con7and con8), and positions of con7and con8 are exchanged, so that con8 is adjusted to the front of the secondary hierarchical expression (con7and con8), and the adjusted secondary hierarchical expression (con8 and con7) is obtained.
After the above adjustment is completed, an adjusted expression is obtained: ((con8 and con7) and (con9or con10)) or (con5 or con4or con6) and (con1and con3and con 2).
And step 406, returning to execute the operation of sequentially obtaining the hierarchical expressions of a plurality of next operation levels belonging to the hierarchical expression of the same previous operation level according to the sequence of the operation levels until the adjustment of the decision expression is completed to obtain the adjusted expression.
And 407, acquiring service data from the database in real time according to the operation sequence of the adjusted expression, and filling the service data into the corresponding sub-expression for calculation to obtain a calculation result matched with the big data decision request.
The embodiment of the invention provides a big data-based decision method, which comprises the steps of sequentially obtaining a plurality of next operation level hierarchical expressions of the hierarchical expression belonging to the same previous operation level according to the sequence of operation levels, and then adjusting the sequence of the plurality of next operation level hierarchical expressions in the previous operation level hierarchical expression according to the sequence of decision contribution degrees of the plurality of next operation level hierarchical expressions from large to small, so that the decision expression can be adjusted according to the decision contribution degree of each hierarchical expression, the execution sequence of the decision expression is optimized, the acquisition and calculation of service data are reduced, the decision efficiency is improved, the waste of system resources is reduced, and the delay of decision execution is reduced.
EXAMPLE five
Fig. 5 is a schematic structural diagram of a big data-based decision device according to a fifth embodiment of the present invention. The apparatus may be implemented in software and/or hardware and may generally be integrated in a computer device. As shown in fig. 5, the apparatus includes: an expression extraction module 501, an expression decomposition module 502, a contribution degree determination module 503, an expression adjustment module 504, and an expression calculation module 505.
The expression extracting module 501 is configured to, when a big data decision request is detected, extract a decision expression included in the big data decision request, where the decision expression includes multiple sub-expressions connected by a logical operator, the sub-expressions include multiple service data to be filled and calculated and connected by a relational operator, the decision expression includes at least one bracketing group, and the bracketing group is used to determine an operation level corresponding to the decision expression; the expression decomposition module 502 is configured to identify a bracket group insertion position of a decision expression, and decompose the decision expression step by step according to an operation level according to the bracket group insertion position to obtain a plurality of level expressions corresponding to a plurality of operation levels, where each level expression includes at least one sub-expression; a contribution determining module 503, configured to determine a decision contribution of each hierarchical expression according to historical decision result data matched with each hierarchical expression and a decision attribute of a logic operator of the hierarchical expression connected to the same operation level; the expression adjusting module 504 is configured to adjust positions of the hierarchical expressions in the decision expressions according to decision contribution degrees of the hierarchical expressions in the same operation level, so as to obtain adjusted expressions; and the expression calculation module 505 is configured to obtain, in real time, the service data from the database according to the operation sequence of the adjusted expression, and fill the service data in the corresponding sub-expressions for calculation, so as to obtain a calculation result matched with the big data decision request.
The embodiment of the invention provides a decision device based on big data, which is characterized in that a plurality of hierarchical expressions corresponding to a plurality of operation levels are obtained by decomposing a decision expression step by step according to the operation levels, the hierarchical expressions comprise at least one sub-expression, then the decision contribution degree of each hierarchical expression is determined according to the historical decision result data matched with each hierarchical expression and the decision attribute of a logic operator of the hierarchical expression connected with the same operation level, the position of each hierarchical expression in the decision expression is adjusted according to the decision contribution degree of each hierarchical expression in the same operation level to obtain an adjusted expression, according to the operation sequence of the adjusted expression, service data is obtained from a database in real time and is filled in the corresponding sub-expression for calculation to obtain a calculation result matched with a big data decision request, the complex decision expressions can be decomposed step by step, the decision contribution degree of each level can be counted according to historical decision result data, the positions of the level expressions in the decision expressions can be adjusted according to the sequence from large to small of the decision contribution degree of the level expressions, and the execution sequence of the decision expressions is optimized, so that the acquisition and calculation of service data are reduced, the decision efficiency is improved, the waste of system resources is reduced, and the delay of decision execution is reduced.
On the basis of the above embodiments, the expression decomposition module 502 may include: the expression acquisition unit is used for acquiring a hierarchy operator from the logic operator according to the operation hierarchy determined by the bracket group insertion position of the decision expression and acquiring a plurality of hierarchy expressions corresponding to a plurality of operation hierarchies respectively according to the hierarchy operator; and restoring the combination of the hierarchical expressions of all the subsequent operation levels corresponding to the hierarchical expression of the previous operation level to obtain the hierarchical expression of the previous operation level.
On the basis of the above embodiments, the expression obtaining unit may include: the expression acquiring subunit is used for acquiring a current processing expression in the current processing expression set, wherein the initial value of the current processing expression set is a decision expression; the expression judging subunit is used for judging whether the current processing expression comprises a logical operator; an operator acquiring subunit, configured to, if yes, acquire, in each logical operator, a highest-level operator that matches the processing expression according to the bracket insertion position of the current processing expression; the expression splitting subunit is used for decomposing the current processing expression into a plurality of hierarchical expressions of next operation levels, wherein the hierarchical expressions of the next operation levels take the current processing expression as the hierarchical expression of the previous operation level according to the position of the operator of the highest level in the current processing expression, and all the hierarchical expressions of the next operation levels are added into the current processing expression set; a processing completion subunit, configured to determine to complete the processing on the current processing expression if the processing is not completed; and the operation returning subunit is used for returning and executing the operation of obtaining one current processing expression in the current processing expression set until the processing of all the current processing expressions in the current processing expression set is completed.
On the basis of the foregoing embodiments, the contribution degree determining module 503 may include: the first acquisition unit is used for acquiring historical decision result data of a set number matched with the decision expression; the second acquisition unit is used for sequentially acquiring the hierarchical expressions of a plurality of next operation levels of the hierarchical expression belonging to the same previous operation level according to the sequence of the operation levels; the data screening unit is used for screening target decision result data respectively corresponding to the hierarchical expression of each next operation level in the historical decision result data, and the target decision result data comprise at least two result values; a third obtaining unit, configured to obtain, according to a decision attribute of a logical operator of a hierarchical expression connecting multiple subsequent operation levels, a quantitative value of target decision result data whose result value matches the decision attribute, as a decision contribution degree corresponding to the hierarchical expression of each subsequent operation level; and the first returning unit is used for returning and executing the operation of sequentially acquiring the hierarchical expressions of a plurality of next operation levels belonging to the hierarchical expression of the same previous operation level according to the sequence of the operation levels until the processing of all the hierarchical expressions is completed.
On the basis of the above embodiments, the logical operators may include: and logical operators and or logical operators; the decision attribute corresponding to the logical operator is false logic and the decision attribute corresponding to the or logical operator is true logic.
On the basis of the above embodiments, the first obtaining unit may include: and the data acquisition subunit is used for acquiring the historical decision result data of the set number matched with the user attributes according to the user attributes of the decision expression.
On the basis of the foregoing embodiments, the expression adjusting module 504 may include: the fourth acquisition unit is used for sequentially acquiring the hierarchical expressions of a plurality of next operation levels of the hierarchical expression belonging to the same previous operation level according to the sequence of the operation levels; the sequence adjusting unit is used for adjusting the sequence of the hierarchical expressions of the plurality of next operation levels in the hierarchical expression of the previous operation level according to the sequence from large to small of the decision contribution degrees of the hierarchical expressions of the plurality of next operation levels; and the second returning unit is used for returning and executing the operation of sequentially obtaining the hierarchical expressions of a plurality of next operation levels belonging to the hierarchical expression of the same previous operation level according to the sequence of the operation levels until the adjustment of the decision expression is completed so as to obtain the adjusted expression.
On the basis of the above embodiments, the order adjusting unit may include: and the sequence adjusting subunit is used for adjusting the sequence of the hierarchical expressions of the plurality of subsequent operation levels in the hierarchical expression of the previous operation level according to the sequence from large to small of the decision contribution degrees of the hierarchical expressions of the plurality of subsequent operation levels and the type of the logical operator connecting the hierarchical expressions of the plurality of subsequent operation levels.
On the basis of the above embodiments, the expression calculation module 505 may include: the single-thread computing unit is used for acquiring the service data from the database in real time in a single-thread mode according to the operation sequence of the adjusted expression and filling the service data into the corresponding sub-expression for computing until a computation ending condition is met so as to obtain a computation result matched with the big data decision request; or the multithreading calculation unit is used for acquiring a plurality of hierarchical expressions belonging to the same operation level according to the operation sequence of the adjusted expressions, establishing a plurality of threads matched with the hierarchical expressions, and acquiring service data from the database in real time in a multithreading parallel processing mode to fill the service data into the corresponding sub-expressions for calculation until the calculation ending condition is met so as to obtain a calculation result matched with the big data decision request.
The big data-based decision device can execute the big data-based decision method provided by any embodiment of the invention, and has corresponding functional modules and beneficial effects for executing the big data-based decision method.
EXAMPLE six
Fig. 6 is a schematic structural diagram of a computer device according to a sixth embodiment of the present invention. FIG. 6 illustrates a block diagram of an exemplary computer device 612 suitable for use in implementing embodiments of the present invention. The computer device 612 shown in fig. 6 is only an example and should not bring any limitations to the functionality or scope of use of embodiments of the present invention.
As shown in fig. 6, the computer device 612 is in the form of a general purpose computing device. Components of computer device 612 may include, but are not limited to: one or more processors 616, a memory 628, and a bus 618 that connects the various system components (including the memory 628 and the processors 616).
Bus 618 represents one or more of any of several types of bus structures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, and a processor or local bus using any of a variety of bus architectures. By way of example, such architectures include, but are not limited to, Industry Standard Architecture (ISA) bus, micro-channel architecture (MAC) bus, enhanced ISA bus, Video Electronics Standards Association (VESA) local bus, and Peripheral Component Interconnect (PCI) bus.
Computer device 612 typically includes a variety of computer system readable media. Such media can be any available media that is accessible by computer device 612 and includes both volatile and nonvolatile media, removable and non-removable media.
The memory 628 is used to store instructions. The memory 628 may include computer system readable media in the form of volatile memory, such as Random Access Memory (RAM)630 and/or cache memory 632. The computer device 612 may further include other removable/non-removable, volatile/nonvolatile computer system storage media. By way of example only, storage system 634 may be used to read from or write to non-removable, nonvolatile magnetic media (not shown in FIG. 6, commonly referred to as a "hard disk drive"). Although not shown in FIG. 6, a magnetic disk drive for reading from and writing to a removable, nonvolatile magnetic disk (e.g., a "floppy disk") and an optical disk drive for reading from or writing to a removable, nonvolatile optical disk (e.g., a CD-ROM, DVD-ROM, or other optical media) may be provided. In such cases, each drive may be connected to bus 618 by one or more data media interfaces. Memory 628 may include at least one program product having a set (e.g., at least one) of program modules that are configured to carry out the functions of embodiments of the invention.
A program/utility 640 having a set (at least one) of program modules 642 may be stored, for example, in memory 628, such program modules 642 including, but not limited to, an operating system, one or more application programs, other program modules, and program data, each of which examples or some combination thereof may comprise an implementation of a network environment. The program modules 642 generally perform the functions and/or methods of the described embodiments of the present invention.
The computer device 612 may also communicate with one or more external devices 614 (e.g., keyboard, pointing device, display 624, etc.), with one or more devices that enable a user to interact with the computer device 612, and/or with any devices (e.g., network card, modem, etc.) that enable the computer device 612 to communicate with one or more other computing devices. Such communication may occur via input/output (I/O) interfaces 622. Also, computer device 612 may communicate with one or more networks (e.g., a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public network such as the Internet) through network adapter 620. As shown, the network adapter 620 communicates with the other modules of the computer device 612 via the bus 618. It should be appreciated that although not shown in FIG. 6, other hardware and/or software modules may be used in conjunction with computer device 612, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, among others.
The processor 616 executes various functional applications and data processing by executing instructions stored in the memory 628, such as performing the following operations: when a big data decision request is detected, extracting a decision expression included in the big data decision request, wherein the decision expression comprises a plurality of sub expressions connected by a logic operator, the sub expressions comprise a plurality of service data to be filled and calculated, the service data are connected by a relational operator, the decision expression comprises at least one number-including group, and the bracket group is used for determining an operation level corresponding to the decision expression; identifying bracket group insertion positions of the decision expressions, and decomposing the decision expressions step by step according to operation levels according to the bracket group insertion positions to obtain a plurality of level expressions respectively corresponding to the operation levels, wherein the level expressions comprise at least one sub-expression; determining decision contribution of each level expression according to historical decision result data matched with each level expression and decision attributes of logic operators of the level expressions connected with the same operation level; adjusting the positions of the expressions of each level in the decision expression according to the decision contribution degrees of the expressions of each level in the same operation level to obtain an adjusted expression; and acquiring service data from the database in real time according to the operation sequence of the adjusted expression, filling the service data into the corresponding sub-expression, and calculating to obtain a calculation result matched with the big data decision request.
On the basis of the above embodiments, the processor 616 is configured to obtain a plurality of hierarchical expressions corresponding to a plurality of operation hierarchies, respectively, by: acquiring a hierarchy operator from the logic operator according to an operation hierarchy determined by the bracket group insertion position of the decision expression, and obtaining a plurality of hierarchy expressions corresponding to a plurality of operation hierarchies respectively according to the hierarchy operator; and restoring the combination of the hierarchical expressions of all the subsequent operation levels corresponding to the hierarchical expression of the previous operation level to obtain the hierarchical expression of the previous operation level.
On the basis of the above embodiments, the processor 616 is configured to obtain a plurality of hierarchical expressions corresponding to a plurality of operation hierarchies, respectively, by: acquiring a current processing expression in a current processing expression set, wherein an initial value of the current processing expression set is a decision expression; judging whether a logic operator is included in the current processing expression; if yes, acquiring a highest level operational character matched with the processing expression in each logic operator according to the bracket insertion position of the current processing expression; decomposing the current processing expression into a plurality of hierarchical expressions of a next operation level which take the current processing expression as a hierarchical expression of a previous operation level according to the position of the operator of the highest level in the current processing expression, and adding all the hierarchical expressions of the next operation level into the current processing expression set; otherwise, determining to finish the processing of the current processing expression; and returning to execute the operation of acquiring one current processing expression in the current processing expression set until the processing of all the current processing expressions in the current processing expression set is completed.
On the basis of the above embodiments, the processor 616 is configured to determine the decision contribution of the hierarchical expressions by: obtaining historical decision result data of a set number matched with the decision expression; sequentially acquiring a plurality of hierarchical expressions of a next operation level belonging to the same hierarchical expression of a previous operation level according to the sequence of the operation levels; screening target decision result data corresponding to the hierarchical expression of each next operation level in the historical decision result data, wherein the target decision result data comprise at least two result values; acquiring a quantity value of target decision result data of which the result value is matched with the decision attribute according to the decision attribute of the logic operator of the hierarchical expression connecting a plurality of subsequent operation levels, wherein the quantity value is used as a decision contribution degree corresponding to the hierarchical expression of each subsequent operation level; and returning to execute the operation of sequentially acquiring the hierarchical expressions of a plurality of next operation levels belonging to the hierarchical expression of the same previous operation level according to the sequence of the operation levels until the processing of all the hierarchical expressions is completed.
On the basis of the above embodiments, the logical operators include: and logical operators and or logical operators; the decision attribute corresponding to the logical operator is false logic and the decision attribute corresponding to the or logical operator is true logic.
On the basis of the above embodiments, the processor 616 is configured to obtain a set number of historical decision result data for the decision expression match by: and acquiring a set amount of historical decision result data matched with the user attributes according to the user attributes of the decision expression.
On the basis of the foregoing embodiments, the processor 616 is configured to obtain the adjusted expression by: sequentially acquiring a plurality of hierarchical expressions of a next operation level belonging to the same hierarchical expression of a previous operation level according to the sequence of the operation levels; adjusting the sequence of the hierarchical expressions of the plurality of next operation levels in the hierarchical expression of the previous operation level according to the sequence of the decision contribution degrees of the hierarchical expressions of the plurality of next operation levels from large to small; and returning to execute the operation of sequentially acquiring the hierarchical expressions of a plurality of next operation levels belonging to the hierarchical expression of the same previous operation level according to the sequence of the operation levels until the adjustment of the decision expression is completed to obtain the adjusted expression.
On the basis of the above embodiments, the processor 616 is configured to adjust the order of the hierarchical expressions of a plurality of subsequent operation levels in the hierarchical expression of the previous operation level by: and adjusting the sequence of the hierarchical expressions of the plurality of subsequent operation levels in the hierarchical expression of the previous operation level according to the sequence from large to small of the decision contribution degrees of the hierarchical expressions of the plurality of subsequent operation levels and the type of the logic operator connecting the hierarchical expressions of the plurality of subsequent operation levels.
On the basis of the above embodiments, the processor 616 is configured to obtain the calculation result matching the adjusted expression by: according to the operation sequence of the adjusted expression, acquiring service data from a database in real time in a single-thread mode, filling the service data into the corresponding sub-expression for calculation until a calculation ending condition is met, and obtaining a calculation result matched with the big data decision request; or acquiring a plurality of hierarchical expressions belonging to the same operation level according to the operation sequence of the adjusted expressions, establishing a plurality of threads matched with the hierarchical expressions, acquiring service data from the database in real time in a multi-thread parallel processing mode, filling the service data into corresponding sub-expressions for calculation until a calculation ending condition is met, and obtaining a calculation result matched with the big data decision request.
EXAMPLE seven
A seventh embodiment of the present invention provides a computer-readable storage medium, where the storage medium is configured to store instructions for executing the big data based decision method provided in any embodiment of the present invention.
Any combination of one or more computer-readable media may be employed. The computer readable medium may be a computer readable signal medium or a computer readable storage medium. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the computer readable storage medium would include the following: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the context of this document, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
A computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.
Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
Computer program code for carrying out operations for aspects of the present invention may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. 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 or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including 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).
It is to be noted that the foregoing is only illustrative of the preferred embodiments of the present invention and the technical principles employed. It will be understood by those skilled in the art that the present invention is not limited to the particular embodiments described herein, but is capable of various obvious changes, rearrangements and substitutions as will now become apparent to those skilled in the art without departing from the scope of the invention. Therefore, although the present invention has been described in greater detail by the above embodiments, the present invention is not limited to the above embodiments, and may include other equivalent embodiments without departing from the spirit of the present invention, and the scope of the present invention is determined by the scope of the appended claims.

Claims (17)

1. A big data-based decision method is characterized by comprising the following steps:
when a big data decision request is detected, extracting a decision expression included in the big data decision request, wherein the decision expression comprises a plurality of sub expressions connected by a logic operator, the sub expressions comprise a plurality of service data to be filled and calculated, the service data are connected by a relational operator, the decision expression comprises at least one bracketed group, and the bracketed group is used for determining an operation level corresponding to the decision expression;
identifying bracket group insertion positions of the decision expressions, and decomposing the decision expressions step by step according to operation levels according to the bracket group insertion positions to obtain a plurality of level expressions corresponding to the operation levels respectively, wherein the level expressions comprise at least one sub-expression;
determining decision contribution of each hierarchical expression according to historical decision result data matched with each hierarchical expression and decision attributes of logic operators of the hierarchical expressions connected with the same operation level;
adjusting the position of each hierarchical expression in the decision expression according to the decision contribution degree of each hierarchical expression in the same operation level to obtain an adjusted expression;
acquiring service data from a database in real time according to the operation sequence of the adjusted expression, filling the service data into the corresponding sub-expression, and calculating to obtain a calculation result matched with the big data decision request;
determining a decision contribution degree of each hierarchical expression according to historical decision result data matched with each hierarchical expression and a decision attribute of a logic operator of the hierarchical expression connected with the same operation level, wherein the decision contribution degree of each hierarchical expression comprises the following steps:
obtaining historical decision result data of a set number matched with the decision expression;
sequentially acquiring a plurality of hierarchical expressions of a next operation level belonging to the same hierarchical expression of a previous operation level according to the sequence of the operation levels;
screening target decision result data corresponding to the hierarchical expression of each subsequent operation level in the historical decision result data, wherein the target decision result data comprise at least two result values;
acquiring a quantity value of target decision result data of which a result value is matched with a decision attribute according to the decision attribute of a logic operator of a hierarchical expression connecting the plurality of subsequent operation levels, wherein the quantity value is used as a decision contribution degree corresponding to the hierarchical expression of each subsequent operation level;
and returning to execute the operation of sequentially acquiring the hierarchical expressions of a plurality of next operation levels belonging to the hierarchical expression of the same previous operation level according to the sequence of the operation levels until the processing of all the hierarchical expressions is completed.
2. The method of claim 1, wherein decomposing the decision expression level by level according to the bracket group insertion position to obtain a plurality of level expressions corresponding to a plurality of operation levels respectively comprises:
acquiring a hierarchy operator from the logic operator according to an operation hierarchy determined by the bracket group insertion position of the decision expression, and obtaining a plurality of hierarchy expressions corresponding to a plurality of operation hierarchies respectively according to the hierarchy operator;
and restoring the combination of the hierarchical expressions of all the subsequent operation levels corresponding to the hierarchical expression of the previous operation level to obtain the hierarchical expression of the previous operation level.
3. The method of claim 2, wherein obtaining a hierarchy operator among the logical operators according to an operation level determined by a bracket group insertion position of the decision expression, and obtaining a plurality of hierarchy expressions corresponding to a plurality of operation levels respectively according to the hierarchy operator, comprises:
acquiring a current processing expression in a current processing expression set, wherein an initial value of the current processing expression set is the decision expression;
judging whether a logic operator is included in the current processing expression;
if yes, according to the bracket insertion position of the current processing expression, in each logic operator, acquiring a highest level operator matched with the processing expression;
decomposing the current processing expression into a plurality of hierarchical expressions of a next operation level which takes the current processing expression as a hierarchical expression of a previous operation level according to the position of the operator of the highest level in the current processing expression, and adding all the hierarchical expressions of the next operation level into the current processing expression set;
otherwise, determining to finish the processing of the current processing expression;
and returning to execute the operation of acquiring one current processing expression in the current processing expression set until the processing of all the current processing expressions in the current processing expression set is completed.
4. The method of claim 2 or 3, wherein the logical operators comprise: and logical operators and or logical operators;
the decision attribute corresponding to the logical operator is false logic and the decision attribute corresponding to the or logical operator is true logic.
5. The method of claim 2 or 3, wherein obtaining a set number of historical decision result data for which the decision expression matches comprises:
and acquiring a set amount of historical decision result data matched with the user attributes according to the user attributes of the decision expression.
6. The method of claim 2, wherein adjusting the position of each hierarchical expression in the decision expression according to the decision contribution of each hierarchical expression in the same operation hierarchy to obtain an adjusted expression comprises:
sequentially acquiring a plurality of hierarchical expressions of a next operation level belonging to the same hierarchical expression of a previous operation level according to the sequence of the operation levels;
adjusting the sequence of the hierarchical expressions of the plurality of next operation levels in the hierarchical expression of the previous operation level according to the sequence of the decision contribution degrees of the hierarchical expressions of the plurality of next operation levels from large to small;
and returning to execute the operation of sequentially acquiring the hierarchical expressions of a plurality of next operation levels belonging to the hierarchical expression of the same previous operation level according to the sequence of the operation levels until the decision expression is adjusted to obtain the adjusted expression.
7. The method according to claim 6, wherein adjusting the order of the hierarchical expressions of the plurality of next operation levels in the hierarchical expression of the previous operation level according to the order of the decision contribution degrees of the hierarchical expressions of the plurality of next operation levels from large to small comprises:
and adjusting the sequence of the hierarchical expressions of the plurality of subsequent operation levels in the hierarchical expression of the previous operation level according to the sequence of the decision contribution degrees of the hierarchical expressions of the plurality of subsequent operation levels from large to small and the type of the logical operator connecting the hierarchical expressions of the plurality of subsequent operation levels.
8. The method according to claim 1, wherein obtaining service data from a database in real time according to the operation sequence of the adjusted expression, filling the service data in a corresponding sub-expression, and performing calculation to obtain a calculation result matched with the big data decision request, comprises:
acquiring service data from a database in real time in a single-thread mode according to the operation sequence of the adjusted expression, filling the service data into the corresponding sub-expression for calculation until a calculation ending condition is met, and obtaining a calculation result matched with the big data decision request;
or acquiring a plurality of hierarchical expressions belonging to the same operation level according to the operation sequence of the adjusted expressions, establishing a plurality of threads matched with the hierarchical expressions, acquiring service data from a database in real time in a multithread parallel processing mode, filling the service data into corresponding sub-expressions, and calculating until a calculation ending condition is met so as to obtain a calculation result matched with the big data decision request.
9. A computer device comprising a processor and a memory, the memory to store instructions that, when executed, cause the processor to:
when a big data decision request is detected, extracting a decision expression included in the big data decision request, wherein the decision expression comprises a plurality of sub expressions connected by a logic operator, the sub expressions comprise a plurality of service data to be filled and calculated, the service data are connected by a relational operator, the decision expression comprises at least one bracketed group, and the bracketed group is used for determining an operation level corresponding to the decision expression;
identifying bracket group insertion positions of the decision expressions, and decomposing the decision expressions step by step according to operation levels according to the bracket group insertion positions to obtain a plurality of level expressions corresponding to the operation levels respectively, wherein the level expressions comprise at least one sub-expression;
determining decision contribution of each hierarchical expression according to historical decision result data matched with each hierarchical expression and decision attributes of logic operators of the hierarchical expressions connected with the same operation level;
adjusting the position of each hierarchical expression in the decision expression according to the decision contribution degree of each hierarchical expression in the same operation level to obtain an adjusted expression;
acquiring service data from a database in real time according to the operation sequence of the adjusted expression, filling the service data into the corresponding sub-expression, and calculating to obtain a calculation result matched with the big data decision request;
the processor is configured to determine a decision contribution for each of the hierarchical expressions by:
obtaining historical decision result data of a set number matched with the decision expression;
sequentially acquiring a plurality of hierarchical expressions of a next operation level belonging to the same hierarchical expression of a previous operation level according to the sequence of the operation levels;
screening target decision result data corresponding to the hierarchical expression of each subsequent operation level in the historical decision result data, wherein the target decision result data comprise at least two result values;
acquiring a quantity value of target decision result data of which a result value is matched with a decision attribute according to the decision attribute of a logic operator of a hierarchical expression connecting the plurality of subsequent operation levels, wherein the quantity value is used as a decision contribution degree corresponding to the hierarchical expression of each subsequent operation level;
and returning to execute the operation of sequentially acquiring the hierarchical expressions of a plurality of next operation levels belonging to the hierarchical expression of the same previous operation level according to the sequence of the operation levels until the processing of all the hierarchical expressions is completed.
10. The computer device of claim 9, wherein the processor is configured to derive the plurality of hierarchical expressions corresponding to the plurality of operation hierarchies, respectively, by:
acquiring a hierarchy operator from the logic operator according to an operation hierarchy determined by the bracket group insertion position of the decision expression, and obtaining a plurality of hierarchy expressions corresponding to a plurality of operation hierarchies respectively according to the hierarchy operator;
and restoring the combination of the hierarchical expressions of all the subsequent operation levels corresponding to the hierarchical expression of the previous operation level to obtain the hierarchical expression of the previous operation level.
11. The computer device of claim 10, wherein the processor is configured to derive the plurality of hierarchical expressions corresponding to the plurality of operation hierarchies, respectively, by:
acquiring a current processing expression in a current processing expression set, wherein an initial value of the current processing expression set is the decision expression;
judging whether a logic operator is included in the current processing expression;
if yes, according to the bracket insertion position of the current processing expression, in each logic operator, acquiring a highest level operator matched with the processing expression;
decomposing the current processing expression into a plurality of hierarchical expressions of a next operation level which takes the current processing expression as a hierarchical expression of a previous operation level according to the position of the operator of the highest level in the current processing expression, and adding all the hierarchical expressions of the next operation level into the current processing expression set;
otherwise, determining to finish the processing of the current processing expression;
and returning to execute the operation of acquiring one current processing expression in the current processing expression set until the processing of all the current processing expressions in the current processing expression set is completed.
12. The computer device of claim 10 or 11, wherein the logical operators comprise: and logical operators and or logical operators;
the decision attribute corresponding to the logical operator is false logic and the decision attribute corresponding to the or logical operator is true logic.
13. A computer device according to claim 10 or 11, wherein the processor is arranged to obtain a set amount of historical decision result data for which the decision expression matches by:
and acquiring a set amount of historical decision result data matched with the user attributes according to the user attributes of the decision expression.
14. The computer device of claim 10, wherein the processor is configured to derive the adjusted expression by:
sequentially acquiring a plurality of hierarchical expressions of a next operation level belonging to the same hierarchical expression of a previous operation level according to the sequence of the operation levels;
adjusting the sequence of the hierarchical expressions of the plurality of next operation levels in the hierarchical expression of the previous operation level according to the sequence of the decision contribution degrees of the hierarchical expressions of the plurality of next operation levels from large to small;
and returning to execute the operation of sequentially acquiring the hierarchical expressions of a plurality of next operation levels belonging to the hierarchical expression of the same previous operation level according to the sequence of the operation levels until the decision expression is adjusted to obtain the adjusted expression.
15. The computer device of claim 14, wherein the processor is configured to adjust the order of the hierarchical expressions of the plurality of subsequent operation levels in the hierarchical expression of the previous operation level by:
and adjusting the sequence of the hierarchical expressions of the plurality of subsequent operation levels in the hierarchical expression of the previous operation level according to the sequence of the decision contribution degrees of the hierarchical expressions of the plurality of subsequent operation levels from large to small and the type of the logical operator connecting the hierarchical expressions of the plurality of subsequent operation levels.
16. The computer device of claim 9, wherein the processor is configured to obtain the computation result matching the adjusted expression by:
acquiring service data from a database in real time in a single-thread mode according to the operation sequence of the adjusted expression, filling the service data into the corresponding sub-expression for calculation until a calculation ending condition is met, and obtaining a calculation result matched with the big data decision request;
or acquiring a plurality of hierarchical expressions belonging to the same operation level according to the operation sequence of the adjusted expressions, establishing a plurality of threads matched with the hierarchical expressions, acquiring service data from a database in real time in a multithread parallel processing mode, filling the service data into corresponding sub-expressions, and calculating until a calculation ending condition is met so as to obtain a calculation result matched with the big data decision request.
17. A storage medium storing instructions for performing a big data based decision method as claimed in any of claims 1-8.
CN201911076168.XA 2019-11-06 2019-11-06 Big data-based decision method, equipment and medium Active CN110826911B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201911076168.XA CN110826911B (en) 2019-11-06 2019-11-06 Big data-based decision method, equipment and medium
PCT/CN2020/120787 WO2021088605A1 (en) 2019-11-06 2020-10-14 Big data-based decision method, device and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911076168.XA CN110826911B (en) 2019-11-06 2019-11-06 Big data-based decision method, equipment and medium

Publications (2)

Publication Number Publication Date
CN110826911A CN110826911A (en) 2020-02-21
CN110826911B true CN110826911B (en) 2020-08-21

Family

ID=69552999

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911076168.XA Active CN110826911B (en) 2019-11-06 2019-11-06 Big data-based decision method, equipment and medium

Country Status (2)

Country Link
CN (1) CN110826911B (en)
WO (1) WO2021088605A1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110826911B (en) * 2019-11-06 2020-08-21 南京星环智能科技有限公司 Big data-based decision method, equipment and medium
CN111638948B (en) * 2020-06-03 2023-04-07 重庆银行股份有限公司 Multi-channel high-availability big data real-time decision making system and decision making method

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103279358A (en) * 2013-06-08 2013-09-04 北京首钢自动化信息技术有限公司 Interpreted dynamic business component construction method for industrial applications
CN104750499A (en) * 2015-04-21 2015-07-01 南京大学 Constraint solving and description logic based web service combination method
CN107704265A (en) * 2017-09-30 2018-02-16 电子科技大学 A kind of configurable rule generating method of service-oriented stream
CN110045953A (en) * 2019-04-22 2019-07-23 第四范式(北京)技术有限公司 Generate the method and computing device of business rule expression formula

Family Cites Families (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5051010B2 (en) * 2008-06-11 2012-10-17 アイシン・エィ・ダブリュ株式会社 Parking lot guidance device, parking lot guidance method and program
US10402735B2 (en) * 2015-03-30 2019-09-03 The Nielsen Company (Us), Llc Methods and apparatus to improve decision tree execution
CN104794240B (en) * 2015-05-08 2019-06-14 国家测绘地理信息局四川测绘产品质量监督检验站 Expression parsing method towards geospatial database attribute value constraint checking
CN107491484B (en) * 2017-07-17 2020-08-28 阿里巴巴集团控股有限公司 Data matching method, device and equipment
CN115993991A (en) * 2018-05-31 2023-04-21 创新先进技术有限公司 Service decision method, device and equipment
CN109902831B (en) * 2018-11-05 2023-04-07 创新先进技术有限公司 Service decision processing method and device
CN109614597B (en) * 2018-12-14 2023-04-07 中通服公众信息产业股份有限公司 Logic expression conversion, splitting and assembling method
CN110188113B (en) * 2019-05-09 2022-05-13 厦门市美亚柏科信息股份有限公司 Method, device and storage medium for comparing data by using complex expression
CN110134517A (en) * 2019-05-21 2019-08-16 山东浪潮通软信息科技有限公司 A kind of parallel calculating method and device based on Formula Parsing
CN110826911B (en) * 2019-11-06 2020-08-21 南京星环智能科技有限公司 Big data-based decision method, equipment and medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103279358A (en) * 2013-06-08 2013-09-04 北京首钢自动化信息技术有限公司 Interpreted dynamic business component construction method for industrial applications
CN104750499A (en) * 2015-04-21 2015-07-01 南京大学 Constraint solving and description logic based web service combination method
CN107704265A (en) * 2017-09-30 2018-02-16 电子科技大学 A kind of configurable rule generating method of service-oriented stream
CN110045953A (en) * 2019-04-22 2019-07-23 第四范式(北京)技术有限公司 Generate the method and computing device of business rule expression formula

Also Published As

Publication number Publication date
CN110826911A (en) 2020-02-21
WO2021088605A1 (en) 2021-05-14

Similar Documents

Publication Publication Date Title
US20220391763A1 (en) Machine learning service
US20210374610A1 (en) Efficient duplicate detection for machine learning data sets
US20200050968A1 (en) Interactive interfaces for machine learning model evaluations
US9886670B2 (en) Feature processing recipes for machine learning
US11915104B2 (en) Normalizing text attributes for machine learning models
CN111400012A (en) Data parallel processing method, device, equipment and storage medium
US20160078361A1 (en) Optimized training of linear machine learning models
CN110688393B (en) Query statement optimization method and device, computer equipment and storage medium
CN111427971B (en) Business modeling method, device, system and medium for computer system
CN114205690B (en) Flow prediction method, flow prediction device, model training device, electronic equipment and storage medium
CN110826911B (en) Big data-based decision method, equipment and medium
CN110838031A (en) Data operation method and device based on ABtest
CN108733790B (en) Data sorting method, device, server and storage medium
CN106844550B (en) Virtualization platform operation recommendation method and device
CN114281823A (en) Table processing method, device, equipment, storage medium and product
US8650180B2 (en) Efficient optimization over uncertain data
CN112000848A (en) Graph data processing method and device, electronic equipment and storage medium
US20190108416A1 (en) Methods for more effectively moderating one or more images and devices thereof
CN117332064A (en) Instruction generation and database operation method, electronic device and computer storage medium
CN115186738B (en) Model training method, device and storage medium
CN116089367A (en) Dynamic barrel dividing method, device, electronic equipment and medium
CN115564578B (en) Fraud recognition model generation method
CN115033616A (en) Data screening rule verification method and device based on multi-round sampling
CN112435151A (en) Government affair information data processing method and system based on correlation analysis
CN110968690A (en) Clustering division method and device for words, equipment and 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
GR01 Patent grant
GR01 Patent grant