Developing new medicines can take years of research and cost millions of dollars before they are even ready for clinical trials. Several biotech startups are using machine learning to revolutionize the process and get drugs into pharmacies more quickly. One of the newest is called Reverie Labs, which is part of Y Combinator’s latest batch. The Boston-based company wants to fix a critical bottleneck in the drug development process by speeding up the process of identifying promising molecules using recently published machine learning algorithms.

Reverie Labs’ founders Connor Duffy, Ankit Gupta and Jonah Kallenbach, who named their company after a pivotal detail in the HBO series “Westworld,” explain that its tech analyzes early ideas for molecules from pharmaceutical scientists and suggests possible improvements to shorten the amount of time it takes to reach clinical trials. Duffy says Reverie Labs’ ambition is to “become a full service molecule-as-a-service company.” It’s already partnered with several biotech companies and academic institutes working on treatments for diseases including influenza and cancer.

Reverie Labs specializes in the lead development stage, which is when researchers focus on prioritizing and optimizing molecules so they can go to animal and human clinical trials more quickly. Pharmaceutical scientists need to first identify the proteins that cause a disease and then find molecular compounds that can bind to those proteins. Then it becomes a process of elimination as they narrow down those molecules to ones that not only create the results they want, but are also suitable for animal and human studies.

Before clinical trials can start, however, they need to evaluate molecules very carefully in order to understand things like how they are metabolized by the body and their potential toxicity.

“I’ve heard it compared to juggling eight balls at once or playing whack-a-mole,” says Duffy. “You want your compound to be very safe before you put it in people, you want to be efficacious and go where you want it to go in your body and you don’t want side effects. There are a lot of problems drug companies need to think about before putting a molecule in a human, and when you fix one problem, you often come up with another problem. We want to alleviate that by looking at all problems at the same time.”

Lead development is very labor intensive and requires the work of many medicinal chemists. Reverie Labs’ founders say it often takes more than $100 million and two years per drug before a final selection of molecules are ready for clinical trials. Reverie Labs wants to set itself apart from other startups focused on solving the same problem by taking recently-discovered machine learning techniques, and applying them to drug development.

“The machine learning algorithms we implemented are some of the most promising advances that have been published in the past couple of years,” says Kallenbach.

First, molecules are “featurized,” or turned into representations that work with machine learning algorithms. Reverie Labs’s tech creates proprietary featurizations based on quantum chemical calculations, then uses them to analyze the molecules’ properties and how they may act in the body. Afterwards, it selects molecules that have the potential to do well in clinical trials or suggests new molecules based on what properties scientists need.

In addition to the machine learning algorithms it uses, Reverie Labs founders say one of the startup’s key differentiators is that it trains its models on customers’ proprietary in-house datasets, which means the tech can integrate more smoothly into existing drug development workflows. Reverie Labs’ software also runs on customers’ virtual private clouds, giving them more security.

While using artificial intelligence to develop new drugs seemed almost like science fiction just a few years ago, the space is developing quickly. Last month, BenevolentAI, one of the first companies to apply deep learning to drug discovery, bought biotech company Promixagen’s operations in the United Kingdom, which it says will make it the first artificial intelligence company to cover the entire drug research and development process. Atomwise, another AI-based drug discovery startup, announced at the beginning of this month that it has raised a $45 million Series A. Other notable startups include Nimbus Therapeutics and Recursion Pharmaceuticals.

The process of creating new drugs is currently very complicated, slow and extremely expensive. With so much room for improvement, the work done by various AI-based startups to improve the process don’t necessarily overlap.

“The space doesn’t seem like a zero sum game at all,” says Gupta. “Many players can be involved and the fact that other startups are interested shows that there is legitimacy to the technology.”

“The end result is trying to delivery life-saving cures faster and more cheaply,” adds Duffy. “We don’t really feel any competitiveness. We want everyone to succeed.”