Food safety index abnormality identification method and system based on knowledge graph

By constructing an inverted risk identification graph based on knowledge graphs, the problem of risk identification in traditional food safety testing is solved, and efficient anomaly tracing and comprehensive test results are achieved for complex production line processes.

CN120851630BActive Publication Date: 2025-12-09JIANGSU QUANZHENG INSPECTION & TESTING CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511366320.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-09-24
Publication Date
2025-12-09
Estimated Expiration
2045-09-24

AI Technical Summary

Technical Problem

Traditional food safety testing relies on a single standard, making it difficult to identify risks in complex production line processes, resulting in fragmented test results and low efficiency in tracing anomalies.

Method used

Based on knowledge graphs, an inverted risk identification graph is constructed. By extracting food safety indicators and their limits from multi-source safety standard texts, correlation analysis is performed between historical abnormal events and production line links to quantify investigation priorities, construct K-level risk nodes, hierarchically detect small batches of trial-produced food, conduct cross-sample cluster analysis, and generate failure hypotheses and confidence probabilities.

Benefits of technology

It enables accurate detection of abnormal food safety indicators and traceability of problems, improving the efficiency of food safety risk management and the comprehensiveness of test results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120851630B_ABST
    Figure CN120851630B_ABST
Patent Text Reader

Abstract

The application relates to the technical field of knowledge graphs, and provides a food safety index abnormality identification method and system based on a knowledge graph. The method comprises the following steps: extracting index safety limits from multi-source standard texts; acquiring abnormal records online and performing correlation analysis to quantize an investigation priority coefficient; dividing K-level risk nodes and constructing an inverted graph; injecting the limits into the graph as a knowledge base; triggering the graph in batches to perform small-batch trial production detection, and generating a defect vector set; performing cross-sample clustering analysis on the defect vector set, identifying N common defects, and generating a fault hypothesis and a confidence probability set. The application solves the technical problems that traditional food safety detection relies on a single standard, it is difficult to identify risks in complex production line links, and the detection results are fragmented and the abnormality tracing efficiency is low, and achieves the technical effects of realizing multi-source standard fusion, abnormality risk grading and defect tracing analysis through a knowledge graph, and improving the comprehensiveness of food safety index abnormality identification and the efficiency of tracing.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The application relates to the technical field of knowledge graphs, in particular to a food safety index abnormality identification method and system based on a knowledge graph. BACKGROUND

[0002] In current food safety supervision, with the expansion of food production scale and the increasing complexity of the supply chain, the traditional monitoring mode relying on manual experience and regular sampling has faced severe challenges. Various food safety standards and regulations are numerous and updated frequently, and the safety limit values of the indexes lack unified structured expression, which makes it difficult to quickly call authoritative data to support decision-making during abnormality detection. At the same time, a large number of historical abnormality records are scattered in different systems, and there is a lack of effective correlation and integration means, which leads to low efficiency of traceability analysis, and the investigation process often relies on subjective judgment, which is blind and lagging. SUMMARY

[0003] The application provides a food safety index abnormality identification method and system based on a knowledge graph, aiming to solve the technical problems that traditional food safety detection relies on a single standard and is difficult to identify risks in complex production line links, resulting in fragmented detection results and low abnormality traceability efficiency.

[0004] The first aspect of the application provides a food safety index abnormality identification method based on a knowledge graph, which comprises the following steps: structurally extracting a plurality of index safety limit values of a plurality of food safety indexes from a plurality of safety standard texts; network searching to obtain a plurality of abnormality traceability processing records of the plurality of food safety indexes, performing correlation analysis of historical abnormality events and production line links, and quantitatively outputting a plurality of abnormality investigation priority coefficients; based on the plurality of abnormality investigation priority coefficients, dividing the plurality of food safety indexes into K-level risk nodes, and then constructing an inverted risk identification graph based on the K-level risk nodes; injecting the plurality of index safety limit values into the inverted risk identification graph as a knowledge base; hierarchically triggering the inverted risk identification graph to perform differential recursive detection on small-batch trial production food, obtaining a batch detection defect vector set; performing cross-sample clustering analysis on the batch detection defect vector set, obtaining N common defect links, and then performing confidence analysis on the N common defect links to generate a fault hypothesis set and a confidence probability set.

[0005] In another aspect of the present disclosure, a food safety index anomaly identification system based on a knowledge graph is provided, which comprises: a safety limit value extraction module for extracting a plurality of index safety limit values of a plurality of food safety indexes from a multi-source safety standard text structure; an association analysis module for obtaining a plurality of abnormal traceability processing records of the plurality of food safety indexes through network search, performing association analysis of historical abnormal events and production line links, and quantitatively outputting a plurality of abnormal investigation priority coefficients; a graph construction module for dividing the plurality of food safety indexes into K-level risk nodes based on the plurality of abnormal investigation priority coefficients, and constructing an inverted risk identification graph based on the K-level risk nodes; a safety limit value injection module for injecting the plurality of index safety limit values as a knowledge base into the inverted risk identification graph; a recursive detection module for triggering the inverted risk identification graph to perform differential recursive detection on small-batch trial production food, and obtaining a batch detection defect vector set; and a confidence analysis module for performing cross-sample clustering analysis on the batch detection defect vector set, obtaining N common defect links, performing confidence analysis on the N common defect links, and generating a fault hypothesis set and a confidence probability set.

[0006] The one or more technical solutions provided in the present disclosure have at least the following technical effects or advantages:

[0007] The food safety index anomaly identification method based on a knowledge graph extracts a plurality of food safety indexes and their safety limit values from a multi-source safety standard text. Then, historical abnormal processing records are searched through a network, the relationship between abnormal events and production links is analyzed, and the investigation priority of each abnormality is determined according to the analysis results. Then, the safety indexes are divided into different risk levels according to the priority, and a risk identification graph is constructed. The safety limit values are injected into the graph as a knowledge base to support the risk identification function of the graph. Then, the trial production batch is differentially detected according to the risk graph, and a detection defect vector is generated. Finally, the defect vector is cross-sample clustered to identify common defect links, and confidence analysis is performed to finally generate a fault hypothesis and the corresponding confidence probability, thereby realizing accurate anomaly detection, problem traceability, and effective management of food safety risks.

[0008] The above description is only a summary of the technical solutions of the present disclosure. In order to more clearly understand the technical means of the present disclosure, the present disclosure can be implemented according to the content of the description, and in order to make the above and other purposes, features and advantages of the present disclosure more obvious and easy to understand, the specific embodiments of the present disclosure are described below. BRIEF DESCRIPTION OF DRAWINGS

[0009] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0010] Figure 1 This is a flowchart illustrating a knowledge graph-based method for identifying anomalies in food safety indicators, as illustrated in one embodiment.

[0011] Figure 2 This is an architecture diagram of a knowledge graph-based food safety indicator anomaly identification system in one embodiment.

[0012] Figure labeling: 11 Safety limit extraction module, 12 Association analysis module, 13 Graph construction module, 14 Safety limit injection module, 15 Recursive detection module, 16 Confidence analysis module. Detailed Implementation

[0013] This application provides a knowledge graph-based method and system for identifying anomalies in food safety indicators, which solves the technical problems of traditional food safety testing relying on a single standard, making it difficult to identify risks in complex production line processes, resulting in fragmented test results and low efficiency in anomaly tracing.

[0014] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of them. All other embodiments obtained by those skilled in the art based on the embodiments of this application without creative effort are within the scope of protection of this application.

[0015] It should be noted that the terms “comprising” and “having”, and any variations thereof, are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or server that includes a series of steps or units is not necessarily limited to those steps or units that are explicitly listed, but may include other steps or modules that are not explicitly listed or that are inherent to such process, method, product, or device.

[0016] Example 1, as Figure 1 As shown, this application provides a method for identifying anomalies in food safety indicators based on knowledge graphs, the method comprising:

[0017] Multiple safety limits for various food safety indicators are extracted from multi-source safety standard texts using a structured approach.

[0018] In the embodiments of the present application, first, food safety standard texts of various sources such as national standards, industry standards, local standards and enterprise internal safety specifications are acquired. These texts usually describe the allowable range of various substances or parameters in food in natural language form, for example, pesticide residues, heavy metal content, microbial limit, food additive dosage, etc. Then, text analysis and semantic recognition technology is used to preprocess the above texts, including word segmentation, part-of-speech tagging, named entity recognition and index keyword extraction, to identify the key description content related to food safety indicators, for example, a certain standard text may stipulate that "the lead content in a certain food shall not exceed 0.5 mg / kg", this information will be extracted as the "lead content" index and associated with the corresponding limit value 0.5 mg / kg. Then, the extracted index and limit value data are summarized to form multiple food safety indicators and corresponding multiple index safety limits, and these food safety indicators, index safety limits and extracted applicable conditions, source standards are structured to form standardized food safety indicator data entries, which can be represented as "index name-limit value type-limit value number-unit-applicable condition-source standard". This provides direct callable knowledge support for subsequent risk node construction, anomaly detection and graph reasoning.

[0019] Table 1: Standardized food safety indicator data entry example table

[0020]

[0021] As shown in Table 1, the standardized food safety indicator data entry example table shows the unified structured data of the limit value type, limit value number, applicable condition and source standard of different food safety indicators, which supports the subsequent risk classification and anomaly identification process.

[0022] Network search is performed to obtain multiple abnormality traceability processing records of the multiple food safety indicators, and correlation analysis of historical abnormal events and production line links is performed to quantitatively output multiple abnormality investigation priority coefficients.

[0023] In one embodiment, first, abnormal records of various food safety indicators in different production batches are obtained through channels such as enterprise internal databases, quality management systems, and industry-shared food safety information platforms, including indicator abnormal values, abnormal times, production line numbers, operation procedures, and corresponding corrective measures, etc. to form multiple abnormal traceability processing records of multiple food safety indicators. Subsequently, based on these abnormal traceability processing records, a mapping relationship between historical abnormal events and production line links is established, and the frequency of each production line link and the indicator abnormal event occurrence, as well as the indicator abnormal record and the corrective measure, is calculated through statistical analysis and classification aggregation. Then, the frequency, indicator abnormal record and corrective measure obtained are multi-dimensionally quantified to generate multiple abnormal investigation priority coefficients. The larger the abnormal investigation priority coefficient is, the greater the possibility and potential harm of the corresponding indicator abnormality of the link, thereby providing a basis for subsequent risk node division and inverted risk identification map construction.

[0024] Further, the present application provides a method for obtaining multiple abnormal traceability processing records of the multiple food safety indicators through network search, performing correlation analysis of historical abnormal events and production line links, and quantitatively outputting multiple abnormal investigation priority coefficients, the method comprising:

[0025] decomposing the first abnormal traceability processing record of the first food safety indicator to obtain multiple deviation processing work orders, wherein each deviation processing work order is composed of an indicator abnormal record, a corrective measure, and a production line responsible procedure; aggregating multiple production line responsible procedures to perform production line link abnormal correlation frequency statistics to obtain M correlation frequencies of M production line links; classifying and aggregating multiple indicator abnormal records and multiple corrective measures of the multiple deviation processing work orders according to the production line link mapping relationship to obtain M groups of indicator abnormal records and M groups of corrective measures; and performing multi-dimensional abnormal quantification based on the M correlation frequencies, M groups of indicator abnormal records, and M groups of corrective measures to output a first abnormal investigation priority coefficient.

[0026] Preferably, first, the first abnormal traceability processing record of the first food safety indicator is extracted from a plurality of abnormal traceability processing records, and the first food safety indicator can be any food safety indicator. Then, the first abnormal traceability processing record is split into a plurality of deviation processing work orders according to record entries, each deviation processing work order containing an indicator abnormal record, a corresponding correction measure, and a production line responsible process, wherein the indicator abnormal record is data that the actual detection value deviates from the standard limit value, such as lead content 0.8 mg / kg, which exceeds the standard limit value 0.5 mg / kg; the correction measure is the operation such as process adjustment, equipment correction, and raw material replacement taken when correcting the deviation; and the production line responsible process is a specific production link or post where the abnormality occurs. Subsequently, the production line responsible processes involved in all deviation processing work orders are aggregated and counted, i.e., the frequency of the same production line link appearing in the deviation processing work order is counted to obtain M production line links and their corresponding M association frequencies, which reflect the risk degree and recurrence probability of the abnormality of each link. Then, according to the mapping relationship of the production line link, the indicator abnormal records and correction measures of the deviation processing work orders under the same production line link are respectively summarized to form M groups of indicator abnormal records and M groups of correction measures, each group of data corresponding to a production line link, facilitating targeted analysis of abnormal characteristics and correction strategies. Finally, the M association frequencies, M groups of indicator abnormal records, and M groups of correction measures are quantified in terms of frequency deviation, severity, and controllability to obtain a first abnormality investigation priority coefficient of the first food safety indicator. The higher the first abnormality investigation priority coefficient, the greater the risk of the first food safety indicator in the corresponding production line link, which should be prioritized for investigation, thereby providing a reliable data basis for subsequent risk node division and inverted risk identification.

[0027] Further, the present application provides a method for multi-dimensional abnormality quantification based on the M association frequencies, M groups of indicator abnormal records, and M groups of correction measures, and outputting a first abnormality investigation priority coefficient, the method comprising:

[0028] mining abnormality distribution association rules of the M groups of indicator abnormal records and M groups of correction measures to obtain M-level abnormality scale intervals and M-level standard correction measures; locating the highest frequency association link among the M association frequencies in descending order of association frequency; extracting a benchmark abnormal value and a benchmark correction measure from the M-level abnormality scale intervals and M-level standard correction measures according to the highest frequency association link; performing multi-dimensional abnormality quantification based on the highest frequency association link, the benchmark abnormal value, and the benchmark correction measure to output the first abnormality investigation priority coefficient, wherein the multi-dimensional abnormality quantification includes frequency deviation quantification, severity quantification, and controllability quantification.

[0029] Optionally, firstly, abnormal distribution association rule mining is performed on the M groups of index abnormal records and the M groups of corrective measures. Specifically, distribution analysis is performed on the abnormal values in each group of index abnormal records, the range of the abnormal values is extracted, that is, the interval in which the abnormal values are mainly concentrated, M-level abnormal scale intervals are formed, and the M groups of corrective measures are statistically summarized, the measure with the highest frequency of occurrence under the same link is analyzed, and the measure is defined as the standard corrective measure of the link, thereby forming M-level standard corrective measures. Subsequently, according to the obtained M production line link correlation frequencies, the frequencies are sorted in descending order, the production line link with the highest abnormal frequency is located, and the link is taken as the highest frequency correlation link, which represents the key link that has the greatest impact on the current index in the historical abnormal data and is the focus of priority investigation. Then, according to the highest frequency correlation link, the corresponding abnormal scale interval and standard corrective measure are extracted from the M-level abnormal scale interval and the M-level standard corrective measure as the benchmark abnormal value and the benchmark corrective measure. Then, based on the highest frequency correlation link, the benchmark abnormal value and the benchmark corrective measure, the index abnormality is quantified in terms of frequency deviation, severity and controllability. For frequency deviation quantification, the correlation frequency of the production line link is subtracted from the average correlation frequency of all production line links for the index abnormality, and then divided by the average correlation frequency to obtain the frequency deviation quantification value. For severity quantification, the absolute difference between each abnormal record of the production line link and the corresponding index standard limit value is calculated, and the calculation result is divided by the limit value to obtain the deviation degree of each abnormal record, and then the deviation degrees are averaged to obtain the severity quantification value. For controllability quantification, the number of successful corrective measures of the benchmark corrective measure is divided by the total number of abnormal times, and then 1 is subtracted from the quotient to obtain the controllability quantification value. Finally, the frequency deviation quantification value, the severity quantification value and the controllability quantification value are weighted and fused to obtain a first abnormality investigation priority coefficient, which provides a reliable data basis for inverted risk identification map construction and subsequent differentiated recursive detection.

[0030] Based on the plurality of abnormality investigation priority coefficients, the plurality of food safety indexes are divided into K-level risk nodes, and an inverted risk identification map is constructed based on the K-level risk nodes.

[0031] In one embodiment, after obtaining the plurality of abnormality investigation priority coefficients, the abnormality investigation priority coefficients are divided by using a percentile split or dynamic segmentation to obtain K-level risk threshold intervals. The plurality of food safety indexes are divided into K-level risk nodes according to the positions of the plurality of abnormality investigation priority coefficients in the K-level risk threshold intervals. The K-level risk nodes are inverted according to their risk conditions, i.e., high-risk nodes are placed at the top of the graph, and low-risk nodes are placed at the bottom of the graph, thereby constructing an inverted risk identification graph. The inverted risk identification graph can help the abnormality detection and investigation work in the production process to proceed hierarchically from high risk to low risk, ensure that the most urgent and serious food safety problems are solved first in limited resources and time, and improve the safety and quality control capability of food production.

[0032] Further, the application provides that, after the plurality of food safety indexes are divided into K-level risk nodes based on the plurality of abnormality investigation priority coefficients, an inverted risk identification graph is constructed based on the K-level risk nodes, including:

[0033] The plurality of abnormality investigation priority coefficients are dynamically divided by using percentile points to obtain K-level risk threshold intervals. The plurality of food safety indexes are mapped to the K-level risk nodes according to the attribution results of the plurality of abnormality investigation priority coefficients in the K-level risk threshold intervals. The K-level risk nodes are inverted in descending order according to the K-level risk threshold intervals, and the inverted risk identification graph is constructed.

[0034] Optionally, first, the abnormality investigation priority coefficients corresponding to all food safety indicators are sorted in ascending order, and three key quantile values of 30%, 70% and 90% are calculated, and then K-level risk threshold intervals are constructed according to the key quantile values, for example, the abnormality investigation priority coefficient ≥ 90% quantile value is the highest risk threshold interval; 70% quantile value ≤ abnormality investigation priority coefficient < 90% quantile value is the higher risk threshold interval; 30% quantile value ≤ abnormality investigation priority coefficient < 70% quantile value is the medium risk threshold interval; and the abnormality investigation priority coefficient < 30% quantile value is the basic risk threshold interval. Then, each abnormality investigation priority coefficient is compared with the K-level risk threshold interval to determine the risk threshold interval to which the abnormality investigation priority coefficient belongs, and the food safety indicators corresponding to the abnormality investigation priority coefficients are mapped to K-level risk nodes, for example, the food safety indicators in the highest risk threshold interval are mapped to L1-level nodes, representing the highest risk; the food safety indicators in the higher risk threshold interval are mapped to L2-level nodes, representing the higher risk; the food safety indicators in the medium risk threshold interval are mapped to L3-level nodes, representing the medium risk; and the food safety indicators in the basic risk threshold interval are mapped to L4-level nodes, representing the basic risk. Then, according to the K-level risk threshold interval, the K-level risk nodes are arranged in descending order, that is, the L1-level nodes are arranged at the top layer of the graph, and then arranged downward to the L4-level nodes. In the inverted risk identification graph, the detection or investigation work is carried out from top to bottom, and when an abnormality occurs in a high-risk node, the detection of part of the low-risk nodes can be skipped, so as to realize the detection strategy of risk priority and rapid positioning, and provide a basis for subsequent hierarchical triggering detection and differential investigation.

[0035] Further, the present application provides that the same layer nodes of the inverted risk identification graph are not forced to be associated, and the abnormality of a child node does not force the risk of a parent node, and the abnormality of a parent node skips the detection of the remaining child nodes.

[0036] Optionally, the inverted risk identification graph is also designed with a triggering rule, which defines the triggering order and dependency relationship of each risk node in the detection process. Specifically, in the inverted risk identification graph, each risk node is arranged hierarchically from top to bottom according to the risk level, but there is no mandatory detection dependency relationship between multiple nodes in the same level, i.e. the nodes in the same layer are triggered independently, and the nodes in the same layer can be detected in parallel or selectively according to the actual detection needs, thereby improving the detection efficiency. At the same time, during the hierarchical triggering process, when an abnormality occurs in a sub-node, it is not necessarily assumed that the parent node is at risk, and only the abnormality of the sub-node is recorded and analyzed as a separate detection result, thereby avoiding misjudgment of the parent node due to the abnormality of the individual sub-node. When the parent node detects an abnormality, it will automatically skip the detection task of the remaining sub-nodes under the jurisdiction of the parent node, and directly enter the detection process of the next parent node or the next level. This is because the abnormality of the parent node is sufficient to indicate that there is a risk in this link, and continuing to detect its sub-nodes will cause waste of resources and redundant operations. Through the design of the above triggering rule, the inverted risk identification graph can optimize the detection order and logic while ensuring the integrity of the detection, reduce unnecessary repeated detection, improve the efficiency and accuracy of the overall detection, and achieve efficient hierarchical identification and dynamic response to food safety risks.

[0037] The plurality of index safety limit values are injected into the inverted risk identification graph as a knowledge base.

[0038] In one embodiment, according to the plurality of food safety index safety limit values structuredly extracted from the multi-source safety standard texts, a limit value data model oriented to a knowledge graph is constructed, the index limit values are semantically bound to the risk nodes in the inverted risk identification graph as attribute nodes, forming a knowledge mapping relationship between the risk nodes and the index limit values, for example, a risk node corresponding to a certain heavy metal content index is associated with its maximum allowable residue amount and related standard document index, so that the risk node can directly call the corresponding limit value information for judgment when triggered for detection, and the bound index safety limit values are injected into the corresponding nodes in the inverted risk identification graph as a knowledge base according to the knowledge mapping relationship, and the traceable limit value version information is retained in the graph. In this way, the inverted risk identification graph can not only intuitively display the hierarchical relationship between different risk nodes, but also call the corresponding safety limit values for accurate comparison when triggered for detection, thereby realizing the automation and standardization of risk identification and providing an executable knowledge base for subsequent small-batch recursive detection and cross-sample clustering analysis.

[0039] The inverted risk identification graph is triggered hierarchically for differential recursive detection of small-batch trial production food, and a batch detection defect vector set is obtained.

[0040] In one embodiment, when detecting the small-batch trial production food, the inverted risk identification graph is hierarchically triggered. In this process, the L1 level node in the highest risk level of the graph is triggered first to detect the first batch of trial production food. If an abnormality is shown, the abnormal value is immediately recorded, and the corresponding defect item is generated, and the subsequent detection of the batch food in L2 and below is suspended to avoid redundant operations. When the L1 node detection result is normal, the L2 node detection is recursively entered, and the hierarchical recursion is triggered downward, until an abnormality occurs or all levels are traversed, so as to obtain the final batch detection defect vector set. The batch detection defect vector set completely depicts the abnormal distribution of each batch of food under different risk levels, not only reflects the detection result of a single batch, but also provides a quantifiable data basis for subsequent cross-sample clustering analysis, common defect link identification and confidence reasoning, and improves the efficiency and pertinence of small-batch trial production food safety risk detection.

[0041] Further, the application provides a hierarchical triggering of the inverted risk identification graph for differential recursive detection of small-batch trial production food to obtain a batch detection defect vector set, the method comprising:

[0042] Starting the detection of the L1 level node in the inverted risk identification graph on the first trial production food, wherein the L1 level node discriminates abnormality according to the L1 level index safety limit value; if any node in the L1 level node detects an abnormality, the first index abnormal value is recorded, and the subsequent detection of the first trial production food is stopped; if the L1 level node detection is normal, the L2 level node detection is recursively executed until the inverted risk identification graph is traversed or an abnormality is detected; the obtained multiple index abnormal values are aggregated to construct a first batch detection defect vector; the inverted risk identification graph is hierarchically triggered for differential recursive detection of small-batch trial production food to obtain multiple batch detection defect vectors, which constitute the batch detection defect vector set.

[0043] Optionally, first, for the first batch of trial production food, the L1 node detection of the highest risk level in the inverted risk identification map is started, each L1 node will call its associated index safety limit value to detect the corresponding food safety index, and determine whether there is an abnormality. If any node in the L1 node detects an abnormality, the abnormal value of the index corresponding to the node is immediately recorded, and the detection of the batch at the L2 and below level nodes is stopped to avoid redundant detection operation and ensure that resources are concentrated for high-risk abnormality processing. If the L1 node detection is all normal, the L2 node is recursively propagated, and the detection is triggered layer by layer according to the hierarchical order from top to bottom of the map. The recursive detection process will continue to be executed until the entire inverted risk identification map is traversed or an abnormality is found in any node. At each triggered node, abnormality determination will be made according to the index safety limit value associated with the node, and the abnormal value will be recorded. After completing the whole process detection of the first batch, all index abnormal values recorded in each level detection of the batch are aggregated to form the detection defect vector of the first batch, each dimension in the vector corresponds to a detected index and its abnormal state and value information. Subsequently, according to the same hierarchical recursive detection process, the subsequent small batch of trial production food is detected by analogy, and the detection defect vectors of each batch are constructed batch by batch, and finally all batch defect vectors are integrated to form a complete batch detection defect vector set, which provides a data basis for subsequent cross-sample clustering analysis, common defect link identification and confidence analysis.

[0044] Further, the application provides that the method further comprises:

[0045] Based on the knowledge graph associated storage solution, the first food safety index, M-level abnormality scale interval, M kinds of production line links and M-level standard correction measures are stored as the first root cause positioning engine; a plurality of root cause positioning engines of the plurality of food safety indexes are constructed by analogy; and the plurality of root cause positioning engines are connected in parallel to construct a cross-sample root cause positioning model.

[0046] Optionally, for the first food safety indicator, the M-level abnormality scale interval associated with it, the M kinds of production line links corresponding to it and the M-level standard correction measures are integrated and stored in the knowledge graph to form a root cause positioning engine of the indicator. Through this root cause positioning engine, when the indicator appears abnormal in subsequent detection, the possible production line link can be quickly located and the applicable standard correction measures can be matched to support dynamic reasoning and decision-making. Subsequently, for multiple food safety indicators, multiple root cause positioning engines are constructed according to the same method. Each root cause positioning engine independently processes the abnormality identification, production line link mapping and correction measure recommendation of its corresponding indicator to ensure that the abnormality analysis of each indicator is targeted and traceable. Finally, the multiple root cause positioning engines are integrated in parallel to construct a cross-sample root cause positioning model. This cross-sample root cause positioning model can uniformly analyze any indicator abnormality in the batch detection defect vector set, match each indicator abnormality in its corresponding root cause positioning engine, identify potential common defect production line links and standard correction measures, and thus support cross-batch and cross-sample root cause positioning.

[0047] After performing cross-sample clustering analysis on the batch detection defect vector set to obtain N common defect links, confidence analysis is performed on the N common defect links to generate a fault hypothesis set and a confidence probability set.

[0048] In one embodiment, after obtaining the batch detection defect vector set, the batch detection defect vector set is input into the cross-sample root cause positioning model for abnormality scale interval matching. The matching results are then aggregated to obtain N common defect links, which are defined as the fault hypothesis set. Subsequently, confidence analysis is performed on the N common defect links identified according to the defect recurrence frequency to quantify the credibility of each defect link causing abnormality, thereby forming a corresponding confidence probability set. The higher the confidence probability, the greater the likelihood of repeated abnormality of the link in multiple batches.

[0049] Further, the present application provides that after performing cross-sample clustering analysis on the batch detection defect vector set to obtain N common defect links, confidence analysis is performed on the N common defect links to generate a fault hypothesis set and a confidence probability set. The method comprises:

[0050] load the first batch of detection defect vectors into the cross-sample root cause positioning model, perform abnormal scale interval matching, output a first associated failure production line set and a first standard correction measure set; analogously, perform abnormal scale interval matching on the batch of detection defect vectors set using the cross-sample root cause positioning model to obtain a batch of associated failure production line sets and a batch of standard correction measure sets; aggregate the batch of associated failure production line sets to obtain the N common defect links and N defect recurrence frequencies, and take the N common defect links as the failure hypothesis set; and quantize the N defect recurrence frequencies to construct the confidence probability set.

[0051] Optionally, first, the detection defect vectors of the first batch are loaded into the cross-sample root cause positioning model, and the model matches the abnormal value of each index with the corresponding M-level abnormal scale interval to determine which production line link may cause the abnormality, and simultaneously matches the standard correction measure corresponding to the link to generate a first associated failure production line set and a first standard correction measure set. Subsequently, the detection defect vectors of subsequent batches are sequentially loaded into the cross-sample root cause positioning model, and the abnormal scale interval matching is repeatedly performed to obtain the associated failure production line sets of each batch and the corresponding standard correction measure sets. Then, the associated failure production line sets of all batches are aggregated and counted to count the frequency of abnormal occurrence of each production line link in different batches. Through counting, N common defect links, i.e., key links that repeatedly appear abnormally in multiple batches, are identified, and are taken as the failure hypothesis set. At the same time, the recurrence frequency of each common defect link is recorded for subsequent quantitative analysis. Finally, for the N defect recurrence frequencies, each defect recurrence frequency is divided by the total defect recurrence frequency to obtain the confidence probability of each common defect link, thereby forming a confidence probability set. These confidence probabilities reflect the possibility of abnormal recurrence of each common defect link in all batches. The higher the confidence probability, the greater the credibility of the link causing the abnormality, thereby providing quantifiable data support for subsequent risk priority ranking, correction measure deployment, and production line optimization.

[0052] Further, after the P common correction measures are obtained by aggregating the batch of standard correction measures sets, a production line dynamic optimization strategy is deployed based on the P common correction measures.

[0053] Optionally, after obtaining the batch standard correction measure set, the repeatedly occurring standard correction measures are classified and aggregated to remove redundant information, and P common correction measures are generated, each of which corresponds to a recommended operation strategy for a specific abnormal type or production line link, such as process adjustment, equipment correction, raw material replacement, or process parameter optimization. Subsequently, based on the P common correction measures, combined with the real-time running data and historical abnormal distribution of the production line, a dynamic optimization strategy is automatically formulated, in which each common correction measure is mapped to the production line link it affects, and the abnormal frequency, severity, and controllability indicators are prioritized. Then, according to the sorting results, the production line dynamic optimization strategy is generated, such as adjusting high-risk links first, adding detection or preventive maintenance for frequently abnormal nodes, and performing routine monitoring for low-risk links. Through this process, the production line dynamic optimization strategy can flexibly adjust the production operation under the premise of ensuring food safety, achieve the balance between abnormal prevention and control and production efficiency, and ensure that the risks in the food production process are controlled and improved in real time.

[0054] In summary, the embodiments of the present application have at least the following technical effects:

[0055] The embodiments of the present application first extract a plurality of index safety limits of a plurality of food safety indicators from a plurality of source safety standard texts; then, network search is performed to obtain a plurality of abnormal traceability processing records of the plurality of food safety indicators, and correlation analysis of historical abnormal events and production line links is performed to quantitatively output a plurality of abnormal investigation priority coefficients; then, based on the plurality of abnormal investigation priority coefficients, the plurality of food safety indicators are divided into K-level risk nodes, and an inverted risk identification graph is constructed based on the K-level risk nodes; further, the plurality of index safety limits are injected into the inverted risk identification graph as a knowledge base; then, the inverted risk identification graph is triggered for differential recursive detection of small-batch trial production food, and a batch detection defect vector set is obtained; finally, cross-sample clustering analysis is performed on the batch detection defect vector set, N common defect links are obtained, and confidence analysis of the N common defect links is performed to generate a fault hypothesis set and a confidence probability set. These technical effects collectively solve the technical problems of traditional food safety detection relying on a single standard, being difficult to identify risks for complex production line links, resulting in fragmented detection results and low abnormal traceability efficiency, and achieve the technical effects of realizing multi-source standard fusion, abnormal risk grading, and defect traceability analysis through a knowledge graph, improving the comprehensiveness of food safety indicator abnormal identification and the efficiency of traceability.

[0056] Embodiment two, based on the same inventive concept as the food safety indicator abnormal identification method based on a knowledge graph in the foregoing embodiments, such as Figure 2As shown, the present application provides a food safety index anomaly identification system based on a knowledge graph, which comprises: a safety limit value extraction module 11: structuredly extracting multiple index safety limit values of multiple food safety indexes from multiple source safety standard texts; an association analysis module 12: obtaining multiple abnormal traceability processing records of the multiple food safety indexes through network search, performing association analysis of historical abnormal events and production line links, and quantitatively outputting multiple abnormal investigation priority coefficients; a graph construction module 13: after dividing the multiple food safety indexes into K-level risk nodes based on the multiple abnormal investigation priority coefficients, constructing an inverted risk identification graph based on the K-level risk nodes; a safety limit value injection module 14: injecting the multiple index safety limit values into the inverted risk identification graph as a knowledge base support; a recursive detection module 15: hierarchically triggering the inverted risk identification graph to perform differential recursive detection on small-batch trial production food, and obtaining a batch detection defect vector set; a confidence analysis module 16: after performing cross-sample clustering analysis on the batch detection defect vector set to obtain N common defect links, performing confidence analysis on the N common defect links, and generating a fault hypothesis set and a confidence probability set.

[0057] Further, the association analysis module 12 is further used to execute the following method:

[0058] decomposing a first abnormal traceability processing record of a first food safety index to obtain multiple deviation processing work orders, wherein each deviation processing work order is composed of an index abnormal record, a correction measure and a production line responsibility process; aggregating multiple production line responsibility processes to perform production line link abnormal association frequency statistics to obtain M association frequencies of M production line links; according to a production line link mapping relationship, classifying and aggregating multiple index abnormal records and multiple correction measures of the multiple deviation processing work orders to obtain M groups of index abnormal records and M groups of correction measures; performing multi-dimensional abnormal quantification based on the M association frequencies, M groups of index abnormal records and M groups of correction measures to output a first abnormal investigation priority coefficient.

[0059] Further, the association analysis module 12 is further used to execute the following method:

[0060] mining abnormal distribution association rules of the M groups of index abnormal records and the M groups of correction measures to obtain M-level abnormal scale intervals and M-level standard correction measures; positioning a highest frequency association link in the M association frequencies in descending order of association frequency; extracting a reference abnormal value and a reference correction measure from the M-level abnormal scale intervals and the M-level standard correction measures according to the highest frequency association link; performing multi-dimensional abnormal quantification based on the highest frequency association link, the reference abnormal value and the reference correction measure to output the first abnormal investigation priority coefficient, wherein the multi-dimensional abnormal quantification includes frequency deviation quantification, severity quantification and controllability quantification.

[0061] Further, the graph construction module 13 is further configured to perform the following method:

[0062] The plurality of anomaly investigation priority coefficients are dynamically divided according to the percentile points to obtain K-level risk threshold intervals; the plurality of food safety indicators are mapped to the K-level risk nodes according to the attribution results of the plurality of anomaly investigation priority coefficients in the K-level risk threshold intervals; and the K-level risk threshold intervals are used to perform descending inversion of the K-level risk nodes to construct the inverted risk identification graph.

[0063] Further, the graph construction module 13 is further configured to perform the following method:

[0064] The nodes in the same layer of the inverted risk identification graph are not forced to be associated, and the abnormality of a child node does not force the risk of a parent node, and the abnormality of a parent node skips the detection of the remaining child nodes.

[0065] Further, the recursive detection module 15 is further configured to perform the following method:

[0066] The L1-level nodes in the inverted risk identification graph are started to detect the first trial production food, wherein the L1-level nodes are used to determine the abnormality according to the L1-level index safety limit value; if any node in the L1-level nodes detects an abnormality, the first index abnormal value is recorded, and the subsequent detection of the first trial production food is stopped; if the L1-level nodes detect normally, the detection is recursively performed to the L2-level nodes, and the recursive detection is performed until the inverted risk identification graph is traversed or an abnormality is detected; and the plurality of index abnormal values are aggregated to construct a first batch detection defect vector; and the inverted risk identification graph is triggered to perform the differentiated recursive detection of the small-batch trial production food according to the hierarchical triggering, and a plurality of batch detection defect vectors are obtained to form a batch detection defect vector set.

[0067] Further, the recursive detection module 15 is further configured to perform the following method:

[0068] The first food safety indicator, the M-level abnormality scale interval, the M kinds of production line links, and the M-level standard correction measures are stored and solved based on the knowledge graph as a first root cause positioning engine; a plurality of root cause positioning engines of the plurality of food safety indicators are constructed by analogy; and the plurality of root cause positioning engines are connected in parallel to construct a cross-sample root cause positioning model.

[0069] Further, the confidence analysis module 16 is further configured to perform the following method:

[0070] The first batch of detection defect vectors are loaded into the cross-sample root cause positioning model, and abnormal scale interval matching is performed, and a first associated failure production line set and a first standard correction measure set are output; the cross-sample root cause positioning model is used to perform abnormal scale interval matching on the batch of detection defect vectors, and a batch of associated failure production line sets and a batch of standard correction measure sets are obtained; the batch of associated failure production line sets are aggregated to obtain the N common defect links and N defect recurrence frequencies, and the N common defect links are taken as the failure hypothesis set; the N defect recurrence frequencies are quantified to construct the confidence probability set.

[0071] Further, the confidence analysis module 16 is also used to execute the following method:

[0072] After aggregating the batch of standard correction measure sets to obtain P common correction measures, a production line dynamic optimization strategy is deployed based on the P common correction measures.

[0073] It should be noted that the above-mentioned sequence of the embodiments of the present application is only for description, and does not represent the advantages and disadvantages of the embodiments. The above describes a specific embodiment of the present application. The processes depicted in the drawings do not necessarily require the specific order and continuous order shown to achieve the desired results. In some embodiments, multi-task processing and parallel processing are also possible or can be advantageous.

[0074] The above only describes the preferred embodiments of the present application and does not limit the present application. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the protection scope of the present application.

[0075] The present application is only an exemplary description of the present application, and should be considered to cover any and all modifications, changes, combinations or equivalents within the scope of the present application. Obviously, those skilled in the art can make various modifications and changes to the present application without departing from the scope of the present application. Thus, if these modifications and changes of the present application belong to the scope of the present application and its equivalents, the present application intends to include these modifications and changes.

Claims

1. A food safety index anomaly identification method based on a knowledge graph, characterized in that, The method comprises: extracting multiple index safety limits of multiple food safety indicators from multi-source safety standard text structure; networking to retrieve multiple abnormal traceability processing records of the multiple food safety indicators, performing correlation analysis of historical abnormal events and production line links, and quantitatively outputting multiple abnormal investigation priority coefficients; After dividing the multiple food safety indicators into K-level risk nodes based on the multiple abnormal investigation priority coefficients, an inverted risk identification graph is constructed based on the K-level risk nodes; The multiple index safety limits are injected into the inverted risk identification graph as a knowledge base; Hierarchical triggering of the inverted risk identification graph for differential recursive detection of small-batch trial production food obtains a batch detection defect vector set; After cross-sample clustering analysis of the batch detection defect vector set obtains N common defect links, confidence analysis of the N common defect links is performed to generate a fault hypothesis set and a confidence probability set; networking to retrieve multiple abnormal traceability processing records of the multiple food safety indicators, performing correlation analysis of historical abnormal events and production line links, and quantitatively outputting multiple abnormal investigation priority coefficients, the method comprising: decompose the first abnormal traceability processing record of the first food safety indicator to obtain multiple deviation processing work orders, wherein each deviation processing work order is composed of an index abnormal record, a correction measure and a production line responsibility process; aggregate multiple production line responsibility processes to perform production line link abnormal correlation frequency statistics to obtain M correlation frequencies of M production line links; According to the mapping relationship between the production line links, the multiple index abnormal records and the multiple correction measures of the multiple deviation processing work orders are classified and aggregated to obtain M groups of index abnormal records and M groups of correction measures; Based on the M correlation frequencies, M groups of index abnormal records and M groups of correction measures, multi-dimensional abnormal quantification is performed to output a first abnormal investigation priority coefficient. 2.The knowledge graph-based food safety indicator anomaly identification method of claim 1, wherein, Based on the M correlation frequencies, M groups of index abnormal records and M groups of correction measures, multi-dimensional abnormal quantification is performed to output a first abnormal investigation priority coefficient, the method comprising: Abnormal distribution association rule mining is performed on the M groups of index abnormal records and M groups of correction measures to obtain M-level abnormal scale intervals and M-level standard correction measures; According to the highest frequency correlation link located in the M correlation frequencies in descending order of correlation frequency; According to the highest frequency correlation link, the reference abnormal value and the reference correction measure are extracted from the M-level abnormal scale interval and the M-level standard correction measure; Based on the highest frequency correlation link, the reference abnormal value and the reference correction measure, multi-dimensional abnormal quantification is performed to output the first abnormal investigation priority coefficient, wherein the multi-dimensional abnormal quantification includes frequency deviation quantification, severity quantification and controllability quantification. 3.The knowledge graph-based food safety indicator anomaly identification method of claim 2, wherein, After dividing the multiple food safety indicators into K-level risk nodes based on the multiple abnormal investigation priority coefficients, an inverted risk identification graph is constructed based on the K-level risk nodes, the method comprising: According to the multiple abnormal investigation priority coefficients, K-level risk threshold intervals are obtained by dynamically dividing the multiple abnormal investigation priority coefficients according to percentile points; mapping the plurality of food safety indicators to the K-level risk nodes according to the belonging results of the plurality of anomaly investigation priority coefficients in the K-level risk threshold intervals; performing descending inversion of the K-level risk nodes according to the K-level risk threshold intervals to construct the inverted risk identification graph. 4.The knowledge graph-based food safety indicator anomaly identification method of claim 3, wherein, The same layer nodes of the inverted risk identification graph are not forced to be associated, and the abnormality of a child node does not force the risk of a parent node, and the abnormality of a parent node skips the detection of the remaining child nodes. 5.The knowledge graph based food safety indicator anomaly identification method of claim 3, wherein, The hierarchical triggering of the inverted risk identification graph is used for differential recursive detection of small-batch trial production food to obtain a batch detection defect vector set, and the method comprises: starting detection of the L1-level nodes in the inverted risk identification graph on a first trial production food, wherein the L1-level nodes determine abnormalities according to L1-level indicator safety limits; if any node in the L1-level nodes detects an abnormality, recording the first indicator abnormal value and stopping the subsequent detection of the first trial production food; if the L1-level nodes detect normally, recursively detecting the L2-level nodes, and recursively executing until the inverted risk identification graph is traversed or an abnormality is detected; aggregating the obtained plurality of indicator abnormal values to construct a first batch detection defect vector; by analogy, hierarchical triggering of the inverted risk identification graph is used for differential recursive detection of small-batch trial production food to obtain a plurality of batch detection defect vectors to form the batch detection defect vector set. 6.The knowledge graph-based food safety indicator anomaly identification method of claim 5, wherein, The method further comprises: storing the first food safety indicator, M-level abnormality scale interval, M production line links, and M-level standard corrective measures based on the knowledge graph as a first root cause positioning engine; by analogy, a plurality of root cause positioning engines of the plurality of food safety indicators are constructed; parallel connection of the plurality of root cause positioning engines to construct a cross-sample root cause positioning model. 7.The knowledge graph-based food safety indicator anomaly identification method of claim 6, wherein, After performing cross-sample clustering analysis on the batch detection defect vector set to obtain N common defect links, confidence analysis is performed on the N common defect links to generate a fault hypothesis set and a confidence probability set, and the method comprises: loading the first batch detection defect vector into the cross-sample root cause positioning model to perform abnormality scale interval matching, outputting a first associated fault production line set and a first standard corrective measure set; by analogy, the cross-sample root cause positioning model is used to perform abnormality scale interval matching on the batch detection defect vector set to obtain a batch associated fault production line set and a batch standard corrective measure set; aggregating the batch associated fault production line set to obtain the N common defect links and N defect recurrence frequencies, and taking the N common defect links as the fault hypothesis set; quantifying the N defect recurrence frequencies to construct the confidence probability set. 8.The knowledge graph based food safety indicator anomaly identification method of claim 7, wherein, After aggregating the batch standard corrective measure set to obtain P common corrective measures, a production line dynamic optimization strategy is deployed based on the P common corrective measures.

9. A food safety index anomaly identification system based on a knowledge graph, characterized by, The system is used to execute the food safety indicator anomaly identification method based on the knowledge graph according to any one of claims 1-8, and the system comprises: a safety limit value extraction module: structured extraction of a plurality of indicator safety limit values of a plurality of food safety indicators from a plurality of source safety standard texts; The correlation analysis module: network search obtains a plurality of abnormal traceability processing records of a plurality of food safety indexes, carries out correlation analysis of historical abnormal events and production line links, and quantitatively outputs a plurality of abnormal investigation priority coefficients; The graph construction module: based on the plurality of abnormal investigation priority coefficients, the plurality of food safety indexes are divided into K-level risk nodes, and then an inverted risk identification graph is constructed based on the K-level risk nodes; The safety limit injection module: the plurality of index safety limits are injected into the inverted risk identification graph as a knowledge base; The recursive detection module: hierarchical triggering of the inverted risk identification graph for differential recursive detection of small-batch trial production food, obtaining a batch detection defect vector set; The confidence analysis module: cross-sample clustering analysis is performed on the batch detection defect vector set, N common defect links are obtained, confidence analysis of the N common defect links is performed, a fault hypothesis set and a confidence probability set are generated.

Citation Information

Patent Citations

  • Multi-source knowledge processing and querying method and device, equipment and medium

    CN120197681A

  • Food package fault monitoring method and system

    CN120541554A