Inspiration
MediBuddy is inspired by the grave issue of misdiagnosis in the healthcare world.
- Approximately 250,000 Americans die from being misdiagnosed every year. Despite rigorous training of healthcare professionals, errors occur and can occur very often, which can lead to fatal consequences such as incorrect treatment plans or the overlooking of major diseases.
By leveraging machine learning models, MediBuddy can analyze symptoms, body measurements, and more inputs by doctors and generate accurate, personalized suggestions on diagnoses and treatments based on previous case data.
- MediBuddy aims to reduce the rates of misdiagnosis by utilizing a large database of medical history and producing accurate predictions of likely diagnosis possibilities. This can help physicians arrive at a more accurate diagnosis for each individual patient based on their symptoms and conditions.
Ultimately, the purpose of MediBuddy is not to replace the job of a doctor, but to complement it.
- As an efficient tool that enhances diagnostic accuracy, accelerates recovery by providing immediate treatment suggestions, and saving money that otherwise would have been spent on unnecessary testing (for diseases that are highly unlikely), MediBuddy is a powerful tool that can help save lives and improve the world of healthcare.
What it does
MediBuddy is a website powered by an AI disease prediction model that works to solve the problem of diagnostic errors in healthcare that lead to hundreds of thousands of deaths every year.
The AI model provides the physician with confident inferences about whether a patient likely has a certain condition MediBuddy acts as a virtual physician’s assistant that can help physicians reinforce their diagnoses and compile personalized reports of recommendations for patients.
The personalized reports, which are generated by Gemini, identify whether or not the patient is likely to have a certain disease, and offer recommendations regarding diet, exercise, and other habits to practice in order to treat or prevent that specific disease.
How we built it
Roles:
- Choidorj Bayarkhuu: Primary frontend developer CS @ UCLA
- Arnav Roy: Primary backend logic developer, machine learning CS @ UCLA
- Stanley Sha: Backend Flask developer and presentation contributor CS @ UCI
- Emma Wu: Data processing, secondary front-end developer and presentation lead STATS + DS @ UCLA
Frontend:
The frontend of MediBuddy is built mostly on HTML and CSS, with bits of SCSS and JavaScript as well.
The main landing page is the home screen that contains information such as a brief summary about the site and navigation to the other pages.
One can access diagnosis reinforcement and data export features from this page
A login page allows a user to log in which then connects to the back end with the database and data specific to each account
A user input page is where the main data for MediBuddy is gathered. The user (a doctor) is given a variety of options for disease to test for. After selecting a condition, the page will then ask for more specific health information of the patient.
The patient’s data then gets sent to the backend where it is processed.
The results that come from the machine learning model are printed on another landing page alongside an LLM that prints a custom report as per the patient’s data and diagnosis.
Backend:
Our backend is the incorporation of the K-Nearest Neighbors machine learning model as well as the LLM functioning through Flask and SQLite
The machine learning model is trained on previous diagnosis data. The data accurately represents the likelihoods of certain health conditions. It is designed to be trained on confirmed diagnosis data for patients in the past.
Creating an app through the Flask framework, we are able to pass the information that we need between the frontend and backend.
Once the backend gets the patient diagnosis back from the machine learning model, the results are fed to the Large Language Model. In our case, we integrated Google Gemini to help generate the custom AI report.
Challenges we ran into
The first major problem that we ran into was that none of us had experience working with a full tech stack. Specifically, backend frameworks were unfamiliar territory for us all. After landing on Flask for the backend and HTML, CSS, and JavaScript for the frontend as the desired framework, we had to go through the learning process of using a framework to help streamline our coding process.
Another significant problem that we ran into was building and training a machine learning model. The end goal was to get the model results to match as closely to the historical test data as we could. It required rigorous testing and tuning. With each iteration of the model, we were able to more closely tune the process until it reached a level of accuracy at which we were satisfied with.
Finally, the last challenge that we ran into was retrieving data from an API. None of us had any prior experience with API, and using API to retrieve information from Gemini was a challenge we had to overcome.
Accomplishments that we're proud of
We are proud of making and training our own machine learning model. Our model has the ability to receive data from a patient and determine, based on that individual’s conditions and historical medical trends, whether or not that patient is likely to have a certain disease or condition. By developing our model using trial-and-error and a K-NN algorithm, we were able to achieve an accurate predictor of disease.
We are also proud of the usability and functionality of our website interface. We used raw HTML, CSS, and Javascript to code our website. It has features such as dynamic animations, a sticky navigation bar, a working sign up/sign in page, a dark/light mode, and an embedded service that receives input data and outputs machine learning plus Gemini-generated medical advice based on that data.
What we learned
We learned how to apply statistical practices to train and use a machine learning model use large data sets
We learned how to write a strong Gemini prompt that yielded detailed and accurate answers.
We learned how to connect frontend and backend elements in a full tech stack for development.
We learned that energy drinks are better than coffee (except for Emma)
What's next for MediBuddy
Training the disease prediction model on more diseases and conditions.
Implementing a “patient” account feature that allows patients to see their profiles and doctor recommendations.
Implement an assignment feature that assigns each patient to a doctor and allows the patient to text/chat with the doctor to directly communicate for medical advice.
Log in or sign up for Devpost to join the conversation.