Abstract
Identifying a person’s blood group correctly is critical for safe medical care, especially in emergencies, surgeries and prenatal care. This work presents an intelligent blood typing system that combines digital microfluidics with deep learning and antigen-based decision rules. A vision transformer learns to recognize agglutination patterns in images of blood droplets, and the standard ABO and Rh rules are then applied automatically to give the blood group. The system detected antigen–antibody agglutination reactions with 100% accuracy, while using smaller amounts of reagents and lowering the cost of testing.
Introduction
Knowing a patient’s blood group quickly and correctly matters most when time is short, such as in emergencies, during surgery and in prenatal care. Conventional blood typing relies on a person looking at the sample to judge whether the blood has clumped after reacting with a test antibody. This visual check can lead to mistakes, particularly when only a small volume of blood is available.
This project addresses the problem by automating the reading of the reaction. It brings together a digital microfluidics chip, which handles very small drops of blood, and a deep-learning model that interprets the result without human judgement.
Proposed Method
The system works in stages. Small blood droplets are handled on a digital microfluidics chip, and images of the droplets are captured. A vision transformer, a type of deep-learning model, is trained to recognize the agglutination patterns that appear in these droplet images. Once the antigen results are known, the standard ABO and Rh rules are applied automatically to assign the final blood group.
The chip is a printed circuit board with a grid of small electrodes, and the blood droplet sits on top of it (Figure 1).
A blood droplet is placed on the chip and moved across the electrodes so that it mixes with a second droplet. Figures 2 and 3 show the steps, with the result observed after 5 and 10 minutes.
Blood samples of all eight blood groups were tested with anti-A, anti-B and anti-D antibodies. When the blood carries the matching antigen, the red cells clump together, which is called agglutination, while the other samples stay smooth (Figure 4).
Droplet images were captured in three ways: on the chip itself, on a glass slide and under a microscope. Samples that clump are called reactive (Figure 5), and samples that stay smooth are called non-reactive (Figure 6).
These images are given to the vision transformer, which classifies the reaction for each antibody. For example, when the A and B results are reactive and the D result is not, the system reports AB negative (Figure 7).
Results and Discussion
The proposed system achieved 100% accuracy in detecting antigen–antibody agglutination reactions, with perfect scores in precision, recall, specificity and F1-score. In addition to its accuracy, the method reduces the volume of reagents needed and minimizes the cost of testing, while improving the reliability of the result.
During training, the loss dropped quickly from about 0.1 to almost zero within the first four epochs (Figure 8). The confusion matrix covers 241 droplet images, 114 non-reactive and 127 reactive, and every one of them was classified correctly (Figure 9). The precision-recall curve and the ROC curve, whose area is 1.00, also show perfect performance (Figures 10 and 11).
Conclusions
This work shows that a digital microfluidics chip combined with a vision transformer can detect agglutination reactions reliably and turn them into a blood group automatically. In future work, the authors aim to build the system into a compact, paper-based microfluidic device, which would allow low-cost, AI-assisted blood typing in portable point-of-care settings.
Author Contributions
S.S.B. carried out the experimental work, developed the methodology and wrote the original draft of the manuscript. A.K. performed experiments and prepared the raw data. K. carried out experiments and contributed to the methodology. H.U. provided resources and technical support. S.U.A. contributed to supervision and critical review of the manuscript. A.T.J. was responsible for funding acquisition and project administration, and also supervised the work and reviewed the manuscript. All authors reviewed and approved the final manuscript.
Funding
- Erasmus+ Capacity Building for Higher Education (CBHE), Strand 2, funded by the European Union (Grant No. Catch VR – 101129191).
- Technology Development Fund, funded by the Higher Education Commission (HEC) Pakistan (Grant No. TDF04-167).
- Patent and Prototyping Support Program, funded by the Directorate General of Science and Technology (DoST), Khyber Pakhtunkhwa, Pakistan (Grant No. DGST25-1245).
Ethical Approval
The blood samples used in this study were leftover specimens from the GIK Institute Medical Center, collected after routine clinical testing. No additional blood was drawn for the research. All samples were fully anonymized before analysis, and the researchers had no access to personal information. The use of these samples followed the institutional policies of the GIK Medical Center and did not require individual informed consent or formal IRB approval.
Competing Interests
The authors declare no competing interests.