Detailed Description
For the purposes of making the objects, technical solutions and advantages of the present specification more apparent, the technical solutions of the present specification will be clearly and completely described below with reference to specific embodiments of the present specification and corresponding drawings. It will be apparent that the described embodiments are only some, but not all, of the embodiments of the present specification. All other embodiments, which are determined by one of ordinary skill in the art without undue burden on the person of ordinary skill in the art based on the embodiments in this specification, are intended to be within the scope of protection of this specification.
The embodiment of the specification provides a root cause positioning method, a root cause positioning system and electronic equipment of a service scene, so as to solve the problem that the existing root cause positioning method of the service scene is high in algorithm complexity and cannot position an alarm root cause in time. The embodiments of the present specification provide a root cause positioning method of a service scenario, and an execution subject of the method may be, but is not limited to, an electronic device or an apparatus or a system that can be configured to execute the method provided by the embodiments of the present specification.
For convenience of description, an embodiment of the method will be described below by taking an electronic device as an example. It will be appreciated that the subject of execution of the method is an exemplary illustration of an electronic device and should not be construed as limiting the method.
Fig. 1 is a flowchart of a root cause positioning method of a service scenario provided in an embodiment of the present disclosure, where the method of fig. 1 may be performed by an electronic device, as shown in fig. 1, and the method may include:
step 110, determining scene data of the current alarm based on at least one data dimension of a service instance in a first preset time period where an occurrence time point of the current alarm is located.
The first preset time period may be set according to actual requirements, and the embodiment of the present specification is not specifically limited.
It should be understood that at least one data dimension is a distinguishing data dimension.
The method comprises the following steps: when an alarm occurs, determining a first preset time period in which the current alarm occurs, and acquiring at least one data dimension of a service instance in the first preset time period; and determining scene data of the current alarm based on at least one data dimension of the service instance in the first preset time period.
For example, assuming that the current alarm occurrence time is 2019, 3, 1, 9, and the first preset time period is 50 minutes from 2019, 3, 1, 8, 50 minutes to 2019, 3, 1, 9, 10 minutes, at this time, acquiring at least one data dimension of the service instance, for example, the at least one data dimension includes: appname & dimension & qualifier & information summary (MD 5) set of all service instances at the current time.
Specifically, if at least one data dimension includes a product production time, a product production parameter, etc., determining that a current alarm scene is a production scene based on the at least one data dimension, and determining scene data of the production scene; if the at least one data dimension includes sales amount of the product, sales mode of the product, etc., determining that the current alarm scene is a sales scene based on the at least one data dimension, and determining scene data of the sales scene.
And 120, taking the scene data of the current alarm as the input of a root cause positioning model to acquire root cause conditional probability distribution corresponding to the current alarm.
The root cause conditional probability distribution can refer to probability conditions of all root causes corresponding to the current alarm.
The root cause positioning model is obtained based on historical alarm scene data and corresponding root cause training.
The training data of the root cause positioning model are historical alarm scene data and corresponding root causes, wherein the historical alarm scene data are determined based on at least one data dimension of a service instance in a second preset time period where a time point of the historical alarm moment occurs, and the corresponding root causes of the historical alarm can be summarized based on working experience of technicians or mined based on frequent modes.
And 130, determining the root cause corresponding to the current alarm based on the root cause conditional probability distribution corresponding to the current alarm.
The method comprises the following steps: and determining the root cause corresponding to the root cause probability meeting the preset condition as the root cause corresponding to the current alarm based on the root cause conditional probability distribution corresponding to the current alarm. The predetermined condition may be selected according to actual requirements, for example, the predetermined condition is a condition with the highest probability, and so on.
According to the embodiment of the specification, the scene data of the current alarm is determined based on at least one data dimension of the service instance in the first preset time period where the occurrence time point of the current alarm is located, so that more alarm scene information can be provided for the subsequent root cause positioning, and the accuracy of the root cause positioning is improved; the scene data of the current alarm is used as the input of the root cause positioning model to acquire the root cause conditional probability distribution corresponding to the current alarm, the root cause corresponding to the current alarm is determined based on the root cause conditional probability distribution corresponding to the current alarm, and the root cause positioning is performed by using the trained root cause positioning model, so that the algorithm complexity of the root cause positioning method is simplified, and the root cause causing the alarm can be timely given when the alarm occurs, so that the purpose of timely stopping damage is achieved.
Alternatively, as an embodiment, step 130 may be specifically implemented as:
determining posterior probability that the current alarm scene is generated by a target root cause based on prior probability of the current alarm scene, prior probability of the target root cause and conditional probability that the scene is the current alarm scene under the condition that the target root cause appears, wherein the target root cause is any root cause in root cause conditional probability distribution corresponding to the current alarm;
and selecting a target root cause with the maximum posterior probability from the root causes in the root cause conditional probability distribution corresponding to the current alarm as the root cause corresponding to the current alarm.
The prior probability (prior probability) is a probability obtained by conventional experience and analysis.
The determining that the current alarm scene is the posterior probability generated by the target root causes can be specifically implemented as follows:
based on the prior probability of the current alarm scene, the prior probability of the target root cause and the conditional probability that the scene is the current alarm scene under the condition that the target root cause appears, the posterior probability that the current alarm scene is generated by the target root cause is determined through a Bayesian principle.
Specifically, assume that a bayesian formula of two variables is adopted, and the formula is:
determining posterior probability that the current alarm scene is generated by a target root cause;
wherein P (A) represents the prior probability of the target root cause A; p (B) represents the prior probability of the current alarm scene B; p (B/A) represents the conditional probability that the scene is the current alarm scene B in the case that the target root cause A appears; p (B/A) represents the posterior probability that the current alarm scenario B is generated by the target root cause A.
For example, if there are sales scenes, production scenes and processing scenes, the sales scenes, the production scenes and the processing scenes are mutually exclusive, the current alarm scenes are respectively the sales scenes, the production scenes and the processing scenes, and the prior probabilities of the sales scenes, the production scenes and the processing scenes are all 1/3;
if the target root cause includes: target root cause a, target root cause b, target root cause c and target root cause d, wherein the target root cause a, target root cause b, target root cause c and target root cause d are mutually exclusive root causes, and the prior probabilities of the target root cause a, the target root cause b, the target root cause c and the target root cause d are all 1/4;
if the conditional probability that the scene is a sales scene when the target root appears as a is 1/a, the conditional probability that the scene is a sales scene when the target root appears as b is 1/b, the conditional probability that the scene is a sales scene when the target root appears as c is 1/c, and the conditional probability that the scene is a sales scene when the target root appears as d is 1/d, then:
posterior probability generated by target root a in sales scenario
Posterior probability generated by target root b in sales scenario
Posterior probability generated by target root c in sales scenario
Posterior probability generated by target root d in sales scenario
If a > b > c > d, the posterior probability that the sales scenario is generated by the target root cause d is the greatest, and it can be determined that the sales scenario is generated by the target root cause d, that is, the root of the sales scenario is generated by the target root cause d.
According to the embodiment of the specification, the target root cause with the maximum posterior probability is selected from the root causes in the root cause conditional probability distribution corresponding to the current alarm to serve as the root cause corresponding to the current alarm, so that the root cause with the maximum possibility in the root causes can be positioned in time when the alarm occurs, and the accuracy of root cause positioning is improved.
Optionally, as an embodiment, before training the root cause positioning model based on the scene data of the historical alarm and the root cause corresponding to the historical alarm, the following two methods may be specifically adopted:
firstly, determining a root cause corresponding to the historical alarm based on the frequency of the historical root cause in unit time and the weight value of the historical root cause; wherein the historical root cause is a root cause that has occurred before the historical alert time.
Secondly, determining a root cause corresponding to the historical alarm based on the probability that the historical root cause and the historical alarm occur simultaneously and the conditional probability of the root cause under the condition that the historical alarm occurs; wherein the historical root cause is a root cause that has occurred before the historical alert time.
Specifically, if the first probability and the second probability are both minimum values, determining the historical root cause as the root cause of the historical alarm. Wherein the first probability is: the root cause is the conditional probability of the historical root cause under the condition that the historical alarm appears; the second probability is: the historical root causes and the historical alarms are concurrent probabilities.
According to the embodiment of the specification, the root cause corresponding to the historical alarm is determined through the historical root cause and the historical alarm, so that training sample data is prepared for the root cause positioning model, when the alarm occurs, the corresponding root cause of the current alarm can be obtained through inputting scene data of the current alarm into the root cause positioning model, and according to the obtained corresponding root cause of the current alarm, the root cause conditional probability distribution corresponding to the current alarm is obtained, more calculation time is not required, and the instantaneity is high.
In the above, fig. 1 illustrates the root cause positioning method of the service scenario in the embodiment of the present specification in detail, and in the following, with reference to fig. 2, the root cause positioning system of the service scenario in the embodiment of the present specification is illustrated in detail.
Fig. 2 is a schematic structural diagram of a root cause positioning system of a service scenario provided in an embodiment of the present disclosure, as shown in fig. 2, a root cause positioning system 200 of the service scenario may include:
a first data determining module 210, configured to determine scene data of a current alarm based on at least one data dimension of a service instance in a first preset time period where an occurrence time point of the current alarm is located;
the input module 220 is configured to take the current alarm scene data as input of a root cause positioning model to obtain a root cause conditional probability distribution corresponding to the current alarm, where the root cause positioning model is obtained based on historical alarm scene data and corresponding root cause training;
a first root cause determining module 230, configured to determine a root cause corresponding to the current alarm based on a root cause conditional probability distribution corresponding to the current alarm.
In one embodiment, the first root cause determining module 230 includes:
the first probability determining unit is used for determining posterior probability that the current alarm scene is generated by a target root cause based on the prior probability of the current alarm scene, the prior probability of the target root cause and the conditional probability that the scene is the current alarm scene under the condition that the target root cause appears, wherein the target root cause is any root cause in root cause conditional probability distribution corresponding to the current alarm;
and the selecting unit is used for selecting a target root cause with the maximum posterior probability from the root causes in the root cause conditional probability distribution corresponding to the current alarm as the root cause corresponding to the current alarm.
In an embodiment, the first probability determining unit includes:
the probability determination subunit is configured to determine, based on the prior probability of the current alarm scene, the prior probability of the target root cause, and the conditional probability that the scene is the current alarm scene when the target root cause appears, a posterior probability that the current alarm scene is generated by the target root cause according to a bayesian principle.
In one embodiment, the root cause positioning system 200 of the service scenario includes:
a second data determining module 240, configured to determine scenario data of the historical alarm based on at least one data dimension of a service instance in a second preset time period where a time point of occurrence of the historical alarm time is located;
the training module 250 is configured to train the root cause positioning model based on the scene data of the historical alarm and the root cause conditional probability distribution corresponding to the historical alarm.
In one embodiment, the root cause positioning system 200 of the service scenario includes:
a second root cause determining module 260, configured to determine a root cause corresponding to the historical alarm based on a frequency of a historical root cause in a unit time and a weight value of the historical root cause, where the historical root cause is a root cause that occurs before the time of the historical alarm.
In one embodiment, the root cause positioning system 200 of the service scenario includes:
and a third root cause determining module 280, configured to determine a root cause corresponding to the historical alarm based on a probability that the historical root cause and the historical alarm occur simultaneously, and based on a conditional probability of the historical root cause when the historical alarm occurs, where the historical root cause is a root cause that occurs before the time of the historical alarm.
In one embodiment, the third root cause determination module 280 includes:
the root cause determining unit is used for determining the historical root cause as the root cause of the historical alarm if the first probability and the second probability are both minimum;
wherein the first probability is: the root cause is the conditional probability of the historical root cause under the condition that the historical alarm appears;
the second probability is: the historical root causes and the historical alarms are concurrent probabilities.
According to the embodiment of the specification, the scene data of the current alarm is determined based on at least one data dimension of the service instance in the first preset time period where the occurrence time point of the current alarm is located, so that more alarm scene information can be provided for the subsequent root cause positioning, and the accuracy of the root cause positioning is improved; the scene data of the current alarm is used as the input of the root cause positioning model to acquire the root cause conditional probability distribution corresponding to the current alarm, the root cause corresponding to the current alarm is determined based on the root cause conditional probability distribution corresponding to the current alarm, and the root cause positioning is performed by using the trained root cause positioning model, so that the algorithm complexity of the root cause positioning method is simplified, and the root cause causing the alarm can be timely given when the alarm occurs, so that the purpose of timely stopping damage is achieved.
Fig. 3 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure. Referring to fig. 3, at the hardware level, the electronic device includes a processor, and optionally an internal bus, a network interface, and a memory. The memory may include a memory, such as a high-speed Random access memory (Random-AccessMemory, RAM), and may further include a non-volatile memory (non-volatile memory), such as at least 1 disk memory, etc. Of course, the electronic device may also include hardware required for other services.
The processor, network interface, and memory may be interconnected by an internal bus, which may be an ISA (Industry Standard Architecture ) bus, a PCI (Peripheral Component Interconnect, peripheral component interconnect standard) bus, or EISA (Extended Industry Standard Architecture ) bus, among others. The buses may be classified as address buses, data buses, control buses, etc. For ease of illustration, only one bi-directional arrow is shown in FIG. 3, but not only one bus or type of bus.
And the memory is used for storing programs. In particular, the program may include program code including computer-operating instructions. The memory may include memory and non-volatile storage and provide instructions and data to the processor.
The processor reads the corresponding computer program from the nonvolatile memory into the memory and then runs the computer program to form a device for associating the resource value-added object with the resource object on a logic level. The processor is used for executing the programs stored in the memory and is specifically used for executing the following operations:
determining scene data of a current alarm based on at least one data dimension of a service instance in a first preset time period where an occurrence time point of the current alarm is located;
taking the scene data of the current alarm as input of a root cause positioning model to acquire root cause conditional probability distribution corresponding to the current alarm, wherein the root cause positioning model is obtained based on the scene data of historical alarms and corresponding root cause training;
and determining the root cause corresponding to the current alarm based on the root cause conditional probability distribution corresponding to the current alarm.
According to the embodiment of the specification, the scene data of the current alarm is determined based on at least one data dimension of the service instance in the first preset time period where the occurrence time point of the current alarm is located, so that more alarm scene information can be provided for the subsequent root cause positioning, and the accuracy of the root cause positioning is improved; the scene data of the current alarm is used as the input of the root cause positioning model to acquire the root cause conditional probability distribution corresponding to the current alarm, the root cause corresponding to the current alarm is determined based on the root cause conditional probability distribution corresponding to the current alarm, and the root cause positioning is performed by using the trained root cause positioning model, so that the algorithm complexity of the root cause positioning method is simplified, and the root cause causing the alarm can be timely given when the alarm occurs, so that the purpose of timely stopping damage is achieved.
The root cause positioning method of the service scenario disclosed in the embodiment shown in fig. 1 of the present specification can be applied to a processor or implemented by the processor. The processor may be an integrated circuit chip having signal processing capabilities. In implementation, the steps of the above method may be performed by integrated logic circuits of hardware in a processor or by instructions in the form of software. The processor may be a general-purpose processor, including a central processing unit (Central Processing Unit, CPU), a network processor (Network Processor, NP), etc.; but also digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), field programmable gate arrays (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components. The various methods, steps, and logic blocks disclosed in one or more embodiments of the present description may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of a method disclosed in connection with one or more embodiments of the present disclosure may be embodied directly in a hardware decoding processor or in a combination of hardware and software modules in a decoding processor. The software modules may be located in a random access memory, flash memory, read only memory, programmable read only memory, or electrically erasable programmable memory, registers, etc. as well known in the art. The storage medium is located in a memory, and the processor reads the information in the memory and, in combination with its hardware, performs the steps of the above method.
The electronic device may also execute the root cause positioning method of the service scenario of fig. 1 executed by the root cause positioning system of the service scenario of fig. 2, which is not described herein.
Of course, in addition to the software implementation, the electronic device in this specification does not exclude other implementations, such as a logic device or a combination of software and hardware, that is, the execution subject of the following processing flow is not limited to a plurality of logic units, but may also be hardware or a logic device.
The embodiments of the present disclosure further provide a computer readable storage medium, on which a computer program is stored, where the computer program when executed by a processor implements a plurality of processes of the above method embodiments, and the same technical effects can be achieved, and for avoiding repetition, a description is omitted herein. Wherein the computer readable storage medium is selected from Read-Only Memory (ROM), random access Memory (Random Access Memory, RAM), magnetic disk or optical disk.
It will be appreciated by those skilled in the art that embodiments of the present description may be provided as a method, system, or computer program product. Accordingly, the present specification may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present description can take the form of a computer program product on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.
The present description is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the specification. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create a system for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In one typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include volatile memory in a computer-readable medium, random Access Memory (RAM) and/or nonvolatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). Memory is an example of computer-readable media.
Computer readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of storage media for a computer include, but are not limited to, phase change memory (PRAM), static Random Access Memory (SRAM), dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), read Only Memory (ROM), electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium, which can be used to store information that can be accessed by a computing device. Computer-readable media, as defined herein, does not include transitory computer-readable media (transmission media), such as modulated data signals and carrier waves.
The foregoing description of specific embodiments of the present invention has been presented. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims can be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
It should also be noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article or apparatus that comprises an element.
The foregoing is merely an example of the present specification and is not intended to limit the present specification. Various modifications and alterations to this specification will become apparent to those skilled in the art. Any modifications, equivalent substitutions, improvements, or the like, which are within the spirit and principles of the present description, are intended to be included within the scope of the claims of the present description.