Inspiration

People often struggle to find fast and reliable information about the medications that they are taking. Drug packages contain leaflets with the information about the drug, but that leaflet contains vast amounts of text and sometimes it may be hard to find the information that we're looking for. We wanted to structure this kind of data and create a comprehensive database containing the most important drug data and provide people of all ages easy access to this database.

What it does

DrugComp is a chatbot with which you can interact to find out different things about the drug that you are taking. For example, you can ask what other medications that you are taking interact with, so you would not take those two drugs simultaneously. Pretty important and useful, isn't it? Other than that, you can ask which are the side effects of that drug, or report your side effects so other people would be more careful about it. And at last, you can ask DrugComp to tell you what each drug is used for.

How we built it

Taking advantage of Comprehend Medical's ability to handle raw medical information, we extracted all relevant entities for each drug from the medicine’s information leaflet. We took different sections (like Drug Interactions, Adverse Reactions, and Indications and Usage) and extracted entities using Comprehend Medical. The extracted information was double checked and cleaned from the inappropriate entities, thus paving a way to create a heterogeneous graph which contained 3 different types of nodes: drugs, adverse reactions and drug usages. Each drug was connected with other incompatible drugs. Also, each drug was connected to other types of nodes (adverse reactions and drug usages) which are relevant for the corresponding drug. This graph-like structure helps us to have clear information of each drug’s properties. Using this graph, we trained a machine learning model for link prediction in order to predict new, unknown drug-drug interactions. Using this, we will acknowledge any possible interactions between two drugs which are not confirmed, but may be a potential problem. To evaluate this model, we used the metric ROC AUC score (Area Under the Curve ROC), which was 0.92 on the test dataset.

All of the data was indexed with the Amazon OpenSearch Service so we can perform fast searches on it. We also created a chatbot using Amazon Lex which recognizes 4 types of intents: ask for drug interactions intent, ask for drug side effects intent, ask for drug indications and usage intent and report drug side effects intent.

Finally, a simple interface was developed so that the users can easily interact with the system and receive understandable information.

Challenges we ran into

The biggest challenge that we’ve dealt with was extracting accurate information from unstructured, noisy data. The data items in our dataset were not the same, they had different forms and structures, and it was time consuming to consolidate data and extract only the relevant information from it.

Other than that, it was really challenging to transform an idea into a product that's inclusive and useful for people of all ages.

Accomplishments that we're proud of

We are extremely proud that we managed to develop an entire architecture for our product and deploy a beta version of it. Other than that, we are very proud that we’ve trained a model with such high accuracy for predicting new links, and we are proud of the chatbot interface that we’ve created which can be used by anyone, even without any medical knowledge. At last, many of the technologies that we’ve used are relatively new and we managed to deal with them well.

What we learned

The most valuable skill that we’ve learned on this project is the AWS expertise that we’ve obtained. We had the opportunity to build an entire application and architecture using AWS services, which was a new experience for us, since so far we’ve rarely built an entire application using only AWS.

What's next for DrugComp

The next steps that we might undertake is to improve the consistency and accuracy of the data that we provide. Also, since it will be more user-friendly, we would like to create a mobile app which besides the text, will take speech as user input for the chatbot. Other opportunities may arise with extracting the chemical elements of a drug and determining the drug interactions, side effects and dosage regulation will be moved on a lower level, possibly even more precise.

Built With

Share this project:

Updates