Intelligent sample collection management method, device, equipment and medium
Through intelligent sample collection management methods, the basic sample data is synchronized, the samples are located in real time and the circulation log is analyzed, which solves the problems of data update lag and poor system interaction in traditional sample circulation management, and achieves efficient, traceable and accurate management of sample circulation.
Patent Information
- Application Number
- CN202510368960.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-27
- Publication Date
- 2025-04-25
- Estimated Expiration
- 2045-03-27
AI Technical Summary
In traditional sample flow management, the collection, storage and circulation of samples rely on manual operations and single-point information entry, resulting in data update lag, inconsistent information, and lack of efficient data interaction mechanisms between different systems, resulting in data loss, repeated recording or status errors.
The intelligent sample collection management method is adopted to synchronize the sample basic data between the warehousing management system, laboratory information management system and mobile terminal equipment by obtaining sample circulation requests, and use multi-threaded positioning technology to determine the sample location in real time, and generate sample circulation logs. Based on the flow exception identification model, analyze logs, identify abnormal situations and perform processing or alarm operations to ensure real-time and consistency of data.
Real-time update of sample information is realized, information inconsistency is avoided, the traceability and efficiency of sample flow is improved, data integrity and accuracy is ensured, and management chaos and wrong operations are reduced.
Smart Images

Figure CN119885043A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of intelligent sample collection management, and in particular to an intelligent sample collection management method, device, equipment and medium. Background Art
[0002] In the traditional sample circulation management process, the collection, storage and circulation of samples mainly rely on manual operation and single-point information entry, which leads to delayed data updates and the problem of inconsistent information. Taking the warehouse management system (WMS) and laboratory information management system (LIMS) as examples, the entry and exit of samples usually require manual scanning or manual entry, which not only increases the possibility of human error, but also causes delays in information synchronization. Due to the lack of efficient data interaction mechanism between different systems, data missing, duplicate records or status errors will occur in multiple links during the sample circulation process. For example, a batch of samples has been sent to the laboratory for testing, but because the information system failed to be updated in time, the WMS still shows that it is in the warehouse state, which will cause confusion for subsequent managers during inventory verification and experimental arrangements. Especially when it involves collaborative management of multiple terminals (such as Web, PDA, and APP), untimely information updates will directly affect the traceability and circulation efficiency of samples. Summary of the invention
[0003] In order to solve the problem that untimely information updating will directly affect the traceability and circulation efficiency of samples when collaborative management involves multiple terminals (such as Web terminals, PDA terminals, and APP terminals), the present application provides an intelligent sample collection management method, device, equipment and medium.
[0004] An intelligent sampling management method, the intelligent sampling management method comprising: Obtaining a sample transfer request, and synchronizing basic sample data between information systems based on the transfer request, the information systems including a warehouse management system, a laboratory information management system, and a mobile terminal device; By using multi-threaded positioning technology, the location data corresponding to the basic data is determined in real time, and a corresponding sample flow log is generated based on the basic data and the location data; Analyze the sample flow log based on the established flow anomaly recognition model to generate corresponding recognition results; If the recognition result is an abnormal result, performing corresponding abnormality handling operations and / or alarm operations according to the abnormal result; If the identification result is a normal result, the corresponding log fragments in the sample flow log are synchronized between each of the information systems according to a predetermined synchronization rule.
[0005] By adopting the above technical solution, sample transfer requests are obtained and sample basic data is synchronized between the warehouse management system (WMS), laboratory information management system (LIMS) and mobile terminal devices, so that information such as sample entry, exit and transfer can be updated in real time between systems, avoiding information inconsistency caused by manual entry or system delay. Secondly, the method uses multi-threaded positioning technology to determine the location information of the sample in real time, and generates a sample flow log in combination with basic data, thereby ensuring the traceability of the sample flow between the warehouse and the laboratory, no longer relying on manual records or single-point scanning, and reducing the management confusion caused by the inability of traditional technology to track the location of samples in real time. Furthermore, based on the established flow anomaly recognition model, the method can automatically analyze the flow log, identify abnormal flow situations, and promptly discover and warn of data missing, duplicate records or status errors, ensuring the integrity and accuracy of the data. When an anomaly is identified, the system can automatically trigger an exception handling or alarm operation, so that management personnel can intervene in time to prevent inventory confusion or experimental arrangement errors caused by untimely information updates. In addition, for normal circulation data, this method uses preset synchronization rules to ensure that each log fragment of the sample circulation log is consistent between WMS, LIMS and mobile terminals, avoiding information errors caused by asynchronous data updates in different systems in traditional technologies. This intelligent sample collection management method not only improves the efficiency of sample circulation, but also ensures the real-time and accuracy of data, fundamentally solving the problems of delayed information updates and poor system interaction in traditional management models.
[0006] In a preferred example, the present application may be further configured as follows: the step of synchronizing basic data of the sample between information systems based on the transfer request includes: Extracting key fields from the transfer request; Match the corresponding sample code according to the key field; Based on the sample code, the corresponding shelf codes in each information system are matched to determine whether the shelf codes are consistent. If they are inconsistent, corresponding abnormal identification data is generated; If they are consistent, a circulated mark is added to the information system that matches the listing code, and a non-circulated mark is added to the information system that does not match the listing code; The circulated identification, the shelf code and / or the abnormal identification data are integrated to generate corresponding basic data.
[0007] By adopting the above technical solution, it is possible to automatically parse the key fields in the circulation request, and verify whether the sample's shelf code is consistent based on the matching rules, so that the sample data between different systems can be accurately matched and verified. When an inconsistency is detected, the system automatically generates abnormal identification data, so that managers can promptly discover and handle potential circulation errors. At the same time, for samples that circulate normally, the system can assign corresponding circulation status identification to them, so as to realize automatic identification and management of circulation data between systems. This not only reduces the workload of manual verification, but also improves the reliability of data verification, and reduces the risk of data omission or duplication during sample circulation.
[0008] In a preferred example, the present application may be further configured as follows: the step of determining the location data corresponding to the basic data in real time by using the multi-threaded positioning technology includes: Matching a corresponding multi-thread management mechanism according to the listing code in the basic data; Based on the multi-thread management mechanism, configure independent threads and collect adjustment parameters for corresponding mobile terminal devices; Based on the mobile terminal device configured with the independent thread and the acquisition adjustment parameter, the corresponding single-thread data is acquired, the single-thread data is stored in a temporary buffer area, and the corresponding data attributes are recorded in the temporary buffer area, wherein the data attributes include a timestamp and a signal strength; Substituting each of the single-threaded data into the determined fusion algorithm to generate corresponding preliminary data; The historical flow data is called, and according to a comparison result between the historical flow data and the preliminary data, it is determined whether to determine the preliminary data as the position data.
[0009] By adopting the above technical solution, it is possible to realize parallel processing of sample positioning data based on a multi-thread management mechanism, so that mobile terminal devices can collect data simultaneously in different threads to improve positioning efficiency. At the same time, the data collected by each thread will be stored in a temporary cache area, and attribute information such as timestamp and signal strength will be attached to facilitate accurate calculations during subsequent data fusion. By setting a fusion algorithm to perform synthetic calculations on the data of multiple threads and verifying it in combination with historical flow data, the final generated sample location data is more accurate, avoiding positioning deviations caused by large errors in single positioning source data, thereby improving the accuracy and real-time performance of sample tracking.
[0010] In a preferred example, the present application may be further configured as follows: the step of generating a corresponding sample flow log based on the basic data and the location data includes: Determine a classification rule for the sample flow log, wherein the classification rule includes a field standardization processing rule and a field arrangement rule, wherein the classification rule is determined according to the category of the information system; Based on the field standardization processing rule, the basic data and the location data are integrated and standardized to generate various classification fields, and associated fields and / or abnormal identification fields associated with each of the classification fields, wherein the abnormal identification fields are generated based on the abnormal identification data; Based on the field arrangement rule, the classification field, the association field and / or the abnormal identification field are rearranged to generate a plurality of flow entries arranged according to the classification field, wherein the classification field is arranged at the first position of the flow entry; Determine the flow entry containing the abnormal identification field as an abnormal entry, and perform a highlighting operation and a statistical positioning operation; Integrate multiple flow entries arranged according to classification fields, and / or perform abnormal entries after highlighting and statistical positioning operations to generate corresponding sample flow logs.
[0011] By adopting the above technical solution, the fields of the circulation log can be standardized, and the fields can be classified and arranged according to the categories of the information system, so that the log data can be stored and managed in a structured manner. During the log generation process, the system can organize the circulation entries in the order of the classification fields based on the field arrangement rules, and automatically detect the abnormal identification fields therein, so as to highlight and statistically locate the abnormal data when it appears. This can not only ensure the uniform format of the circulation log and improve the readability of the log data, but also quickly identify and locate abnormal samples when sample circulation anomalies occur, improve the efficiency of abnormal handling, and enhance the reliability of sample circulation management.
[0012] In a preferred example, the present application may be further configured as follows: in the step of analyzing the sample flow log based on the established flow anomaly recognition model to generate a corresponding recognition result, the recognition result includes an abnormal result and a normal result, and the abnormal result includes a first abnormal recognition result and a second abnormal recognition result, and the step further includes: Searching whether there is an abnormal entry in the sample flow log, and if so, generating a corresponding first abnormality identification result according to the abnormal entry; If it does not exist, based on the established flow anomaly identification model, selecting the target field required by the established flow anomaly identification model from the classification field and the association field in each of the flow entries; If the target field is a timestamp field and a location coordinate field, logical matching is performed on the target field according to the abnormal condition rule library predefined in the established flow abnormality recognition model, and a corresponding abnormal mark is output; If the target field is an operation type field, the historical abnormal operation data set is called, and features are compared with the operation type field to output a corresponding abnormal probability value; If the abnormal mark is detected to appear and / or the abnormal probability value exceeds a preset probability threshold, a corresponding second abnormality identification result is generated.
[0013] By adopting the above technical solution, it is possible to automatically retrieve abnormal entries based on the data in the sample flow log and generate a first abnormal identification result to ensure that known abnormal data can be quickly identified. At the same time, the system can also conduct in-depth analysis of the target fields in the log based on the established flow anomaly identification model, and output abnormal marks or abnormal probability values through logical matching of timestamp fields and location coordinate fields, or feature comparison of operation type fields. When an abnormal mark is detected, or the abnormal probability value exceeds the preset threshold, the system can generate a second abnormal identification result, thereby realizing intelligent prediction of potential anomalies, improving the comprehensiveness and accuracy of sample anomaly detection, and enabling managers to take timely countermeasures to reduce management risks brought about by abnormal circulation.
[0014] In a preferred example, the present application can be further configured as follows: the step of generating the abnormal condition rule base predefined in the established flow abnormality recognition model includes: Obtain timestamp conflict events and position offset events in historical abnormal flow logs, and extract conflict time intervals and offset distance thresholds; generating a timestamp conflict rule according to the conflict time interval; Generate a position offset rule according to the offset distance threshold, specifically: if the Euclidean distance between the position coordinate field in the current flow entry and the standard coordinate of the preset flow path exceeds the offset distance threshold, trigger a position offset mark; Storing the timestamp conflict rule and the position offset rule in the abnormal condition rule library; In the step of performing logical matching on the target field according to the abnormal condition rule base predefined in the established flow abnormality recognition model and outputting the corresponding abnormal mark, the abnormal mark includes a timestamp conflict mark and a position offset mark, and the step further includes: If the target field is a timestamp field, based on the timestamp conflict rule, determine whether the difference between the timestamp field and the timestamp field in the adjacent flow entry is less than a preset time threshold, and if so, trigger a timestamp conflict mark; If the target field is a location coordinate field, based on the location offset rule, it is determined whether the Euclidean distance between the location coordinate field and the standard coordinates of the preset flow path exceeds the offset distance threshold, and if so, a location offset mark is triggered.
[0015] By adopting the above technical solution, it is possible to build an abnormal condition rule base based on historical abnormal flow logs, and generate corresponding timestamp conflict rules and position offset rules by extracting the key features of timestamp conflict events and position offset events. The system can use these rules to perform logical matching on newly collected flow data, and judge whether the flow data complies with standard operating specifications based on preset thresholds. When the system detects that the deviation of the timestamp field or the location coordinate field exceeds the set threshold, it automatically triggers the abnormal mark to ensure that any time conflict or location abnormality can be discovered and handled in time. This can not only reduce the omission of abnormalities due to misjudgment or information lag, but also improve the safety and controllability of the sample flow process and optimize the overall abnormal management mechanism.
[0016] The second object of the invention is achieved by the following technical solutions: An intelligent sample collection management device, the intelligent sample collection management device comprising: A first acquisition module, used to obtain a sample transfer request, and synchronize basic sample data between information systems based on the transfer request, wherein the information systems include a warehouse management system, a laboratory information management system, and a mobile terminal device; A determination module, used to determine the location data corresponding to the basic data in real time through a multi-threaded positioning technology, and generate a corresponding sample flow log based on the basic data and the location data; An analysis module, used to analyze the sample flow log based on the established flow anomaly recognition model to generate a corresponding recognition result; An execution module, configured to execute a corresponding exception handling operation and / or an alarm operation according to the abnormal result if the recognition result is an abnormal result; A synchronization module is used to synchronize corresponding log segments in the sample flow log between each of the information systems according to a predetermined synchronization rule if the identification result is a normal result.
[0017] The third objective of the present application is achieved through the following technical solutions: A computer device comprises a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the above-mentioned intelligent sampling management method when executing the computer program.
[0018] The fourth objective of the present application is achieved through the following technical solutions: A computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the above-mentioned intelligent sampling management method are implemented.
[0019] In summary, the present application includes at least one of the following beneficial technical effects: This application obtains sample circulation requests and synchronizes sample basic data between warehouse management systems (WMS), laboratory information management systems (LIMS) and mobile terminal devices, so that information such as sample entry, exit, and circulation can be updated in real time between systems, avoiding information inconsistency problems caused by manual entry or system delays. Secondly, the method uses multi-threaded positioning technology to determine the location information of samples in real time, and generates sample circulation logs in combination with basic data, thereby ensuring the traceability of sample circulation between warehouses and laboratories, no longer relying on manual records or single-point scanning, and reducing management confusion caused by the inability of traditional technologies to track sample locations in real time. Furthermore, based on the established circulation anomaly recognition model, the method can automatically analyze circulation logs, identify abnormal circulation situations, and promptly discover and warn of data missing, duplicate records, or status errors, ensuring data integrity and accuracy. When an anomaly is identified, the system can automatically trigger an exception handling or alarm operation, allowing management personnel to intervene in time to prevent inventory confusion or experimental arrangement errors caused by untimely information updates. In addition, for normal circulation data, this method uses preset synchronization rules to ensure that each log fragment of the sample circulation log is consistent between WMS, LIMS and mobile terminals, avoiding information errors caused by asynchronous data updates in different systems in traditional technologies. This intelligent sample collection management method not only improves the efficiency of sample circulation, but also ensures the real-time and accuracy of data, fundamentally solving the problems of delayed information updates and poor system interaction in traditional management models. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] Figure 1 This is a flow chart of an intelligent sample collection management method in one embodiment of the present application; Figure 2 This is a flowchart for implementing step S10 in an intelligent sampling management method in one embodiment of the present application; Figure 3 This is a flowchart for implementing step S20 in an intelligent sampling management method in one embodiment of the present application; Figure 4 This is another implementation flow chart of step S20 in an intelligent sampling management method in an embodiment of the present application; Figure 5 This is a flowchart for implementing step S30 in an intelligent sampling management method in one embodiment of the present application; Figure 6 This is another implementation flow chart of an intelligent sampling management method in one embodiment of the present application; Figure 7 This is a flowchart for implementing step S303 in an intelligent sampling management method in one embodiment of the present application; Figure 8 This is a principle block diagram of an intelligent sample collection management device in one embodiment of the present application; Fig. 9 It is a schematic diagram of a device in an embodiment of the present application. DETAILED DESCRIPTION
[0021] The present application is further described in detail below in conjunction with the accompanying drawings.
[0022] In one embodiment, if Figure 1 As shown, the present application discloses an intelligent sample collection management method, which specifically includes the following steps: S10, obtaining a sample transfer request, and synchronizing the basic data of the sample between information systems based on the transfer request, the information system includes a warehouse management system, a laboratory information management system and a mobile terminal device; in this embodiment, obtaining a sample transfer request refers to receiving a sample transfer instruction initiated by a user through an interface of a mobile terminal device or a warehouse management system, for example, a laboratory needs to transport a batch of samples from a warehouse to a testing station. The transfer request must include key information such as the sample number, batch number, and target transfer location. The process of synchronizing basic data is to synchronize the inventory information in the warehouse management system, the test task data in the laboratory information management system, and the real-time operation records in the mobile terminal device through a predefined data interface protocol (such as REST API or MQTT protocol) to ensure that the basic attributes of the samples in all systems (such as storage conditions, validity period, current status) remain consistent. For example, when a sample is marked as "out of the warehouse" in the warehouse management system, the laboratory information management system will automatically update the status of the sample to "in transit", and the real-time transportation path will be displayed on the mobile terminal device. This cross-system data synchronization mechanism can eliminate information islands and avoid process interruptions caused by data delays or conflicts.
[0023] S20. Through multi-threaded positioning technology, the location data corresponding to the basic data is determined in real time, and the corresponding sample flow log is generated based on the basic data and the location data; in this embodiment, the multi-threaded positioning technology refers to allocating independent computing threads to each mobile terminal device involved in the sample flow (such as a GPS module or a handheld scanner on a transport vehicle), and collecting positioning signals from different devices (such as GPS coordinates, Bluetooth beacon distances, or RFID read and write locations). For example, when the sample is transported from the warehouse to the laboratory, the GPS module on the transport vehicle continues to send longitude and latitude data, and the handheld scanner reads the location information of the sample tag through RFID during the handover. The system merges multi-source positioning data into accurate real-time location coordinates through timestamp alignment and signal strength weighting algorithms. The generated sample flow log records the relationship between the location data and the basic data (such as environmental parameters such as temperature and humidity) at each time point, for example, "2023-10-01 14:30:00, sample A-001 is located at coordinates (X, Y, Z), ambient temperature 23°C". This high-precision log can provide a complete spatiotemporal trajectory evidence chain for subsequent abnormal analysis.
[0024] S30. Analyze the sample flow log based on the established flow anomaly recognition model to generate corresponding recognition results; in this embodiment, the flow anomaly recognition model adopts a hybrid architecture, including a real-time detection module based on a rule engine and a probability prediction module based on machine learning. The rule engine module directly marks abnormal events through predefined logical conditions (such as "transportation time exceeds the threshold" or "location deviates from the preset path by more than 50 meters"). For example, if a sample is detected to be stagnant for more than 2 hours during transportation, a "transportation delay" alarm is triggered. The machine learning module trains the classification model through historical abnormal data and analyzes the hidden patterns in the log, such as predicting the risk of sample deterioration due to environmental temperature and humidity fluctuations through time series analysis. The input features of the model include timestamp interval, location movement rate, environmental parameter change gradient, etc., and the output result is an abnormal probability value. When the rule engine and the machine learning module trigger an abnormality at the same time, the system will mark the recognition result as "high confidence abnormality" to reduce the false alarm rate.
[0025] S40. If the recognition result is an abnormal result, the corresponding exception handling operation and / or alarm operation is performed according to the abnormal result; in this embodiment, the exception handling operation is divided into two categories: automatic intervention and manual intervention. For example, when the system detects that the transportation path of a sample deviates from the preset route and the ambient temperature exceeds the standard, the automatically executed operations include: sending instructions to the transport vehicle to force the temperature control equipment to cool down, and pushing alarm information (such as SMS or APP notification) to the person in charge through the mobile terminal, and marking the abnormal path segment in red on the map. For exceptions that require manual processing (such as damaged sample labels that cannot be identified), the system will generate an emergency task order and assign it to the nearest inspection personnel, and freeze the status of the sample in the warehouse management system to prevent misoperation. The alarm operation supports a hierarchical mechanism. For example, "low temperature warning" only records logs, while "location loss for more than 30 minutes" will trigger an audible and visual alarm and notify the superior administrator.
[0026] S50. If the identification result is a normal result, the corresponding log fragment in the sample flow log is synchronized between each information system according to the predetermined synchronization rules. In this embodiment, the synchronization rules define the key fields and trigger conditions of the log fragment. For example, when the sample completes the laboratory test and is marked as "normal", the system only synchronizes the test time, the tester number and the result summary to the warehouse management system, while the detailed test data (such as the spectral analysis chart) is retained in the laboratory information management system. The synchronization process adopts an incremental update method, and asynchronous transmission is realized through a message queue (such as Kafka) to avoid system blocking. For example, when the mobile terminal uploads the handover completion record, the system will automatically extract fields such as "handover time" and "recipient signature", and encrypt and synchronize them to the test task board of the laboratory system. This on-demand synchronization mechanism reduces redundant data transmission, while ensuring that each system only obtains necessary information related to its function, improving data security and processing efficiency.
[0027] In one embodiment, if Figure 2 As shown, in step S10, i.e., the step of synchronizing basic data of samples between information systems based on the transfer request, it includes: S101. Extract key fields in the circulation request; in this embodiment, extracting key fields in the circulation request refers to parsing the necessary information for uniquely identifying samples and circulation paths from the circulation application submitted by the user. For example, when a laboratory initiates a test request for a batch of drugs, the circulation request must include fields such as the batch number, production date, storage warehouse number, and target laboratory number of the drug. These fields are structured and extracted using regular expressions or predefined JSON templates, such as automatically identifying "Batch Number: 2023-ABC-001" from unstructured text and mapping it to standardized fields. This process can filter out redundant information (such as the applicant's remarks) to ensure that subsequent processes only process core data, thereby reducing the waste of computing resources and improving data processing efficiency.
[0028] S102. Match the corresponding sample code according to the key field; in this embodiment, matching the sample code means comparing the extracted key field with the database records in the warehouse management system and the laboratory system to generate a globally unique sample identification code. For example, the corresponding sample code "SAMP-2023-09876" is queried in the inventory table of the warehouse management system through the batch number "2023-ABC-001", and it is verified whether the code is bound to the detection task in the laboratory system. The matching process adopts database joint query technology. If it is found that the same batch number has multiple conflicting codes in different systems (such as the warehouse system record is "SAMP-2023-09876", and the laboratory system mistakenly stores it as "SAMP-2023-9876"), the anomaly detection process is triggered. This step ensures the consistency of data across systems and avoids sample mismatch or loss due to coding errors.
[0029] S103, based on the sample code, match the corresponding shelf code in each information system, determine whether the shelf codes are consistent, if not, generate corresponding abnormal identification data; in this embodiment, the shelf code refers to the physical or logical location identification of the sample in a specific system. For example, the shelf code in the warehouse management system is "Area A-3 rows-5 layers" (indicating the shelf location), and the shelf code in the laboratory information management system is "biochemical test bench-02" (indicating the test equipment number). The system queries the associated shelf code in the two systems through the sample code "SAMP-2023-09876". If the warehouse system returns "Area A-3 rows-5 layers", and the laboratory system returns "unassigned", it is determined to be inconsistent and generates abnormal identification data (such as error code "ERR_LOC_MISMATCH"). This mechanism can detect location information conflicts caused by manual operation errors or system synchronization delays in real time, such as when the sample has been shipped out but the laboratory has not allocated testing resources.
[0030] S104. If they are consistent, a circulated mark is added to the information system that matches the shelf code, and a non-circulated mark is added to the information system that does not match the shelf code; in this embodiment, the circulated mark and the non-circulated mark are used to mark the processing status of each system in this circulation. For example, when the shelf codes of the storage system and the laboratory system are successfully matched, the system will add an "out of the warehouse" mark to the sample record in the storage system and a "pending detection" mark in the laboratory system; and for unmatched mobile terminal devices (such as a barcode scanner that does not respond to queries), it is marked as "not ready". These identifiers are implemented through database status fields or log marks, such as updating the "status" field to "TRANSFERRED" in MySQL. This design can clarify the responsibility boundaries of each link. For example, when a sample is lost during transportation, the device failure node can be quickly located by checking the "not ready" mark of the mobile terminal.
[0031] S105, integrate the circulated identification, shelf code and / or abnormal identification data, and generate corresponding basic data. In this embodiment, the integration process is to merge the status information, location code and abnormal records scattered in different systems into a basic data entity with a unified structure. For example, the "shipped" identification of the storage system, the "biochemical test station-02" shelf code of the laboratory system and the "in transit" status reported by the mobile terminal are encapsulated as basic data in JSON format: {status:"in transit", "warehouse_location":"A area-3 rows-5 floors", "lab_location":"biochemical test station-02", "errors":[]}. If there is abnormal identification data (such as ERR_LOC_MISMATCH), it is added to the "errors" array and accompanied by a timestamp and source system information. The basic data will serve as the only input source for subsequent circulation logs and abnormal analysis to ensure that the full-link data is traceable and the format is standardized. For example, in the subsequent process, an alarm can be triggered directly based on the "errors" field without secondary parsing of the original system log.
[0032] In one embodiment, if Figure 3 As shown, in step S20, i.e., the step of determining the position data corresponding to the basic data in real time by using the multi-threaded positioning technology, includes: S2011, according to the shelf code in the basic data matching corresponding multi-threaded management mechanism; In the present embodiment, the shelf code is a kind of information coding for uniquely identifying the storage location of the sample, and each sample will be assigned a shelf code when entering the warehouse, which is usually associated with the warehouse location number, shelf number, storage area number, etc., so that the storage location of the sample can be accurately located during the sample circulation process. The multi-threaded management mechanism is a computing resource management strategy, which can automatically allocate computing tasks according to different shelf codes, so that the positioning calculations of multiple samples can be carried out in parallel, thereby improving the computing efficiency of the system. Under the traditional single-threaded positioning method, the location information of the sample needs to be processed in sequence, resulting in computing delays in high concurrency situations, affecting the real-time nature of the data. Through the multi-threaded management mechanism, data processing tasks can be reasonably allocated between multiple computing threads according to the different shelf codes, so that the location information of the sample can be calculated simultaneously, improving the throughput of the positioning calculation. For example, when a batch of samples are stored at the same time and distributed in different storage areas, the system can automatically assign computing tasks to multiple independent threads according to the shelf code, so that each thread can independently calculate the location information of samples in the corresponding area, avoiding competition and bottlenecks for computing resources, thereby improving overall positioning efficiency.
[0033] S2012, based on the multi-thread management mechanism, configure independent threads and acquisition adjustment parameters for the corresponding mobile terminal device; in this embodiment, the mobile terminal device includes but is not limited to PDA handheld devices, RFID scanners, smart tag readers, Wi-Fi location detectors, Bluetooth Beacon receivers, etc. These devices are used to collect the location information of samples during the sample circulation process, and upload them to the system for processing through wireless or wired communication. The configuration method of the independent thread is to dynamically adjust according to the storage area of the sample, the workload of the device, and the priority of data acquisition to ensure that each device can obtain reasonable computing resource support during the data acquisition process and avoid acquisition delays caused by resource competition between threads. The acquisition adjustment parameters are used to optimize the data acquisition method of the device, including adjusting the data acquisition frequency, setting the signal filtering threshold, optimizing the acquisition range, etc. For example, in a high-density storage environment, due to the large number of RFID tags, the system can automatically reduce the scanning frequency to reduce the data redundancy caused by repeated scanning, and in an environment with large signal interference, the system can increase the judgment threshold of the signal strength to filter out noise data and improve the accuracy of the collected data.
[0034] S2013. Based on the mobile terminal device configured with independent threads and acquisition adjustment parameters, the corresponding single-thread data is obtained, the single-thread data is stored in a temporary buffer area, and the corresponding data attributes are recorded in the temporary buffer area, and the data attributes include timestamp and signal strength; in this embodiment, the single-thread data refers to the sample location information collected by a certain independent thread, such as the tag identification data obtained by the RFID scanner, the sample signal strength information detected by the Wi-Fi AP, and the sample reception time recorded by the Bluetooth Beacon device. The temporary buffer area is an intermediate storage area for storing real-time acquisition data, which can ensure that all collected data will not be lost before further calculation, and also facilitate subsequent data fusion processing. The timestamp is used to record the precise acquisition time of each piece of data to ensure that the data can be correctly sorted in the subsequent positioning calculation to avoid data confusion. Signal strength refers to the signal power value received by the device, such as the RSSI (Received Signal Strength Indicator) of the RFID signal, which is used to evaluate the relative distance between the sample and the read-write device. For example, when an RFID scanner scans a sample, it will return multiple signal data. The system will store the value with the highest signal strength and record the reception time of the signal to improve the accuracy of positioning.
[0035] S2014, substitute each single-thread data into the determined fusion algorithm to generate corresponding preliminary data; in this embodiment, the fusion algorithm is used to integrate the data collected by multiple devices or multiple threads to improve the calculation accuracy of the sample position. Since there are certain errors in the data collected by different devices, or due to environmental factors (such as metal interference, signal shielding, etc.), individual data has large deviations, it is necessary to optimize and correct the collected single-thread data through a data fusion algorithm. Common data fusion algorithms include but are not limited to weighted average method, Kalman filter, particle filter, etc. For example, the weighted average method will give different weights according to the confidence of different sensor data, and calculate the final location information; Kalman filter can be dynamically corrected based on historical data and current observation data, reduce random errors, and improve the stability of positioning; particle filter can be used for positioning optimization in nonlinear environments, and is suitable for complex storage environments. In a specific application, assuming that the RFID scanner and Wi-Fi AP simultaneously obtain the location data of a sample, where the RFID signal indicates that the sample is on shelf A, and the Wi-Fi signal indicates that the sample is closer to shelf B, the fusion algorithm can comprehensively calculate the confidence of these two sets of data, and finally obtain the best storage location of the sample.
[0036] S2015, call historical circulation data, and determine whether to determine the preliminary data as location data based on the comparison results between the historical circulation data and the preliminary data. In this embodiment, the historical circulation data refers to the past storage location and circulation trajectory of the sample recorded in the system, which is usually stored in the database and can be used to compare whether the currently calculated location information conforms to the normal circulation mode of the sample. The purpose of this step is to verify the accuracy of the preliminary data through historical data to prevent incorrect positioning due to acquisition errors or signal interference. For example, if the historical records of a sample show that it has been stored in the A warehouse for 90% of the time in the past, and the current positioning data suddenly shows that it is in the C warehouse, the system will further analyze the reliability of the location information and require additional data verification, such as re-scanning or comparison with manual operation records. In addition, in scenarios with high precision requirements such as cold chain management and storage of dangerous goods, this step is particularly important, which can effectively avoid sample storage anomalies caused by incorrect positioning. For example, in refrigerated sample management, if the historical storage location of a refrigerated sample has always been in the refrigerated area, but new location data shows that it is stored in the normal temperature area, the system can trigger an alarm to prompt the management staff to check to ensure that the sample has not been misplaced or damaged.
[0037] In one embodiment, if Figure 4 As shown, in step S20, i.e., the step of generating a corresponding sample flow log based on the basic data and the location data, it includes: S2021. Determine the classification rules of the sample flow log, wherein the classification rules include field standardization processing rules and field arrangement rules, wherein the classification rules are determined according to the category of the information system; in this embodiment, the sample flow log is a detailed data set that records the flow process of samples between warehouses, laboratories and various links. In order to ensure the uniformity and readability of the log data, a set of standardized processing rules needs to be established. The field standardization processing rules are used to format and convert data from different data sources so that they can be compatible with each other between different systems. For example, the sample data fields in the warehouse management system (WMS) include "sample number", "storage location", "warehouse entry time", etc., while the sample data fields in the laboratory information management system (LIMS) include "test number", "experimental progress", "test results", etc. The data formats of the two are different. If standardization is not performed, the log data will lose information or cause data structure confusion when it is transmitted between different systems. Therefore, the system will convert the data of different systems into a unified data structure according to the field standardization rules, such as expressing "storage location" as "storage location number" in the warehouse management system and "laboratory area number" in the laboratory information management system, and storing it in the log with the standard field name "location number" to ensure the consistency of log records. The field arrangement rule is used to specify the organization method of log data storage, so that the data can be sorted in a certain order to facilitate subsequent query and analysis. For example, in the warehouse management system, the sample flow log is sorted by storage location so that managers can quickly view the sample storage status of a certain warehouse area, while in the laboratory information management system, the sample flow log is sorted by experimental batch number so that the experimenter can track the testing progress of the same batch of samples. The classification rule is determined according to the category of the information system, which means that the data classification method between different systems can be different to meet different business needs. For example, the classification in the warehouse management system is based on storage area, shelf number, etc., while the classification in the laboratory management system is based on experimental tasks, sample categories, etc. When samples flow from the storage system to the laboratory, the system will automatically adjust the organization of the log according to the information category, so that operators of different systems can view the log according to their familiar classification methods, thereby improving the convenience of data query.
[0038] S2022, based on the field standardization processing rules, integrate and standardize the basic data and location data to generate each classification field, and the associated fields and / or abnormal identification fields associated with each classification field, and the abnormal identification field is generated based on the abnormal identification data; in this embodiment, the basic data refers to the static information of the sample, including the sample ID, specification, batch number, manufacturer, etc., and the location data refers to the geographical location information of the sample during the circulation process, including the warehouse number, laboratory number, storage equipment number, etc. Since the basic data and location data come from different systems, their formats are different, so they need to be standardized. For example, the basic data of a sample is stored in a warehouse management system, and the location data is the signal data collected in real time by the RFID device. In order to ensure that the log can accurately record these data, the system will convert the data according to the field standardization processing rules to make it conform to a unified storage format. In addition, during the standardization process, the system will automatically generate classification fields, such as "sample category", "storage area", etc., so that the log can be organized according to different classification methods. At the same time, in order to improve the data integrity of the log, the system will also generate associated fields associated with the classification fields. For example, when the classification field of a sample is "refrigerated sample", its associated fields include "storage temperature", "storage equipment", etc., in order to provide more detailed information. The abnormal identification field is used to mark abnormal situations in the log. For example, when the system detects that the storage location of the sample has changed abnormally, or the circulation time is abnormally short, indicating human error or system failure, the system will automatically add an abnormal identification field to the log to prompt the management personnel to check. For example, the historical storage location of a sample is "refrigerated area", but the latest location information shows that it is stored in the "normal temperature area". The system will automatically add the abnormal identification "storage location abnormality" to the log for subsequent abnormal analysis.
[0039] S2023. Based on the field arrangement rule, the classification field, the association field and / or the abnormal identification field are rearranged to generate a plurality of flow entries arranged according to the classification field, wherein the classification field is arranged at the first position of the flow entry; in this embodiment, the main function of the field arrangement rule is to ensure the readability and traceability of the log data, so that the management personnel can view the detailed information of the sample flow in a certain logical order. The classification field is the main retrieval basis of the log, so it needs to be arranged in the first position so that the relevant data can be quickly located when querying the log. For example, in a warehouse management system, the log data can be sorted according to the sample storage location, so that the management personnel can quickly find all the sample flow records of a certain storage location, and in a laboratory management system, the log data can be sorted according to the experimental batch number, so that the experimenter can quickly find the progress of the sample detection of a certain batch. The association field is used to supplement the information of the classification field. For example, in a log sorted by sample category, the association field includes information such as the supplier and production date of the sample, so as to provide more detailed data support. The abnormal identification field is used to mark abnormal situations in the log, so that abnormal records can be quickly filtered out when querying data. For example, in a laboratory sample management system, the sample flow log is classified according to the experimental task first. The classification field is the experimental batch number, and the associated fields are the sample number and the tester information. If an abnormality occurs during the flow of a sample, such as an abnormal change in the storage location, the abnormal identification field will be automatically added to the log and highlighted for subsequent processing.
[0040] S2024, determine the circulation entry containing the abnormal identification field as an abnormal entry, and perform a highlight prompt operation and a statistical positioning operation; in this embodiment, the abnormal entry refers to a log record containing an abnormal identification field, which usually represents an abnormal situation that occurs during the sample circulation process, such as the storage location deviating from the historical storage path, the sample circulation time is too short or too long, etc. During the log generation process, the system will automatically detect these abnormal entries and prompt them by highlighting, color marking, etc., so that managers can quickly identify and handle abnormalities. For example, during sample inventory, if the storage location of a sample has changed significantly, such as moving from a high temperature area to a low temperature area, the system will automatically mark the entry in red and add a detailed abnormal description to the abnormal log to remind managers to review. At the same time, the statistical positioning operation is used to calculate the frequency of abnormal occurrence, the scope of influence, and the information of the associated samples to help managers analyze the causes of abnormal occurrence. For example, if the storage frequency of a batch of samples is high, it indicates that there is a management problem in the storage area. The system can automatically generate an abnormal report and recommend optimization measures, such as adjusting the storage rules or adding automatic detection equipment.
[0041] S2025, integrate multiple circulation entries arranged according to classification fields, and / or perform highlight prompt operation and statistical positioning operation after abnormal entries, generate corresponding sample circulation log. In the present embodiment, the final integration of the circulation log is completed based on the above steps, that is, all circulation entries will be organized according to the classification field, and abnormal entries will be marked separately to ensure the integrity and readability of the log content. The final log not only includes the basic information, location data, and classification information of the sample, but also contains abnormal situations that occur during the circulation process, and provides detailed timestamps, operators, abnormal identification and other information for subsequent analysis and query. For example, in the sample management system, managers can directly open the circulation log, view the historical circulation records of a sample, and quickly locate abnormal records without manually retrieving multiple databases. At the same time, the system can also generate a circulation analysis report based on the log data to help optimize the sample management process and improve circulation efficiency.
[0042] In one embodiment, if Figure 5 As shown, in step S30, i.e., the step of analyzing the sample flow log based on the established flow anomaly recognition model to generate a corresponding recognition result, the recognition result includes an abnormal result and a normal result, and the abnormal result includes a first abnormal recognition result and a second abnormal recognition result. The step also includes: S301. Check whether there are abnormal entries in the sample circulation log. If there are, generate the corresponding first abnormal identification result according to the abnormal entry. In this embodiment, the sample circulation log is a comprehensive data set that records information such as samples in different storage locations, circulation links, operators and operation time. The abnormal entry refers to the entry in the log record that contains an abnormal identification field, such as storage location abnormality, timestamp abnormality, operation step abnormality, etc. When the system performs abnormal analysis, it will first search the log to find out whether there are entries with abnormal identification fields marked. For example, the storage location of a sample is shown as a cold storage area in the historical record, but the latest circulation record shows that it is stored in the normal temperature area. This change exceeds the allowed circulation path, and the system will automatically identify the log entry as an abnormal entry. If such an abnormality is detected, the system will generate a first abnormal identification result, which can be used directly to warn management personnel or as input data for subsequent abnormal analysis. For example, in a cold chain management system, if the circulation records of a batch of vaccine samples show that they are frequently moved from the cold storage area to the normal temperature area and then back to the cold storage area in a short period of time, the system will automatically identify such abnormal circulation situations, generate the first abnormal identification result, and trigger the alarm mechanism to prevent the vaccine from becoming ineffective due to temperature fluctuations.
[0043] S302, if it does not exist, then based on the established flow anomaly recognition model, select the target field required by the established flow anomaly recognition model from the classification field and the associated field in each flow entry; in this embodiment, the target field refers to the field that needs to be focused on in the abnormal recognition process, such as timestamp, storage location, operation type, etc. These fields play a key role in the sample flow process and can reflect whether the sample flow is normal or not. When the system fails to find the marked abnormal entry in the log, it will further extract the relevant target field from the log data for a more in-depth analysis. For example, in a laboratory management system, the classification field of the sample is "experiment number", and the associated field is "experimenter", "experimental equipment number", etc. The system will extract the fields that best reflect abnormal behavior, such as "sample storage location", "experiment start time", "experimental operator", etc., based on the needs of the abnormal recognition model, so as to analyze whether there is abnormal flow in the future.
[0044] S303, if the target field is a timestamp field and a location coordinate field, the target field is logically matched according to the abnormal condition rule base predefined in the established flow abnormality recognition model, and the corresponding abnormal mark is output; in this embodiment, the timestamp field refers to the time information of the sample flow in different links, such as the storage time, storage time, and outbound time, and the location coordinate field refers to the specific storage location of the sample in the storage or laboratory environment, such as the storage location number, shelf number, and laboratory table number. The abnormal condition rule base is a set of rules summarized from historical abnormal data, including time conflict rules, location offset rules, and flow path rationality rules. When the system detects that there is an abnormality in the timestamp field and the location coordinate field, it will perform logical matching based on these rules to determine whether there is an abnormality. For example, if the flow log of a sample shows that it is stored in the A storage location at 10:00, but appears in the B storage location at 10:02, and the normal movement time of these two storage locations takes at least 10 minutes, the system will judge that the flow time of the sample is abnormal according to the time conflict rule, and output the abnormal mark. Similarly, in a hazardous chemical management system, if the historical storage location of a chemical reagent has always been a specific safety cabinet, and the latest storage location is changed to an ordinary shelf, the system will determine that its storage location does not meet the safety storage standards based on the position offset rules, and generate an abnormal mark to remind managers to check.
[0045] S304. If the target field is an operation type field, the historical abnormal operation data set is called, and the feature is compared with the operation type field, and the corresponding abnormal probability value is output; in this embodiment, the operation type field refers to the specific operation that records the sample during the circulation process, such as "warehouse entry", "warehouse exit", "detection", "destruction", etc. The historical abnormal operation data set is a database that stores abnormal operations that occurred in the past, including information such as operators, operation time, operation type, and abnormal frequency. When the system detects the operation type of a sample, it will call the historical abnormal operation data set and compare it with the operation to determine whether the operation has abnormal characteristics. For example, if the operation type of a sample is "warehouse exit", but the system finds that more than 90% of the warehouse exit operations in the historical records of the sample are accompanied by abnormal situations (such as sample damage, experimental failure, etc.), the system will calculate the abnormal probability value of the operation and determine whether it needs to be marked as an abnormal operation. Similarly, in the drug management system, if the "destruction" operation of a high-value drug is usually performed by a senior administrator, but this destruction operation is performed by a low-privilege user and is inconsistent with the historical destruction record, the system will compare the abnormal features, calculate the abnormal probability value, and trigger an alarm when the abnormal probability value exceeds the set threshold to prevent the drug from being illegally destroyed or stolen.
[0046] S305, if the abnormal mark is detected and / or the abnormal probability value exceeds the preset probability threshold, the corresponding second abnormal identification result is generated. In this embodiment, the appearance of the abnormal mark means that there are clear abnormalities in the sample flow log, such as timestamp conflicts, position abnormalities, etc., and the abnormal probability value exceeds the preset threshold, which means that the abnormality of a certain operation is high and needs further verification. When one of these two conditions is met, the system will generate a second abnormal identification result and record the abnormal details, such as the abnormal type, the time of abnormal occurrence, the sample ID involved in the abnormality, etc. For example, in a laboratory sample management system, if the storage location of a sample is abnormal and the abnormal probability value of the operation type exceeds the set 90% threshold, the system will automatically generate a second abnormal identification result and push it to the alarm system of the manager for timely intervention and processing. In addition, in a high-security warehouse management system, if the circulation path of a batch of dangerous goods is greatly deviated from the historical data, and the probability value of the abnormal operation exceeds the preset threshold, the system can further generate an automatic locking command to prevent the batch of dangerous goods from being transported or operated incorrectly to ensure the safety of circulation.
[0047] In one embodiment, if Figure 6 As shown, before step S30, a step of generating a predefined abnormal condition rule base in the established flow abnormality recognition model is also included, and the generating step includes: S60, obtain the timestamp conflict event and position offset event in the historical abnormal flow log, extract the conflict time interval and offset distance threshold; in this embodiment, the historical abnormal flow log refers to the collection of all abnormal event data recorded by the system during the sample flow process, and these logs contain the unique identification, storage location, timestamp, operator, abnormal type and other information of the abnormal sample. The timestamp conflict event refers to the unreasonable time interval of the timestamp of the sample in the log record, for example, the sample is recorded in two storage locations far apart in a short time, or it undergoes multiple flow state changes in a very short time, which exceeds the reasonable operation time range. The position offset event refers to the storage location of the sample being significantly offset in a short time, for example, the normal storage location of the sample is usually in the A laboratory, and the log record shows that it was moved to the B warehouse in a short time, and the physical distance between the two storage locations exceeds the normal flow range. The system automatically extracts these abnormal events, analyzes historical data, calculates the average time interval of the timestamp conflict, and the average threshold of the position offset. For example, in a hazardous materials management system, a certain type of hazardous chemicals usually needs to complete storage confirmation within 10 minutes. If the system finds that there are multiple storage confirmation operations in the historical data with only a 1-minute interval, the system will extract the time interval and mark it as a timestamp conflict event. Similarly, in a cold chain management system, if the storage location of a batch of refrigerated medicines is frequently moved from the cold storage area to the normal temperature area and then back to the cold storage area in a short period of time, and the moving distance exceeds 5 meters, the system will treat the moving distance as a position offset event and record its offset distance threshold.
[0048] S70, generating timestamp conflict rules according to the conflict time interval; In this embodiment, the historical abnormal flow log refers to the collection of all abnormal event data recorded by the system during the sample flow process, and these logs contain information such as the unique identification, storage location, timestamp, operator, and abnormal type of abnormal samples. A timestamp conflict event refers to an unreasonable time interval between the timestamps of the samples in the log records, such as the samples being recorded in two storage locations far apart in a short period of time, or undergoing multiple flow state changes in a very short period of time, which exceeds the reasonable operation time range. A position offset event refers to a significant offset in the storage location of the sample in a short period of time, such as the normal storage location of the sample is usually in laboratory A, and the log record shows that it was moved to warehouse B in a short period of time, and the physical distance between the two storage locations exceeds the normal flow range. The system will automatically extract these abnormal events, analyze historical data, calculate the average time interval of timestamp conflicts, and the average threshold of position offsets. For example, in a hazardous materials management system, a certain type of hazardous chemicals usually needs to complete storage confirmation within 10 minutes, and the system finds that there are multiple storage confirmation operations in the historical data with only 1 minute intervals, then the system will extract the time interval and mark it as a timestamp conflict event. Similarly, in the cold chain management system, if the storage location of a batch of refrigerated medicines is frequently moved from the cold storage area to the normal temperature area and then back to the cold storage area within a short period of time, and the moving distance exceeds 5 meters, the system will treat the moving distance as a position offset event and record its offset distance threshold.
[0049] S80. Generate a position offset rule according to the offset distance threshold; in this embodiment, the position offset rule refers to a reasonable storage position range calculated based on historical data, which is used to determine whether the movement of the sample conforms to the normal circulation mode. After the system analyzes multiple position offset events, it will calculate the average offset distance of the sample in a short time and set an offset threshold. For example, if the system finds that the normal movement range of the sample is usually within 2 meters, and the movement distance of the abnormal storage event is mostly more than 10 meters, the system will set a position offset rule, that is, if the sample moves more than 10 meters in a short time, its storage position is considered abnormal. For example, in a certain intelligent warehousing system, the storage location of some high-value samples is usually fixed on a specific shelf, and the system detects that these samples are moved to another shelf within 5 minutes, and the distance between the shelves exceeds 15 meters, then the system will determine that the movement exceeds the normal circulation range and generate a position offset rule. Similarly, in a laboratory sample management system, samples usually circulate within the laboratory, but if a sample is moved out of the laboratory in a short period of time and appears in the office area or non-laboratory location, and the offset distance exceeds the set threshold, the system will automatically generate a location offset rule and use the rule in subsequent tests to determine whether there is any abnormality in the flow of samples.
[0050] S90, storing the timestamp conflict rule and the position offset rule in the abnormal condition rule base; in this embodiment, the abnormal condition rule base is a database for storing and managing all abnormal detection rules within the system, and the rule base is used to support the execution of the abnormal detection algorithm, so that the system can detect potential abnormal situations in real time during the sample circulation process. The main purpose of storing the timestamp conflict rule and the position offset rule is to provide a standardized judgment basis for subsequent abnormal detection to ensure that the abnormal detection logic under different samples and different environments is consistent. For example, in an intelligent laboratory management system, the system will regularly update the abnormal condition rule base, and adjust the timestamp conflict threshold and the position offset threshold according to the latest abnormal event, so as to continuously optimize the accuracy of abnormal detection. Similarly, in an intelligent warehouse management system, the system can dynamically adjust the rule base according to the logistics data of different storage areas. For example, in a storage area with a high turnover rate, the system will relax the judgment threshold of the timestamp conflict, and in a sensitive storage area (such as a dangerous goods storage area), the system will lower the judgment threshold of the timestamp conflict to improve the level of safety management. In addition, the system can automatically generate anomaly detection reports based on the data in the rule base and provide visual analysis to help managers understand potential problems in sample circulation and optimize warehousing and experimental management processes.
[0051] In one embodiment, if Figure 7 As shown, in step S303, the target field is logically matched according to the abnormal condition rule base predefined in the established flow abnormality recognition model, and the corresponding abnormal mark is output. The abnormal mark includes a timestamp conflict mark and a position offset mark. Step S303 also includes: S3031. If the target field is a timestamp field, based on the timestamp conflict rule, determine whether the difference between the timestamp field and the timestamp field in the adjacent flow entry is less than the preset time threshold, and if it is less than, trigger the timestamp conflict mark; in this embodiment, the timestamp field refers to the time data of the sample in different flow links, such as the sample's storage time, storage time, outbound time, experiment start time, etc. The timestamp conflict rule is used to detect time anomalies in the sample flow process, and usually sets a reasonable time threshold to determine whether two consecutive timestamps conform to the normal flow logic. For example, the average flow time for samples to be transferred from the warehouse to the laboratory usually takes more than 5 minutes, and the system finds that a sample has completed the flow from the warehouse to the laboratory in just 30 seconds. This situation is likely due to data entry errors, repeated label scanning, or failure to actually complete the flow operation. Therefore, the system will calculate the time difference between the timestamp and the previous flow record according to the timestamp conflict rule, and determine whether it is less than the set time threshold. If the time difference is less than the preset time threshold, it means that the sample's circulation time is abnormal, and the system will automatically trigger a timestamp conflict mark to remind management personnel to review the sample's circulation. For example, in a hazardous goods warehouse management system, a certain high-risk chemical usually requires at least 10 minutes of safety inspection and handover confirmation during the circulation process. If the system detects that the sample is moved from warehouse A to laboratory B within 2 minutes, it means that the time interval is much lower than the normal operating time. The system will generate a timestamp conflict mark and record the abnormal event for subsequent review.
[0052] S3032. If the target field is a location coordinate field, based on the location offset rule, determine whether the Euclidean distance between the location coordinate field and the standard coordinate of the preset circulation path exceeds the offset distance threshold, and if it exceeds, trigger the location offset mark. In this embodiment, the location coordinate field refers to the geographical or storage location information used to record the current location of the sample, such as shelf number, laboratory number, storage cabinet number, etc. The location offset rule is used to determine whether the sample is stored according to the normal circulation path, and usually sets an offset distance threshold to calculate the degree of offset between the current position of the sample and the standard storage position. Euclidean distance is a mathematical calculation method for measuring the straight-line distance between two coordinate points. In sample circulation management, Euclidean distance can be used to evaluate the storage offset of the sample. For example, a batch of refrigerated samples is usually stored on shelf one in temperature control area A, and the system detects that the current location of the sample is shelf ten in area B, and the straight-line distance between the two exceeds the set offset distance threshold of 10 meters, which means that the sample is not circulated according to the prescribed storage path, and the system will trigger the location offset mark and mark the storage status of the sample as abnormal. For example, in a laboratory sample management system, a certain high-value biological sample should be strictly stored in a specific low-temperature storage area, but if the system detects that the sample has been moved to an ordinary laboratory table in a short period of time and the position offset exceeds 5 meters, the system will generate a position offset mark to prevent the sample from becoming invalid due to storage errors. Similarly, in an intelligent warehouse management system, if the storage location of some valuable equipment suddenly shifts significantly, for example, a device is usually stored in a safety cabinet, but the latest circulation log shows that it is located on an open shelf, and the offset distance exceeds the set threshold, the system will immediately mark the location of the device as abnormal and trigger a security alarm to prevent potential equipment loss or misuse.
[0053] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
[0054] In one embodiment, a smart sample collection management device is provided, and the smart sample collection management device corresponds one-to-one to a smart sample collection management method in the above embodiment. Figure 8 As shown, the intelligent sample collection management device includes a first acquisition module, a determination module, an analysis module, an execution module and a synchronization module. The detailed description of each functional module is as follows: The first acquisition module is used to obtain a sample transfer request, and based on the transfer request, synchronize the basic data of the sample between information systems, the information systems including a warehouse management system, a laboratory information management system and a mobile terminal device; the determination module is used to determine the location data corresponding to the basic data in real time through multi-threaded positioning technology, and generate a corresponding sample flow log based on the basic data and the location data; the analysis module is used to analyze the sample flow log based on the established flow anomaly recognition model to generate a corresponding recognition result; the execution module is used to perform corresponding exception handling operations and / or alarm operations according to the abnormal result if the recognition result is an abnormal result; the synchronization module is used to synchronize the corresponding log fragments in the sample flow log between each of the information systems according to a predetermined synchronization rule if the recognition result is a normal result.
[0055] Optionally, the acquisition module includes: an extraction unit for extracting key fields in the circulation request; a first matching unit for matching the corresponding sample code according to the key fields; a judgment unit for matching the corresponding shelf codes in each information system based on the sample code, and judging whether the shelf codes are consistent, and if not, generating corresponding exception identification data; an adding unit for adding a circulated identification to the information system that matches the shelf code, and adding a non-circulated identification to the information system that does not match the shelf code, if they are consistent; a first integration unit for integrating the circulated identification, the shelf code and / or exception identification data to generate corresponding basic data; Optionally, the determination module includes: a matching unit, used to match the corresponding multi-thread management mechanism according to the listing code in the basic data; a configuration unit, used to configure independent threads and acquisition adjustment parameters for the corresponding mobile terminal device based on the multi-thread management mechanism; an acquisition unit, used to acquire corresponding single-thread data based on the mobile terminal device configured with independent threads and acquisition adjustment parameters, store the single-thread data in a temporary buffer area, and record corresponding data attributes in the temporary buffer area, wherein the data attributes include timestamp and signal strength; a first generation unit, used to substitute each of the single-thread data into a determined fusion algorithm to generate corresponding preliminary data; a first determination unit, used to call historical flow data, and determine whether to determine the preliminary data as location data based on the comparison result between the historical flow data and the preliminary data; Optionally, the determination module also includes: a second determination unit, which is used to determine the classification rules of the sample flow log, the classification rules include field standardization processing rules and field arrangement rules, wherein the classification rules are determined according to the category of the information system; a second integration unit, which is used to integrate and standardize the basic data and the location data based on the field standardization processing rules to generate each classification field, and each associated field and / or abnormal identification field associated with the classification field, wherein the abnormal identification field is generated based on the abnormal identification data; an arrangement unit, which is used to rearrange the classification field, the associated field and / or the abnormal identification field based on the field arrangement rules to generate a plurality of flow entries arranged according to the classification field, wherein the classification field is arranged at the first position of the flow entry; a third determination unit, which is used to determine the flow entry containing the abnormal identification field as an abnormal entry, and perform a highlighting operation and a statistical positioning operation; a second generation unit, which is used to integrate a plurality of flow entries arranged according to the classification field, and / or perform a highlighting operation and a statistical positioning operation on the abnormal entries, to generate a corresponding sample flow log; Optionally, the analysis module includes: a retrieval unit, used to retrieve whether there is an abnormal entry in the sample flow log, and if so, generate a corresponding first abnormality identification result according to the abnormal entry; a selection unit, used to select the target field required by the established flow abnormality identification model from the classification field and the association field in each flow entry based on the established flow abnormality identification model if it does not exist; a second matching unit, used to perform logical matching on the target field according to the abnormal condition rule library predefined in the established flow abnormality identification model if the target field is a timestamp field and a location coordinate field, and output a corresponding abnormal mark; a comparison unit, used to call a historical abnormal operation data set if the target field is an operation type field, perform feature comparison with the operation type field, and output a corresponding abnormal probability value; a third generation unit, used to generate a corresponding second abnormality identification result if the abnormal mark is detected and / or the abnormal probability value exceeds a preset probability threshold; Optionally, the intelligent sample collection management device further includes: a second acquisition module, used to acquire timestamp conflict events and position offset events in historical abnormal flow logs, and extract conflict time intervals and offset distance thresholds; a first generation module, used to generate timestamp conflict rules according to the conflict time intervals; a second generation module, used to generate position offset rules according to the offset distance threshold, specifically: if the Euclidean distance between the position coordinate field in the current flow entry and the standard coordinates of the preset flow path exceeds the offset distance threshold, a position offset mark is triggered; a storage module, used to store the timestamp conflict rules and position offset rules in the abnormal condition rule library; Optionally, the second matching unit includes: a first judgment subunit, which is used to judge whether the difference between the timestamp field and the timestamp field in the adjacent flow entry is less than a preset time threshold based on the timestamp conflict rule if the target field is a timestamp field, and if so, trigger a timestamp conflict mark; and a second judgment subunit, which is used to judge whether the Euclidean distance between the position coordinate field and the standard coordinates of the preset flow path exceeds the offset distance threshold based on the position offset rule if the target field is a position coordinate field, and if so, trigger a position offset mark.
[0056] For the specific definition of an intelligent sampling management device, please refer to the definition of an intelligent sampling management method above, which will not be repeated here. Each module in the above-mentioned intelligent sampling management device can be implemented in whole or in part by software, hardware and a combination thereof. The above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.
[0057] In one embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as follows: Fig. 9 As shown. The computer device includes a processor, a memory, a network interface and a database connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, an intelligent sampling management method is implemented.
[0058] In one embodiment, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the following steps when executing the computer program: S10, obtaining a sample transfer request, and synchronizing basic sample data between information systems based on the transfer request, the information systems including a warehouse management system, a laboratory information management system, and a mobile terminal device; S20. Determine the location data corresponding to the basic data in real time through multi-threaded positioning technology, and generate a corresponding sample flow log based on the basic data and the location data; S30, analyzing the sample flow log based on the established flow anomaly recognition model to generate corresponding recognition results; S40, if the recognition result is an abnormal result, executing a corresponding abnormality handling operation and / or an alarm operation according to the abnormal result; S50: If the identification result is a normal result, the corresponding log fragments in the sample flow log are synchronized between each information system according to a predetermined synchronization rule.
[0059] In one embodiment, a computer readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented: S10, obtaining a sample transfer request, and synchronizing basic sample data between information systems based on the transfer request, the information systems including a warehouse management system, a laboratory information management system, and a mobile terminal device; S20. Determine the location data corresponding to the basic data in real time through multi-threaded positioning technology, and generate a corresponding sample flow log based on the basic data and the location data; S30, analyzing the sample flow log based on the established flow anomaly recognition model to generate corresponding recognition results; S40, if the recognition result is an abnormal result, executing a corresponding abnormality handling operation and / or an alarm operation according to the abnormal result; S50: If the identification result is a normal result, the corresponding log fragments in the sample flow log are synchronized between each information system according to a predetermined synchronization rule.
[0060] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be implemented by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.
[0061] The embodiments described above are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, a person skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.
Claims
1. An intelligent sampling management method, characterized in that: The intelligent sampling management method comprises: Obtaining a sample transfer request, and synchronizing basic sample data between information systems based on the transfer request, the information systems including a warehouse management system, a laboratory information management system, and a mobile terminal device; By using multi-threaded positioning technology, the location data corresponding to the basic data is determined in real time, and a corresponding sample flow log is generated based on the basic data and the location data; Analyze the sample flow log based on the established flow anomaly recognition model to generate corresponding recognition results; If the recognition result is an abnormal result, performing corresponding abnormality handling operations and / or alarm operations according to the abnormal result; If the identification result is a normal result, then synchronizing the corresponding log fragments in the sample flow log between each of the information systems according to a predetermined synchronization rule; The step of synchronizing basic data of samples between information systems based on the transfer request includes: Extracting key fields from the transfer request; Match the corresponding sample code according to the key field; Based on the sample code, the corresponding shelf codes in each information system are matched to determine whether the shelf codes are consistent. If they are inconsistent, corresponding abnormal identification data is generated; If they are consistent, a circulated mark is added to the information system that matches the listing code, and a non-circulated mark is added to the information system that does not match the listing code; Integrate the circulated identification, the shelf code and / or abnormal identification data to generate corresponding basic data; The step of determining the position data corresponding to the basic data in real time by using the multi-threaded positioning technology includes: Matching a corresponding multi-thread management mechanism according to the listing code in the basic data; Based on the multi-thread management mechanism, configure independent threads and collect adjustment parameters for corresponding mobile terminal devices; Based on the mobile terminal device configured with the independent thread and the acquisition adjustment parameter, the corresponding single-thread data is obtained, the single-thread data is stored in a temporary buffer area, and the corresponding data attributes are recorded in the temporary buffer area, where the data attributes include a timestamp and a signal strength; Substituting each of the single-threaded data into the determined fusion algorithm to generate corresponding preliminary data; The historical flow data is called, and according to a comparison result between the historical flow data and the preliminary data, it is determined whether to determine the preliminary data as the position data.
2. The intelligent sample collection management method according to claim 1, characterized in that: The step of generating a corresponding sample flow log based on the basic data and the location data includes: Determine a classification rule for the sample flow log, wherein the classification rule includes a field standardization processing rule and a field arrangement rule, wherein the classification rule is determined according to the category of the information system; Based on the field standardization processing rule, the basic data and the location data are integrated and standardized to generate various classification fields, and associated fields and / or abnormal identification fields associated with each of the classification fields, wherein the abnormal identification fields are generated based on the abnormal identification data; Based on the field arrangement rule, the classification field, the association field and / or the abnormal identification field are rearranged to generate a plurality of flow entries arranged according to the classification field, wherein the classification field is arranged at the first position of the flow entry; Determine the flow entry containing the abnormal identification field as an abnormal entry, and perform a highlighting operation and a statistical positioning operation; Integrate multiple flow entries arranged according to classification fields, and / or perform abnormal entries after highlighting and statistical positioning operations to generate corresponding sample flow logs.
3. The intelligent sample collection management method according to claim 2, characterized in that: In the step of analyzing the sample flow log based on the established flow anomaly recognition model to generate a corresponding recognition result, the recognition result includes an abnormal result and a normal result, and the abnormal result includes a first abnormal recognition result and a second abnormal recognition result. The step also includes: Searching whether there is an abnormal entry in the sample flow log, and if so, generating a corresponding first abnormality identification result according to the abnormal entry; If it does not exist, based on the established flow anomaly identification model, select the target field required by the established flow anomaly identification model from the classification field and the association field in each of the flow entries; If the target field is a timestamp field and a location coordinate field, logical matching is performed on the target field according to the abnormal condition rule library predefined in the established flow abnormality recognition model, and a corresponding abnormal mark is output; If the target field is an operation type field, the historical abnormal operation data set is called, and features are compared with the operation type field to output a corresponding abnormal probability value; If the abnormal mark is detected to appear and / or the abnormal probability value exceeds a preset probability threshold, a corresponding second abnormality identification result is generated.
4. The intelligent sampling management method according to claim 3, characterized in that: The steps of generating the abnormal condition rule base predefined in the established flow abnormality recognition model include: Obtain timestamp conflict events and position offset events in historical abnormal flow logs, and extract conflict time intervals and offset distance thresholds; generating a timestamp conflict rule according to the conflict time interval; Generate a position offset rule according to the offset distance threshold, specifically: if the Euclidean distance between the position coordinate field in the current flow entry and the standard coordinate of the preset flow path exceeds the offset distance threshold, trigger a position offset mark; Storing the timestamp conflict rule and the position offset rule in the abnormal condition rule library; In the step of performing logical matching on the target field according to the abnormal condition rule base predefined in the established flow abnormality recognition model and outputting the corresponding abnormal mark, the abnormal mark includes a timestamp conflict mark and a position offset mark, and the step further includes: If the target field is a timestamp field, based on the timestamp conflict rule, determine whether the difference between the timestamp field and the timestamp field in the adjacent flow entry is less than a preset time threshold, and if so, trigger a timestamp conflict mark; If the target field is a location coordinate field, based on the location offset rule, it is determined whether the Euclidean distance between the location coordinate field and the standard coordinates of the preset flow path exceeds the offset distance threshold, and if so, a location offset mark is triggered.
5. An intelligent sample collection management device, characterized in that: The intelligent sample collection management device comprises: A first acquisition module, used to obtain a sample transfer request, and synchronize basic sample data between information systems based on the transfer request, wherein the information systems include a warehouse management system, a laboratory information management system, and a mobile terminal device; A determination module, used to determine the location data corresponding to the basic data in real time through a multi-threaded positioning technology, and generate a corresponding sample flow log based on the basic data and the location data; An analysis module, used to analyze the sample flow log based on the established flow anomaly recognition model to generate a corresponding recognition result; An execution module, configured to execute a corresponding exception handling operation and / or an alarm operation according to the abnormal result if the recognition result is an abnormal result; A synchronization module is used to synchronize the corresponding log fragments in the sample flow log between each of the information systems according to a predetermined synchronization rule if the identification result is a normal result.
6. The intelligent sample collection management device according to claim 5, characterized in that: The acquisition module comprises: An extraction unit, used to extract key fields in the transfer request; A first matching unit, used for matching a corresponding sample code according to the key field; A judgment unit, used to match the corresponding shelf codes in each information system based on the sample code, and judge whether the shelf codes are consistent. If they are inconsistent, generate corresponding abnormal identification data; An adding unit, used for adding a circulated mark to the information system that matches the shelf code, and adding a non-circulated mark to the information system that does not match the shelf code, if they are consistent; A first integration unit, used to integrate the circulated identification, the shelf code and / or abnormal identification data to generate corresponding basic data; The determination module includes: a matching unit, which is used to match the corresponding multi-thread management mechanism according to the listing code in the basic data; A configuration unit, configured to configure independent threads and acquisition adjustment parameters for corresponding mobile terminal devices based on the multi-thread management mechanism; an acquisition unit, configured to acquire corresponding single-thread data based on a mobile terminal device configured with independent threads and acquisition adjustment parameters, store the single-thread data in a temporary buffer area, and record corresponding data attributes in the temporary buffer area, wherein the data attributes include a timestamp and a signal strength; A first generating unit, used for substituting each of the single-thread data into the determined fusion algorithm to generate corresponding preliminary data; A first determining unit, configured to call historical flow data and determine whether to determine the preliminary data as location data according to a comparison result between the historical flow data and the preliminary data; The determination module also includes: A second determination unit is used to determine a classification rule for the sample flow log, wherein the classification rule includes a field standardization processing rule and a field arrangement rule, wherein the classification rule is determined according to a category of the information system; A second integration unit is used to integrate and standardize the basic data and the location data based on the field standardization processing rule to generate each classification field, and associated fields and / or abnormal identification fields associated with each classification field, wherein the abnormal identification field is generated based on the abnormal identification data; an arrangement unit, configured to rearrange the classification field, the association field and / or the abnormal identification field based on the field arrangement rule to generate a plurality of flow entries arranged according to the classification field, wherein the classification field is arranged at the first position of the flow entry; A third determining unit, configured to determine the flow entry containing the abnormal identification field as an abnormal entry, and perform a highlighting operation and a statistical positioning operation; The second generating unit is used to integrate multiple flow entries arranged according to the classification field, and / or perform the abnormal entries after the highlighting operation and the statistical positioning operation, and generate a corresponding sample flow log; The analysis module comprises: A retrieval unit, configured to retrieve whether there is an abnormal entry in the sample flow log, and if so, generate a corresponding first abnormality identification result according to the abnormal entry; A selection unit, configured to select, if not existing, a target field required by the established flow anomaly identification model from the classification field and the association field in each of the flow entries based on the established flow anomaly identification model; A second matching unit is used for, if the target field is a timestamp field and a location coordinate field, performing a logical match on the target field according to an abnormal condition rule base predefined in the established flow abnormality recognition model, and outputting a corresponding abnormal mark; A comparison unit, configured to call a historical abnormal operation data set, perform feature comparison with the operation type field, and output a corresponding abnormal probability value if the target field is an operation type field; A third generating unit is used to generate a corresponding second abnormality recognition result if the abnormality mark is detected to appear and / or the abnormality probability value exceeds a preset probability threshold; The intelligent sample collection management device further comprises: The second acquisition module is used to obtain timestamp conflict events and position offset events in the historical abnormal flow log, and extract the conflict time interval and offset distance threshold; A first generating module, configured to generate a timestamp conflict rule according to the conflict time interval; A second generating module is used to generate a position offset rule according to the offset distance threshold, specifically: if the Euclidean distance between the position coordinate field in the current flow entry and the standard coordinate of the preset flow path exceeds the offset distance threshold, a position offset mark is triggered; A storage module, used for storing the timestamp conflict rule and the position offset rule in the abnormal condition rule library; The second matching unit comprises: A first judgment subunit is used for judging, if the target field is a timestamp field, whether the difference between the timestamp field and the timestamp field in the adjacent flow entry is less than a preset time threshold based on the timestamp conflict rule, and triggering a timestamp conflict mark if the difference is less than a preset time threshold; The second judgment subunit is used to judge whether the Euclidean distance between the location coordinate field and the standard coordinates of the preset flow path exceeds the offset distance threshold based on the location offset rule if the target field is a location coordinate field, and trigger a location offset mark if it exceeds.
7. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the intelligent sampling management method as claimed in any one of claims 1 to 4 are implemented.
8. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of an intelligent sampling management method as claimed in any one of claims 1 to 4 are implemented.
Citation Information
Patent Citations
Tracing record processing method and apparatus
CN105608588A
Product traceability method and system in network, computer system and storage medium
CN108846010A
Product anti-counterfeiting method and device based on block chain
CN110097377A
Full-process monitoring method and device for human biological sample, medium and equipment
CN116230093A
Distributed log acquisition and analysis system and method
CN118193260A
Cited By
Target object state identification method and device, equipment and medium
CN121009912A
A target object state recognition method, device, equipment and medium
CN121009912B