Primary index management system and identity recognition method
By combining an improved snowflake algorithm and attribute association analysis with an attention mechanism, patients are assigned primary index numbers, weights are dynamically adjusted, and similarities are calculated using a Siamese network. This solves the accuracy and efficiency issues of patient identification in multi-hospital platforms and enables efficient patient data management and sharing.
Patent Information
- Application Number
- CN202511219242.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-08-28
- Publication Date
- 2025-10-17
- Estimated Expiration
- 2045-08-28
AI Technical Summary
Existing technologies cannot effectively solve the problems of accuracy and efficiency in patient identity identification in multi-hospital platforms, especially when patient information is inconsistent. The lack of dynamic adjustment of matching weights and automatic merging mechanisms makes manual verification time-consuming and error-prone.
An improved snowflake algorithm is used to assign a primary index number with a number retention function to each patient. Attribute association analysis and attention mechanism are combined to dynamically assign attribute weights. The Siamese network is used to calculate similarity, set personal interval values and dynamic decision buffer ranges, and automatically merge or push them to the doctor's end for judgment.
It improves the accuracy of patient data identification and management efficiency, ensures the uniqueness and traceability of data, enhances the flexibility and intelligence of the system, and ensures data integrity and consistency.
Smart Images

Figure CN120804101A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application belongs to the technical field of data management, and particularly relates to a main index management system and an identity recognition method. BACKGROUND
[0002] With the development of medical informatization, a plurality of hospital platforms have accumulated a large amount of patient medical data. However, due to the relatively independent information systems of different hospitals, the recording modes of patient information in different systems are different, which leads to different identities of the same patient in different hospitals, which brings great difficulty to the sharing, analysis and utilization of medical data. For example, the name of a patient may be different in pronunciation and characters, and the name may be a nickname, the ID number may be incomplete or inaccurate due to input errors or the patient not providing accurate information, and the birth date may also have recording deviations. Therefore, how to accurately identify the patient identity in the data of the multi-hospital platform and establish a unified main index archive has become a problem to be solved in the current medical data processing field.
[0003] A Chinese patent with the authorized announcement number CN106295182B discloses an identity recognition method based on patient biological information, which comprises: obtaining the similarity weight of the patient data to be identified and any other data in the patient identity database through social attribute feature matching; obtaining the similarity of the patient data to be identified and any other data in the patient identity database through biological attribute feature matching; performing weighted calculation on the similarity weight and the similarity to obtain the comprehensive similarity of the patient data to be identified and any other data in the patient identity database; comparing the comprehensive similarity with a set threshold; if the comprehensive similarity is greater than the set threshold, it is considered that the two data belong to the same person, thereby realizing the recognition of the patient identity. The technical solution can improve the efficiency and success rate of patient main index recognition.
[0004] The above prior art has the following problems: it is unable to dynamically adjust the key attributes according to the data characteristics, such as the matching weight of different attributes, and the suspected cases need to be checked by artificial all the time, which is time-consuming and prone to errors, and there is also a lack of forced merging mechanism, which is unable to handle data conflicts or special cases confirmed by doctors. SUMMARY
[0005] In view of the deficiencies of the prior art, the present application provides a main index management system and an identity recognition method, wherein an improved snowflake algorithm is used to allocate a main index number with a number preservation function to each patient, and patient attribute information and the main index number are stored in a main index archive in a distributed manner to construct a patient basic archive; attribute correlation analysis combined with an attention mechanism is used to dynamically allocate attribute weights, new collected patient data is identified one by one in the main index archive, and an improved similarity algorithm combined with dynamic attribute weights is used to calculate multidimensional similarity; attribute personal interval values are set, the similarity results and the personal interval values are comprehensively judged, and if the similarity is higher than a threshold value, the patient is determined to be the same person, suspected cases are pushed to a doctor terminal, and the main index archive is updated, thereby improving the accuracy of patient data recognition and management efficiency.
[0006] To achieve the above object, the present application provides the following technical scheme.
[0007] An identity recognition method comprises the following steps:
[0008] Step S1: patient data of a multi-hospital platform is acquired, an improved snowflake algorithm is used to allocate a main index number to each patient, the main index number is associated with attribute information of the patient, and the main index number and the attribute information are stored in a main index archive in a distributed manner; the main index number has a number preservation function;
[0009] Step S2: attribute correlation analysis combined with an attention mechanism is used to dynamically allocate attribute weights, new collected patient data is identified one by one in the main index archive according to attribute values, and a Siamese network is used to calculate similarity between the new collected patient data and existing patient data in the main index archive in combination with dynamic attribute weights;
[0010] Step S3: personal interval values of each attribute are set, similarity results and the personal interval values are comprehensively judged in combination with a preset dynamic decision buffer interval range, and automatic merging or pushing to a doctor terminal is performed according to a comprehensive judgment result;
[0011] Step S4: after the doctor receives the pushed data in the background, the doctor adds or independently merges according to actual conditions, and updates the merged data or newly added patient records to the main index archive; the independent merging comprises normal merging and forced merging.
[0012] Specifically, the specific steps of step S1 comprise:
[0013] S1.1: according to a multi-hospital platform architecture, a unique data center ID is allocated to each hospital platform, and a unique worker machine ID is allocated to different business modules in each data center;
[0014] S1.2: Set the sequence number bit number and the timestamp encoding rule, binary encode the data center ID and the worker ID to obtain a first index number and a second index number;
[0015] The timestamp encoding rule adopts a timestamp combined with millisecond level and microsecond level;
[0016] S1.3: Initialize the sequence number, obtain patient data of a multi-hospital platform, and perform preprocessing;
[0017] S1.4: Process each patient record in turn from the preprocessed patient data:
[0018] Binary encode the current time according to the timestamp encoding rule as a third index number;
[0019] Concatenate the third index number, the first index number, the second index number and the sequence number in order, and convert the concatenated binary number into a decimal number as the primary index number of the patient;
[0020] In the same microsecond segment, the sequence number is incremented by 1 each time a primary index number is generated, and if the sequence number reaches the maximum value of the sequence number bit number, a new primary index number is generated in the next microsecond segment and the sequence number is reset to zero.
[0021] Specifically, the specific steps of the step S1 further include:
[0022] S1.5: Extract attribute information of the patient from the preprocessed patient data in turn, traverse each attribute, and form a key-value pair set by taking the attribute name as the key and combining the corresponding attribute value and the primary index number generated in S1.4 as the value;
[0023] S1.6: Construct an empty information association table in the primary index archive, and insert the primary index number generated in S1.4 and the key-value pairs in the key-value pair set generated in S1.5 into the empty information association table row by row;
[0024] S1.7: Read the patient data records in the information association table row by row, obtain the primary index number of each patient data record, and calculate the hash value of the primary index number using a modulo hash function;
[0025] S1.8: According to the calculated hash value of the primary index number, distribute the patient data records to the corresponding partitions; the number of partitions is the maximum value of the hash value of the primary index number;
[0026] S1.9: In the primary index archive, create an independent partition table for each partition, and create an index for each partition table;
[0027] S1.10: Write the patient data records assigned to each partition in S1.8 into the corresponding partition table to obtain the main index archive after partition storage.
[0028] Specifically, the specific steps of step S2 include:
[0029] S2.1: Extract the existing patient data D from the main index archive after partition storage according to the partition number history , and obtain new patient data D in real time new ;
[0030] S2.2: According to D history and D new , forming an attribute set A={a1,…,a n}, where a n Represents the nth attribute, where n represents the number of attribute categories;
[0031] S2.3: For each pair of attributes (a i ,a j ), i≠j, using the chi-square test method, based on D history Patient data calculation in (a i ,a j )'s attribute correlation g ij , and construct the attribute association matrix, where i and j represent attribute indices;
[0032] S2.4: According to the attribute type in attribute set A, set attribute encoding rules and set D history and D new Convert it into vector form according to the attribute encoding rules to obtain the archive patient data vector set V history and new patient data vector v new , where each patient data corresponds to an n-dimensional vector, and the i-th dimension of the vector represents attribute a i The coded value of
[0033] S2.5: For v new The i-th attribute dimension in Use the attention mechanism to calculate its attention score c i , after normalization, we get the weight w of each attribute i .
[0034] Specifically, the specific steps of step S2 also include:
[0035] S2.6: Load a pre-trained Siamese network; the Siamese network includes two sub-networks with shared weights; the sub-networks take the patient data vector as input and output a feature vector;
[0036] S2.7: input the new patient data vector v new and V history into two sub-networks of the pre-trained Siamese network respectively, to obtain the new patient data feature vector f1 and the set of archive patient data feature vectors F , respectively, where , and represents the Nth archive patient data feature vector, N represents the number of archive patient data feature vectors, k represents the archive patient data vector index, and k ∈ [1, N];
[0037] S2.8: for f1 and each archive patient data feature vector f history in F , calculate the similarity d k between f1 and f using the Euclidean distance.
[0038] Specifically, the specific steps of S2.3 include:
[0039] S2.31: extract the existing patient data D history in the main index archive according to the partition number, and confirm that each attribute in the attribute set A exists in D history ;
[0040] S2.32: for each pair of attributes (a i , a j ), extract its observation value and construct a two-dimensional contingency table; the rows of the contingency table represent different values of a i , and the columns represent different values of a j ;
[0041] S2.33: count the number of occurrences of each combination (a i = B, a j = C) and fill it into the corresponding cell of the contingency table, where B and C represent two attribute values;
[0042] S2.34: according to the product of the number of samples with a i value B and the number of samples with a j value C in the contingency table, divided by the total number of samples, the expected frequency E BC of each cell is obtained;
[0043] S2.35: according to the square of the difference between the observed frequency O BC and the expected frequency E BC , divided by E BC, and sum the quotients obtained by division to obtain the chi-square statistic, and use the chi-square statistic as attribute a i and a j The attribute correlation g ij ; The summation is performed based on all cells in the contingency table;
[0044] S2.36: Based on the number of rows (row) and columns (col) in the contingency table, calculate the degrees of freedom (df) = (row - 1) × (col - 1).
[0045] S2.37: Use the chi-square distribution table to find the critical value p based on the degrees of freedom;
[0046] S2.38: If g ij >p, then determine attribute a i and a j There is a significant correlation between them, otherwise, attribute a is determined i and a j There was no significant correlation between
[0047] S2.39: For each pair of attributes (a i ,a j ), fill the calculated attribute association degree into the preset empty attribute association matrix to obtain the attribute association matrix, and the dimension of the attribute association matrix is the number of attributes in the attribute set A.
[0048] Specifically, the specific steps of step S3 include:
[0049] S3.1: Define a personal interval value range for each attribute, and define a dynamic decision buffer range based on the personal interval value range; the dynamic decision buffer range is ±10% of the personal interval value range;
[0050] S3.2: Obtaining the similarity between the newly collected patient data in step S2 and the existing patient data in the main index archive;
[0051] S3.3: For each newly collected patient data, check whether its attribute value falls within the personal interval value range;
[0052] If all attribute values of the newly collected patient data fall within the individual interval value range, it is determined to be the same person, and the newly collected patient data is merged with the existing patient data in the master index archive based on the master index number;
[0053] If there is an attribute value that is not within the personal interval value range, but the similarity result is within the preset dynamic decision buffer range, it is determined to be the same person, and the missing attribute association is completed through the knowledge graph. At the same time, the completed patient data is merged with the existing patient data in the main index archive;
[0054] If the attribute value is not within the personal interval value range, and the similarity result is not within the preset dynamic decision buffer interval range, the newly collected patient data is pushed to the doctor end for background viewing and judgment.
[0055] Specifically, the specific steps of the step S4 include:
[0056] S4.1: After the doctor receives the pushed data in the background, the corresponding combination situation is generated according to the actual situation, and the newly collected patient data is compared with the existing patient data in the main index archive;
[0057] S4.2: Whether the newly collected patient data and the existing patient data in the main index archive are the same person is judged;
[0058] If it is judged that they are not the same person, a new patient record is generated, and the new patient record is entered into the system;
[0059] If it is judged that they are the same person, the newly collected patient data is combined with the existing patient data in the main index archive according to the main index number;
[0060] S4.3: The combined patient data or the newly added patient record is updated to the main index archive.
[0061] A main index management system, comprising: an index allocation module, an identification module, a judgment and decision module, and a doctor end module;
[0062] The index allocation module is used for collecting patient data of a multi-hospital platform, and allocating a unique main index number to each patient, storing patient attribute information and the main index number into a main index archive;
[0063] The identification module uses attribute association analysis combined with an attention mechanism to perform dynamic attribute weight allocation, and calculates the multi-dimensional similarity of the newly collected patient data and the existing patient data in the main index archive;
[0064] The judgment and decision module is used for comprehensive judgment according to the similarity calculation result and the personal interval value, and decides whether it is the same person or is pushed to the doctor end for background viewing and judgment;
[0065] The doctor end module is used for the doctor to receive the pushed data in the background, to perform adding or combining operation according to the actual situation, and to save the updated data into the main index archive.
[0066] Compared with the prior art, the beneficial effects of the present application are:
[0067] 1.The present application proposes an identity recognition method, which assigns a main index number with a number preservation function to each patient through an improved snowflake algorithm, and distributes the patient attribute information and the main index number, forming a unified and efficient patient basic archive library, which not only ensures the uniqueness and traceability of patient data, but also improves the efficiency and accuracy of data management; at the same time, the dynamic attribute weight distribution is carried out by using attribute association analysis combined with attention mechanism, and the multi-dimensional similarity is calculated by using the improved similarity algorithm, so that the newly collected patient data can be accurately matched with the existing patient data in the main index archive library, effectively improving the accuracy and efficiency of patient identity recognition.
[0068] 2.The present application proposes an identity recognition method, which sets the individual interval value of each attribute for comprehensive judgment, and pushes to the doctor end for background viewing and judgment when the similarity is the same or a suspected case occurs, further enhancing the reliability and flexibility of patient identity recognition; doctors can generate corresponding combination according to actual situation, add new patient records or merge existing patient data, ensuring the integrity and consistency of patient data. BRIEF DESCRIPTION OF DRAWINGS
[0069] Figure 1 is a schematic diagram of the present application;
[0070] Figure 2 is a principle flow chart of the present application;
[0071] Figure 3 is a main index generation flow chart of the present application;
[0072] Figure 4 is a main index management system architecture diagram of the present application. DETAILED DESCRIPTION
[0073] Example 1:
[0074] Please refer to Figure 1 and Figure 2 , the present application provides an embodiment: an identity recognition method, comprising the following steps:
[0075] Step S1: obtaining patient data of a multi-hospital platform, using an improved snowflake algorithm to assign a main index number to each patient, associating the main index number with the attribute information of the patient, and distributing and storing in a main index archive library; the main index number has a number preservation function;
[0076] Step S2: Dynamic attribute weight allocation using attribute association analysis combined with attention mechanism, for newly collected patient data, according to attribute values, one by one identification is carried out in the main index archive, and the similarity between the newly collected patient data and the existing patient data in the main index archive is calculated using the Siamese network combined with the dynamic attribute weight;
[0077] Step S3: Set the personal interval value of each attribute, according to the similarity result and the personal interval value, combined with the preset dynamic decision buffer interval range for comprehensive judgment, and according to the comprehensive judgment result for automatic merging or pushing the doctor end in the background;
[0078] Step S4: After the doctor receives the pushed data in the background, according to the actual situation, add or independently merge, update the merged data or newly added patient record to the main index archive; The independent merging includes normal merging and forced merging.
[0079] In summary, the unified management and efficient sharing of patient data of multiple hospital platforms are realized, wherein the improved snowflake algorithm ensures the uniqueness and traceability of patient data, the attention mechanism and attribute association analysis improve the accuracy and efficiency of patient identity recognition, especially, the missing attribute association is completed through the knowledge graph and machine learning inference algorithm, which further enhances the intelligence and practicality of the system, in addition, the artificial judgment link of the doctor end not only ensures the accuracy of the result, but also improves the flexibility of the system.
[0080] Embodiment 2:
[0081] Please refer to Figure 3 The specific steps of step S1 in the embodiment include:
[0082] S1.1: According to the multi-hospital platform architecture, a unique data center ID is allocated to each hospital platform, and a unique worker machine ID is allocated to different business modules inside each data center;
[0083] S1.2: Set the number of serial number bits and the time stamp encoding rule, binary encode the data center ID and the worker machine ID to get the first index number and the second index number;
[0084] The time stamp encoding rule adopts a time stamp combining millisecond level and microsecond level;
[0085] Further, the specific steps of S1.2 include:
[0086] S1.21: According to system requirements and data volume, the number of serial numbers is pre-set;
[0087] S1.22: Adopt a time stamp encoding rule combining millisecond level and microsecond level;
[0088] S1.23: Binary encode the data center ID and the worker ID respectively, assuming that the data center ID and the worker ID are both integers, directly convert them into binary form, for example, if the data center ID is 123 in decimal and the worker ID is 45 in decimal, their binary encodings are 1111011 and 101101 respectively;
[0089] S1.24: Take the binary encoding of the data center ID as the first index number, and take the binary encoding of the worker ID as the second index number.
[0090] S1.3: Initialize the sequence number, obtain the patient data of the multi-hospital platform, and pre-process; the patient data includes but is not limited to name, ID number, medical insurance number, date of birth, gender, address, and medical record attribute information;
[0091] S1.4: Process each patient record in turn from the pre-processed patient data:
[0092] Encode the current time into binary according to the timestamp encoding rule as the third index number;
[0093] Concatenate the third index number, the first index number, the second index number and the sequence number in order, and convert the concatenated binary number to decimal number as the patient's main index number;
[0094] In the same microsecond segment, each time a main index number is generated, the sequence number is incremented by 1, and if the sequence number reaches the maximum value of the sequence number bit, wait for the next microsecond segment to generate a new main index number and reset the sequence number to zero;
[0095] S1.5: Extract the attribute information of the patient from the pre-processed patient data, iterate through each attribute, and take the attribute name as the key, and take the corresponding attribute value and the main index number generated in S1.4 as the value to form a key-value pair set;
[0096] S1.6: Construct an empty information association table in the main index archive, and insert the key-value pairs in the key-value pair set generated in S1.5 and the main index number generated in S1.4 into the empty information association table row by row;
[0097] S1.7: Read the patient data records in the information association table row by row, obtain the main index number of each patient data record, and calculate the hash value of the main index number using the modulo hash function;
[0098] Further, the specific steps of S1.7 include:
[0099] S1.71: read patient data records from the information association table row by row using a database query language, wherein each row of patient data records should contain the primary index number of the patient and its attribute information;
[0100] S1.72: extract the primary index number of the patient from the currently read row;
[0101] S1.73: input the extracted primary index number of the patient into a modulo hash function to obtain a hash value Value of the primary index number, and record it, wherein the formula of the hash value Value of the primary index number is Value = HashFunction(X) mod M, wherein X represents the extracted primary index number of the patient, M represents a positive integer, which defines the target range size of the hash value, HashFunction(·) represents the modulo hash function, and mod represents the modulo operator.
[0102] S1.8: according to the calculated hash value of the primary index number, the patient data records are distributed to the corresponding partitions; the number of partitions is the maximum value of the hash value of the primary index number;
[0103] S1.9: in the primary index archive, an independent partition table is created for each partition, and an index is created for each partition table;
[0104] Further, in S1.9, the number of partitions to be created is determined according to the hash value range of the calculated primary index number, for example, if the hash value range is 0 to 999, 1000 partitions are selected to be created;
[0105] Creating an index for each partition table means creating a hash index on each partition table, mainly including using the command provided by the database management system to execute the operation of creating a hash index on the selected partition table column, specifically, the creation process of the hash index is mainly to map the value of the index column to the hash table by using the hash function, so as to quickly find, wherein the hash table is an array or a linked list array, which is used to store hash values and corresponding data record pointers, when querying, the database system calculates the hash value of the query condition, and finds the corresponding record pointer in the hash table, so as to realize fast access.
[0106] S1.10: write the patient data records distributed to each partition in S1.8 into the corresponding partition table to obtain the primary index archive after partition storage.
[0107] The specific steps of the step S2 include:
[0108] S2.1: extract the existing patient data D history from the primary index archive after partition storage according to the partition number new ;
[0109] S2.2: According to D history and D new , forming an attribute set A={a1,…,a n}, where a n Represents the nth attribute, where n represents the number of attribute categories;
[0110] It should be noted that attribute a i To meet: or Condition, and i∈[1,n], where i represents the attribute index.
[0111] S2.3: For each pair of attributes (a i ,a j ), i≠j, using the chi-square test method, based on D history Patient data calculation in (a i ,a j )'s attribute correlation g ij , and construct the attribute association matrix, where i and j represent attribute indices;
[0112] S2.4: Set attribute encoding rules according to the attribute types in attribute set A, and set D history and D new Convert it into vector form according to the attribute encoding rules to obtain the archive patient data vector set V history and new patient data vector v new , where each patient data corresponds to an n-dimensional vector, and the i-th dimension of the vector represents attribute a i The encoding value of , each dimension represents an attribute, that is, the vector dimension is the attribute dimension;
[0113] Furthermore, the attribute types in attribute set A include but are not limited to strings, numbers, and dates. In the present invention, string attributes are encoded using one-hot encoding, number attributes directly use their values, and date attributes are converted into the number of days from a preset base date; the base date is an arbitrarily set fixed date, wherein one-hot encoding is the prior art content in this field and is not an inventive solution of this application, and will not be elaborated here.
[0114] S2.5: For v new The i-th attribute dimension in Use the attention mechanism to calculate its attention score c i , after normalization, we get the weight w of each attribute i ;
[0115] Furthermore, the specific steps of S2.5 include:
[0116] S2.51: Obtain a new patient data vector v new ;
[0117] S2.52: Initialize a trainable attention weight vector for each attribute dimension;
[0118] S2.53: For each attribute dimension in the new patient data vector, calculate its attention score using an attention mechanism, specifically, perform a dot product between the attribute dimension value and the attention weight vector;
[0119] S2.54: Normalize the calculated attention scores using a softmax function to obtain the weight of each attribute, where the softmax function is a prior art content in the field and is not the inventive scheme of the present application, and will not be described here;
[0120] S2.54: Output the normalized weight as the final weight of each attribute dimension.
[0121] S2.6: Load a pre-trained Siamese network; the Siamese network includes two sub-networks that share weights; the sub-networks take patient data vectors as input and output feature vectors;
[0122] Wherein, when loading the pre-trained Siamese network, the Siamese network architecture is loaded first, and then the patient data in the master index repository is used to train it to obtain the trained Siamese network, the specific steps include:
[0123] S2.61: Define the architecture of the Siamese network, wherein the Siamese network consists of two sub-networks that share weights, and the two sub-networks receive a pair of inputs and output corresponding feature vectors;
[0124] S2.62: Load pre-trained Siamese network model parameters, wherein loading pre-trained Siamese network model parameters is to read the model's weight and bias parameters from a file and assign these parameters to the corresponding layers of the Siamese network, and the process of pre-training the Siamese network model includes:
[0125] Randomly select paired patient data vectors (v l1 ,v l2 ) from the archive patient data vector set V history , and label the labels according to their actual similarity, similar to 1, and dissimilar to 0, to form training data, where l1 and l2 represent the index of the archive patient data vector in V new ;
[0126] The architecture of the Siamese network is trained using the training data, and the network parameters are optimized using a contrastive loss function to obtain the trained Siamese network.
[0127] S2.7: input the new patient data vector v new and each archive patient data vector in V history into two sub-networks of the pre-trained Siamese network respectively to obtain a new patient data feature vector f1 and a set of archive patient data feature vectors F wherein, represents the Nth archive patient data feature vector, N represents the number of archive patient data feature vectors, k represents the archive patient data vector index, and k ∈ [1, N];
[0128] S2.8: for f1 and each archive patient data feature vector in F history calculate the similarity d k between the new patient data feature vector f1 and each archive patient data feature vector using the Euclidean distance, wherein the formula for calculating the Euclidean distance is prior art content in the art and is not the inventive scheme of the present application, and is not described here.
[0129] The specific steps of S2.3 include:
[0130] S2.31: extract the existing patient data D history in the main index archive according to the partition number after partition storage, and confirm that each attribute in the attribute set A exists in D history ;
[0131] S2.32: for each pair of attributes (a i , a j ), extract its observation value and construct a two-dimensional contingency table; the rows of the contingency table represent different values of a i , and the columns represent different values of a j ;
[0132] S2.33: count the number of occurrences of each combination (a i =B, a j =C) and fill it into the corresponding cell of the contingency table, wherein B and C represent two attribute values;
[0133] For example, assuming that a i is the gender attribute and a j is the symptom, B can be male or female, and C can be headache or abdominal pain, etc., then (a i =B, a j =C) can represent gender is male and symptom is abdominal pain.
[0134] S2.34: According to the contingency table, attribute a i The number of samples with value B also represents attribute a j The product of the number of samples with value C divided by the total number of samples, resulting in the expected frequency E of each cell BC , where attribute a i The number of samples with value B also represents attribute a i The sum of the observed frequencies of all cells in the row with value B, attribute a j The number of samples with value C also represents attribute a j The sum of the observed frequencies of all cells in the column with value C;
[0135] S2.35: According to the observed frequency O BC And the square of the difference between the expected frequency E BC , divided by E BC , and the sum of the quotient, resulting in the chi-square statistic, and the chi-square statistic as the attribute association degree g i of attribute a j and a ij ; the sum is based on all cells in the contingency table;
[0136] Where the observed frequency is obtained by the contingency table, and each cell in the contingency table contains the observed frequency under the corresponding category combination, for example, the observed frequency of headache and male in S2.33 is 10.
[0137] S2.36: According to the number of rows row and the number of columns col in the contingency table, calculate the degrees of freedom df=(row-1)×(col-1);
[0138] S2.37: Use the chi-square distribution table to find the critical value p according to the degrees of freedom;
[0139] Where the chi-square distribution table lists the critical values under different degrees of freedom and significance levels; the significance level is a preset value, and the invention selects the significance level as 0.05.
[0140] S2.38: If g ij >p, it is determined that there is a significant association between attribute a i and a j , otherwise, it is determined that there is no significant association between attribute a i and a j ;
[0141] S2.39: For each pair of attributes (a i , a j), fill the calculated attribute correlation degree into the preset empty attribute correlation matrix to obtain an attribute correlation matrix, and a dimension of the attribute correlation matrix is a number of attributes in the attribute set A.
[0142] The specific steps of step S3 include:
[0143] S3.1: defining a personal interval value range for each attribute, and defining a dynamic decision buffer interval range according to the personal interval value range; the dynamic decision buffer interval range is ±10% of the personal interval value range;
[0144] S3.2: obtaining the similarity between the newly collected patient data and the existing patient data in the master index archive in step S2;
[0145] S3.3: checking whether the attribute values of each newly collected patient data fall within the personal interval value range;
[0146] If all the attribute values of the newly collected patient data fall within the personal interval value range, it is determined that the patient is the same person, and the newly collected patient data is merged with the existing patient data in the master index archive according to the master index number;
[0147] If there is an attribute value that is not within the personal interval value range, but the similarity result is within the preset dynamic decision buffer interval range, it is determined that the patient is the same person, and the missing attribute correlation is completed through the knowledge graph, and the completed patient data is merged with the existing patient data in the master index archive;
[0148] The specific steps of completing the missing attribute correlation through the knowledge graph include:
[0149] S3.31: using a graph database Neo4j to construct a knowledge graph, wherein the graph database Neo4j is prior art content in the field and is not the creative scheme of the present application, and will not be described here;
[0150] S3.32: under the condition of determining that the patient is the same person, checking whether the newly collected patient data has a missing attribute value by comparing the newly collected patient data with the existing patient data in the master index archive;
[0151] S3.33: if there is a missing attribute value, finding the nodes and edges related to the missing attribute in the knowledge graph for the missing attribute;
[0152] S3.34: according to the query result, using an inference algorithm to complete the missing attribute correlation, and updating the completed data to the patient record, including:
[0153] extracting the patient data containing the missing attribute from the patient record database using a query statement;
[0154] Select attributes associated with missing attributes as features and standardize the features;
[0155] Load a pre-trained random forest regression model, which is a prior art in the field and not part of the inventive concept of the present application, and therefore not described in detail here;
[0156] Input the pre-processed features into the pre-trained random forest regression model for inference and prediction to obtain the estimated value of the missing attribute, for example, for each record of missing attribute, use the model to predict the value of attribute_x;
[0157] Update the predicted missing attribute value to the patient record using a SQL update statement, which is a prior art in the field and not part of the inventive concept of the present application, and therefore not described in detail here.
[0158] If there is an attribute value that is not within the personal interval value range, and the similarity result is not within the preset dynamic decision buffer interval range, or a suspected case occurs, the newly collected patient data is pushed to the doctor's end for background viewing and judgment.
[0159] Wherein, the suspected case includes:
[0160] The combination of symptoms exhibited by the patient is not common in common diseases, or does not completely match the combination of symptoms of known diseases, i.e. there is a new disease or complication;
[0161] Compare the newly collected data with the patient's historical data and find that there is a significant change or inconsistency, i.e. the patient's condition has changed or a new problem has occurred;
[0162] There are outliers or data points that do not conform to the regular pattern in the newly collected patient data.
[0163] The specific steps of step S4 include:
[0164] S4.1: After the doctor receives the pushed data in the background, he generates the corresponding combination according to the actual situation, and compares the newly collected patient data with the existing patient data in the main index archive;
[0165] S4.2: Determine whether the newly collected patient data and the existing patient data in the main index archive are the same person;
[0166] If it is determined that they are not the same person, a new patient record is generated and the new patient record is entered into the system;
[0167] If the same person is determined, the newly collected patient data is merged with the existing patient data in the master index archive according to the master index number;
[0168] S4.3: Update the merged patient data or newly added patient record to the master index archive.
[0169] Embodiment 3:
[0170] Referring to Figure 4 Another embodiment provided by the present application is a master index management system, comprising:
[0171] an index allocation module, an identification module, a judgment and decision module, and a doctor end module;
[0172] The index allocation module is configured to collect patient data of a multi-hospital platform, allocate a unique master index number to each patient, and store patient attribute information and the master index number in a master index archive;
[0173] The identification module is configured to use attribute association analysis combined with an attention mechanism to perform dynamic attribute weight allocation, and calculate multi-dimensional similarity between newly collected patient data and existing patient data in the master index archive;
[0174] The judgment and decision module is configured to make a comprehensive judgment according to the similarity calculation result and the individual interval value, and determine whether the same person is determined or pushed to the doctor end for background viewing and judgment;
[0175] The doctor end module is configured to perform adding or merging operations according to actual conditions after the doctor receives the pushed data from the background, and save the updated data to the master index archive.
[0176] The index allocation module comprises a data collection unit, an index allocation unit, and a data storage unit.
[0177] The data collection unit is configured to collect patient data from a multi-hospital platform.
[0178] The index allocation unit is configured to allocate a master index number with a number reservation function to each patient using an improved snowflake algorithm.
[0179] The data storage unit is configured to distribute and store the attribute information and the master index number of the patient in the master index archive, forming a patient basic archive.
[0180] The identification module comprises a weight allocation unit and a similarity calculation unit.
[0181] The weight distribution unit uses attribute correlation analysis combined with an attention mechanism to dynamically distribute attribute weights; and the similarity calculation unit is used to identify each patient data in the main index archive according to attribute values, and uses an improved similarity algorithm combined with dynamic attribute weights to calculate the multidimensional similarity between the newly collected patient data and the existing patient data in the archive.
[0182] The embodiments of the present application are described above with reference to the drawings; however, the present application is not limited to the specific embodiments described above, and the specific embodiments described above are merely illustrative, not restrictive, and a person of ordinary skill in the art can make changes, modifications, replacements and variations to the above-described embodiments without departing from the purpose of the present application and the scope of protection, which are all within the protection of the present application.
[0183] If the technical solutions of the present disclosure involve personal information, the product applying the technical solutions of the present disclosure has been explicitly informed of the personal information processing rules before processing the personal information and has obtained the personal independent consent. If the technical solutions of the present disclosure involve sensitive personal information, the product applying the technical solutions of the present disclosure has obtained the personal independent consent before processing the sensitive personal information and at the same time meets the requirement of "explicit consent". For example, at the personal information collection device such as a camera, an explicit and prominent sign is set to inform that the personal information collection range has been entered and the personal information will be collected. If the individual voluntarily enters the collection range, it is considered to agree to collect the personal information. Or, on the device for processing personal information, the personal information processing rules are informed by using obvious signs / information, and the personal authorization is obtained by means of pop-up information or asking the individual to upload the personal information by himself / herself. The personal information processing rules can include the personal information processor, the purpose of processing personal information, the processing method, and the type of processed personal information, etc.
Claims
1. An identity recognition method, characterized in that: include: Step S1: Obtain patient data from multiple hospital platforms, assign a primary index number to each patient using an improved snowflake algorithm, associate the primary index number with the patient's attribute information, and store the data in a distributed manner in a primary index archive; the primary index number has a number preservation function; Step S2: Use attribute association analysis combined with the attention mechanism to perform dynamic attribute weight assignment. For newly collected patient data, identify them one by one in the main index archive based on their attribute values, and use the Siamese network combined with dynamic attribute weights to calculate the similarity between the newly collected patient data and the existing patient data in the main index archive. Step S3: Set the personal interval value for each attribute, make a comprehensive judgment based on the similarity result and the personal interval value, combined with the preset dynamic decision buffer range, and automatically merge or push the results to the backend doctor based on the comprehensive judgment result; Step S4: After receiving the pushed data in the background, the doctor adds or merges it autonomously according to the actual situation, and updates the merged data or the newly added patient records to the main index archive; the autonomous merge includes normal merge and forced merge.
2. An identity recognition method according to claim 1, characterized in that: The specific steps of step S1 include: S1.1: Based on the multi-hospital platform architecture, each hospital platform is assigned a unique data center ID, and within each data center, unique work machine IDs are assigned to different business modules; S1.2: Set the serial number digits and timestamp encoding rules, and perform binary encoding on the data center ID and the work machine ID to obtain the first index number and the second index number. The timestamp encoding rule adopts a timestamp combining millisecond and microsecond levels; S1.3: Initialize the serial number, obtain patient data from multiple hospital platforms, and perform preprocessing; S1.4: Process each patient record in turn from the preprocessed patient data: Encode the current time into binary according to the timestamp encoding rule as the third index number; Concatenate the third index number, the first index number, the second index number, and the serial number in sequence, and convert the concatenated binary number into a decimal number as the patient's primary index number; In the same microsecond segment, each time a primary index number is generated, the sequence number is incremented by 1. If the sequence number reaches the maximum number of sequence number digits, a new primary index number is generated in the next microsecond segment and the sequence number is reset to zero.
3. An identity recognition method according to claim 2, characterized in that: The specific steps of step S1 also include: S1.5: Extract the patient's attribute information one by one from the preprocessed patient data, traverse each attribute, and use the attribute name as the key and the corresponding attribute value and the primary index number generated in S1.4 as the value to form a key-value pair set; S1.6: Construct an empty information association table in the primary index archive, and insert the primary index number generated in S1.4 and the key-value pairs in the key-value pair set generated in S1.5 into the empty information association table row by row; S1.7: Read the patient data records in the information association table row by row, obtain the primary index number of each patient data record, and calculate the hash value of the primary index number using the modulo hash function; S1.8: Assign the patient data records to corresponding partitions based on the calculated hash value of the primary index number; the number of partitions is the maximum value of the hash value of the primary index number; S1.9: In the primary index archive, create a separate partition table for each partition and create an index for each partition table; S1.10: Write the patient data records assigned to each partition in S1.8 into the corresponding partition table to obtain the main index archive after partition storage.
4. An identity recognition method according to claim 3, characterized in that: The specific steps of step S2 include: S2.1: Extract the existing patient data D from the main index archive after partition storage according to the partition number history , and obtain new patient data D in real time new ; S2.2: According to D history and D new , forming an attribute set A={a1,…,a n }, where a n Represents the nth attribute, where n represents the number of attribute categories; S2.3: For each pair of attributes (a i ,a j ), i≠j, using the chi-square test method, based on D history Patient data calculation in (a i ,a j )'s attribute correlation g ij , and construct the attribute association matrix, where i and j represent attribute indices; S2.4: According to the attribute type in attribute set A, set attribute encoding rules and set D history and D new Convert it into vector form according to the attribute encoding rules to obtain the archive patient data vector set V history and new patient data vector v new , where each patient data corresponds to an n-dimensional vector, and the i-th dimension of the vector represents attribute a i The coded value of S2.5: For v new The i-th attribute dimension in Use the attention mechanism to calculate its attention score c i , after normalization, we get the weight w of each attribute i .
5. An identity recognition method according to claim 4, characterized in that: The specific steps of step S2 also include: S2.6: Load a pre-trained Siamese network; the Siamese network includes two sub-networks with shared weights; the sub-networks take the patient data vector as input and output a feature vector; S2.7: Transform the new patient data vector v new and V history Each archive patient data vector in Input them into the two sub-networks of the pre-trained Siamese network respectively to obtain the feature vector f1 of the new patient data and the feature vector set of the archive patient data in, represents the Nth archive patient data feature vector, N represents the number of archive patient data feature vectors, k represents the archive patient data vector index, and k∈[1,N]; S2.8: For f1 and F history Each patient data feature vector in the archive Use Euclidean distance to calculate the new patient data feature vector f1 and each archive patient data feature vector The similarity between k .
6. An identity recognition method according to claim 5, characterized in that: The specific steps of S2.3 include: S2.31: Obtain the existing patient data D from the main index archive after partition storage according to the partition number history , and confirm that every attribute in attribute set A exists in D history middle; S2.32: For each pair of attributes (a i ,a j ), extract its observation values and construct a two-dimensional contingency table; the rows of the contingency table represent a i Different values of, column represents a j Different values of ; S2.33: Count each combination (a i =B,a j =C) appears and is filled into the corresponding cells of the contingency table, where B and C represent two attribute values; S2.34: According to the attribute a in the contingency table i The number of samples with value B and attribute a j The expected frequency E of each cell is obtained by multiplying the number of samples with the value C by the total number of samples. BC ; S2.35: Based on the observed frequency O BC and the expected frequency E BC The square of the difference, divided by E BC , and sum the quotients obtained by division to obtain the chi-square statistic, and use the chi-square statistic as attribute a i and a j The attribute correlation g ij ; The summation is performed based on all cells in the contingency table; S2.36: Based on the number of rows (row) and columns (col) in the contingency table, calculate the degrees of freedom (df) = (row - 1) × (col - 1). S2.37: Use the chi-square distribution table to find the critical value p based on the degrees of freedom; S2.38: If g ij >p, then determine attribute a i and a j There is a significant correlation between them, otherwise, attribute a is determined i and a j There was no significant correlation between S2.39: For each pair of attributes (a i ,a j ), fill the calculated attribute association degree into the preset empty attribute association matrix to obtain the attribute association matrix, and the dimension of the attribute association matrix is the number of attributes in the attribute set A.
7. An identity recognition method according to claim 6, characterized in that: The specific steps of step S3 include: S3.1: Define a personal interval value range for each attribute, and define a dynamic decision buffer range based on the personal interval value range; the dynamic decision buffer range is ±10% of the personal interval value range; S3.2: Obtaining the similarity between the newly collected patient data in step S2 and the existing patient data in the main index archive; S3.3: For each newly collected patient data, check whether its attribute value falls within the personal interval value range; If all attribute values of the newly collected patient data fall within the individual interval value range, it is determined to be the same person, and the newly collected patient data is merged with the existing patient data in the master index archive based on the master index number; If there is an attribute value that is not within the personal interval value range, but the similarity result is within the preset dynamic decision buffer range, it is determined to be the same person, and the missing attribute association is completed through the knowledge graph. At the same time, the completed patient data is merged with the existing patient data in the main index archive; If there is an attribute value that is not within the personal interval value range and the similarity result is not within the preset dynamic decision buffer range, the newly collected patient data will be pushed to the doctor's side for background review and judgment.
8. An identity recognition method according to claim 7, characterized in that: The specific steps of step S4 include: S4.1: After receiving the pushed data in the background, the doctor generates a corresponding combination according to the actual situation and compares the newly collected patient data with the existing patient data in the main index archive; S4.2: Determine whether the newly collected patient data and the patient data already in the master index archive are for the same person; If it is determined that the patient is not the same person, a new patient record is generated and entered into the system; If it is determined to be the same person, the newly collected patient data will be merged with the existing patient data in the master index archive based on the master index number; S4.3: Update the master index archive with merged patient data or newly added patient records.
9. A master index management system, used to implement an identity recognition method according to any one of claims 1 to 8, characterized in that: include: Index allocation module, identification module, judgment and decision module, doctor-side module; The index allocation module is used to collect patient data from multiple hospital platforms, assign a unique primary index number to each patient, and store the patient attribute information and primary index number in the primary index archive; The recognition module uses attribute association analysis combined with an attention mechanism to perform dynamic attribute weight assignment and calculate the multi-dimensional similarity between newly collected patient data and existing patient data in the main index archive; The judgment and decision module is used to make a comprehensive judgment based on the similarity calculation results and the individual interval value, and decide whether to judge it as the same person or push it to the doctor's end for background review and judgment; In the doctor-side module, after receiving the push data from the background, the doctor adds or merges the data according to the actual situation and saves the updated data into the main index archive.
Citation Information
Patent Citations
A method for identity recognition based on patient biometric information
CN106295182B
Identity recognition method based on patient biological information
CN106295182A
Patient record matching method based on patient primary index, storage medium and equipment
CN114121204A
Patient probability matching system based on scene dynamic weight calculation
CN118210836A
Construction method for realizing patient primary index based on similarity calculation algorithm
CN118520002A