Visual system for real-time quality control based on patient data

CN122802559APending Publication Date: 2026-09-22SHANGHAI KUNLAI BIOLOGICAL TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611296219.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-25
Publication Date
2026-09-22

AI Technical Summary

Technical Problem

[0005]针对现有技术的不足,本发明提供了基于患者数据的实时质量控制的可视化系统,解决了现有临床检验分析设备在运行过程中缺乏对样本检测数据的实时监测与拦截机制,导致电极模块发生基线漂移或极性异常时无法及时触发前端硬件动作,进而引发后续光学模块进行无效吸样、造成试剂消耗,且容易使错误检验结果流入实验室信息系统的问题

Benefits of technology

[0029]1.本发明通过缓冲网关截获测量结果报文,提取电极模块的测量信号计算电中性校验量。当校验量小于下限校验阈值时,缓冲网关执行算法熔断并生成拦截指令,使执行单元在光学模块吸样前控制管路执行排空和冲洗。该机制利用检测模块间的时间差,在设备运行阶段直接阻断异常样本的处理流程,避免了光学模块进行无效的样本吸取与试剂消耗,从源头防止错误检验结果流入信息系统。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122802559A_ABST
    Figure CN122802559A_ABST
Patent Text Reader

Abstract

The present application relates to the field of clinical test data processing, and discloses a real-time quality control visualization system based on patient data, comprising an information system, an analysis device, a buffer gateway, an execution unit and a display terminal.The analysis device detects patient sample output measurement result messages; the buffer gateway intercepts the messages, extracts electrode module signals to generate an electrical neutral check quantity, and generates an interception instruction when the check quantity is below a lower limit check threshold; the execution unit receives the interception instruction before the optical module samples, and issues emptying and flushing instructions; the information system extracts measurement signals to calculate single item Z scores and comprehensive Z scores; and the display terminal converts the Z scores into visual threshold encodings and renders them in a matrix grid divided into an upper triangular region and a lower triangular region.By intercepting abnormal samples based on early measurement signals during the sampling stage, the system avoids invalid reagent consumption, and uses a double triangular matrix grid to intuitively display the deviation state of multidimensional quality control data.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of clinical laboratory data processing, specifically a visualization system for real-time quality control based on patient data. Background Technology

[0002] In routine quality control, medical laboratories, in addition to using external quality control materials for intermittent sampling and statistical analysis, have also introduced real-time quality control technology based on patient data. This technology directly uses the test results of patient samples as a source of quality control data to achieve continuous monitoring of the testing process. Existing processing methods mainly include direct statistical methods and regression residual methods. The former observes trend changes by calculating statistical measures such as the moving mean or median of test results from consecutive batches of patients, while the latter establishes a time-series regression model and extracts the residuals between predicted and actual values ​​to assess the quality control status.

[0003] The aforementioned conventional data-driven modeling methods have limitations in practical applications. Clinical sample data often exhibits autocorrelation effects, and to meet the robustness requirements of the central limit theorem or regression model, the system typically needs to perform data filtering on the raw test results. This filtering mechanism not only disrupts the complete monitoring of patient data but also easily eliminates biased data reflecting actual hardware malfunctions. Furthermore, this purely algorithmic, post-hoc analysis mechanism cannot synchronously intervene in the hardware's operational process when core physical modules such as electrodes malfunction. This results in subsequent optical modules continuing to perform ineffective sampling and measurement operations on abnormal samples, leading to wasted testing reagents, and distorted data easily flowing into the information system.

[0004] Existing real-time quality control systems lack depth in visualizing multidimensional data. Since algorithm outputs are often presented as conventional numerical lists, when multiple tests generate quality control data simultaneously, operators struggle to intuitively grasp the correlation between individual indicator deviations and overall system deviations from the basic interface. This hinders quick assessment of the underlying testing system's status and increases the difficulty of routine maintenance and troubleshooting. Therefore, this invention provides a real-time quality control visualization system based on patient data to address the shortcomings of existing technologies. Summary of the Invention

[0005] To address the shortcomings of existing technologies, this invention provides a visualization system for real-time quality control based on patient data. This system solves the problem that existing clinical laboratory analysis equipment lacks a real-time monitoring and interception mechanism for sample test data during operation. This results in the inability to trigger front-end hardware actions in a timely manner when the electrode module experiences baseline drift or polarity abnormalities, leading to invalid sample aspiration by the subsequent optical module, reagent consumption, and the easy influx of erroneous test results into the laboratory information system.

[0006] To achieve the above objectives, the present invention provides the following technical solution:

[0007] The first aspect of this invention provides a real-time quality control visualization system based on patient data, comprising an information system, an analysis device, a buffer gateway, an execution unit, and a display terminal. The analysis device includes an electrode module and an optical module for detecting the electrolyte concentration of patient samples and outputting measurement result messages.

[0008] The buffer gateway is located between the analysis device and the information system; the buffer gateway's memory stores a lower limit verification threshold; the buffer gateway is used to intercept the measurement result message, establish a buffer in the memory to perform timing alignment, and extract the measurement signal of the electrode module to generate an electrical neutrality check quantity; when the electrical neutrality check quantity is less than the lower limit verification threshold, the buffer gateway is used to execute an algorithmic circuit breaker, generate a sample-level interception flag and an interception command; the buffer gateway is communicatively connected to the execution unit and is used to send the interception command to the execution unit.

[0009] The information system is used to extract the aligned measurement signals to calculate the individual Z-scores of the patient samples, and to calculate the comprehensive Z-scores of the patient samples by combining the weighting factors of each ion.

[0010] The execution unit is used to control the pipeline to distribute samples to the electrode module, so that the sampling action of the optical module is delayed relative to the measurement action of the electrode module, so as to form a time window for receiving the interception command, and to receive the interception command before the optical module samples, and issue emptying and rinsing commands.

[0011] The display terminal is connected to the information system and is used to convert the single-item Z-score and the comprehensive Z-score into visual threshold codes and generate a two-dimensional matrix interface; the grid of the two-dimensional matrix interface is divided into an upper triangular area and a lower triangular area; the display terminal is used to render the visual threshold codes in the upper triangular area and the lower triangular area, and to distinguish and display the intercepted patient samples according to the sample-level interception flag.

[0012] In the technical solution of this invention, a buffer gateway is introduced as an independent control layer between the device interaction and the information system. The system utilizes the physical characteristics of electrolytes maintaining physiological electroneutrality to extract the measurement signals preferentially output by the electrode module to construct verification conditions. Before the optical module initiates the sampling action, the buffer gateway completes the polarity offset determination and uses the time difference to generate a hardware-level interrupt command, which is then sent to the execution unit. This control mechanism moves the traditional post-event data quality control to pre-event sample injection interception during device operation, blocking the spread of abnormalities from the fluid pipeline end. Simultaneously, the display terminal, through the mapping setting of a two-dimensional matrix grid and double-triangular regions, integrates single-item deviations and multi-item comprehensive deviations within a single grid, replacing data lists with visual threshold encoding to achieve an intuitive presentation of the multi-dimensional quality control status.

[0013] Furthermore, the buffer gateway uses the device number, patient sample identifier, medical order number, test item code, message sequence number, and timestamp as index fields. The buffer gateway is used to write the sodium ion signal, chloride ion signal, and bicarbonate ion signal corresponding to the same patient sample into the cache unit to perform the timing alignment. When the cache unit does not receive the bicarbonate ion signal within the asynchronous alignment waiting time, the buffer gateway generates a timeout flag. This mechanism ensures that messages asynchronously output across modules are aligned on the same timeline, preventing misaligned data from participating in subsequent calculations.

[0014] Furthermore, the buffer gateway is used to clear the buffer waiting queue corresponding to the patient sample when the algorithm circuit breaker is executed; the buffer gateway is used to terminate the waiting for subsequent optical module colorimetric data and discard the intercepted electrode module data packets; the buffer gateway is used to write the sample-level interception flag into the memory and send an abnormal event message to the information system; the information system is used to prohibit the measurement result message from participating in baseline maintenance after receiving the abnormal event message. This mechanism performs isolation at the data end while triggering hardware interception, preventing abnormal sample data from being mixed into the baseline parameter model and affecting the historical mean.

[0015] Furthermore, the electroneutrality check is the concentration difference between sodium ion concentration and chloride ion concentration in the patient's serum sample; the buffer gateway is used to compare the concentration difference with the lower limit check threshold; when the concentration difference is less than the lower limit check threshold, the buffer gateway is used to determine that the patient sample has triggered a polarity shift.

[0016] Furthermore, the information system stores a baseline parameter model; the baseline parameter model includes the mean of one-dimensional features, the standard deviation of one-dimensional features, a medical association weight mapping table, a comprehensive mean, and a comprehensive standard deviation of historical samples; the information system is used to calculate the single-item Z-score using the mean of one-dimensional features and the standard deviation of one-dimensional features; the information system is used to calculate the comprehensive Z-score using the medical association weight factors corresponding to the gaps between sodium ions, chloride ions, bicarbonate ions, and anions, as well as the comprehensive mean and the comprehensive standard deviation.

[0017] Furthermore, the execution unit extends the reagent aspiration and sample dispensing actions of the optical module by creating an optical delay waiting time. This optical delay waiting time is the sum of the electrode measurement time, buffer gateway calculation time, control message transmission time, and execution unit mechanical response time. The system uses this time window to ensure that interception is determined before the sample dispensing probe contacts the sample.

[0018] Furthermore, the buffer gateway is connected to the execution unit via an independent control bypass; the buffer gateway is used to send a hardware interrupt signal to the execution unit when the interception command is generated; the execution unit is used to receive the interception command during the period when the optical module is in the optical delay waiting time, and cancel the reagent aspiration action and sample drop action of the optical module; the execution unit is used to control the sample dispensing mechanism to move to the washing pool to empty the residual patient sample in the probe, and start the liquid circuit system to perform flushing under hydraulic pressure of 0.15MPa to 0.2MPa.

[0019] Furthermore, the X-axis of the two-dimensional matrix interface represents the patient sample sequence, and the Y-axis represents the detection items; the detection items include three directly measured dimensions: sodium ions, chloride ions, and bicarbonate ions; the upper triangular area is filled with the visual threshold coding color corresponding to the Z-score of the single item; the lower triangular area is filled with the visual threshold coding color corresponding to the comprehensive Z-score, and the visual coding includes the first to sixth visual codes.

[0020] Furthermore, the display terminal is used to read the abnormal event message uploaded by the buffer gateway and the sample-level interception flag bit through the information system; for patient samples that trigger the algorithm's circuit breaker, the display terminal is used to retrieve the interception reason code in the abnormal event message to generate a degradation mask, and render the grid of the two-dimensional matrix interface corresponding to the patient sample as a solid grayscale mask or a grayscale mask with diagonal texture. Through mask rendering, the interface can independently identify the intercepted data, preventing operators from misreading it.

[0021] Furthermore, the information system is used to extract the visual threshold code in the two-dimensional matrix interface to perform continuous offset determination; when the visual threshold code corresponding to the comprehensive Z score reaches the fifth level visual threshold code or the sixth level visual threshold code in three consecutive patient samples, the information system is used to issue a degradation scheduling instruction to the analysis device.

[0022] A second aspect of the present invention provides a real-time quality control visualization method based on patient data, applied to the visualization system described in any one of the first aspects above, comprising the following steps:

[0023] The device analyzes the electrolyte concentration of patient samples using the electrode and optical modules and outputs measurement result reports.

[0024] The buffer gateway establishes a buffer in the memory, intercepts the measurement result message to perform timing alignment, calculates the electrical neutrality check quantity based on the measurement signal of the electrode module, and when it is determined that the electrical neutrality check quantity is less than the lower limit check threshold, it executes the algorithm to generate a sample-level interception flag and an interception instruction, and sends the interception instruction to the execution unit.

[0025] The information system extracts the Z-score of each item based on the aligned measurement signal, and calculates the comprehensive Z-score by combining the weighting factors of each ion.

[0026] The execution unit controls the pipeline to distribute samples to the electrode module, delaying the sampling action of the optical module relative to the measurement action of the electrode module, so as to form a time window for receiving the interception command, and receiving the interception command before the optical module samples, and issuing emptying and rinsing commands.

[0027] The display terminal converts the single-item Z-score and the comprehensive Z-score into visual threshold codes, generates a two-dimensional matrix interface based on the visual threshold codes, renders the visual threshold codes within a grid divided into upper and lower triangular areas, and distinguishes and displays the intercepted patient samples based on the sample-level interception flag.

[0028] This invention provides a visualization system for real-time quality control based on patient data. It has the following beneficial effects:

[0029] 1. This invention intercepts measurement result messages through a buffer gateway and extracts the measurement signals from the electrode module to calculate the electrical neutrality check value. When the check value is less than the lower limit check threshold, the buffer gateway executes an algorithm to trigger a circuit breaker and generates an interception command, causing the execution unit to control the pipeline to perform emptying and rinsing before the optical module aspirates the sample. This mechanism utilizes the time difference between detection modules to directly block the processing flow of abnormal samples during equipment operation, avoiding invalid sample aspiration and reagent consumption by the optical module, and preventing erroneous test results from flowing into the information system at the source.

[0030] 2. This invention calculates the Z-score of a single item and the comprehensive Z-score combined with weighting factors through an information system, and converts them into corresponding visual threshold codes through a display terminal. The display terminal divides the grid of the generated two-dimensional matrix interface into upper and lower triangular areas for simultaneously rendering the visual threshold codes of the single item and the comprehensive Z-score. This display method integrates the deviation of a single item and the comprehensive deviation of multiple items into the same spatial unit, replacing the conventional plain text data list, allowing operators to intuitively grasp the multidimensional quality control status of the sample through a graphical interface.

[0031] 3. When the buffer gateway triggers the circuit breaker algorithm, this invention simultaneously clears the buffer waiting queue and discards abnormal data packets, while sending an abnormal event message to the information system to prevent the abnormal measurement result from participating in baseline parameter maintenance. Simultaneously, the display terminal retrieves the interception reason code for the sample triggering the circuit breaker, generates a degradation mask, and renders the corresponding matrix grid as a grayscale mask. This mechanism prevents distorted data from being mixed into the baseline parameter model and affecting the calculation of historical means, and provides independent graphical identification of the intercepted data on the front-end interface, avoiding human misinterpretation. Attached Figure Description

[0032] Figure 1 This is a system framework diagram of the present invention;

[0033] Figure 2 This is a flowchart of the method of the present invention;

[0034] Figure 3 Flowchart for constructing the baseline parameter model of this invention;

[0035] Figure 4 This is a flowchart of the asynchronous timing alignment and exception handling process of the present invention;

[0036] Figure 5 This is a flowchart of the multidimensional feature state quantization process of the present invention;

[0037] Figure 6 This is a schematic diagram of the two-dimensional matrix topology and visualization rendering principle of the present invention;

[0038] Figure 7 This is a timing diagram of the hardware-software synergistic control and reagent blocking of the present invention;

[0039] Figure 8 This is the multidimensional characteristic state kernel density estimation and phase space trajectory mapping diagram of the present invention.

[0040] Among them, 10 is the information system; 20 is the analytical equipment; 21 is the electrode module; 22 is the optical module; 23 is the main control unit; 24 is the sample dispensing mechanism; 25 is the liquid circuit system; 30 is the buffer gateway; 40 is the execution unit; and 50 is the display terminal. Detailed Implementation

[0041] The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0042] See attached document Figure 1 The real-time quality control visualization system based on patient data of the present invention includes an information system 10, an analysis device 20, a buffer gateway 30, an execution unit 40, and a display terminal 50.

[0043] Information system 10 is deployed on the server side to perform data processing and instruction scheduling within the system, and establishes a data communication link with analysis device 20 via buffer gateway 30 based on a bidirectional medical instrument interface protocol. The data processing process of information system 10 includes: extracting the target electrolyte concentration from the patient sample and calculating the anion gap; assigning corresponding weight factors to each detection dimension according to the medical correlation between sodium ions, chloride ions, bicarbonate ions and the anion gap; and calculating the individual Z-score and comprehensive Z-score of the patient sample based on the above data.

[0044] The analytical device 20 is used to hold patient samples, detect the concentration of target electrolytes in the patient samples, and output corresponding measurement signals. The analytical device 20 contains detection components with different detection principles, including an electrode module 21 and an optical module 22. The electrode module 21 uses potentiometry to detect sodium and chloride ions in the patient samples and generates sodium and chloride ion signals. The optical module 22 uses enzymatic kinetic colorimetry to detect bicarbonate ions in the same patient sample and generates a bicarbonate ion signal. Because the detection principles of the electrode module 21 and the optical module 22 are different, the detection cycle of the electrode module 21 is shorter than that of the optical module 22. Therefore, there is an inherent timing difference when the analytical device 20 outputs the detection signals for each ion.

[0045] A buffer gateway 30 is installed on the data transmission link between the analysis device 20 and the information system 10. It intercepts measurement result messages sent by the analysis device 20 to the information system 10 and establishes an asynchronous alignment buffer in its memory. As a medical instrument interface protocol proxy node, after receiving the result message from the analysis device 20, the buffer gateway 30 first sends a reception confirmation back to the analysis device 20. Then, based on the device number, patient sample identifier, medical order number, test item code, message sequence number, and timestamp, it performs buffering and forwarding control on the result message to prevent communication timeouts caused by the analysis device 20 waiting for result message alignment.

[0046] The buffer gateway 30 calls the medical order data sequence in the information system 10 to perform timing suspension, alignment, or release processing on the intercepted measurement signals to eliminate the timing difference in the output results caused by the different detection cycles of the electrode module 21 and the optical module 22. During the timing suspension period, the buffer gateway 30 calculates the sodium-chloride concentration difference using the sodium ion concentration and chloride ion concentration output by the electrode module 21 in advance, and generates a physiological electrical neutrality check value accordingly. When the polarity shift of this concentration difference exceeds the physiological acid-base compensation range, the buffer gateway 30 determines that the current patient sample has a risk of pre-sampling error such as contamination of blood collected from the same side as the intravenous infusion fluid, and triggers the abnormal processing bypass.

[0047] For patient samples that trigger the anomaly handling bypass, the buffer gateway 30 executes an algorithmic circuit breaker at the data transmission layer. The algorithmic circuit breaker blocks the measurement result data of this patient sample from entering the information system 10 for subsequent baseline parameter maintenance, while allowing the anomaly event message to enter the information system 10 for status recording, mask rendering, and traceability management. This prevents abnormal measurement values ​​from altering the statistical parameters in the baseline parameter model. When executing the algorithmic circuit breaker, the buffer gateway 30 writes a sample-level interception flag for the current patient sample identifier and generates an anomaly event message. This anomaly event message includes the patient sample identifier, device number, interception reason code, trigger threshold, trigger timestamp, and processing status. The buffer gateway 30 uploads the anomaly event message to the information system 10 for subsequent mask rendering by the display terminal 50.

[0048] The execution unit 40 is located at the device end of the analytical apparatus 20 and is electrically connected to the mechanical transmission mechanism, fluid piping assembly, and reagent compartment of the analytical apparatus 20. The execution unit 40 includes a main control unit 23, a sample dispensing mechanism 24, a liquid circuit system 25, and drive interfaces that are respectively connected to the electrode module 21 and the optical module 22. The main control unit 23 is used to receive upper-level control messages and issue lower-level execution commands to the sample dispensing mechanism 24, the liquid circuit system 25, the electrode module 21, and the optical module 22.

[0049] The execution unit 40 provides a control application programming interface for receiving and parsing control messages issued by the information system 10. The execution unit 40 converts the control messages into underlying mechanical control commands for the device, driving the electrode module 21 or optical module 22 to perform physical rinsing, hardware reset, or sample introduction interruption. The buffer gateway 30 is also electrically connected to the main control unit 23 via an independent control bypass. This independent control bypass is used to bypass the conventional information system scheduling path and send a high-priority interception command to the main control unit 23 when an abnormal sample triggers the algorithm's circuit breaker.

[0050] To prevent the mechanical sample loading action of the optical module 22 from preceding the data processing results of the electrode module 21, the execution unit 40 incorporates staggered sample loading scheduling logic. In real-time quality control mode, this staggered sample loading scheduling logic is executed as the normal operating logic. The fluid piping assembly prioritizes distributing and delivering samples to the electrode module 21, while the reagent aspiration and sample loading actions of the optical module 22 are extended by at least one electrode measurement cycle on the time axis. This extended waiting time... Not less than the electrode measurement time Buffer gateway 30 computation time Control message transmission time and the mechanical response time of the execution unit 40 The sum of these signals ensures that the sodium ion signal and chloride ion signal can be used to identify anomalies before the optical module 22 actually comes into contact with the sample.

[0051] When the buffer gateway 30 identifies a risk of error before sampling, the execution unit 40 obtains an interception command in advance through an independent control bypass. Since the optical module 22 is still in the mechanical waiting period created by the staggered sample injection schedule, contaminated samples remain in the front injection needle or transition fluid tubing. Based on this, the execution unit 40 directly issues waste liquid drainage and high-pressure physical flushing commands to prevent samples contaminated by intravenous infusion fluid from contacting the enzymatic reaction cuvette of the optical module 22, thereby achieving hardware self-protection across physical measurement principles. When the analysis device 20 is also equipped with hemolysis index detection, absorbance pre-scanning, or potassium ion abnormal elevation detection functions, the execution unit 40 can further combine the aforementioned auxiliary signals to perform the same drainage and flushing treatment on hemolyzed samples.

[0052] Display terminal 50 is electrically connected to information system 10 and is used to acquire visual threshold encoding data generated by information system 10 after parameter quantization. Display terminal 50 also acquires abnormal event messages and sample-level interception flags uploaded by buffer gateway 30 from information system 10. Display terminal 50 renders and outputs a two-dimensional matrix interface based on the visual threshold encoding data, which displays the quality control results in the form of a triangular heatmap. For patient sample sequences containing sample-level interception flags, display terminal 50 does not call conventional Z-score color mapping rules, but instead performs mask rendering based on the interception reason code in the abnormal event message.

[0053] In the two-dimensional matrix interface, the X-axis maps the patient sample sequence, and the Y-axis maps the laboratory test items. The Y-axis includes at least three directly measured items: sodium ions, chloride ions, and bicarbonate ions; in extended display mode, the Y-axis can further include the derived correlation dimension of anion gap. Each matrix grid is divided into upper and lower triangular regions. The color of the upper triangular region indicates the deviation of the Z-score for a single test item, while the color of the lower triangular region indicates the deviation of the overall Z-score for the corresponding patient sample. Through this display method, the display terminal 50 can simultaneously present single-item quality anomalies and multivariate correlation quality anomalies in the same matrix coordinate system, allowing operators to intuitively judge the current operating status of the analysis device 20. When multiple analysis devices 20 are connected to the system simultaneously, the display terminal 50 uses the device number as a filtering dimension or a partitioned display dimension to generate a two-dimensional matrix interface corresponding to each analysis device 20, avoiding the mixing of patient sample sequences from different analysis devices 20 in the same matrix. The two-dimensional matrix interface can be represented as a two-dimensional matrix topology interface or a triangular heatmap interface.

[0054] See attached document Figure 2 The present invention provides a real-time quality control visualization method based on patient data, comprising the following steps.

[0055] S10, acquire measurement data from historical samples. Information system 10 extracts pre-accumulated measurements of sodium ions, chloride ions, bicarbonate ions, and calculated anion gap values, and introduces corresponding medical correlation weight factors for sodium ions, chloride ions, bicarbonate ions, and anion gaps. Subsequently, information system 10 calculates the mean and standard deviation of each feature dimension and establishes a medical correlation weight mapping table, thereby constructing a baseline parameter model that includes the mean, standard deviation, and weight mapping relationship of the single-dimensional features. Historical sample data that has been marked as generated during pre-sampling contamination, communication anomalies, or equipment malfunctions are not included in the baseline parameter model by information system 10.

[0056] S20: Intercept the real-time measurement signal generated by the analysis device 20. The buffer gateway 30, in conjunction with the medical order sequence data, performs asynchronous timing alignment and anomaly handling bypass at the data transmission layer. Asynchronous timing alignment uses the device number, patient sample identifier code, medical order number, test item code, message sequence number, and timestamp as matching fields.

[0057] During the asynchronous timing alignment waiting period, the buffer gateway 30 extracts the previously arrived electrode measurement potential data and constructs a sodium chloride ion imbalance based on it. When the sodium chloride ion imbalance is identified as a non-physiological in vitro dilution characteristic, the buffer gateway 30 immediately triggers an anomaly handling bypass, terminating the waiting for subsequent optical colorimetric data and simultaneously blocking invalid measurement results from being incorporated into the baseline parameter model. The buffer gateway 30 also synchronously generates an anomaly event message and uploads it to the information system 10, enabling the information system 10 to retain an anomaly status record of the patient sample sequence even if a valid Z-score has not been generated.

[0058] S30, quantify the feature states of the sample data that have completed time-series alignment. Information system 10, in conjunction with physiological constraint logic, quantifies the three direct measurement dimensions of sodium ions, chloride ions, and bicarbonate ions, as well as the derived correlation dimension of anion gap, and calculates the single-item Z-score of the current patient sample; at the same time, information system 10 calculates the comprehensive Z-score based on medical correlation weight factors, which is used to characterize the overall deviation of multiple correlation detection items in the same patient sample.

[0059] S40, establish a two-dimensional matrix and generate a triangular heatmap. The display terminal 50 establishes a two-dimensional matrix based on the patient sample sequence and test dimensions, mapping the quantized feature states of the information system 10 to visual threshold codes. Each grid in the two-dimensional matrix is ​​divided into an upper triangular region and a lower triangular region. The upper triangular region is used to display the visual threshold code corresponding to the single-item Z-score, and the lower triangular region is used to display the visual threshold code corresponding to the overall Z-score.

[0060] For data that has not yet completed timing alignment, or data that has been blocked by the algorithm's circuit breaker bypass, the display terminal 50 performs downgrade mask rendering, causing the data region to form a visual fault in the triangular heatmap that differs from conventional visual threshold encoding. The triggering basis for the downgrade mask includes the asynchronous alignment timeout flag, the sample-level interception flag bit in the abnormal event message, and the interception reason code corresponding to the sample identification code. In this way, the display terminal 50 can visually distinguish between systemic equipment failures and individual sample contamination.

[0061] S50: A closed-loop control command is generated based on the visual threshold coding feature combination in the two-dimensional matrix. The information system 10 extracts the visual threshold coding results from the triangular heat map, performs cross-comparison through a logical judgment matrix, and sends a closed-loop control command for a specific physical module to the analysis device 20.

[0062] For patient sample sequences that trigger non-physiological in vitro dilution characteristics, the information system 10 generates an interception loop instruction based on the staggered sample injection scheduling already executed by the underlying equipment, using a logical decision matrix. This interception loop instruction is sent through an independent control bypass between the buffer gateway 30 and the main control unit 23, and its priority is higher than that of the routine detection scheduling instruction. Before the optical enzymatic reaction occurs, the execution unit 40 empties the contaminated sample retained at the front-end transition pipeline, thereby using the front-end electrochemical signal to guide the back-end optomechanical action, achieving reagent loss blocking and cross-contamination prevention.

[0063] After receiving the abnormal event message, the information system 10 generates a mask identifier at the corresponding patient sample sequence position on the display terminal 50 and prohibits the patient sample result from participating in subsequent baseline parameter maintenance.

[0064] The following explanation, based on specific application scenarios, system operation mechanisms, and internal mathematical models, further clarifies the above steps.

[0065] See attached document Figure 3 The construction and initialization of the baseline parameter model are completed by the information system 10 on the server side. This model is used to provide a benchmark for deviation calculation and anomaly judgment in subsequent real-time quality control.

[0066] Information system 10 collects and analyzes patient sample measurement data generated by analysis device 20 during its historical operating cycle via a network interface, and extracts historical sample records of more than 500 consecutive cases. These historical sample records include measurements of sodium ion concentration, chloride ion concentration, and bicarbonate ion concentration from the same patient's serum sample. To ensure that the model parameters have a stable statistical basis, the data included in the historical sample set should be valid sample data that has passed routine quality control verification; data that has triggered algorithm circuit breakers, asynchronous alignment timeouts, pre-sampling contamination flags, equipment maintenance status flags, or manual review rejection flags will not be included in the historical sample set.

[0067] After the system enters the continuous operation phase, the historical sample set can be maintained according to a preset sliding window. When the sliding window is updated, the information system 10 only allows valid samples to enter the model data pool, thereby preventing abnormal samples from changing the statistical baseline during subsequent model updates.

[0068] After obtaining direct measurement data for sodium ions, chloride ions, and bicarbonate ions, the information system 10 calculates the anion gap for the corresponding patient sample based on the electroneutrality balance of human plasma. Specifically, the anion gap is equal to the serum sodium ion concentration minus the sum of the chloride ion concentration and the bicarbonate ion concentration. The theoretical basis of the anion gap is standard knowledge in the field of clinical chemistry testing and will not be elaborated upon in this manual.

[0069] Information system 10 assigns medically relevant weighting factors to sodium ions, chloride ions, bicarbonate ions, and anion gaps based on the differences in measurement principles of the detection items and the ability of multivariate indicators to reflect system errors. In one embodiment, information system 10 pre-stores the reference range mean values ​​for each feature dimension, where the reference range mean value for sodium ions is 140.5, the reference range mean value for chloride ions is 102.5, the reference range mean value for bicarbonate ions is 25.5, and the reference range mean value for anion gaps is 8.5.

[0070] Sodium and chloride ions are obtained by potentiometric measurement using electrode module 21. Since the detection principle is consistent and the measurement stability is high, information system 10 assigns a weighting factor of 1 to both sodium and chloride ions. Bicarbonate ions are obtained by enzymatic kinetic colorimetry using optical module 22. Their detection process is relatively greatly affected by reaction temperature, reagent state, and incubation conditions; therefore, information system 10 assigns a weighting factor of 2 to bicarbonate ions. The anion gap is calculated jointly by sodium, chloride, and bicarbonate ions. It reflects the correlation offset between the directly measured items and amplifies systematic errors such as incomplete purging of fluid lines, contamination, or reagent cross-contamination. Therefore, information system 10 assigns a weighting factor of 3 to the anion gap.

[0071] By configuring the aforementioned reference range mean and weighting factors, information system 10 can convert detection items of different concentration levels to a unified calculation caliber based on the relative reference range mean, and establish a medical correlation weight mapping table in the underlying data structure. This mapping table is used to determine the proportion of each feature dimension in the comprehensive value calculation.

[0072] Information system 10 constructs a baseline parameter model based on an ensemble of at least 500 historical samples. For each feature dimension among sodium ions, chloride ions, bicarbonate ions, and the anion gap, information system 10 extracts all historical data for that dimension and calculates the mean and standard deviation of that dimension's single-dimensional feature. The mean of the single-dimensional feature is calculated according to the formula... Calculate; one-dimensional standard deviation according to the formula Calculate; where, This represents the mean values ​​of the gaps between sodium ions, chloride ions, bicarbonate ions, and anions obtained from this. This represents the standard deviation corresponding to each feature dimension. This represents the detected or calculated value of a single historical sample in the corresponding dimension. The mean and standard deviation of each feature dimension are saved according to the original physical dimensions of the corresponding item to ensure consistency in subsequent comparisons.

[0073] After completing the single-dimensional parameter extraction, information system 10 calculates the comprehensive parameters of the aforementioned historical sample set. Information system 10 follows the formula... Calculate the weighted average; where, The average value of sodium ions, chloride ions, bicarbonate ions and anions, weighted relative to the reference range mean; , , and These represent the calculated mean values ​​of the single-dimensional features, respectively; the 140.5, 102.5, 25.5, and 8.5 in the denominator represent the mean values ​​of the reference ranges for each dimension, respectively. Subsequently, information systems below 10 are processed according to the formula:

[0074] ; Calculate the weighted composite standard deviation; where, This represents the weighted composite standard deviation; , , and These represent the values ​​of a single historical sample. The resulting baseline parameter model encapsulates the single-dimensional and comprehensive statistical parameters required for subsequent calculations.

[0075] The single-dimensional feature mean, single-dimensional standard deviation, medical correlation weight mapping table, comprehensive value mean, and comprehensive value standard deviation generated by the above processing together constitute the baseline parameter model required for real-time quality control. This baseline parameter model is encapsulated and stored in the database module of information system 10. The database module includes a medical order data area, a sample status data area, and a baseline parameter data area, where the baseline parameter model is stored and used for subsequent real-time sample deviation calculations. Sample data with sample-level interception flags, timeout flags, equipment malfunction flags, or manual review and removal flags are not included in the baseline parameter model maintenance queue.

[0076] During continuous system operation, information system 10 maintains the baseline parameter model according to a preset update cycle. The preset update cycle can be a fixed sample number cycle, a fixed time window cycle, or it can be triggered after manual review. Before each update, information system 10 reads the sample status flags and removes data with flags indicating algorithm circuit breaker failure, asynchronous alignment timeout, equipment malfunction, maintenance status, or manual review removal. Information system 10 recalculates the mean and standard deviation of each feature dimension using only valid samples, and simultaneously calculates the mean and standard deviation of the composite value corresponding to the valid sample set. The medical correlation weight factor remains unchanged as a preset parameter; when adjustment is needed, it is reset by a user with the appropriate permissions in the configuration interface. Through this update method, the baseline parameter model can be continuously maintained along with patient sample data, while preventing abnormal samples from entering the model and changing the statistical benchmark.

[0077] See attached document Figure 4This invention provides an asynchronous timing alignment and anomaly handling process. This process is mainly executed by the buffer gateway 30 at the data transmission layer, used to align the result signals generated in different detection cycles, and to block abnormal data from entering the subsequent quality control model when non-physiological abnormal features are detected.

[0078] The buffer gateway 30 intercepts the measurement result messages sent out by the analysis device 20 and establishes an asynchronous alignment buffer in its internal memory. Because the electrode module 21 in the analysis device 20 requires a short time to complete the potential measurement of sodium and chloride ions, while the optical module 22 requires a longer time to complete the enzymatic kinetic colorimetric detection of bicarbonate ions, the sodium, chloride, and bicarbonate ion signals from the same patient sample typically do not arrive at the buffer gateway 30 simultaneously. The buffer gateway 30 calls the medical order data sequence in the information system 10, extracts the current patient sample identification code, and maps the arriving sodium and chloride ion signals to the cache unit corresponding to that patient sample identification code.

[0079] The asynchronous alignment buffer uses the device number, patient sample identifier, medical order number, test item code, message sequence number, and timestamp as index fields. For the same patient sample, the buffer gateway 30 writes the sodium ion signal, chloride ion signal, and bicarbonate ion signal into the same buffer unit. If the buffer unit does not receive the bicarbonate ion signal within a preset waiting time, the buffer gateway 30 generates an asynchronous alignment timeout flag and uploads a timeout event message to the information system 10.

[0080] The aforementioned preset waiting time is determined based on the maximum detection cycle of the optical module 22, the fault tolerance time of the medical instrument interface communication, and the processing time of the buffer gateway 30, and its value satisfies the following relationship:

[0081] ;

[0082] In the formula, This represents the preset waiting time for the buffer unit within the buffer gateway 30; This represents the maximum detection cycle of optical module 22; This represents the fault tolerance time for medical instrument interface communication. This represents the processing time of the buffer gateway 30.

[0083] When data is suspended, the buffer gateway 30 does not cause the analysis device 20 to be in a communication blocking state. Specifically, after receiving the result message sent by the analysis device 20, the buffer gateway 30 first returns a reception confirmation to the analysis device 20, then temporarily stores the received result message in the asynchronous alignment buffer and delays forwarding it to the information system 10. Once the signal from the optical module 22 under the same patient sample identification code arrives and alignment is completed, the buffer gateway 30 then uniformly releases the corresponding result message. This processing method eliminates the timing difference in result output caused by different detection cycles without affecting the normal communication cycle of the analysis device 20. The underlying data packet parsing, buffer queue allocation, and message confirmation mechanism of the medical instrument interface can be implemented using conventional laboratory information system communication methods in this field.

[0084] During the asynchronous alignment waiting period, the buffer gateway 30 also uses the previously arrived electrode measurement data for pre-sampling anomaly identification. The buffer gateway 30 reads the sodium ion concentration measurement values ​​and chloride ion concentration measurement values ​​in the asynchronous alignment buffer, calculates the concentration difference between them, and defines this concentration difference as the sodium-chloride ion imbalance degree. Under normal physiological conditions, the sodium ion concentration in human serum is usually higher than the chloride ion concentration, and there is a relatively stable concentration difference between the two. Therefore, this difference can be used as a verification parameter for the local physiological electroneutrality state. The sodium-chloride ion imbalance degree is calculated according to the following formula:

[0085] ;

[0086] In the formula, This represents the sodium chloride ion imbalance calculated by buffer gateway 30. The value of sodium ion concentration in the patient's serum sample output by electrode module 21. This represents the chloride ion concentration value in the same patient's serum sample output by the same electrode module 21.

[0087] The buffer gateway 30 identifies non-physiological polarity shifts based on sodium-chloride ion imbalance. When a patient sample is at risk of contamination from the same side as the intravenous infusion fluid, such as from 0.9% sodium chloride solution, the sodium-chloride concentration difference in the patient sample may be significantly reduced because the sodium and chloride ion concentrations in such infusion fluids are close to equimolar. The buffer gateway 30 compares the calculated sodium-chloride ion imbalance with a preset lower limit verification threshold. This lower limit verification threshold can be set according to clinical physiological extremes, and in one embodiment, it ranges from 15 mmol / L to 20 mmol / L. When the sodium-chloride ion imbalance is less than this lower limit verification threshold, the buffer gateway 30 determines that the result has non-physiological in vitro dilution characteristics and marks the current patient sample as having a risk of pre-sampling error. The lower limit verification threshold is pre-stored in the buffer gateway's memory and can be configured according to clinical physiological extremes.

[0088] For patient samples that trigger non-physiological in vitro dilution characteristics, the buffer gateway 30 initiates an anomaly handling bypass at the data transmission layer. After the anomaly handling bypass is initiated, the buffer gateway 30 clears the asynchronous alignment buffer waiting queue corresponding to the patient sample identifier, terminates the waiting for subsequent colorimetric data from the optical module 22, and discards any intercepted sodium ion and chloride ion data packets. Simultaneously, the buffer gateway 30 writes a sample-level interception flag to the memory for the patient sample identifier.

[0089] After writing the sample-level interception flag, the buffer gateway 30 sends an abnormal event message to the information system 10. The abnormal event message includes the patient sample identifier, device number, interception reason code, sodium-chloride ion imbalance, lower limit verification threshold, trigger timestamp, and processing status. Upon receiving the abnormal event message, the information system 10 does not write the patient sample into the baseline parameter model; instead, it marks the patient sample as a mask rendering object. The abnormal event message is only used for status display, traceability recording, and closed-loop control; it is not used as a valid measurement result of the patient sample in Z-score calculation or baseline parameter maintenance.

[0090] When colorimetric data from the optical module 22 of the same patient sample arrives at the buffer gateway 30 in a subsequent cycle, the buffer gateway 30 identifies the abnormal state of the data by comparing the sample-level interception flag and discards the optical colorimetric data accordingly. Through the above processing, the buffer gateway 30 prevents isolated optical colorimetric data from entering the information system 10 and also prevents the communication queue from being blocked due to residual data from abnormal samples.

[0091] The buffer gateway 30's mechanism of blocking abnormal measurement results from entering the information system 10 at the gateway node constitutes an algorithmic circuit breaker. This algorithmic circuit breaker prevents abnormal samples such as blood contamination from entering the baseline parameter model maintenance process, thereby reducing the risk of abnormal values ​​causing offset contamination to the mean, standard deviation, and subsequent comprehensive Z-score calculations of each feature dimension, and maintaining the statistical stability of the baseline parameter model.

[0092] The data sent out by the buffer gateway 30 is divided into valid measurement result messages and abnormal event messages. Valid measurement result messages include sodium ion concentration, chloride ion concentration, bicarbonate ion concentration, and corresponding patient sample identification codes, indicating that asynchronous alignment has been completed and the abnormal handling bypass has not been triggered. These are used by the information system 10 to perform anion gap calculation, Z-score calculation, and baseline parameter maintenance. Abnormal event messages include sample status information indicating that the algorithm has been triggered by circuit breaking, asynchronous alignment has timed out, or bypass control has failed. These are used only by the display terminal 50 to perform mask rendering, the information system 10 to perform traceability recording, and the execution unit 40 to perform closed-loop control. By separating valid measurement result messages from abnormal event messages, the system retains the traceability of abnormal samples while preventing abnormal measurement values ​​from entering the quality control mathematical model.

[0093] See attached document Figure 5 This invention provides a multi-dimensional feature state quantification process. This process is executed in the background by information system 10 and is used to calculate the deviation of individual items and the overall deviation of patient samples that have completed time-series alignment.

[0094] Before calculating the Z-score, information system 10 first reads the sample status flags corresponding to the patient sample identifier. If the patient sample has an algorithm circuit breaker flag, an asynchronous alignment timeout flag, or a bypass control failure flag, information system 10 does not perform single-item Z-score and comprehensive Z-score calculations for the patient sample, but instead transfers the patient sample to the abnormal event display process. Only patient samples that have completed timing alignment and have not triggered the abnormal handling bypass enter the multi-dimensional feature state quantification process.

[0095] For patient samples that have not triggered the abnormality handling bypass, the buffer gateway 30 performs data release according to physiological constraint logic, synchronously packages the time-aligned sodium ion concentration measurements, chloride ion concentration measurements, and bicarbonate ion concentration measurements, and uploads them to the information system 10. After receiving the above sample data, the information system 10 calculates the anion gap of the current patient sample based on the electroneutrality balance of human plasma.

[0096] Information system 10 calls the baseline parameter model pre-stored in the baseline parameter data area of ​​the database module, extracts the one-dimensional feature mean and one-dimensional standard deviation corresponding to each feature dimension of sodium ion, chloride ion, bicarbonate ion, and anion gap, and calculates the single-item Z-score of the current patient sample under each of the above feature dimensions. The Z-score is used to represent the standard deviation multiple of the current measured or calculated value from the corresponding baseline mean, thereby converting the measurement results of different test items and different concentration levels into a unified dimensionless deviation index. The single-item Z-score is calculated according to the formula... Perform calculations;

[0097] In the formula, The Z-score of a single item extracted and quantified by the information system 10; The sodium ion detection value, chloride ion detection value, bicarbonate ion detection value, or anion gap calculation value represent the current sample of a single patient; This represents the mean of the corresponding dimension of the single-dimensional features extracted from the baseline parameter model; This represents the one-dimensional standard deviation of the corresponding dimension extracted from the baseline parameter model. Using this formula, measurement results of different orders of magnitude are converted into dimensionless deviation indices.

[0098] After calculating the deviation of each individual item, information system 10 further calculates the comprehensive Z-score of the current patient sample by combining the weighting factors of each ion. The comprehensive Z-score is calculated according to the formula... Perform calculations;

[0099] In the formula, The comprehensive Z-score represents the degree of overall deviation within the same patient sample; , , and These represent the real-time detection values ​​and calculated values ​​of each item for a single patient sample, respectively; the denominators 140.5, 102.5, 25.5, and 8.5 are the preset reference range averages for each item; the multipliers and the number of added terms 1, 1, 2, and 3 in the numerator are the corresponding weighting factors. This represents the weighted average stored in the baseline parameter model; This represents the weighted composite standard deviation stored in the baseline parameter model. After completing the above calculations, the system temporarily stores the generated feature state data in memory, serving as the data basis for subsequent two-dimensional matrix visual thresholding.

[0100] After the above processing, the information system 10 obtains the individual Z-scores for each feature dimension of the current patient sample and the overall Z-score for the patient sample. The quantified feature state data is temporarily stored in the memory area of ​​the information system 10 and serves as the data basis for subsequent two-dimensional matrix construction, visual threshold encoding, and closed-loop control determination.

[0101] See attached document Figure 6 This invention provides a two-dimensional matrix topology and visualization rendering principle. The visualization rendering process is completed by a display terminal 50 in conjunction with an information system 10, used to convert single-item Z-scores, overall Z-scores, and abnormal event states into a directly observable two-dimensional matrix interface.

[0102] Display terminal 50 receives feature status quantification data from information system 10 and establishes a two-dimensional matrix coordinate system in the graphical user interface. The X-axis of the two-dimensional matrix is ​​the patient sample sequence axis, with patient samples arranged according to the sample injection time sequence of analysis device 20. To adapt to continuous testing scenarios, display terminal 50 sets a sliding window in the X-axis direction. This sliding window displays the latest preset number of patient sample nodes; when new patient sample data enters, the earliest sample node entering the window moves out of the current display interface.

[0103] The Y-axis of the two-dimensional matrix represents the laboratory testing items, including at least three directly measurable dimensions: sodium ions, chloride ions, and bicarbonate ions. In extended display mode, the Y-axis can also include a derived correlation dimension: the anion gap. The display terminal 50, through the orthogonal arrangement of the patient sample sequence on the X-axis and the testing items on the Y-axis, forms a visual topological space on the screen composed of multiple matrix grids, allowing the quality control status of different patient samples and different testing items to be located to specific grids.

[0104] Information system 10 generates visual threshold codes based on the absolute value of the Z-score. Specifically, information system 10 divides the absolute value of the Z-score into six levels: a Z-score absolute value less than or equal to 1 is coded as Level 1, indicating no significant deviation; a Z-score absolute value greater than 1 and less than or equal to 1.5 is coded as Level 2, indicating a slight deviation; a Z-score absolute value greater than 1.5 and less than or equal to 2 is coded as Level 3, indicating a mild warning; a Z-score absolute value greater than 2 and less than or equal to 2.5 is coded as Level 4, indicating a moderate warning; a Z-score absolute value greater than 2.5 and less than 3 is coded as Level 5, indicating a severe warning; and a Z-score absolute value greater than or equal to 3 is coded as Level 6, indicating a serious loss of control. After receiving the above visual threshold codes, display terminal 50 renders the Level 1 to Level 6 codes as dark green, light green, yellow, orange, light red, and dark red respectively through a color mapping engine, thereby forming a graded warning color scheme.

[0105] After completing visual threshold encoding and color mapping, the display terminal 50 segments and renders individual matrix grids in the two-dimensional matrix to form a triangular heatmap. The display terminal 50 divides the individual matrix grid into upper and lower triangular regions, using the main diagonal as the boundary. For the same patient sample and the same test item, the upper triangular region is filled with the color corresponding to the Z-score of the single test item, and the lower triangular region is filled with the color corresponding to the overall Z-score of the patient sample. Thus, a single matrix grid simultaneously presents both the local deviation state of a single test item and the overall deviation state after the association of multiple items, facilitating comparison of local and systemic anomalies within the same interface for the operator.

[0106] For patient samples that have been blocked by the buffer gateway 30 through the exception handling bypass, the display terminal 50 performs downgraded mask rendering. Since these patient samples do not form a valid Z-score, conventional visual thresholding and color mapping rules are no longer applicable. The display terminal 50 reads the exception event message and sample-level interception flag uploaded by the buffer gateway 30 through the information system 10, and determines the masking method based on the interception reason code. For patient samples that have triggered non-physiological in vitro dilution features and have been circuit-broken by the algorithm, the display terminal 50 renders the corresponding matrix grid as a solid grayscale mask; for patient samples that have timed out due to asynchronous alignment but have not triggered non-physiological in vitro dilution features, the display terminal 50 can use a grayscale mask with a diagonal texture. The color of the grayscale mask can be configured as a neutral grayscale value of RGB (128, 128, 128).

[0107] Through the aforementioned masking rendering method, the display terminal 50 forms a visual segmentation in the continuous heatmap matrix that differs from the red-yellow-green visual threshold encoding. This visual segmentation is used to indicate that the current sample is in a state of unavailable data or abnormal bypass processing, rather than directly indicating that the detection system has experienced a routine quality control failure. Therefore, operators can distinguish between individual sample blood contamination, asynchronous alignment timeouts, and systemic malfunctions of the analysis equipment 20, reducing the probability of misjudging a sample as a faulty device before sampling.

[0108] When rendering the triangular heatmap, the display terminal 50 also distinguishes between continuous high-level visual threshold codes and single-point grayscale masks. If the same analysis device 20 shows the same detection item or multiple detection items with level 5 or 6 visual threshold codes in consecutive patient samples, the display terminal 50 marks this state as a system-level quality anomaly. If the matrix grid corresponding to a single patient sample is covered by a grayscale mask, and no continuous high-level visual threshold codes appear in the preceding and following patient samples, the display terminal 50 marks this state as an anomaly before the sampling of an individual sample. Through this discrimination method, the triangular heatmap not only shows the degree of deviation of a single patient sample, but also reflects the abnormal distribution pattern in a continuous sample sequence.

[0109] See attached document Figure 7 This invention provides a hardware-software co-control and reagent blocking timing. This timing is completed collaboratively by the information system 10, the buffer gateway 30, and the analysis device 20, and is used to convert the judgment result of the quality control algorithm into the underlying electromechanical action of the analysis device 20.

[0110] Information system 10 receives characteristic state quantification data and sample-level interception flags generated by buffer gateway 30, and performs cross-comparison in the background logical judgment matrix to generate corresponding physical scheduling instructions. The logical judgment matrix includes continuous offset judgment, module location judgment, and sample-level anomaly judgment.

[0111] In the continuous offset determination, the information system 10 compares the visual threshold codes of consecutive patient samples based on the Westgard multi-rule concept in clinical laboratory quality control. When the comprehensive Z-score visual threshold code of the same analysis device 20 reaches level 5 or 6 in three consecutive patient samples, or the single-item Z-score visual threshold code of the same test item reaches level 5 or 6 in three consecutive patient samples, the information system 10 determines that the analysis device 20 is in an unstable operating state and generates a degradation scheduling instruction. This degradation scheduling instruction is sent to the main control unit 23 of the analysis device 20 through the serial communication interface.

[0112] In module positioning determination, information system 10 identifies the corresponding processing target based on abnormal combinations of different detection items. When the Z-scores of sodium ions and chloride ions show a unidirectional shift in multiple consecutive patient samples, or when high-level visual threshold codes appear consecutively, while bicarbonate ions do not shift synchronously, information system 10 determines that electrode module 21 has a drift risk and generates instructions to flush, reset, or calibrate electrode module 21. When the Z-score of bicarbonate ions shows a unidirectional shift in multiple consecutive patient samples, or when high-level visual threshold codes appear consecutively, while sodium ions and chloride ions do not shift synchronously, information system 10 determines that optical module 22 or reagent incubation status has an abnormal risk and generates instructions to flush optical module 22, check reagent status, or pause sample injection. When high-level visual threshold codes appear simultaneously in the anion gap derived dimension and multiple direct measurement dimensions, information system 10 determines that there is a risk of cross-contamination or systemic carryover contamination in the fluid pipeline and generates instructions to flush the entire pipeline and downgrade sample injection. If a single patient sample triggers a grayscale mask and no consecutive high-level visual threshold codes appear in the preceding and following patient samples, the information system 10 determines that it belongs to the risk of contamination before individual sample sampling, generates a sample resampling prompt, and does not trigger the overall failure shutdown of the analysis equipment 20.

[0113] After receiving the downgraded scheduling instruction, the main control unit 23 executes downgraded scheduling based on the existing staggered sample injection scheduling logic. In real-time quality control mode, the main control unit 23 normally controls the sample dispensing mechanism 24 to prioritize the allocation of serum samples to the electrode module 21, and delays the sample aspiration and dispensing actions of the optical module 22 by at least one complete electrode detection cycle. The downgraded scheduling instruction is not used for the initial initiation of staggered sample injection, but rather to further reduce the injection cycle time, increase the rinsing frequency, or suspend subsequent injection actions of the optical module 22, based on the staggered sample injection already in operation.

[0114] The main control unit 23 executes the above timing mode at the microcontroller's bottom layer, controlling the sample dispensing mechanism 24 to first absorb the sample and inject it into the electrode module 21 for potential measurement, and then delaying the sample absorption and dispensing actions of the optical module 22. The delay time of the sample absorption and dispensing actions of the optical module 22 satisfies the following relationship:

[0115] ;

[0116] In the formula, This represents the delay time between the sample aspiration and dispensing actions of optical module 22; Representative electrode measurement time; This represents the computation time of buffer gateway 30; This represents the control message transmission time; This represents the mechanical response time of execution unit 40.

[0117] Electrode measurement time Buffer gateway 30 computation time Control message transmission time and the mechanical response time of execution unit 40 The parameter configuration table can be pre-stored in information system 10 or main control unit 23. The parameter configuration table is read during system initialization to determine the parameters. After the analysis device 20 has undergone maintenance, calibration, or module replacement, a user with the appropriate permissions can rewrite the aforementioned time parameters. In one embodiment, the electrode detection cycle is set to 45 to 60 seconds, based on the potential response stabilization time of a conventional ion-selective electrode. This time delay allows the main control unit 23 to reserve a processing window for individual sample status identification and hardware interception before the optical module 22 actually contacts the sample.

[0118] During the delayed waiting period when the sample dispensing mechanism 24 adds a sample to the optical module 22, the electrode module 21 first completes the potential measurement of sodium and chloride ions. The buffer gateway 30 intercepts the above measurement data and calculates the sodium and chloride ion imbalance. If this imbalance triggers a non-physiological polarity shift, the buffer gateway 30 generates a sample-level interception flag for the current patient sample and sends a high-priority hardware interrupt signal to the main control unit 23 via the underlying control bus. This underlying control bus can be implemented using a CAN bus, RS485 bus, GPIO interrupt line, or internal Ethernet control channel of the device, and is used to transmit an interception command containing the patient sample identification code, interception reason code, and interruption priority. At this time, since the optical module 22 is still in a delayed waiting state, the sample dispensing mechanism 24 has not yet introduced the patient sample into the reaction cup and enzyme reagent of the optical module 22.

[0119] If the main control unit 23 does not return an interception confirmation within the preset response time, the buffer gateway 30 uploads a bypass control failure event to the information system 10. Based on this, the information system 10 generates a device-side response anomaly prompt on the display terminal 50 and simultaneously sends a pause sample injection command from the optical module 22 to the analysis device 20. The information system 10 also marks the patient sample and a preset number of subsequent samples as verification targets. The preset number can be configured by the user in the information system 10 or calculated based on the residual volume of the tubing in the analysis device 20 and the single sample injection volume.

[0120] After receiving and confirming the interception of the hardware interrupt signal, the main control unit 23 sends a timing termination command to cancel the original sample aspiration and dispensing actions of the optical module 22. Subsequently, the main control unit 23 controls the spindle motor of the sample dispensing mechanism 24 to rotate, moving the sample dispensing mechanism 24 to the cleaning tank position inside the analytical device 20; it opens the waste discharge solenoid valve of the liquid circuit system 25 to discharge the contaminated sample remaining in the probe of the sample dispensing mechanism 24 into the waste liquid pipeline; then it starts the high-pressure cleaning pump of the liquid circuit system 25 to force-wash the inner and outer walls of the probe with deionized water under a hydraulic pressure of 0.15MPa to 0.2MPa.

[0121] After cleaning, the main control unit 23 returns a processing completion status to the buffer gateway 30 and the information system 10. The processing completion status is bound to and stored with the abnormal event message, allowing the display terminal 50 to display the interception and processing results of the current patient sample and for subsequent traceability. Through the combination of staggered sample injection, sample-level interception, and mechanical emptying and cleaning, the system can prevent contact between intravenously infused liquid contaminated samples and biochemical reagents in the optical module 22 before the optical enzymatic reaction occurs, reducing the risk of reagent cross-contamination and continuous systematic errors.

[0122] Compared to quality control methods that rely solely on quality control materials or single-item threshold judgments, this embodiment uses the gaps between sodium ions, chloride ions, bicarbonate ions, and anions in real patient samples to form a medical correlation data set. It then calculates a comprehensive Z-score by combining the reference range mean and differential weighting factors, thereby continuously monitoring systematic shifts during the testing process without consuming additional quality control materials. The display terminal 50 simultaneously displays the single-item Z-score and the comprehensive Z-score within the same matrix grid using a triangular heatmap. This allows operators to identify single-item anomalies from the upper triangular region and multivariate correlation anomalies from the lower triangular region. The buffer gateway 30 also utilizes the sodium and chloride ion signals arriving earlier during the asynchronous alignment waiting period to identify non-physiological in vitro dilution characteristics. Through algorithmic fracturing, sample-level interception flags, and independent control bypasses, it prevents contaminated samples from entering the baseline parameter model and optical module 22, thereby reducing the risk of abnormal samples continuously affecting the statistical baseline, reagent system, and subsequent sample testing results.

[0123] To verify the actual operating mechanism and closed-loop control effect of the technical solution of the present invention, the following detailed embodiments are described in conjunction with the underlying data flow process and hardware-level timing parameters.

[0124] The information system initialized the baseline parameter model based on 600 consecutive valid historical samples. The system preset the reference ranges for each dimension as follows: sodium ion 140.5 mmol / L, chloride ion 102.5 mmol / L, bicarbonate ion 25.5 mmol / L, and anion gap 12.5 mmol / L. Statistical calculations showed the following mean and standard deviation for each single-dimensional feature written into the baseline parameter data area: sodium ion mean 140.0 mmol / L and standard deviation 2.0 mmol / L; chloride ion mean 102.0 mmol / L and standard deviation 1.5 mmol / L; bicarbonate ion mean 25.0 mmol / L and standard deviation 1.2 mmol / L; anion gap mean 12.0 mmol / L and standard deviation 1.8 mmol / L. The information system calculated the normalized composite baseline mean as 7.00 and the composite standard deviation as 0.25, using weighting factors of 1, 1, 2, and 3 for sodium ion, chloride ion, bicarbonate ion, and anion gap, respectively.

[0125] The underlying timing configuration of the analytical device is as follows: electrode measurement takes 45 seconds, buffer gateway parsing takes 2 seconds, bus message transmission takes 1 second, and execution unit mechanical response takes 2 seconds. Based on the aforementioned constraint formula, the main control unit sets the delay time for the optical module's sample aspiration and dispensing mechanical actions to 50 seconds. Under normal operating conditions, the off-peak sample injection scheduling logic controls the sample dispensing mechanism to rigidly extend the optical module's sample injection action by 50 seconds.

[0126] Scenario 1 involves a latent system error caused by a localized temperature control malfunction in the analytical device. After a patient sample is injected into the analyzer, the electrode module outputs a sodium ion concentration of 141.0 mmol / L and a chloride ion concentration of 103.0 mmol / L. The buffer gateway calculates a sodium-chloride ion imbalance of 38.0 mmol / L, which is higher than the lower limit of the verification threshold of 15.0 mmol / L. The system determines that the sample does not exhibit pre-sampling in vitro dilution characteristics and releases the data. After the optical module completes the detection, it outputs a bicarbonate concentration of 20.0 mmol / L. Based on this, the information system calculates the anion gap of the sample to be 18.0 mmol / L.

[0127] The information system then quantifies the characteristic states of each dimension. The Z-score calculation results for each item are: sodium ion 0.50, chloride ion 0.67, bicarbonate ion -4.17, and anion gap 3.33. The comprehensive value calculation step performs an accumulation operation based on the mean of the corresponding reference range and the weighting factor, and the normalized comprehensive value of the current sample is 7.895. The information system further calculates the comprehensive Z-score to be 3.58. In the two-dimensional matrix interface generated by the display terminal, the upper and lower triangular regions of the patient sample grid are rendered as dark red visual threshold codes, representing severe loss of control, because the absolute value of the Z-score exceeds the threshold limit of 3.0. The information system identifies this specific high-frequency visual threshold code combination, determines that the optical module has drifted independently, and immediately sends a closed-loop control command via the serial communication interface to prompt calibration.

[0128] Scenario 2 involves hardware-level defense against contaminated samples from the same side as intravenous infusion fluid. Another contaminated sample containing 0.9% sodium chloride solution enters the process, with the electrode module outputting a sodium ion concentration of 154.0 mmol / L and a chloride ion concentration of 152.0 mmol / L. At this time, the optical module is in a 50-second mechanical suspension cycle. The buffer gateway intercepts the electrode data and calculates the sodium-chloride ion imbalance as 2.0 mmol / L, which is below the lower limit verification threshold of 15.0 mmol / L. The buffer gateway triggers the data transmission layer algorithm circuit breaker, writes a sample-level interception flag, and sends a high-priority hardware interrupt signal to the main control unit along the independent control bypass. The main control unit responds by canceling the original action of the optical module and controlling the sample dispensing mechanism to move to the washing tank to perform a high-pressure venting procedure. The contaminated sample is blocked in the transition tubing stage and does not come into contact with the enzymatic reagents inside the optical module.

[0129] To verify the technical effectiveness of this invention, 10,000 patient serum samples were processed in a parallel control manner over a 30-day operating period. The control group's equipment had its hardware and software collaborative interception mechanism disabled and used traditional internal quality control methods; the experimental group's equipment had the quality control system provided by this invention enabled. During the experiment, 50 intravenous infusion contamination samples of different concentrations were randomly introduced. System performance data are recorded in Table 1.

[0130] Table 1: Comparison of Operating Indicators of Different Quality Control Systems

[0131] Comparison Indicators control group system Experimental group system Detection rate of venous contamination samples 12.0% 100.0% Number of successful reagent cross-contamination prevention 0 cases 50 cases Number of invalid measurement results mixed into the baseline model 50 times 0 times Physical loss due to abnormal contact of optical reagents 50 test samples 0 test samples Number of false negative test reports 44 copies 0 copies Unplanned equipment downtime for cleaning and reset 14.5 hours 0.5 hours

[0132] refer to Figure 8 As shown in Table 1, the technical solution of this invention has significant advantages in identification accuracy and system-level defense capabilities. At the physical execution level, the electrochemical pre-identification, gateway hardware-level interruption, and mechanical spindle emergency stop are strictly aligned in timing, confirming that the pre-emptive time window created by staggered sample injection can fully cover the entire cycle of identification and interception. At the data control level, facing continuous contamination impacts, the control group's system error showed a continuous amplification trend and a deviation from the statistical baseline, while the experimental group precisely isolated abnormal data through data transmission layer algorithmic circuit breaking, maintaining the purity of the baseline model. The experimental group completely avoided false negative report output and biochemical reagent waste, fundamentally blocking the physical transfer and statistical spread of pre-analytical errors to the analytical process, effectively ensuring the continuous and stable operation of the testing system.

[0133] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.

Claims

1. A visualization system for real-time quality control based on patient data, characterized in that, It includes an information system, analysis equipment, a buffer gateway, an execution unit, and a display terminal; the analysis equipment is equipped with an electrode module and an optical module for detecting the electrolyte concentration of patient samples and outputting measurement result messages; The buffer gateway is located between the analysis device and the information system; the memory of the buffer gateway stores a lower limit verification threshold. The buffer gateway is used to intercept the measurement result message, establish a buffer in the memory to perform timing alignment, and extract the measurement signal of the electrode module to generate an electrical neutrality check quantity; When the electrical neutrality check quantity is less than the lower limit check threshold, the buffer gateway is used to perform algorithmic circuit breaking, and generate a sample-level interception flag and an interception command; The information system is used to extract the aligned measurement signals to calculate the individual Z-scores of the patient samples, and to calculate the comprehensive Z-scores of the patient samples by combining the weighting factors of each ion. The execution unit is used to control the pipeline to distribute samples to the electrode module, so that the sampling action of the optical module is delayed relative to the measurement action of the electrode module, so as to form a time window for receiving the interception command, and to receive the interception command before the optical module samples, and issue emptying and rinsing commands. The display terminal is connected to the information system and is used to convert the single-item Z-score and the comprehensive Z-score into visual threshold codes and generate a two-dimensional matrix interface; the grid of the two-dimensional matrix interface is divided into an upper triangular area and a lower triangular area; the display terminal is used to render the visual threshold codes in the upper triangular area and the lower triangular area, and to distinguish and display the intercepted patient samples according to the sample-level interception flag.

2. The visualization system for real-time quality control based on patient data according to claim 1, characterized in that, The buffer gateway uses the device number, patient sample identification code, doctor's order number, test item code, message sequence number, and timestamp as index fields; the buffer gateway is used to write the sodium ion signal, chloride ion signal, and bicarbonate ion signal corresponding to the same patient sample into the cache unit to perform the timing alignment; when the cache unit does not receive the bicarbonate ion signal within the asynchronous alignment waiting time, the buffer gateway is used to generate a timeout flag.

3. The visualization system for real-time quality control based on patient data according to claim 1, characterized in that, The buffer gateway is used to clear the buffer waiting queue corresponding to the patient sample when the algorithm circuit breaker is executed; the buffer gateway is used to terminate the waiting for subsequent optical module colorimetric data and discard the intercepted electrode module data packets; the buffer gateway is used to write the sample-level interception flag bit into the memory and send an abnormal event message to the information system. The information system is used to prevent the measurement result message from participating in baseline maintenance after receiving the abnormal event message.

4. The visualization system for real-time quality control based on patient data according to claim 1, characterized in that, The electroneutrality check is the concentration difference between sodium ion concentration and chloride ion concentration in the patient's serum sample; the buffer gateway is used to compare the concentration difference with the lower limit check threshold; when the concentration difference is less than the lower limit check threshold, the buffer gateway is used to determine that the patient sample has triggered a polarity shift.

5. The visualization system for real-time quality control based on patient data according to claim 1, characterized in that, The information system stores a baseline parameter model; the baseline parameter model includes the mean of one-dimensional features, the standard deviation of one-dimensional features, the medical association weight mapping table, the comprehensive mean, and the comprehensive standard deviation of historical samples; the information system is used to calculate the single-item Z-score using the mean of one-dimensional features and the standard deviation of one-dimensional features; the information system is used to calculate the comprehensive Z-score using the medical association weight factors corresponding to the gaps between sodium ions, chloride ions, bicarbonate ions, and anions, as well as the comprehensive mean and the comprehensive standard deviation.

6. The visualization system for real-time quality control based on patient data according to claim 1, characterized in that, The execution unit is used to extend the reagent aspiration and sample dispensing actions of the optical module to form an optical delay waiting time; the optical delay waiting time is the sum of the electrode measurement time, the buffer gateway calculation time, the control message transmission time, and the execution unit mechanical response time.

7. The visualization system for real-time quality control based on patient data according to claim 6, characterized in that, The buffer gateway is connected to the execution unit via an independent control bypass; the buffer gateway is used to send a hardware interrupt signal to the execution unit when the interception command is generated; the execution unit is used to receive the interception command during the period when the optical module is in the optical delay waiting time, and cancel the reagent aspiration action and sample drop action of the optical module; the execution unit is used to control the sample dispensing mechanism to move to the washing pool to empty the residual patient sample in the probe, and start the liquid circuit system to perform flushing under hydraulic pressure of 0.15MPa to 0.2MPa.

8. The visualization system for real-time quality control based on patient data according to claim 1, characterized in that, The X-axis of the two-dimensional matrix interface represents the patient sample sequence, and the Y-axis represents the detection items. The detection items include three directly measured dimensions: sodium ions, chloride ions, and bicarbonate ions. The upper triangular area is filled with the visual threshold coding color corresponding to the Z-score of the single item. The lower triangular area is filled with the visual threshold coding color corresponding to the comprehensive Z-score. The visual coding includes the first to sixth visual codes.

9. The visualization system for real-time quality control based on patient data according to claim 1, characterized in that, The display terminal is used to read the abnormal event message uploaded by the buffer gateway and the sample-level interception flag bit through the information system; For a patient sample that triggers the circuit breaker algorithm, the display terminal retrieves the interception reason code from the abnormal event message to generate a degradation mask, and renders the grid of the two-dimensional matrix interface corresponding to the patient sample as a solid grayscale mask or a grayscale mask with diagonal texture.

10. The visualization system for real-time quality control based on patient data according to claim 8, characterized in that, The information system is used to extract the visual threshold code in the two-dimensional matrix interface and perform continuous offset determination; when the visual threshold code corresponding to the comprehensive Z score reaches the fifth level visual threshold code or the sixth level visual threshold code in three consecutive patient samples, the information system is used to issue a degradation scheduling instruction to the analysis device.