Skip to content

Commit

Permalink
Merge pull request microsoft#634 from shahpreetk/fix-closing-brackets
Browse files Browse the repository at this point in the history
fix: added missing closing brackets in Chp 6 README.md
  • Loading branch information
koreyspace authored Nov 19, 2024
2 parents 7256782 + 7190c54 commit b762d3c
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions 06-text-generation-apps/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -399,9 +399,9 @@ Now that we have played out a scenario, let's write code to match the demonstrat
1. Let's change the code in the following way:

```python
no_recipes = input("No of recipes (for example, 5: ")
no_recipes = input("No of recipes (for example, 5): ")

ingredients = input("List of ingredients (for example, chicken, potatoes, and carrots: ")
ingredients = input("List of ingredients (for example, chicken, potatoes, and carrots): ")

# interpolate the number of recipes into the prompt an ingredients
prompt = f"Show me {no_recipes} recipes for a dish with the following ingredients: {ingredients}. Per recipe, list all the ingredients used"
Expand All @@ -410,8 +410,8 @@ Now that we have played out a scenario, let's write code to match the demonstrat
Taking the code for a test run, could look like this:

```output
No of recipes (for example, 5: 3
List of ingredients (for example, chicken, potatoes, and carrots: milk,strawberries
No of recipes (for example, 5): 3
List of ingredients (for example, chicken, potatoes, and carrots): milk,strawberries
-Strawberry milk shake: milk, strawberries, sugar, vanilla extract, ice cubes
-Strawberry shortcake: milk, flour, baking powder, sugar, salt, unsalted butter, strawberries, whipped cream
Expand All @@ -427,7 +427,7 @@ To further improve it, we want to add the following:
- **Filter out ingredients**. We want to be able to filter out ingredients we don't like or are allergic to. To accomplish this change, we can edit our existing prompt and add a filter condition to the end of it like so:

```python
filter = input("Filter (for example, vegetarian, vegan, or gluten-free: ")
filter = input("Filter (for example, vegetarian, vegan, or gluten-free): ")

prompt = f"Show me {no_recipes} recipes for a dish with the following ingredients: {ingredients}. Per recipe, list all the ingredients used, no {filter}"
```
Expand All @@ -437,9 +437,9 @@ To further improve it, we want to add the following:
An example input of running the program can now look like so:

```output
No of recipes (for example, 5: 3
List of ingredients (for example, chicken, potatoes, and carrots: onion,milk
Filter (for example, vegetarian, vegan, or gluten-free: no milk
No of recipes (for example, 5): 3
List of ingredients (for example, chicken, potatoes, and carrots): onion,milk
Filter (for example, vegetarian, vegan, or gluten-free): no milk
1. French Onion Soup
Expand Down Expand Up @@ -539,9 +539,9 @@ To further improve it, we want to add the following:
Taking this code for a spin, we now arrive at the following output:

```output
No of recipes (for example, 5: 2
List of ingredients (for example, chicken, potatoes, and carrots: apple,flour
Filter (for example, vegetarian, vegan, or gluten-free: sugar
No of recipes (for example, 5): 2
List of ingredients (for example, chicken, potatoes, and carrots): apple,flour
Filter (for example, vegetarian, vegan, or gluten-free): sugar


-Apple and flour pancakes: 1 cup flour, 1/2 tsp baking powder, 1/2 tsp baking soda, 1/4 tsp salt, 1 tbsp sugar, 1 egg, 1 cup buttermilk or sour milk, 1/4 cup melted butter, 1 Granny Smith apple, peeled and grated
Expand Down

0 comments on commit b762d3c

Please sign in to comment.