A Medical Data Incremental Synchronization Method Based on Semantic Feature Hash Matching
By using a semantic feature hash matching method, the problem of identifying business semantic changes in incremental medical data synchronization was solved, enabling accurate formation of incremental data sets and backend data consistency verification, thus avoiding unnecessary data synchronization and conflicts.
Patent Information
- Application Number
- CN202611627570.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-10-21
- Publication Date
- 2026-11-17
AI Technical Summary
Existing methods for incremental synchronization of medical data struggle to accurately identify changes in business semantics, resulting in unchanged data being synchronized, and inconsistent synchronization benchmarks between the front-end and back-end, affecting data consistency.
A semantic feature-based hash matching method is adopted to divide the data to be synchronized and the baseline data through semantic mapping relationship, generate field groups and record-level hash fingerprints, identify the differential semantic field groups, and perform baseline status verification and data conflict handling in the background to ensure the accuracy and consistency of data synchronization.
It enables the generation of incremental data sets based on actual business semantic changes, avoiding the synchronization of unchanged content, ensuring that backend data is not directly overwritten, and improving the accuracy and consistency of data synchronization.
Smart Images

Figure CN123115277A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of incremental synchronization technology, and in particular to a method for incremental synchronization of medical data based on semantic feature hash matching. Background Technology
[0002] Incremental synchronization technology primarily involves the identification, updating, transmission, and consistency maintenance of data changes between front-end business terminals and back-end servers, databases, or business systems. It typically revolves around the identification and synchronization of newly added, modified, and deleted data, as well as data reflecting changes in business status. It is widely applied in medical informatics, smart wards, nursing management, mobile healthcare, hospital information systems, and other business scenarios requiring front-end and back-end data interaction. Specifically, incremental synchronization of medical data primarily relies on data record time information, version information, unique identifiers, business fields, database logs, or change records to determine the data to be synchronized. It then determines the content to be synchronized based on the relationships between added, modified, or deleted data, and completes the transmission and updating of the corresponding medical data through data interfaces, message transmission, database replication, or data exchange mechanisms.
[0003] Current incremental synchronization of medical data often relies on time information, version information, unique identifiers, business fields, database logs, or change records to determine the data to be synchronized. When only some business content changes or field expression is adjusted on the nursing dashboard front end, the judgment method based on record status is difficult to distinguish between changes in business semantics and changes in data expression. It is easy to include data that has not undergone business changes in the synchronization scope, and it is also difficult to locate the specific changes within the record. If the corresponding record changes again after the front end generates the data to be synchronized, it will also cause inconsistencies between the synchronization benchmark and the actual write status. Summary of the Invention
[0004] This invention aims to provide a method for incremental synchronization of medical data based on semantic feature hash matching. It addresses the synchronization process of medical business data between the nursing dashboard front-end and back-end. The method involves semantic field partitioning and standardization of the medical business data to be synchronized and the synchronization baseline data. Based on field group hash fingerprints and record-level hash fingerprints, it identifies changes in business records and locates differing semantic field groups. Incremental data sets are formed based on these differing semantic field groups. Simultaneously, baseline status verification and data conflict handling are performed in the nursing dashboard back-end to establish a data synchronization processing link for medical business data, from front-end change identification and incremental data formation to back-end write verification.
[0005] To achieve the above objectives, the present invention adopts the following technical solution: a medical data incremental synchronization method based on semantic feature hash matching, comprising the following steps: S1: Obtain the medical business data to be synchronized and the synchronization baseline data from the nursing dashboard, and divide the corresponding business records into the current semantic field group and the baseline semantic field group according to the semantic mapping relationship. S2: Process the current semantic field group and the baseline semantic field group according to the unified standard to form a standardized semantic feature. Generate a field group hash fingerprint based on the standardized semantic feature, and combine the field group hash fingerprint according to the semantic identifier to generate the current record-level hash fingerprint and the baseline record-level hash fingerprint. S3: Compare the current record-level hash fingerprint with the baseline record-level hash fingerprint. If they match, end the synchronization. If they do not match, compare the corresponding field group hash fingerprint according to the semantic identifier. Determine the difference semantic field group and change type based on the field group existence status and hash matching result. S4: Extract medical business data based on the difference semantic field group and the change type, associate it with the baseline record-level hash fingerprint to form an incremental data set, and send the incremental data set to the nursing dashboard backend; S5: The nursing dashboard backend generates a backend record-level hash fingerprint based on the current business record in the backend database, and compares it with the baseline record-level hash fingerprint. If they match, the backend database is updated based on the incremental data set and the updated record-level hash fingerprint is returned. If they do not match, the writing stops and a data conflict status is returned.
[0006] Furthermore, the semantic mapping relationship is the correspondence between medical business fields and semantic identifiers; the medical business fields in the medical business data to be synchronized and the synchronization benchmark data are read, the corresponding semantic identifiers are determined according to the semantic mapping relationship, and the medical business fields with the same semantic identifiers and belonging to the same business record are respectively assigned to the current semantic field group and the benchmark semantic field group.
[0007] Furthermore, a record correspondence relationship is established between the medical business data to be synchronized and the synchronization benchmark data according to the business record identifier; when a corresponding benchmark business record exists, the current semantic field group and the benchmark semantic field group are formed according to the semantic mapping relationship; when no corresponding benchmark business record exists, the hash fingerprint comparison process is skipped, the current semantic field group is determined as the difference semantic field group, and the change type is determined as addition.
[0008] Furthermore, the unified specification determines the field arrangement rules and data expression rules according to the semantic identifier, and performs field sorting, data type conversion and state expression normalization processing on the current semantic field group and the baseline semantic field group; the field contents after processing are combined according to the field arrangement rules to form the corresponding standardized semantic features.
[0009] Further, the normalized semantic features are hashed to generate the current field group hash fingerprint and the base field group hash fingerprint, respectively; the hash fingerprint combination order is determined according to the semantic identifier, and the current field group hash fingerprint and the base field group hash fingerprint corresponding to the same business record are combined and hashed to generate the current record-level hash fingerprint and the base record-level hash fingerprint.
[0010] Further, the current record-level hash fingerprint is compared with the baseline record-level hash fingerprint; if they match, the incremental synchronization of the corresponding business record is terminated; if they do not match, a field group correspondence relationship is established between the current semantic field group and the baseline semantic field group according to the semantic identifier, and the corresponding field group hash fingerprints are compared to form a field group matching result.
[0011] Further, the existence status of the current semantic field group and the baseline semantic field group is detected according to the field group correspondence relationship; when the current semantic field group exists and the baseline semantic field group does not exist, the current semantic field group is determined as the difference semantic field group, and the change type is determined as addition; when the current semantic field group does not exist and the baseline semantic field group exists, the baseline semantic field group is determined as the difference semantic field group, and the change type is determined as deletion; when both the current semantic field group and the baseline semantic field group exist and the field group matching results are inconsistent, the current semantic field group is determined as the difference semantic field group, and the change type is determined as modification; when both the current semantic field group and the baseline semantic field group exist and the field group matching results are consistent, the current semantic field group is not determined as the difference semantic field group.
[0012] Further, a business record identifier and the semantic identifier are determined for the differential semantic field group; when the change type is addition or modification, the corresponding field content is extracted from the medical business data to be synchronized; when the change type is deletion, the business record identifier and the semantic identifier are used as deletion location information; the business record identifier, the semantic identifier, the change type, the baseline record-level hash fingerprint, and the corresponding field content are associated to form the incremental data set.
[0013] Furthermore, the nursing dashboard backend reads the current business record in the backend database based on the business record identifier associated with the incremental data set; processes the current business record according to the semantic mapping relationship, the unified specification, and the hash generation rules used when generating the baseline record-level hash fingerprint, and generates the backend record-level hash fingerprint; when the backend record-level hash fingerprint is consistent with the baseline record-level hash fingerprint, performs data modification on the medical business data according to the change type, and generates the updated record-level hash fingerprint based on the modified business record.
[0014] Furthermore, when the background record-level hash fingerprint is inconsistent with the baseline record-level hash fingerprint, the nursing dashboard background stops writing to the incremental data set and returns the data conflict status and the business record identifier; the nursing dashboard retains the synchronization baseline data, re-acquires the current business record according to the business record identifier, and performs field group hash matching between the medical business data to be synchronized and the current business record and the synchronization baseline data respectively to determine the semantic field groups of only local change, only background change, and both parties change; when the hash fingerprint of the local field group corresponding to the semantic field group of both parties change is inconsistent with the hash fingerprint of the background field group, it is determined to be a concurrent conflict; when there is no concurrent conflict, the current business record is used as the retry baseline, and the incremental dataset is re-formed according to the semantic field group of only local change and then merged and sent to the nursing dashboard background.
[0015] The beneficial effects of the technical solutions provided in the embodiments of the present invention include at least the following: By dividing the medical business data to be synchronized into synchronization benchmark data based on semantic mapping relationships, and forming standardized semantic features through unified specifications, field group hash fingerprints and record-level hash fingerprints are generated. Since record-level hash fingerprints are used to filter business records that have changed, and field group hash fingerprints are used to locate semantically different field groups and change types, incremental data sets can be formed according to actual business semantic changes, avoiding unchanged content from entering the synchronization scope. Before writing to the nursing dashboard backend, the backend record-level hash fingerprint is compared with the benchmark record-level hash fingerprint. Only when they match are the backend database updated; if they do not match, the writing stops and a data conflict status is returned, thus preventing incremental data under different synchronization benchmarks from directly overwriting backend records. Attached Figure Description
[0016] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0017] Figure 1 A schematic diagram of the incremental synchronization method for medical data; Figure 2 This is a schematic diagram illustrating the semantic mapping relationship and the formation of semantic field groups; Figure 3 This is a schematic diagram illustrating the generation and matching of hierarchical hash fingerprints. Figure 4 A schematic diagram illustrating the formation of incremental data sets; Figure 5 This is a diagram illustrating background benchmark verification and data conflict rollback. Detailed Implementation
[0018] To facilitate understanding of the technical solutions described in this invention, the main data objects and processing relationships involved in this embodiment are uniformly explained. The nursing dashboard is a front-end business carrier software for ward nursing staff to maintain medical business data. The medical business data to be synchronized formed in the nursing dashboard refers to the data set that needs to be compared with the nursing dashboard backend in the current data state. The synchronization benchmark data refers to the data set used for difference comparison with the medical business data to be synchronized. Medical business data corresponds to business records formed during ward nursing. Business records can carry patient information, nursing item information, examination item information, examination indicator data, and shift handover information. Business record identifiers are used to determine the corresponding business records between the medical business data to be synchronized, the synchronization benchmark data, and the backend database. Semantic mapping relationship is the correspondence between medical business fields and semantic identifiers. Semantic identifiers are used to characterize the business meaning of the medical business fields. The current semantic field group is a set of fields composed of medical business fields with the same semantic identifier and belonging to the same business record in the medical business data to be synchronized. The benchmark semantic field group is a set of fields formed in the same way in the synchronization benchmark data. Standardized semantic features are data expressions that can be hashed after processing the semantic field groups according to unified field arrangement rules and data expression rules. Field group hash fingerprints are used to characterize the data state of a semantic field group after normalization, while record-level hash fingerprints are used to characterize the data state of a business record after combining various semantic field groups. Difference semantic field groups indicate the range of added, deleted, or modified data between the current data state and the baseline data state. Incremental data sets carry the synchronized data corresponding to the difference semantic field groups and the baseline record-level hash fingerprint upon which synchronization is based.
[0019] Example 1 Please see Figure 1-5This embodiment provides a method for incremental synchronization of medical data based on semantic feature hash matching. This method takes the medical business data to be synchronized generated by the nursing dashboard and the synchronization benchmark data as input. It completes one incremental synchronization of medical data through semantic field group division, standardized semantic feature formation, hierarchical hash matching, incremental data set construction, and pre-write verification in the nursing dashboard backend. After nursing staff add, modify, or maintain medical business records in the nursing dashboard, the medical business data to be synchronized reflects the current data status saved on the nursing dashboard, and the synchronization benchmark data represents the data benchmark compared with the current business record.
[0020] S1: Obtain the medical business data to be synchronized and the synchronization baseline data from the nursing dashboard, and divide the corresponding business records into the current semantic field group and the baseline semantic field group according to the semantic mapping relationship.
[0021] The system reads the currently saved medical business data to be synchronized from the nursing dashboard and reads the corresponding synchronization benchmark data. Both the medical business data to be synchronized and the synchronization benchmark data use business records as comparison objects. Each business record has a business record identifier used to establish the correspondence. The business record identifier is used to determine whether the current business record and the benchmark business record belong to the same business object. The encoding of the business record identifier only needs to maintain a unique correspondence among the current business record, the benchmark business record, and the corresponding business record in the backend database.
[0022] Semantic mapping records the correspondence between medical business fields and semantic identifiers. During field partitioning, each medical business field in a business record is read sequentially. The semantic identifier corresponding to each medical business field is found based on the semantic mapping relationship. Medical business fields with the same semantic identifier and belonging to the same business record are then grouped into the same field group. This process is repeated for the medical business data to be synchronized to form the current semantic field group, and the same process is repeated for the baseline data to be synchronized to form the baseline semantic field group. The semantic identifier corresponds to the business meaning of the medical business field, not its physical position in the data record. Therefore, even if the field arrangement or data organization order changes between the current business record and the baseline business record, as long as the corresponding medical business fields are mapped to the same semantic identifier through the semantic mapping relationship, they are assigned to the corresponding current semantic field group and baseline semantic field group.
[0023] Before medical business fields are added to a field group, a record mapping relationship is established between the medical business data to be synchronized and the synchronization baseline data based on the business record identifier. For the current business record in the medical business data to be synchronized, if a baseline business record with the same business record identifier exists in the synchronization baseline data, a record mapping relationship is established between the current business record and the baseline business record, and corresponding current semantic field groups and baseline semantic field groups are formed according to semantic mapping relationships. The field groups are mapped based on semantic identifiers, so the current semantic field group and the baseline semantic field group corresponding to the same semantic identifier can directly compare data status in subsequent steps.
[0024] When no baseline business record with the same business record identifier as the current business record exists in the synchronized baseline data, it means that there is no corresponding record for the current business record in the synchronized baseline data. In this state, a current semantic field group is formed based on the current business record, and the current semantic field group is determined as the difference semantic field group, while the change type is determined as new. This process allows the current business record without a baseline business record to avoid creating non-existent baseline field content, and also allows the new data status to be passed to the subsequent incremental data formation process. After S1, the current semantic field group, the baseline semantic field group, and their corresponding semantic identifiers are output; for data without a baseline business record, the determined difference semantic field group and the new change type are also output.
[0025] S2: Process the current semantic field group and the baseline semantic field group according to the unified standard to form standardized semantic features. Generate field group hash fingerprints based on the standardized semantic features, and combine field group hash fingerprints according to semantic identifiers to generate the current record-level hash fingerprint and the baseline record-level hash fingerprint.
[0026] The system receives the current semantic field group and the baseline semantic field group output by S1. The unified specification ensures that the current semantic field group and the baseline semantic field group, belonging to the same semantic identifier, use the same data organization criteria. The unified specification constrains at least the field arrangement rules, data type conversion rules, and state expression normalization rules. The field arrangement rules determine the order in which multiple medical business fields within a semantic field group enter the normalized semantic features; the data type conversion rules ensure that data corresponding to the same business meaning uses a consistent data expression type; and the state expression normalization rules convert equivalent expressions corresponding to the same business state into a unified state expression.
[0027] When applying a unified standard to the current semantic field group and the baseline semantic field group, the corresponding field arrangement rules and data representation rules are first invoked based on the semantic identifier. Then, the field content is arranged according to the field arrangement rules, and the field values are processed according to the data type conversion rules and state representation normalization rules. The processed field content is combined in a determined order to form the normalized semantic features corresponding to the current semantic field group and the baseline semantic field group. Since the two types of field groups corresponding to the same semantic identifier apply the same normalization rules, the subsequent hash processing targets the semantic content processed by the consistent data representation rules.
[0028] After constructing the normalized semantic features, a hashing process is performed on each normalized semantic feature. The hashing process employs a hash operation method that generates the same hash result for the same input and produces comparable hash results for different inputs. Processing the normalized semantic features of the current semantic field group yields the hash fingerprint of the current field group, and processing the normalized semantic features of the baseline semantic field group yields the hash fingerprint of the baseline field group. Each field group hash fingerprint is associated with its corresponding semantic identifier, enabling subsequent steps to compare the current field group hash fingerprint with the baseline field group hash fingerprint based on the same semantic identifier.
[0029] Record-level hash fingerprints are formed based on field group hash fingerprints. For the same business record, the combination order of each field group hash fingerprint is determined according to the semantic identifier. The current field group hash fingerprints belonging to the current business record are combined according to this combination order, and the combined data is hashed to form the current record-level hash fingerprint. The baseline field group hash fingerprints belonging to the baseline business record are combined according to the same semantic identifier order, and the combined data is hashed to form the baseline record-level hash fingerprint. Record-level hash fingerprints are used to represent the current semantic data state and baseline semantic data state of the entire business record, while field group hash fingerprints are used to represent the data state of each semantic field group within the business record. After S2, the current field group hash fingerprint, baseline field group hash fingerprint, current record-level hash fingerprint, and baseline record-level hash fingerprint are output, where each field group hash fingerprint maintains its correspondence with the business record identifier and semantic identifier.
[0030] S3: Compare the current record-level hash fingerprint with the baseline record-level hash fingerprint. If they match, end the synchronization. If they do not match, compare the corresponding field group hash fingerprints according to the semantic identifier. Determine the difference semantic field group and change type based on the existence status of the field group and the hash matching result.
[0031] First, the current record-level hash fingerprint under the same record correspondence is compared with the baseline record-level hash fingerprint. If the current record-level hash fingerprint matches the baseline record-level hash fingerprint, it indicates that the entire business record data state obtained according to the same semantic field division, unified specifications, and hash generation method is consistent. In this case, the corresponding business record does not enter the incremental data formation process, and the current synchronization judgment for this business record ends. If the current record-level hash fingerprint does not match the baseline record-level hash fingerprint, it indicates that at least one semantic field group within the corresponding business record has a different data state, and the field group-level comparison continues.
[0032] Field group-level comparisons use semantic identifiers as the basis for correspondence. For the current semantic field group and the baseline semantic field group, a correspondence is first established based on the semantic identifiers. Then, the existence status of the current semantic field group and the baseline semantic field group with the same semantic identifier is checked. When the current semantic field group exists but the baseline semantic field group does not, the current semantic field group is identified as a difference semantic field group, and the change type is determined to be "new". This status indicates that semantic content not present in the baseline data has appeared in the current data, and subsequent incremental data generation will use the field content corresponding to the current semantic field group as the source of new data.
[0033] When the current semantic field group does not exist but the baseline semantic field group does, the baseline semantic field group is designated as the difference semantic field group, and the change type is determined as deletion. This status indicates that the semantic content existing in the baseline data no longer exists in the current data. Subsequently, the field content of the baseline semantic field group will no longer be used as the object to be added. Instead, the business record identifier and semantic identifier will be used to locate the range of data to be deleted in the backend.
[0034] When both the current semantic field group and the baseline semantic field group exist, the hash fingerprint of the current field group is compared with that of the baseline field group. If they are inconsistent, the current semantic field group is identified as the difference semantic field group, and the change type is identified as modification, indicating that the business content corresponding to the same semantic identifier has changed from the baseline state to the current state. If they are consistent, the current semantic field group is not identified as the difference semantic field group, and the corresponding field group is not included in the subsequent incremental data set. Through the progressive processing of record-level comparison and field group-level comparison, the record-level hash fingerprint is used to first determine whether a business record needs to be compared further, and the field group hash fingerprint is used to determine which semantic field group the difference falls into when there is a discrepancy at the record level, and further obtain the change type of addition, deletion, or modification. S3 outputs the difference semantic field group, business record identifier, semantic identifier, and corresponding change type as input for S4 to form the incremental data set.
[0035] S4: Extract medical business data based on the difference semantic field group and change type, associate it with the baseline record-level hash fingerprint to form an incremental data set, and send the incremental data set to the nursing dashboard backend.
[0036] The system receives the difference semantic field groups and change types generated by S3, and determines the business record identifier and corresponding semantic identifier for each difference semantic field group. The business record identifier is used to locate the corresponding business record in the nursing dashboard backend, the semantic identifier is used to locate the corresponding semantic field range within the business record, and the change type is used to determine which type of data change (add, delete, or modify) the backend performs on the corresponding data.
[0037] When the change type is "Add," the field content corresponding to the difference semantic field group is extracted from the medical business data to be synchronized, and the field content is associated with the business record identifier, semantic identifier, change type, and the baseline record-level hash fingerprint of the corresponding business record. When the change type is "Modify," the field content of the current difference semantic field group is also extracted from the medical business data to be synchronized. The current field content is used as the data state to be written to the backend, and associated with the corresponding business record identifier, semantic identifier, modification change type, and baseline record-level hash fingerprint. When the change type is "Delete," the deletion location information is formed using the business record identifier and semantic identifier. The field content of the baseline semantic field group is not used as new write content. The deletion location information is associated with the deletion change type and the corresponding baseline record-level hash fingerprint, which is used by the nursing dashboard backend to determine the location of the data to be deleted.
[0038] Difference data belonging to the same business record are merged according to the business record identifier to form a corresponding incremental data set. The incremental data set maintains at least the association between the business record identifier, semantic identifier, change type, and base record-level hash fingerprint; for addition and modification types, it also maintains the association between the corresponding field content and the above data; for deletion types, deletion location information is used to replace the field content during addition or modification. The resulting incremental data set does not use the entire business record as fixed transmission content, but rather uses the difference semantic field group determined by S3 as the data range, ensuring that data not determined to be in the difference semantic field group does not enter the current incremental data set.
[0039] After the incremental data set is formed, it is sent to the nursing dashboard backend. The data sent to the nursing dashboard backend retains the correspondence between each data item, enabling the nursing dashboard backend to retrieve the corresponding current business record in the backend database based on the business record identifier, determine the location where data changes need to be performed based on the semantic identifier, determine the data change method based on the change type, and perform a data state comparison before writing based on the baseline record-level hash fingerprint. S4 outputs the incremental data set sent to the nursing dashboard backend, which serves as the input for S5 to perform backend baseline verification and data change.
[0040] S5: The nursing dashboard backend generates a backend record-level hash fingerprint based on the current business record in the backend database, and compares it with the baseline record-level hash fingerprint. If they match, the backend database is updated based on the incremental data set and the updated record-level hash fingerprint is returned. If they do not match, the writing stops and a data conflict status is returned.
[0041] After receiving the incremental data set, the nursing dashboard backend first reads the current business record in the backend database based on the business record identifier associated with the incremental data set. The current business record in the backend represents the actual data state saved in the backend database when the nursing dashboard backend is about to execute this incremental data change. To ensure that the current business record in the backend can be compared with the baseline record-level hash fingerprint carried by the incremental data set, the nursing dashboard backend processes the current business record according to the semantic mapping relationship, unified specifications, and hash generation rules used when forming the baseline record-level hash fingerprint.
[0042] The nursing dashboard backend first divides the current business records into semantic field groups corresponding to the aforementioned semantic identifiers based on semantic mapping relationships. Then, it forms standardized semantic features according to a unified standard. The standardized semantic features are then hashed to obtain the corresponding field group hash fingerprints. Finally, the corresponding field group hash fingerprints are combined according to the same semantic identifier combination order as the baseline record-level hash fingerprint to generate the backend record-level hash fingerprint. This process ensures that the backend record-level hash fingerprint and the baseline record-level hash fingerprint are based on the same semantic field division, the same standardization process, and the same hash generation rules. Therefore, it can be used to compare the baseline state used when the frontend generates the incremental data set with the actual data state when the backend is ready to write.
[0043] When the backend record-level hash fingerprint matches the baseline record-level hash fingerprint, it indicates that the current business record in the backend still corresponds to the synchronous baseline data state upon which the current incremental data set was based. The nursing dashboard backend executes the corresponding data changes according to the change type in the incremental data set. For the addition type, the target business record and target semantic location are determined based on the business record identifier and semantic identifier, and the corresponding field content in the incremental data set is written to the backend database. For the modification type, the corresponding medical business data is located based on the business record identifier and semantic identifier, and the corresponding data is updated with the current field content carried by the incremental data set. For the deletion type, the location of the data to be deleted is determined based on the deletion location information formed by the business record identifier and semantic identifier, and the corresponding data is deleted. After the data change is completed, the nursing dashboard backend generates an updated record-level hash fingerprint based on the changed business record according to the same generation rules as the aforementioned record-level hash fingerprint, and returns the updated record-level hash fingerprint to the nursing dashboard. The returned updated record-level hash fingerprint is used to represent the business record data state after the nursing dashboard backend completes the current incremental data change.
[0044] When the hash fingerprint of a backend record is inconsistent with the hash fingerprint of the baseline record, it indicates that the current business record data state when the nursing dashboard backend is preparing to write is inconsistent with the synchronization baseline data state used to form the incremental data set. In this case, the nursing dashboard backend stops writing the corresponding incremental data set, does not overwrite the current backend business record with the current incremental data set, and returns a data conflict status and the corresponding business record identifier to the nursing dashboard. The data conflict status indicates that the current incremental data set cannot continue to be written based on the original baseline record-level hash fingerprint, and the business record identifier is used to enable the nursing dashboard to re-acquire the conflicting current backend business record.
[0045] Upon receiving a data conflict status, the nursing dashboard retrieves the current business record from the backend database based on the returned business record identifier. It retains the synchronization baseline data used to form the incremental data set, without overwriting the synchronization baseline data with the newly retrieved current business record. The business record corresponding to the synchronization baseline data is used as the original baseline state, the business record corresponding to the medical business data to be synchronized locally on the nursing dashboard is used as the local current state, and the newly retrieved current business record is used as the backend current state. Then, following the processing methods in S1 to S3, semantic field groups are divided, normalized, hash fingerprints are generated, and field group hash matching is performed to determine the semantic field groups that change only locally, only in the backend, or both parties.
[0046] For semantic field groups that have changed on both sides, compare the hash fingerprints of the corresponding field groups in the local current state with those in the backend current state. If they match, it is determined that there are no pending conflicts in the corresponding semantic field group. If they do not match, it is determined that there are concurrent conflicts in the corresponding semantic field group, and the current synchronization is stopped. If there are no concurrent conflicts, the re-acquired backend current business record is used as the retry baseline state, and a difference semantic field group and change type relative to the retry baseline state are formed based on the semantic field groups that have only changed locally. S4 is then re-executed to form a new incremental data set.
[0047] The newly formed incremental data set is sent to the nursing dashboard backend again. The nursing dashboard backend rereads the current business records in the backend database and generates a backend record-level hash fingerprint. It compares the backend record-level hash fingerprint with the record-level hash fingerprint corresponding to the retry baseline state. If they match, the data change corresponding to the incremental data set is executed. If they do not match, the current synchronization is stopped and the data conflict state is retained.
[0048] The newly formed incremental data set is sent back to the nursing dashboard backend. The nursing dashboard backend rereads the current business records in the backend database following the same processing path as in S5, and regenerates the backend record-level hash fingerprint. Simultaneously, it compares the hash fingerprint with the updated synchronization baseline data. If they match, the corresponding data changes are executed according to the new incremental data set. If they still do not match, it indicates that the current business records in the backend have again differed from the new synchronization baseline data after the incremental data set is re-formed. In this case, the synchronization is stopped, the data conflict state is retained, and data that has lost its corresponding baseline is no longer used for writing.
[0049] The aforementioned conflict handling forms a rollback process with clearly defined exit conditions. Upon the first detection of an inconsistency between the backend record-level hash fingerprint and the baseline record-level hash fingerprint, the current backend business record is re-acquired to update the baseline data, and the incremental data set is reconstructed using the updated baseline data. If the re-comparison still shows inconsistency, the current synchronization is stopped. Therefore, the resynchronization process will not continuously loop without a defined termination state. The nursing dashboard can identify data records where synchronization was incomplete based on the retained data conflict status, ensuring that the current backend business record is not overwritten by the original incremental data set.
[0050] In this embodiment, patient information, nursing item information, examination item information, examination indicator data, and shift handover information can all be included in the above processing flow as medical business data. For any medical business data, as long as the corresponding medical business field can be identified by semantic mapping and a record correspondence between the current data and the baseline data can be established according to the business record identifier, the difference judgment and incremental synchronization can be performed using the S1 to S5 processing chain. The actual number of semantic field groups is determined by the semantic identifier in the corresponding business record.
[0051] By first organizing the original medical business fields into a current semantic field group and a baseline semantic field group with definite business meaning through semantic mapping relationships, and then generating standardized semantic features under a unified standard, the field arrangement and data expression methods can be processed consistently before hash comparison. By first comparing the current record-level hash fingerprint with the baseline record-level hash fingerprint, and then comparing the field group hash fingerprint when the record-level comparison is inconsistent, it is possible to first determine whether there are differences in the business records, and then locate the differences to the corresponding semantic field groups. By forming an incremental data set based on the difference semantic field groups and change types, the data range sent to the nursing dashboard backend can correspond to the already identified business semantic changes. By comparing the backend record-level hash fingerprint with the baseline record-level hash fingerprint before data writing, the corresponding data writing can be stopped when the current business record in the backend is inconsistent with the synchronous baseline data, and the comparison baseline can be re-established using the conflict rollback process.
[0052] The specific data organization, processing order, field status, hash comparison relationship, conflict handling, and data transfer method between the nursing dashboard and the nursing dashboard backend described in this embodiment are used to explain the possible implementations of the present invention and should not limit the present invention to the specific implementation content listed. Without departing from the technical solutions described in this invention, any equivalent substitutions, modifications, combinations, order adjustments, equivalent transformations of field names, and equivalent acceptance of execution entities that can be made by those skilled in the art should fall within the scope of protection of this application, but should not alter the substantive technical correspondence between semantic field group division, standardized semantic feature formation, hierarchical hash matching, incremental data set construction, and backend benchmark verification.
Claims
1. A method for incremental synchronization of medical data based on semantic feature hash matching, characterized in that, The method includes: Obtain the medical business data to be synchronized and the synchronization baseline data from the nursing dashboard, and divide the corresponding business records into the current semantic field group and the baseline semantic field group according to the semantic mapping relationship; The current semantic field group and the baseline semantic field group are processed according to a unified standard to form a standardized semantic feature. A field group hash fingerprint is generated based on the standardized semantic feature, and the field group hash fingerprint is combined according to the semantic identifier to generate the current record-level hash fingerprint and the baseline record-level hash fingerprint. Compare the current record-level hash fingerprint with the baseline record-level hash fingerprint. If they match, the synchronization ends. If they do not match, compare the corresponding field group hash fingerprints according to the semantic identifier. Determine the difference semantic field group and change type based on the field group existence status and hash matching results. Based on the differential semantic field group and the change type, extract medical business data, associate it with the baseline record-level hash fingerprint to form an incremental data set, and send the incremental data set to the nursing dashboard backend; The nursing dashboard backend generates a backend record-level hash fingerprint based on the current business records in the backend database, and compares it with the baseline record-level hash fingerprint. If they match, the backend database is updated based on the incremental data set and the updated record-level hash fingerprint is returned. If they do not match, writing is stopped and a data conflict status is returned.
2. The incremental synchronization method for medical data based on semantic feature hash matching according to claim 1, characterized in that, The semantic mapping relationship is the correspondence between medical business fields and the semantic identifier; Read the medical business fields in the medical business data to be synchronized and the synchronization benchmark data, determine the corresponding semantic identifiers according to the semantic mapping relationship, and classify the medical business fields with the same semantic identifiers and belonging to the same business record into the current semantic field group and the benchmark semantic field group respectively.
3. The incremental synchronization method for medical data based on semantic feature hash matching according to claim 2, characterized in that, Establish a record correspondence between the medical business data to be synchronized and the synchronization benchmark data according to the business record identifier; When a corresponding baseline business record exists, the current semantic field group and the baseline semantic field group are formed according to the semantic mapping relationship; When there is no corresponding baseline business record, skip the hash fingerprint comparison process, determine the current semantic field group as the difference semantic field group, and determine the change type as new.
4. The incremental synchronization method for medical data based on semantic feature hash matching according to claim 1, characterized in that, The unified specification determines the field arrangement rules and data expression rules according to the semantic identifier, and performs field sorting, data type conversion and state expression normalization processing on the current semantic field group and the baseline semantic field group. The field contents, after being processed according to the field arrangement rules, are respectively formed into the corresponding standardized semantic features.
5. The incremental synchronization method for medical data based on semantic feature hash matching according to claim 4, characterized in that, The normalized semantic features are hashed to generate hash fingerprints for the current field group and the baseline field group, respectively. The hash fingerprint combination order is determined according to the semantic identifier. The hash fingerprint of the current field group and the hash fingerprint of the base field group corresponding to the same business record are combined respectively and hashed to generate the hash fingerprint of the current record level and the hash fingerprint of the base record level.
6. The incremental synchronization method for medical data based on semantic feature hash matching according to claim 1, characterized in that, Compare the current record-level hash fingerprint with the baseline record-level hash fingerprint; If the comparison is consistent, the incremental synchronization of the corresponding business records will be terminated; When there is a discrepancy, a field group correspondence is established between the current semantic field group and the baseline semantic field group according to the semantic identifier, and the corresponding field group hash fingerprints are compared to form a field group matching result.
7. The incremental synchronization method for medical data based on semantic feature hash matching according to claim 6, characterized in that, Detect the existence status of the current semantic field group and the baseline semantic field group based on the field group correspondence; When the current semantic field group exists and the baseline semantic field group does not exist, the current semantic field group is determined as the difference semantic field group, and the change type is determined as addition; When the current semantic field group does not exist and the baseline semantic field group exists, the baseline semantic field group is determined as the difference semantic field group, and the change type is determined as deletion; When both the current semantic field group and the baseline semantic field group exist and the matching results of the field groups are inconsistent, the current semantic field group is determined as the difference semantic field group, and the change type is determined as modification; When both the current semantic field group and the baseline semantic field group exist and the matching results of the field groups are consistent, the current semantic field group is not determined as the difference semantic field group.
8. The incremental synchronization method for medical data based on semantic feature hash matching according to claim 1, characterized in that, Determine the business record identifier and the semantic identifier for the group of differential semantic fields; When the change type is addition or modification, the corresponding field content is extracted from the medical business data to be synchronized; when the change type is deletion, the business record identifier and the semantic identifier are used as deletion location information. The incremental data set is formed by associating the business record identifier, the semantic identifier, the change type, the baseline record-level hash fingerprint, and the corresponding field content.
9. The incremental synchronization method for medical data based on semantic feature hash matching according to claim 1, characterized in that, The nursing dashboard backend reads the current business record from the backend database based on the business record identifier associated with the incremental data set; The current business record is processed according to the semantic mapping relationship, the unified specification, and the hash generation rules used when generating the baseline record-level hash fingerprint, and the background record-level hash fingerprint is generated. When the background record-level hash fingerprint is consistent with the baseline record-level hash fingerprint, the medical business data is modified according to the change type, and the updated record-level hash fingerprint is generated based on the modified business record.
10. The incremental synchronization method for medical data based on semantic feature hash matching according to claim 9, characterized in that, When the background record-level hash fingerprint is inconsistent with the baseline record-level hash fingerprint, the nursing dashboard background stops writing to the incremental data set and returns the data conflict status and the business record identifier; The nursing dashboard retains the synchronization baseline data, re-acquires the current business record based on the business record identifier, and performs field group hash matching between the medical business data to be synchronized and the current business record and the synchronization baseline data respectively to determine the semantic field groups of only local change, only backend change, and both parties change. When the hash fingerprint of the local field group corresponding to the semantic field group changed by both parties is inconsistent with the hash fingerprint of the backend field group, it is determined to be a concurrent conflict; When there are no concurrent conflicts, the current business record is used as the retry benchmark, and the incremental dataset is re-formed based on the locally changed semantic field group and then merged and sent to the nursing dashboard backend.
