240 likes | 385 Views
A Personalized Recipe Database System with User-Centered Adaptation and Tutoring Support. Student: Liping Wang Supervisor: Prof. Qing Li. City University of Hong Kong, Hong Kong. Outline. Introduction Recipe Modeling Recipe Cooking Graph Mining User Adaptation Prototype System
E N D
A Personalized Recipe Database System with User-Centered Adaptation and Tutoring Support Student: Liping Wang Supervisor: Prof. Qing Li City University of Hong Kong, Hong Kong
Outline • Introduction • Recipe Modeling • Recipe Cooking Graph Mining • User Adaptation • Prototype System • Conclusion & Future Work
Introduction • People can not live without foods • Existing recipe websites provide huge amounts of recipes throughout the world • Fail to give support on analyzing and comparing recipes • What are important cooking principles & skills; what makes two dishes’ taste so different, etc. • Unable to help users find similar recipes in a comprehensive manner • only keyword-based search on recipe names • Fail to adapt recipes to meet the real-world situation • e.g. due to lack of ingredients or user preference
Our Contributions • Propose a recipe model which encompasses static attributes as well as dynamic behaviours • e.g. cooking procedures and constraints • Present a novel perspective of evaluating the “quality” of a recipe by constructing and analysing its cooking graph • capture both action flows and data/ingredient flows • Provide a promising way to address the problem of recipe adaptation heuristically • with flexible and feasible solutions
Recipe on the Web Recipe on the Web
Sample Recipe The Cooking Procedure of “Triple Cheese Pasta Primavera”
Sample Recipe Parsing the Cooking Procedure of “Triple Cheese Pasta Primavera”
Recipe Model • A recipe R is modeled and represented by a tuple of three elements: R = <M, RP, SP> Where • (a) M={Mi | i = 1.. m} – a set of ingredients. An ingredient Mi is either a basic ingredient or a set of ingredients: • Mi = <MID, MP>, MID—unique identity, MP—member level properties (and functions) such as the name, quantity and image • Three classes: Main, Minor and Seasoning; • (b) RP is a set of recipe-level properties (and functions) applied on R itself, • such as the main cooking style, region, nutrition and images of the dish of the recipe;
Recipe Model • (c) SP = (V, E, Cons, Ingr) is a labeled directed“Cooking Graph”, • V={vi | i = 1..n} is a set of nodes. vi—a cooking action “cooking action constraints”: Cons(vi)—constraint conditions to be satisfied when vi takes place. e.g. conditions on temperature and duration etc. • E is a set of directed edges on V—temporal execution flow of the cooking actions;named “action flows”. An edge <vi ,vj> —vj should take place after vi. “cooking transition constraints”: Cons(vi , vj) –the conditions to be satisfied for the flow to take place. • Ingr(vi) – ingredientsthat should be added into vi O(vi) –the output ingredients of vi These inputs and outputs for the nodes are called “ingredient flows”.
Cooking Graph The Cooking Graph of “Triple Cheese Pasta Primavera”
Basic Properties • Definition 1. (Reachability) A cooking graph is defined as “reachable” if each of its nodes is “reachable”; a node is “reachable” if it is on a directed path from a starting node to the end node. • Definition 2. (Consistency) A cooking graph is defined to be “consistent” if the conditions for each node/edge is consistent (i.e. there exists assignment to variables to make the conditions true).
Constraints and Rules • Definition 3. (Constraint) A constraint is a predicate followed by one or more terms, enclosed in parentheses and separated by commas; a term is either a constant, variable or function expression. • Constraints specify all kinds of conditions or restrictions in the recipe model; • Three categories: intra-recipe constraints, inter-recipe constraints and outer-recipe constraints. • Incompatible(Spinach, Tofu) says spinach and tofu are incompatible and should not be cooked together.
Constraints and Rules • Definition 4. (Rule) A rule is a logical implication of the form “If A Then B” (or, A->B), where A and B are sentences. • Validate the correctness of a recipe through reasoning and recognition process. • Handle complex situations such as to make necessary adjustment or compensation once an improper cooking action occurs. • Describe cooking skills that have been widely accepted and commonly used. • Over_Put(salt) → Add(vinegar|water) says that if too much salt has been put into a dish, then neutralize the salty taste by adding either vinegar or water.
Recipe Cooking Graph Mining • Pattern — Some subgraphs occur in one or more cooking graphs; have certain influence on the cooking effects (e.g. taste, appearance). • Find patterns for a set of recipes • What’s usually done and what’s usually put in the cooking procedure (one action, a series of actions, an ingredients, a set of ingredients, actions combined with ingredients) • Cooking graphs of different recipes may share the same pattern • Distinct subgraphs that determine the cooking effect (e.g. taste) should be identified
Sample Cooking Style Generally describe how a recipe is cooked in a Pattern Combination or in Graph Abstraction.
User Adaptation • Usually a user wants to make a dish that has the same cooking result (e.g. taste, appearance) as the recipe exhibits. • Unfortunately, the user is very likely to get a slightly or even totally different dish as he/she modifies the cooking procedure. • Objective reasons—e.g. lack of some ingredients, Subjective reasons—e.g. wrong cooking actions by carelessness.
User Adaptation • When the user makes an adaptation, the system will check if the modified cooking graph is feasible. • If not, a set of feasible templates are provided. • The remaining subgraph is replaced by the user selected one. • Property check (Reachability, Consistency) Template Selection and Instantiation
Summary • Proposed a data model to represent a recipe • Advocated cooking graph mining to find frequent used patterns (actions, ingredients) • Tried to solve recipe adaptation problem by using patterns as templates • Developed a prototype system—RecipeView
Further Work • Discover patterns of cooking graphs • Refine and strengthen the algorithm of recipe adaptation
Acknowledgement • Thanks to Mr. Yu Li for his cooperation on RecipeView System • Many thanks to Prof. Xiaofeng Meng and Prof. Guozhu Dong for their precious suggestions on our project