Generating Personalized Recipes from Historical User Preferences
Bodhisattwa Prasad Majumder∗, Shuyang Li∗, Jianmo Ni, Julian McAuley
Computer Science and Engineering
University of California, San Diego{bmajumde, shl008, jin018, jmcauley}@ucsd.edu

Abstract
Existing approaches to recipe generation areunable to create recipes for users with culinary
preferences but incomplete knowledge of ingredients in specific dishes. We propose a newtask of personalized recipe generation to help
these users: expanding a name and incomplete ingredient details into complete naturaltext instructions aligned with the user’s historical preferences. We attend on technique- andrecipe-level representations of a user’s previously consumed recipes, fusing these ‘useraware’ representations in an attention fusion
layer to control recipe text generation. Experiments on a new dataset of 180K recipes and700K interactions show our model’s ability
to generate plausible and personalized recipes
compared to non-personalized baselines.

1

Introduction

In the kitchen, we increasingly rely on instructions
from cooking websites: recipes. A cook with apredilection for Asian cuisine may wish to prepare chicken curry, but may not know all necessary ingredients apart from a few basics. Theseusers with limited knowledge cannot rely on existing recipe generation approaches that focus on
creating coherent recipes given all ingredients anda recipe name (Kiddon et al., 2016). Such models do not address issues of personal preference(e.g. culinary tastes, garnish choices) and incomplete recipe details. We propose to approach bothproblems via personalized generation of plausible, user-specific recipes using user preferences
extracted from previously consumed recipes.
Our work combines two important tasks fromnatural language processing and recommendersystems: data-to-text generation (Gatt and Krahmer, 2018) and personalized recommendation∗

denotes equal contribution(Rashid et al., 2002). Our model takes as user input the name of a specific dish, a few key ingredients, and a calorie level. We pass these loose
input specifications to an encoder-decoder framework and attend on user profiles—learned latent
representations of recipes previously consumed bya user—to generate a recipe personalized to theuser’s tastes. We fuse these ‘user-aware’ representations with decoder output in an attention fusion
layer to jointly determine text generation. Quantitative (perplexity, user-ranking) and qualitative
analysis on user-aware model outputs confirm that
personalization indeed assists in generating plausible recipes from incomplete ingredients.
While personalized text generation has seen
success in conveying user writing styles in the
product review (Ni et al., 2017; Ni and McAuley,2018) and dialogue (Zhang et al., 2018) spaces, weare the first to consider it for the problem of recipe
generation, where output quality is heavily dependent on the content of the instructions—such as
ingredients and cooking techniques.
To summarize, our main contributions are as
follows:
1. We explore a new task of generating plausible and personalized recipes from incomplete
input specifications by leveraging historicaluser preferences;1
2. We release a new dataset of 180K+ recipes
and 700K+ user reviews for this task;
3. We introduce new evaluation strategies forgeneration quality in instructional texts, centering on quantitative measures of coherence. We also show qualitatively and quantitatively that personalized models generate
high-quality and specific recipes that alignwith historical user preferences.
1

Oursourcecode
andappendix
https://github.com/majumderb/
recipe-personalization

are

at

2

Related Work

Large-scale transformer-based language models
have shown surprising expressivity and fluency
in creative and conditional long-text generation(Vaswani et al., 2017; Radford et al., 2019). Recent works have proposed hierarchical methods
that condition on narrative frameworks to generateinternally consistent long texts (Fan et al., 2018;
Xu et al., 2018; Yao et al., 2018). Here, we generate procedurally structured recipes instead of freeform narratives.
Recipe generation belongs to the field of datato-text natural language generation (Gatt andKrahmer, 2018), which sees other applicationsin automated journalism (Leppänen et al., 2017),
question-answering (Agrawal et al., 2017), andabstractive summarization (Paulus et al., 2018),
among others. Kiddon et al. (2015); Bosselut et al.
(2018b) model recipes as a structured collection ofingredient entities acted upon by cooking actions.
Kiddon et al. (2016) imposes a ‘checklist’ attention constraint emphasizing hitherto unused ingredients during generation. Yang et al. (2017) attend over explicit ingredient references in the priorrecipe step. Similar hierarchical approaches thatinfer a full ingredient list to constrain generation
will not help personalize recipes, and would be infeasible in our setting due to the potentially unconstrained number of ingredients (from a spaceof 10K+) in a recipe. We instead learn historicalpreferences to guide full recipe generation.
A recent line of work has explored user- anditem-dependent aspect-aware review generation(Ni et al., 2017; Ni and McAuley, 2018). This
work is related to ours in that it combines contextual language generation with personalization.
Here, we attend over historical user preferencesfrom previously consumed recipes to generate
recipe content, rather than writing styles.

3

Approach

Our model’s input specification consists of: therecipe name as a sequence of tokens, a partial listof ingredients, and a caloric level (high, medium,low). It outputs the recipe instructions as a token
sequence: Wr = {wr,0 , . . . , wr,T } for a recipe rof length T . To personalize output, we use historical recipe interactions of a user u ∈ U.
Encoder: Our encoder has three embedding layers: vocabulary embedding V, ingredient embedding I, and caloric-level embedding C. Each token

in the (length Ln ) recipe name is embedded via V;
the embedded token sequence is passed to a twolayered bidirectional GRU (BiGRU) (Cho et al.,2014), which outputs hidden states for names{nenc,j ∈ R2dh }, with hidden size dh . Similarly
each of the Li input ingredients is embedded via I,
and the embedded ingredient sequence is passed
to another two-layered BiGRU to output ingredient hidden states as {ienc,j ∈ R2dh }. The caloric
level is embedded via C and passed through a projection layer with weights Wc to generate calorie
hidden representation cenc ∈ R2dh .
Ingredient Attention: We apply attention (Bahdanau et al., 2015) over the encoded ingredientsto use encoder outputs at each decoding time step.
We define an attention-score function α with key
K and query Q:
α(K, Q) =exp (tanh (Wα [K + Q] + bα )),Zwith trainable weights Wα , bias bα , and normalization term Z. At decoding time t, we calculate
the ingredient context ait ∈ Rdh as:
ait =

Li
X

α (ienc,j , ht ) × ienc,j .

j=1

Decoder: The decoder is a two-layer GRU withhidden state ht conditioned on previous hidden
state ht−1 and input token wr,t from the original
recipe text. We project the concatenated encoder
outputs as the initial decoder hidden state:Ääh0 ∈ Rdh = Wh0 [nenc,Ln ; ienc,Li ; cenc ] + bh0
ht , ot = GRU

Äî

ó

ä

wr,t ; ait , ht−1 .

To bias generation toward user preferences, we
attend over a user’s previously reviewed recipes tojointly determine the final output token distribution. We consider two different schemes to model
preferences from user histories: (1) recipe interactions, and (2) techniques seen therein (definedin Section 4). Rendle et al. (2009); Quadrana et al.
(2018); Ueda et al. (2011) explore similar schemes
for personalized recommendation.
Prior Recipe Attention: We obtain the set ofprior recipes for a user u: Ru+ , where each recipe
can be represented by an embedding from a recipe
embedding layer R or an average of the name tokens embedded by V. We attend over the k-mostrecent prior recipes, Ruk+ , to account for temporal drift of user preferences (Moore et al., 2013).

Split# Users# Recipes# Actions

Sparsity3

Train
Dev
Test

25,076
7,023
12,455160,901
6,621
11,695698,901
7,023
12,45599.983%––

Table 1: Statistics of Food.com interactions

4

Figure 1: Sample data flow through model architecture. Emphasis on prior recipe attention scores (darker
is stronger). Ingredient attention omitted for clarity.

These embeddings are used in the ‘Prior Recipe’and ‘Prior Name’ models, respectively.
Given a recipe representation r ∈ Rdr (where
dr is recipe- or vocabulary-embedding size depending on the recipe representation) the priorrecipe attention context art u is calculated as
art u =Xα (r, ht ) × r.

k+
r∈Ru

Prior Technique Attention: We calculate priortechnique preference (used in the ‘Prior Tech‘
model) by normalizing co-occurrence between
users and techniques seen in Ru+ , to obtain a preference vector ρu . Each technique x is embedded
via a technique embedding layer X to x ∈ Rdx .
Prior technique attention is calculated asaxt u =X(α (x, ht ) + ρu,x ) × x,+x seen in Ru

where, inspired by copy mechanisms (See et al.,2017; Gu et al., 2016), we add ρu,x for technique x
to emphasize the attention by the user’s prior technique preference.
Attention Fusion Layer: We fuse all contexts
calculated at time t, concatenating them with decoder GRU output and previous token embedding:aft = ReLU Wf wr,t ; ot ; ait ; (art u or axt u ) +bf .
Ä

î

ó

ä

We collect a novel dataset of 230K+ recipe texts
and 1M+ user interactions (reviews) over 18 years(2000-2018) from Food.com.2 Here, we restrict torecipes with at least 3 steps, and at least 4 and no
more than 20 ingredients. We discard users withfewer than 4 reviews, giving 180K+ recipes and700K+ reviews, with splits as in Table 1.
Our model must learn to generate from a diverse recipe space: in our training data, the average recipe length is 117 tokens with a maximum of 256. There are 13K unique ingredients
across all recipes. Rare words dominate the vocabulary: 95% of words appear <100 times, accounting for only 1.65% of all word usage. As such,
we perform Byte-Pair Encoding (BPE) tokenization (Sennrich et al., 2016; Radford et al., 2018),
giving a training vocabulary of 15K tokens across
19M total mentions. User profiles are similarly diverse: 50% of users have consumed ≤6 recipes,
while 10% of users have consumed >45 recipes.
We order reviews by timestamp, keeping themost recent review for each user as the test set, thesecond most recent for validation, and the remainder for training (sequential leave-one-out evaluation (Kang and McAuley, 2018)). We evaluate
only on recipes not in the training set.
We manually construct a list of 58 cooking
techniques from 384 cooking actions collected byBosselut et al. (2018b); the most common techniques (bake, combine, pour, boil) account for
36.5% of technique mentions. We approximate
technique adherence via string match between therecipe text and technique list.

5

We then calculate the token probability:
P (Sr,t ) = softmax WP [aft ] + bP ,
Ä

Recipe Dataset: Food.com

äand maximize the log-likelihood of the generated
sequence conditioned on input specifications anduser preferences. Figure 1 shows a case where thePrior Name model attends strongly on previously
consumed savory recipes to suggest the usage ofan additional ingredient (‘cilantro’).

Experiments and Results

For training and evaluation, we provide our modelwith the first 3-5 ingredients listed in each recipe.
We decode recipe text via top-k sampling (Radford et al., 2019), finding k = 3 to produce satisfactory results. We use a hidden size dh = 2562

https://www.kaggle.com/shuyangli94/
food-com-recipes-and-user-interactions
3
Ratio of unobserved actions to all possible actions.

ModelBPE PPL

BLEU-1

BLEU-4

ROUGE-L

D-1 (%)

D-2 (%)UMA

MRR

PP (%)

NN
Enc-Dec–
9.611

20.27928.391

0.465
3.385

16.87125.001

0.931
0.220

9.394
1.928

0.100
0.100

0.293
0.293

–
–

Prior Tech
Prior Recipe
Prior Name

9.572
9.551
9.516

28.86427.85828.046

3.312
3.215
3.211

24.92024.82224.794

0.233
0.231
0.233

2.158
2.062
2.080

0.128
0.302
0.505

0.319
0.412
0.628

62.82166.02661.165

Table 2: Metrics on generated recipes from test set. D-1/2 = Distinct-1/2, UMA = User Matching Accuracy, MRR= Mean Reciprocal Rank, PP = Pairwise preference over baseline (evaluated for 310 recipe pairs per model).
Input

Name: Pomberrytini; Ingredients: pomegranate-blueberry juice, cranberry juice, vodka ; Calorie: Low

Gold

Place everything except the orange slices in a cocktail shaker. Shake until well mixed and well chilled.
Pour into martini glasses and float an orange slice in each glass.

Enc-Dec

Combine all ingredients. Cover and refrigerate. Serve with whipped topping.

Prior Tech

Combine all ingredients. Store in refrigerator. Serve over ice. Enjoy!

Prior Recipe

Pour the ice into a cocktail shaker. Pour in the vodka and vodka. Add a little water and shake to mix.
Pour into the glass and garnish with a slice of orange slices. Enjoy!

Prior Name

Combine all ingredients except for the ice in a blender or food processor. Process to make a smoothpaste and then add the remaining vodka and blend until smooth. Pour into a chilled glass andgarnish with a little lemon and fresh mint.

Table 3: Sample generated recipe. Emphasis on personalization and explicit ingredient mentions via highlights.

for both the encoder and decoder. Embedding dimensions for vocabulary, ingredient, recipe, techniques, and caloric level are 300, 10, 50, 50, and
5 (respectively). For prior recipe attention, we
set k = 20, the 80th %-ile for the number ofuser interactions. We use the Adam optimizer(Kingma and Ba, 2015) with a learning rate of
10−3 , annealed with a decay rate of 0.9 (Howard
and Ruder, 2018). We also use teacher-forcing(Williams and Zipser, 1989) in all training epochs.
In this work, we investigate how leveraging
historical user preferences can improve generation quality over strong baselines in our setting.
We compare our personalized models against twobaselines. The first is a name-based NearestNeighbor model (NN). We initially adapted theNeural Checklist Model of Kiddon et al. (2016)as a baseline; however, we ultimately use a simple Encoder-Decoder baseline with ingredient attention (Enc-Dec), which provides comparable
performance and lower complexity. All personalized models outperform baseline in BPE perplexity (Table 2) with Prior Name performing thebest. While our models exhibit comparable performance to baseline in BLEU-1/4 and ROUGE-L,
we generate more diverse (Distinct-1/2: percentage of distinct unigrams and bigrams) and acceptable recipes. BLEU and ROUGE are not the mostappropriate metrics for generation quality. A ‘correct’ recipe can be written in many ways with thesame main entities (ingredients). As BLEU-1/4
capture structural information via n-gram matching, they are not correlated with subjective recipe
quality. This mirrors observations from Baheti
et al. (2018); Fan et al. (2018).
We observe that personalized models makemore diverse recipes than baseline. They thus
perform better in BLEU-1 with more key entities (ingredient mentions) present, but worse in
BLEU-4, as these recipes are written in a personalized way and deviate from gold on the phrasal
level. Similarly, the ‘Prior Name’ model generates
more unigram-diverse recipes than other personalized models and obtains a correspondingly lower
BLEU-1 score.
Qualitative Analysis: We present sample outputs for a cocktail recipe in Table 3, and additional recipes in the appendix. Generation quality progressively improves from generic baseline
output to a blended cocktail produced by ourbest performing model. Models attending overprior recipes explicitly reference ingredients. The
Prior Name model further suggests the additionof lemon and mint, which are reasonably associated with previously consumed recipes like coconut mousse and pork skewers.

Personalization: To measure personalization, we
evaluate how closely the generated text corresponds to a particular user profile. We computethe likelihood of generated recipes using identical
input specifications but conditioned on ten different user profiles—one ‘gold’ user who consumed
the original recipe, and nine randomly generated
user profiles. Following Fan et al. (2018), we expect the highest likelihood for the recipe conditioned on the gold user. We measure user matching accuracy (UMA)—the proportion where thegold user is ranked highest—and Mean Reciprocal
Rank (MRR) (Radev et al., 2002) of the gold user.
All personalized models beat baselines in both
metrics, showing our models personalize generated recipes to the given user profiles. The Prior
Name model achieves the best UMA and MRR by
a large margin, revealing that prior recipe names
are strong signals for personalization. Moreover,
the addition of attention mechanisms to capture
these signals improves language modeling performance over a strong non-personalized baseline.
Recipe Level Coherence: A plausible recipe
should possess a coherent step order, and we evaluate this via a metric for recipe-level coherence.
We use the neural scoring model from Bosselut
et al. (2018a) to measure recipe-level coherence
for each generated recipe. Each recipe step is encoded by BERT (Devlin et al., 2019). Our scoring model is a GRU network that learns the overall recipe step ordering structure by minimizing
the cosine similarity of recipe step hidden representations presented in the correct and reverse orders. Once pretrained, our scorer calculates thesimilarity of a generated recipe to the forward andbackwards ordering of its corresponding gold label, giving a score equal to the difference between
the former and latter. A higher score indicates
better step ordering (with a maximum score of2). Table 4 shows that our personalized models
achieve average recipe-level coherence scores of
1.78-1.82, surpassing the baseline at 1.77.
Recipe Step Entailment: Local coherence is also
crucial to a user following a recipe: it is crucial
that subsequent steps are logically consistent withprior ones. We model local coherence as an entailment task: predicting the likelihood that a recipe
step follows the preceding. We sample several
consecutive (positive) and non-consecutive (negative) pairs of steps from each recipe. We train a
BERT (Devlin et al., 2019) model to predict the

Model

Recipe Level
Coherence

Recipe Step
Entailment

Enc-Dec

1.77

0.72

Prior Tech
Prior Recipe
Prior Name

1.78
1.80
1.82

0.73
0.76
0.78

Table 4: Coherence metrics on generated recipes fromtest set.

entailment score of a pair of steps separated by a
[SEP] token, using the final representation of the[CLS] token. The step entailment score is computed as the average of scores for each set of consecutive steps in each recipe, averaged over every
generated recipe for a model, as shown in Table 4.
Human Evaluation: We presented 310 pairs ofrecipes for pairwise comparison (Fan et al., 2018)(details in appendix) between baseline and each
personalized model, with results shown in Table 2.
On average, human evaluators preferred personalized model outputs to baseline 63% of the time,
confirming that personalized attention improves
the semantic plausibility of generated recipes. We
also performed a small-scale human coherence
survey over 90 recipes, in which 60% of users
found recipes generated by personalized models
to be more coherent and preferable to those generated by baseline models.

6

Conclusion

In this paper, we propose a novel task: to generate personalized recipes from incomplete input specifications and user histories. On a large
novel dataset of 180K recipes and 700K reviews,
we show that our personalized generative models
can generate plausible, personalized, and coherent recipes preferred by human evaluators for consumption. We also introduce a set of automatic coherence measures for instructional texts as well as
personalization metrics to support our claims. Our
future work includes generating structured representations of recipes to handle ingredient properties, as well as accounting for references to collections of ingredients (e.g. “dry mix”).
Acknowledgements. This work is partly supported by NSF #1750063. We thank all reviewers
for their constructive suggestions, as well as Rei
M., Sujoy P., Alicia L., Eric H., Tim S., Kathy C.,
Allen C., and Micah I. for their feedback.

References
Aishwarya Agrawal, Jiasen Lu, Stanislaw Antol, Margaret Mitchell, C. Lawrence Zitnick, Devi Parikh,and Dhruv Batra. 2017. VQA: visual question answering. IJCV, 123(1):4–31.
Dzmitry Bahdanau, Kyunghyun Cho, and Yoshua Bengio. 2015. Neural machine translation by jointly
learning to align and translate. In ICLR.
Ashutosh Baheti, Alan Ritter, Jiwei Li, and Bill Dolan.
2018. Generating more interesting responses inneural conversation models with distributional constraints. In EMNLP.
Antoine Bosselut, Asli Çelikyilmaz, Xiaodong He,
Jianfeng Gao, Po-Sen Huang, and Yejin Choi.
2018a. Discourse-aware neural rewards for coherent text generation. In NAACL-HLT.
Antoine Bosselut, Omer Levy, Ari Holtzman, Corin
Ennis, Dieter Fox, and Yejin Choi. 2018b. Simulating action dynamics with neural process networks.
In ICLR.
Kyunghyun Cho, Bart van Merrienboer, ÇaglarGülçehre, Dzmitry Bahdanau, Fethi Bougares, Holger Schwenk, and Yoshua Bengio. 2014. Learningphrase representations using RNN encoder-decoder
for statistical machine translation. In EMNLP.
Jacob Devlin, Ming-Wei Chang, Kenton Lee, andKristina Toutanova. 2019. BERT: pre-training ofdeep bidirectional transformers for language understanding. In NAACL-HLT 2019.
Angela Fan, Mike Lewis, and Yann Dauphin. 2018. Hierarchical neural story generation. In ACL.
Albert Gatt and Emiel Krahmer. 2018. Survey of thestate of the art in natural language generation: Coretasks, applications and evaluation. J. Artif. Intell.
Res., 61:65–170.
Jiatao Gu, Zhengdong Lu, Hang Li, and Victor O. K.
Li. 2016. Incorporating copying mechanism insequence-to-sequence learning. In ACL.
Jeremy Howard and Sebastian Ruder. 2018. Universal
language model fine-tuning for text classification. In
ACL.
Wang-Cheng Kang and Julian McAuley. 2018. Selfattentive sequential recommendation. In ICDM.
Chloé Kiddon, Ganesa Thandavam Ponnuraj, Luke
Zettlemoyer, and Yejin Choi. 2015. Mise en place:
Unsupervised interpretation of instructional recipes.
In EMNLP.
Chloé Kiddon, Luke Zettlemoyer, and Yejin Choi.
2016. Globally coherent text generation with neural checklist models. In EMNLP.
Diederik P. Kingma and Jimmy Ba. 2015. Adam: A
method for stochastic optimization. In ICLR.

Leo Leppänen, Myriam Munezero, Mark GranrothWilding, and Hannu Toivonen. 2017. Data-driven
news generation for automated journalism. In INLG.
Joshua L. Moore, Shuo Chen, Douglas Turnbull, andThorsten Joachims. 2013. Taste over time: The temporal dynamics of user preferences. In ISMIR.
Jianmo Ni, Zachary C. Lipton, Sharad Vikram, and Julian McAuley. 2017. Estimating reactions and recommending products with generative models of reviews. In IJCNLP.
Jianmo Ni and Julian McAuley. 2018. Personalized review generation by expanding phrases and attending
on aspect-aware representations. In ACL.
Romain Paulus, Caiming Xiong, and Richard Socher.
2018. A deep reinforced model for abstractive summarization. In ICLR.
Massimo Quadrana, Paolo Cremonesi, and Dietmar
Jannach. 2018. Sequence-aware recommender systems. In UMAP.
Dragomir R. Radev, Hong Qi, Harris Wu, and Weiguo
Fan. 2002. Evaluating web-based question answering systems. In LREC.
Alec Radford, Karthik Narasimhan, Tim Salimans, andIlya Sutskever. 2018. Improving language understanding by generative pre-training.
Alec Radford, Jeff Wu, Rewon Child, David Luan,
Dario Amodei, and Ilya Sutskever. 2019. Language
models are unsupervised multitask learners.
Al Mamunur Rashid, Istvan Albert, Dan Cosley, Shyong K. Lam, Sean M. McNee, Joseph A. Konstan,and John Riedl. 2002. Getting to know you: learning new user preferences in recommender systems.
In IUI.
Steffen Rendle, Christoph Freudenthaler, Zeno Gantner, and Lars Schmidt-Thieme. 2009.
BPR:
bayesian personalized ranking from implicit feedback. In UAI.
Abigail See, Peter J. Liu, and Christopher D. Manning.
2017. Get to the point: Summarization with pointergenerator networks. In ACL.
Rico Sennrich, Barry Haddow, and Alexandra Birch.
2016. Neural machine translation of rare words withsubword units. In ACL.
Mayumi Ueda, Mari Takahata, and Shinsuke Nakajima. 2011. User’s food preference extraction for
personalized cooking recipe recommendation. In
SPIM.
Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob
Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz
Kaiser, and Illia Polosukhin. 2017. Attention is all
you need. In NIPS.

Ronald J. Williams and David Zipser. 1989. A learning algorithm for continually running fully recurrent
neural networks. Neural Computation, 1(2):270–
280.
Jingjing Xu, Xuancheng Ren, Yi Zhang, Qi Zeng, Xiaoyan Cai, and Xu Sun. 2018. A skeleton-basedmodel for promoting coherence among sentences innarrative story generation. In EMNLP.
Zichao Yang, Phil Blunsom, Chris Dyer, and Wang
Ling. 2017. Reference-aware language models. In
EMNLP.
Lili Yao, Nanyun Peng, Ralph M. Weischedel, Kevin
Knight, Dongyan Zhao, and Rui Yan. 2018. Planand-write: Towards better automatic storytelling.
CoRR, abs/1811.05701.
Saizheng Zhang, Emily Dinan, Jack Urbanek, Arthur
Szlam, Douwe Kiela, and Jason Weston. 2018. Personalizing dialogue agents: I have a dog, do you
have pets too? In ACL.

Appendix
Food.com: Dataset Details
Our raw data consists of 270K recipes and 1.4M
user-recipe interactions (reviews) scraped from
Food.com, covering a period of 18 years (January
2000 to December 2018). See Table 5 for dataset
summary statistics, and Table 6 for sample information about one user-recipe interaction and therecipe involved.

Raw
Processed# Recipes# Users# Reviews

Sparsity (%)

231,637
178,265

226,570
25,076

1,132,367
749,053

99.99899.983

Table 5: Interaction statistics for Food.com dataset before and after data processing.

Generated Examples
See Table 7 for a sample recipe for chicken chili
and Table 8 for a sample recipe for sweet waffles.

Human Evaluation
We prepared a set of 15 pairwise comparisons
per evaluation session, and collected 930 pairwise
evaluations (310 per personalized model) over 62
sessions. For each pair, users were given a partial recipe specification (name and 3-5 key ingredients), as well as two generated recipes labeled ‘A’and ‘B’. One recipe is generated from our baseline encoder-decoder model and one recipe is generated by one of our three personalized models(Prior Tech, Prior Name, Prior Recipe). The orderof recipe presentation (A/B) is randomly selected
for each question. A screenshot of the user evaluation interface is given in Figure 2. We ask the user
to indicate which recipe they find more coherent,
and which recipe best accomplishes the goal indicated by the recipe name. A screenshot of thissurvey interface is given in Figure 3.

FieldValue

dateuser idrecipe id
namen stepssteps
n ingredients
ingredients
calorie level2002-03-30
27395
23933
chinese candy
4[‘melt butterscotch chips in heavy saucepan over low heat’,‘fold in peanuts and chinese noodles until coated’,’drop by tablespoon onto waxed paper’,‘let stand in cool place until firm’]
3[‘butterscotch chips’, ‘chinese noodles’, ‘salted peanuts’]
0 (Low)

Table 6: Sample data from GeniusKitchen with recipe and user interaction details.

Figure 2: A sample question for pairwise evaluation survey.

InputName: Chicken Bell Pepper Chili Weight Watchers
Ingredients: olive oil, red bell pepper, green bell pepper, yellow bell pepper
Calorie: MediumGold

In a large nonstick dutch oven or saucepan, heat the oil.
Saute the bell peppers and onion until softened, about 5 minutes.
Add the chicken.
Cook, breaking apart with a wooden spoon, until no longer pink, 5 - 7 minutes.
Sprinkle with the flour, chili powder, cumin, cocoa powder, and cayenne.
Cook, stirring briskly and constantly, 1 minute. Stir in the tomatoes and vinegar.
Bring to a boil.
Reduce the heat and simmer, stirring frequently, until thick, 30 - 40 minutes.
Stir in the chickpeas.
Simmer until heated through, about 5 minutes.

Enc-Dec

Heat oil in a large, heavy pot over medium heat.
Add chicken and cook until browned on both sides, about 10 minutes, or until browned; drain.
Add onion and garlic and saute for 2 minutes.
Add chicken broth, chicken broth, and corn starch.
Bring to a slow boil, reduce heat, cover and simmer for 30 minutes.
Remove from heat and add the tomatoes and corn.
Simmer until chicken is cooked through, about 10 minutes.
Serve over rice or noodles.

Prior TechHeat oil in large saucepan over medium - high heat.
Add chicken and cook until browned.
Add bell pepper and onions, cook 2 minutes, stirring frequently.
Add chicken broth.
Cover, simmer, stirring occasionally, for 10 minutes or until vegetables are tender, stirring occasionally.
Add chicken, cover, and cook 10 more minutes or until chicken is cooked through.
Remove from heat.
Stir in remaining ingredients.
Season with salt and pepper to taste.
Serve over rice and top with additional shredded cheese and cilantro.

Prior Recipe

Heat oil in large dutch oven over medium - high.
Add chicken, bell peppers, bell peppers and onion.
Saute 2 - 3 minutes.
Add broth and tomato paste; stir.
Bring to a boil.
Reduce heat and simmer, covered,for 10 minutes or until rice is tender, stirring often.
Stir in chicken.
Cover and simmer for 10 minutes.
Stir in parsley.
Serve over rice.
Garnish with cilantro.

Prior Name

Heat the oil in a large skillet over medium - high heat.
Add the peppers and onions.
Cook, stirring, until the vegetables are soft and beginning to soften, about 5 minutes.
Stir in the tomatoes, corn, corn, and corn.
Bring to a boil.
Reduce heat to low, cover, and simmer for 10 minutes.
Add the chicken and cook for another 10 minutes or until the vegetables are tender.
Stir in the cilantro and serve.

Table 7: Sample generated recipe “Chicken Bell Pepper Chili Weight Watchers” for all models.

InputName: Cinna Nilla Waffles
Ingredients: flour, egg, milk, vegetable oil, sugar
Calorie: Medium

Gold

Heat waffle iron.
Beat eggs in large bowl with hand beater until fluffy.
Beat in remaining ingredients until smooth.
Pour batter into waffle iron and cook for approximately 5 minutes.
Serve immediately or cool to pack into freezer bags and freeze.

Enc-DecMix the flour, baking soda, and salt in a bowl.
In a separate bowl, whisk together the milk, oil, eggs and sugar.
Stir the flour mixture into the egg mixture, and continue to mix well.
Add the flour to the egg mixture.
Mix well and pour into a greased waffle iron.
Cook for 2 minutes, remove from heat and serve.

Prior Tech

In a medium bowl mix flour, eggs, and milk until combined.
Add the dry ingredients and stir until just combined and do not mix.
Heat griddle over medium heat, add the oil, oil, and cook the pancakes until goldenbrown and cooked through.
Serve with a little milk or cream. Enjoy

Prior Recipe

In a mixing bowl, whisk together the eggs, milk, oil, sugar, vanilla, salt and vanilla.
Cover and let the mixture stand in the fridge for about 1 hour.
Spoon batter into waffle iron and close the grill.

Prior Name

Preheat waffle iron.
Beat together the eggs, milk and oil until well blended, add the vanilla and mix wellwith a mixer.
Fold in flour, baking powder, and cinnamon.
Spread 1 / 2 the mixture in a greased waffle iron.
Bake until golden brown, about 15 minutes per side.
Sprinkle with powdered sugar and serve warm.
Table 8: Sample generated waffle recipe for all models.

Figure 3: A sample question for coherence evaluation survey.