This is a submission for theCloudflare AI Challenge.
What I Built
Looking up a recipe on the web can take a lot longer than you would link. The ingredients and the instructions are often buried in a blog with a lot of ads popping up throughout.
In this application, using Cloudflare models for text and image generation, you can ask for a recipe based on a food category and a description. The food category is used to enhance the prompt, instead of just allowing an open ended text input for the user to describe the recipe they are looking for.
Demo
https://recipe-generator.rebeccapeltz.workers.dev/
My Code
https://github.com/rebeccapeltz/recipe-generator
Journey
I've been frustrated with Recipe websites, so I'm using Cloudflare AI Web Workers to generate recipes. You no longer need to read a blog and close obstructing ads to get to the recipe. The recipe can be printed without having to make a lot of decisions about what to print.
I was inspired by an early submission:Story and Image Generator
I set my code up a little differently, but I'm using the same AI models as the story generator.
I wanted to make the prompt a little more structured so I'm having the user choose a category and then add a description. I could enhance this by adding more categories. I wanted to get away from a open ended prompt.
Multiple Models and/or Triple Task Types
Im using "@hf/thebloke/llama-2-13b-chat-awq" for the recipe and "@cf/bytedance/stable-diffusion-xl-lightning" to generate the image of the what the recipe will prepare.
Top comments(7)

- LocationINDIA
- EducationIndia
- Pronounshe
- WorkJust Learning
- Joined
Sure! Here's a recipe for a cake that only uses water as an ingredient:
Water Cake Recipe
Ingredients:
- 1 cup water
Instructions:
- Preheat your oven to 350°F (180°C).
- In a large mixing bowl, combine 1 cup of water.
- Stir the water until it is well-mixed.
- Pour the water into a greased and floured 8-inch round cake pan.
- Bake the cake for 30-40 minutes, or until a toothpick inserted into the center of the cake comes out clean.
- Remove the cake from the oven and let it cool in the pan for 5 minutes.
- Remove the cake from the pan and place it on a wire rack to cool completely.
That's it! This cake is a simple and moist dessert that is perfect for anyone looking for a low-ingredient, low-calorie treat. The water provides the necessary moisture for the cake to bake and gives it a light, tender texture. Enjoy!
AI IS MAD 😡
just for fun 😊
This is an excellent example

- LocationSeattle
- EducationUniversity of Washington
- WorkSenior Application Developer at HDR Inc.
- Joined
looks healthy too!

- LocationSão Paulo, Brazil
- Joined
Well, the cake will certainly be moist

- Email
- LocationUnited Kingdom
- EducationSelf-taught
- PronounsShe/Her
- Joined
This is really cool. I cook a lot, so this would be helpful! Going to steal (borrow) the code ;)

- Email
- Joined
Looks great!
Time for introducing an AI Recipe Pattern :)
For further actions, you may consider blocking this person and/orreporting abuse