Disclaimer: We are using an analogy between baking bread and creating an artificial intelligence (AI) program merely for ‘edutainment’ purposes. The recipe below assumes prior knowledge of some AI terms. For a glossary, see: Artificial Intelligence (AI) Terms Defined for Healthcare Providers.
Making a healthcare-focused artificial intelligence (AI) program is not all that different from baking bread. Both tasks require combining the right ingredients with meticulous attention to detail, a dash of creativity, and a good dose of time for the right chemistry to happen. The recipe below is endlessly adaptable to anyone’s needs.
Ingredient list:
Data: Analogous to flour in bread. Data is the building block of the program and probably the most important ingredient. Large quantities of high-quality data does not guarantee an artisan program, but it is a necessary first step.
Neural networks: Analogous to yeast in bread-making. Bread rises because the yeast creates a huge network of tiny little gas bubbles that spread the gluten from the wheat apart. Neural networks (a type of machine learning) similarly create an organized network of associations between different types of data in the large data sets (for example, inputs and outputs) by looking for connections between individual datum. The neural networks form a huge interconnected “loaf” which serves as a scaffold for when the program wants to either make predictions or generate entirely new creative content.
After rising, “bread” still needs to “bake” just as neural networks “rise” to the challenge of creating connections between various data points and form the basic outlines of the program. Like yeast in baking, neural networks make connections between data points, get some feedback, and respond to the feedback by trying to create even better connections. (Just like bread recipes sometimes call for double rising, or “proofing.”) There are various types of neural networks just as there are different kinds of rising agents (yeast, baking soda, baking powder), and the choice of neural networks determines the qualities of the final AI program.
Human Feedback: Analogous to salt in bread. Salt is a subtle necessity for good bread and human feedback is vital for any program which seeks to mimic human intelligence. When it comes to healthcare, humans remain undisputed experts. An AI program without human feedback might produce outputs that simply don’t make sense (known as hallucinations). Salt is usually only added to bread once, but for our AI recipe, we recommend a minimum of two separate rounds of feedback. This is like a baker adding a pinch of salt to a batch of dough, checking it with a taste test, and adding a pinch more. A master programmer, like a master chef, uses the first taste of the program to guide the output in the right direction. After the dough has a chance to rise (i.e. the neural networks have a chance to look for associations between different kinds of data), the program is sampled by expert “beta-testers” who test the performance of the AI with data in real-life settings and send the AI program back for a second (or perhaps third or fourth) round of feedback. This is where the analogy breaks down a little, too much salt can be added bread. But when it comes to AI programs for healthcare specifically, it’s difficult to put an upper limit on the amount of feedback (unlike programs used for writing fiction or creating humorous art).
High-powered computing: Analogous to the heat required for bread to rise, bake, and eventually become toast. Computing power (in the form of both code and the energy to run it) is necessary for all steps in the creation, testing, and running of the AI program. AI programs, unlike the simple algorithm computer programs written in schools, are usually designed for continuous learning, to grow from experience with users, and to look for connections between data inputs and outputs. Creating them, testing them, and running them all takes considerable energy.
Time: Analogous to rising/proofing and resting time. AI programs require both hands-on time and time for “proofing.” There is no shortcut to this. Bakers can outsource their breadmaking to kits, automation, or they can purchase frozen loafs that only require popping them into the oven. Making a program from scratch allows more control but also means more chances to make mistakes. An AI program may fail during its creation and a couple “loaves” may need to be thrown out until it is right!
Directions:
-
Pick the recipe: Baguettes and brioche are both delicious but not interchangeable! To decide on the best AI program, ask what problems the program should solve. Just like white flour can’t magically create whole wheat bread, a data set that doesn’t include people over the age of 65 probably won’t help health care decision making for that population.
-
Mis-en-place: The French phrase of putting everything in place before cooking translates well to the AI world. Plan for the right data sets, beta-testers, and machine learning algorithms to solve the chosen set of problems. Balancing accuracy, speed, transparency, and power should all be considered before starting the initial mixing of the data and machine learning.
-
Mix the data with the machine learning model: At this stage, both questions and answers from the data set are provided directly to the algorithm, which finds any associations between these two groups of data.
-
Let the neural networks interact with the data: The initial machine learning is analogous to a first rise in bread making (where yeast comes into play). Once the data and algorithms are combined, the neural networks find their own connections between data points in the data set.
-
Test the model with a new data set: By giving the program brand new inputs, programmers can check the product to ensure it’s “rising” to the occasion as expected. As in the first data set, the programmers know the input and expected output. For this test, however, the expected output is unknown to the program, which allows the programmers to judge the accuracy of the program against an answer key. This is analogous to visually examining the bread after the first rise: it’s not ready for use, but progress should be observed. It isn’t a real test, but if something doesn’t look right, this might be the time for an adjustment!
-
Perform Beta testing: Beta testing is analogous to a second rise or “proofing.” AI creators find experts (Beta testers) and expose the model to real life problems to solve. Beta testing uncovers hallucinations or unexpected outcomes under safe conditions, because a non-expert may encounter wrong answers without this critical step. Just as proofing bread helps it create more pockets of air and rise higher; beta testing is necessary for improving the trustworthiness of the AI program
-
“Bake” the AI program by deploying it to the target users: Prepping the AI program for real life problem solving is analogous to baking bread. It is the easiest step, but one of the most important! Just like pre-heating the oven, education of the AI users ahead of time is a critical step. There is no bread without waiting a little bit, and there never will be a 100% accurate/perfect AI program. The users should understand that AI programs will do many things better than a human but will always require human supervision to interpret some of the answers.
-
If these first steps are successful, an AI program is likely to work well and there will be lots of enthusiasm at this stage. But it’s not quite finished...
-
A completed program, like a completed loaf of bread, needs proper storage: The AI program should stand alone, but just as bread quickly becomes stale, health information is always changing and requires constant updating and maintenance. Not only does information in the world outside the program change, but the program itself adapts and changes as well. AI programs can be used in ways that the baker can’t even imagine. Once it’s sliced and in the hands of the end-users (and not just the beta testers), the program will continue to benefit from feedback and enhancements. Protocols for regular monitoring and maintenance are just as important as proper storage of bread!
- Toasting the bread: Let’s stretch the analogy between baking bread and AI a little bit more and say that whenever someone wants to eat the bread, it must be toasted. (We know that untoasted bread tastes great too!) Just like toasting bread requires heat, a generative AI program requires power every time it is used. Because AI programs are learning and growing things, the owners of the program are generally responsible for maintenance. In other words, whoever owns the program pays for the electricity to use it (i.e. “toast the bread”).
There’s the basic recipe. Put together high-quality ingredients (data sets, neural networks, and human users for testing), let the bread rise a couple of times (while the machine learning programs teach themselves to predict or create outputs) and a wide variety of generative AI programs can be baked. Bon Appetit!