<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>Conversational Retrieval of Cooking Recipes</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Christian Zeyen</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Gilbert Mu¨ller</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Ralph Bergmann</string-name>
          <email>bergmann@uni-trier.de</email>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>Business Information Systems II University of Trier 54286 Trier</institution>
          ,
          <country country="DE">Germany</country>
        </aff>
      </contrib-group>
      <fpage>237</fpage>
      <lpage>244</lpage>
      <abstract>
        <p>This paper presents a new approach for exploring a collection of cooking recipes represented as cooking workflows by means of a conversation. Users are guided through the search process by answering posed questions. Thus, they are not required to formulate queries and they do not need to browse a recipe collection by hand. Questions involve ingredients and cooking activities contained in the workflows. The approach is implemented in our CookingCAKE system, extending it with a dialog component.</p>
      </abstract>
      <kwd-group>
        <kwd>Recipe Retrieval</kwd>
        <kwd>Conversational Retrieval</kwd>
        <kwd>Workflows</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>1 Introduction</title>
      <p>Nowadays, numerous cooking recipes are available online and various search engines
support users in finding suitable recipes. Beside providing a keyword-based search,
some engines also support an ingredient-based search by asking the user to specify
desired and undesired ingredients. However, in practice, amateur chefs may only have a
vague idea of their desired dish or they lack detailed knowledge about required
ingredients and thus have difficulties in providing a precise query. In 2010, Yummly1 launched
the first semantic search platform for food and recipes. By capturing the semantics of
recipe descriptions and ingredients, Yummly is able to handle more vague queries such
as general terms in a keyword-based search. For example, if the user starts a search with
the keyword meat, Yummly initiates a dialog asking the user which kind of meat she
would like. Then, further questions are posed concerning various properties such as the
desired type of dish, preparation time, nutritional preferences, and additional
ingredients.</p>
      <p>
        This paper follows a similar approach and provides a method to conduct a
conversation with the user to find desired cooking recipes. We focus on structural features of
recipes thus representing them as workflows. More precisely, in addition to considering
the occurance of ingredients and preparation steps, we also analyze their
dependencies. Based on this information, questions concerning the further processing of desired
ingredients can be posed. Thus, the ingredient-based search capabilities provided in
typical search engines for recipes are extended by this approach. Moreover, we
investigate how such features can be constructed automatically from the underlying workflow
1 www.yummly.com
Copyright © 2017 for this paper by its authors. Copying permitted for private and
academic purpose. In Proceedings of the ICCBR 2017 Workshops. Trondheim, Norway
repository and we propose a respective question selection strategy for the
conversation. We consider a recipe search as a problem solving process in which the problem
description specifies the user’s preferences of a desired dish and a possible solution is
a recipe describing its preparation. We apply the methodology of conversational
casebased reasoning (CCBR) [
        <xref ref-type="bibr" rid="ref1 ref2">1,2</xref>
        ], which particularly focuses on the interactive nature of
problem solving. CCBR approaches include methods which incrementally elicit the
relevant features of the target problem in an interactive dialog, often with the aim of
minimizing the communication effort for the user. The basic assumption behind CCBR
is that guided question answering requires less domain expertise than providing detailed
queries from scratch. To apply CCBR with cooking workflows, we combine CCBR with
process-oriented case-based reasoning (POCBR) [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ], which usually deals with cases as
workflows or process descriptions expressing procedural experiential knowledge.
Consequently, we propose a new conversational POCBR approach [
        <xref ref-type="bibr" rid="ref10">10</xref>
        ], called C-POCBR,
for the retrieval of cooking workflows. We implemented the approach in our
CookingCAKE system [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ], which is part of the CAKE framework2, extending it with a dialog
component. CookingCAKE is a POCBR system for retrieving and adapting3 cooking
workflows based on a user-defined query specifying desired and undesired ingredients
and preparation steps.
      </p>
      <p>In the following, section 2 briefly introduces the representation and querying of
cooking workflows before section 3 describes our C-POCBR approach. Section 4
concludes the paper and briefly discusses future work.
2</p>
    </sec>
    <sec id="sec-2">
      <title>Cooking Workflows</title>
      <p>
        In our approach a cooking recipe is represented as a workflow describing the process to
prepare a particular dish [
        <xref ref-type="bibr" rid="ref3 ref9">9,3</xref>
        ] (see Fig. 1). Cooking workflows consist of a set of
preparation steps (also called task nodes) and a set of ingredients (also called data nodes)
shared between its tasks. Task nodes are linked by control-flow edges defining the
execution order. This forms the control-flow. Task nodes, data nodes, and relationships
(represented by data-flow edges) between the two of them form the data-flow. To each
2 See cake.wi2.uni-trier.de
3 However, the dialog component does not yet consider the available adaptation methods.
node a semantic label is assigned, which is structured hierarchically in a data
taxonomy of ingredients or a task taxonomy of cooking steps. Thereby, workflows can be
generalized regarding their semantic labels [
        <xref ref-type="bibr" rid="ref7">7</xref>
        ]. Generalized workflows provide a more
general description and thus stand for a set of more specific workflows. For example,
the workflow in Figure 1 can be generalized by generalizing the ingredient american
cheese to the more general ingredient cheese from the data taxonomy.
      </p>
      <p>
        In order to retrieve cooking workflows with case-based reasoning, the user’s
preferences must be specified in a query, which in turn must be evaluated against the available
workflows. For this purpose, we proposed a process-oriented query language (POQL)
[
        <xref ref-type="bibr" rid="ref8">8</xref>
        ] and a similarity measure [
        <xref ref-type="bibr" rid="ref10">10</xref>
        ] to determine the best-matching workflows for a given
POQL query. In a nutshell, POQL consists of two parts. In a query part, the user can
specify workflow fragments representing properties the searched recipe should fulfill.
In an additional restriction part, the user can define undesired situations, e.g., unwanted
ingredients, which should be avoided.
3
      </p>
    </sec>
    <sec id="sec-3">
      <title>A Conversational Retrieval Approach</title>
      <p>To facilitate the elaboration of a POQL query for workflow retrieval, our approach
guides the user through the query process with a sequence of questions about her
preferences. The more questions are answered, the more knowledge about desired and
undesired properties is available, which is stored in an internal POQL query. A major focus
is put on the automatic creation of questions to avoid that they need to be specified
manually. For this purpose, we consider workflow fragments as characteristic properties of
a workflow, which we refer to as features. The basic idea is to extract features from
the workflows stored in the repository (case base) automatically, which are then used
as the subject of questions. In order to conduct efficient conversations, we rank features
by their ability to distinguish workflows from one another. Furthermore, identified
relations between features enable to generate coherent follow-up questions and to infer
irrelevant features based on already answered questions.
3.1</p>
      <sec id="sec-3-1">
        <title>Features of a Cooking Workflow</title>
        <p>
          In principle, a feature can be any fragment of a cooking workflow. In a workflow, the
smallest possible feature consists of a single workflow item. This can be a single node
such as a data or a task node. More complex features can be created by extracting
partial workflows. To derive questions on a more general level of detail, we apply a
generalization algorithm [
          <xref ref-type="bibr" rid="ref7">7</xref>
          ], which generalizes semantic labels based on the task and
data taxonomies. The generalization produces a generalized workflow W from the
original workflow W , from which more general features can be extracted. We extract
and annotate two different kinds of features for each workflow W in the case base:
– specific feature nodes and generalized feature nodes, i.e., single nodes from W and
single nodes for all generalizations within the taxonomy up to the respective node
in the generalized workflow W
– specific feature workflows and generalized feature workflows, i.e., partial workflows
(consisting of more than one node) from W and W , respectively
4
        </p>
        <p>A feature workflow Wd describes structural properties of a workflow W regarding
a particular data item d from W . It consists of all (and at least one) tasks connected to d
and which are connected by control-flow edges. Moreover, Wd additionally comprises
all data items that are connected to those tasks. For instance, regarding the cooking
workflow depicted in Figure 1, a feature workflow constructed for the ingredient white
bread contains the associated processing steps toast and spread. It further comprises
the ingredient butter, which is required for the task spread.
lated feature g1 = fcut, meatg is more general and equally large while the feature
g2 = fparma-hamg is more specific and smaller.
3.2</p>
      </sec>
      <sec id="sec-3-2">
        <title>Questioning Strategy</title>
        <p>In order to obtain the user’s preferences most suitable to determine the best matching
cooking workflows, i.e., the candidate workflows, a respective questioning strategy is
required. The dialog component iteratively creates and displays questions until the user
selects a desired workflow. With each question answered by the user, the set of candidate
workflows, which encompasses the whole case base at the beginning of a conversation,
is reduced. The dialog starts with an empty query and the set of candidate features, i.e.,
relevant features to be asked in a question, comprises the full set of features.</p>
        <p>In the main loop, the dialog component selects a question based on the candidate
features. The selection process considers the previously answered questions as well
as the ranking and relationships of features. Each question involves one or in certain
cases several candidate features. We provide three major types of questions, which are
depicted in Table 1. Based on the ranking of the candidate features, the subject matter
of a question is determined. If the user answers that the suggested feature is desired,
specific follow-up questions are selected in the subsequent iterations. Those
followup questions are derived from related features and aim at further refining the previous
question asked. An example is given in Table 1, which presents a sequence of three
questions (Q) including the possible answers (A) and the user-selected answers (marked
with a box).</p>
        <p>At the beginning of a conversation the highest ranked feature from the candidate
features is suggested in a feature question (FQ ). This type of question is not related
to previously suggested features and it will be asked as long as the user selects the
suggested feature as irrelevant or undesired. In the example, the feature meat is the
subject matter of the first question and it is selected as desired by the user.</p>
        <p>If a feature in a FQ is selected as desired, a first follow-up question, i.e., a
specialization question (SQ ), is posed suggesting one or (if available) several equally large but
6
more specific features. The user can choose a specialization, select specializations as
undesired, or mark all specializations as irrelevant. This type of question is repeated as
long as further specializations exist and are desired by the user. In the example, the user
chooses chicken as her desired type of meat.</p>
        <p>Following the SQ s, an enlargement question (EQ ) is displayed to the user that
suggests, if available, larger features than the previously selected and/or specialized
feature. Just as in SQ , the user has three different options: choose an enlargement,
select enlargements as undesired, or mark all enlargements as irrelevant. In the given
example, we assume that the user does not like shredded or chopped chicken and thus
selects those features as undesired. If no more EQ s are available, the next initial FQ is
selected, addressing a new and potentially unrelated subject matter.</p>
        <p>When the set of candidate features is updated due to an ignored or answered
question, irrelevant features are inferred based on the relations between features. If a
question is marked as irrelevant, all the related features (e.g., more specific and larger
features) are marked as irrelevant, too. If suggested features are selected as undesired, they
are added to the restriction part of the current query and related irrelevant features are no
longer considered as candidate features, to prevent the system from repetitively asking
the user what she does not like. If a feature is marked as desired, also related features
such as more general features are removed from the set of candidate features. If a user
chooses a specialization or an enlargement, the target feature that is already present in
the query is replaced with the new feature.
3.3</p>
      </sec>
      <sec id="sec-3-3">
        <title>Conversation with CookingCAKE</title>
        <p>Based on the extracted features and the questioning strategy, the conversation is
conducted in the dialog component of CookingCAKE4. The graphical user interface is
illustrated in Figure 3. It consists of three displays suggesting the best matching
workflow (upper part of figure), showing a question (middle of figure), and summarizing the
current query (lower part of figure). Figure 3 presents a progressed state in a
conversation in which some preferences are already obtained from the user and specified in
the internal query by the system. In the given example, the current query contains firm
cheese as desired and meat as undesired. The question displayed is a follow-up
question targeting the further refinement of the current query. In the example, the question
suggests alternative processing steps for firm cheese. The user has two options to react:
1. Ignore the question: In this case, the features being subject of the question as well
as related features are ignored and the next best question is displayed.
2. Answer the question: Causes the system to extend the query and to perform a
similarity-based retrieval on the current set of candidate workflows. The workflow
with the highest similarity is displayed to the user.</p>
        <p>In the upper part of the user interface, a solution workflow best fulfilling the current
query is suggested to the user. With respect to this suggestion, the user has two
additional options to react:
4 Online demo available at cookingcake.wi2.uni-trier.de/conversation
1. Ignore the suggestion: The user can actively ignore the suggested workflow, which
causes the system to exclude it from the solution candidates and to trigger a new
retrieval for the next best workflow.
2. Select the suggestion: In this event, the conversation terminates successfully.</p>
      </sec>
    </sec>
    <sec id="sec-4">
      <title>Conclusions and Future Work</title>
      <p>
        We presented an approach to retrieve cooking workflows by means of an interactive
dialog with users. To save effort for defining suitable questions, a method for the automatic
creation of questions based on extracted features was described. We recently showed in
an experimental evaluation that those features are meaningful subjects of questions and
that they are suitable to distinguish workflows from one another [
        <xref ref-type="bibr" rid="ref10">10</xref>
        ]. Furthermore, our
results indicate that the conversational approach has the potential to reduce the retrieval
time and thus is able to reduce the communication effort for users.
      </p>
      <p>In future work we plan to extend the presentation and explanation of workflows
and features. For the sake of simplicity, we used a simplistic representation of cooking
recipes and considered basic features, which could be extended in the future. Also,
future work should investigate how adaptability of workflows can be considered during
a conversation. By this means, interactive retrieval could be combined with interactive
adaptation to provide more diverse and customized cooking workflows for users.
Acknowledgments. This work was funded by the German Research Foundation (DFG),
project number BE 1373/3-3.</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          1.
          <string-name>
            <surname>Aha</surname>
            ,
            <given-names>D.W.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Breslow</surname>
            ,
            <given-names>L.A.</given-names>
          </string-name>
          ,
          <article-title>Mun˜oz-</article-title>
          <string-name>
            <surname>Avila</surname>
          </string-name>
          , H.:
          <article-title>Conversational case-based reasoning</article-title>
          .
          <source>Applied Intelligence</source>
          <volume>14</volume>
          (
          <issue>1</issue>
          ),
          <fpage>9</fpage>
          -
          <lpage>32</lpage>
          (
          <year>2001</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          2.
          <string-name>
            <surname>Aha</surname>
            ,
            <given-names>D.W.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>McSherry</surname>
            ,
            <given-names>D.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Yang</surname>
            ,
            <given-names>Q.</given-names>
          </string-name>
          :
          <article-title>Advances in conversational case-based reasoning</article-title>
          .
          <source>Knowledge Engingeering Review</source>
          <volume>20</volume>
          (
          <issue>3</issue>
          ),
          <fpage>247</fpage>
          -
          <lpage>254</lpage>
          (
          <year>2005</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          3.
          <string-name>
            <surname>Bergmann</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Gil</surname>
            ,
            <given-names>Y.</given-names>
          </string-name>
          :
          <article-title>Similarity assessment and efficient retrieval of semantic workflows</article-title>
          .
          <source>Inf. Syst</source>
          .
          <volume>40</volume>
          ,
          <fpage>115</fpage>
          -
          <lpage>127</lpage>
          (
          <year>2014</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          4.
          <string-name>
            <surname>Kohlmaier</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Schmitt</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Bergmann</surname>
            ,
            <given-names>R.:</given-names>
          </string-name>
          <article-title>A similarity-based approach to attribute selection in user-adaptive sales dialogs</article-title>
          . In: Aha,
          <string-name>
            <given-names>D.W.</given-names>
            ,
            <surname>Watson</surname>
          </string-name>
          , I. (eds.)
          <source>Case-Based Reasoning Research and Development</source>
          ,
          <string-name>
            <surname>ICCBR</surname>
          </string-name>
          <year>2001</year>
          .
          <article-title>LNCS</article-title>
          , vol.
          <year>2080</year>
          , pp.
          <fpage>306</fpage>
          -
          <lpage>320</lpage>
          . Springer (
          <year>2001</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          5.
          <string-name>
            <surname>Minor</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Montani</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Recio-Garca</surname>
            ,
            <given-names>J.A.</given-names>
          </string-name>
          :
          <article-title>Process-oriented case-based reasoning</article-title>
          .
          <source>Information Systems</source>
          <volume>40</volume>
          ,
          <fpage>103</fpage>
          -
          <lpage>105</lpage>
          (
          <year>2014</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          6. Mu¨ller, G.,
          <string-name>
            <surname>Bergmann</surname>
          </string-name>
          , R.:
          <article-title>CookingCAKE: A framework for the adaptation of cooking recipes represented as workflows</article-title>
          . In:
          <string-name>
            <surname>Kendall-Morwick</surname>
            ,
            <given-names>J</given-names>
          </string-name>
          . (ed.)
          <source>Workshop Proceedings from (ICCBR</source>
          <year>2015</year>
          ). CEUR, vol.
          <volume>1520</volume>
          , pp.
          <fpage>221</fpage>
          -
          <lpage>232</lpage>
          . CEUR-WS.org (
          <year>2015</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          7. Mu¨ller, G.,
          <string-name>
            <surname>Bergmann</surname>
          </string-name>
          , R.:
          <article-title>Generalization of workflows in process-oriented case-based reasoning</article-title>
          . In: Russell,
          <string-name>
            <given-names>I.</given-names>
            ,
            <surname>Eberle</surname>
          </string-name>
          , W. (eds.)
          <source>Proceedings of the 28th Int. Florida Artificial Intelligence Research</source>
          Society Conference,
          <string-name>
            <surname>FLAIRS</surname>
          </string-name>
          <year>2015</year>
          . pp.
          <fpage>391</fpage>
          -
          <lpage>396</lpage>
          . AAAI Press (
          <year>2015</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          8. Mu¨ller, G.,
          <string-name>
            <surname>Bergmann</surname>
          </string-name>
          , R.: POQL:
          <article-title>A new query language for process-oriented case-based reasoning</article-title>
          . In: Bergmann,
          <string-name>
            <surname>R.</surname>
          </string-name>
          , Go¨rg,
          <string-name>
            <surname>S.</surname>
          </string-name>
          , Mu¨ller, G. (eds.)
          <source>Proceedings of the LWA 2015. CEUR Workshop Proceedings</source>
          , vol.
          <volume>1458</volume>
          , pp.
          <fpage>247</fpage>
          -
          <lpage>255</lpage>
          . CEUR-WS.org (
          <year>2015</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          9.
          <string-name>
            <surname>Schumacher</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Minor</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Walter</surname>
            ,
            <given-names>K.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Bergmann</surname>
          </string-name>
          , R.:
          <article-title>Extraction of procedural knowledge from the web</article-title>
          .
          <source>In: Workshop Proceedings: WWW'12</source>
          .
          <string-name>
            <surname>Lyon</surname>
          </string-name>
          , France (
          <year>2012</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref10">
        <mixed-citation>
          10.
          <string-name>
            <surname>Zeyen</surname>
            ,
            <given-names>C.</given-names>
          </string-name>
          , M u¨ller, G.,
          <string-name>
            <surname>Bergmann</surname>
          </string-name>
          , R.:
          <article-title>Conversational process-oriented case-based reasoning</article-title>
          .
          <source>In: Proceedings of ICCBR 2017. LNCS</source>
          , Springer (
          <year>2017</year>
          )
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>