3732 lines
227 KiB
Plaintext
3732 lines
227 KiB
Plaintext
{
|
|
"cells": [
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {},
|
|
"source": [
|
|
"# Manual Recipe Creation based on Popular Yummly Recipes"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 1,
|
|
"metadata": {},
|
|
"outputs": [],
|
|
"source": [
|
|
"import sys\n",
|
|
"sys.path.append(\"../\")\n",
|
|
"sys.path.append(\"../EvolutionaryAlgorithm/\")"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 2,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"text/html": [
|
|
" <script type=\"text/javascript\">\n",
|
|
" window.PlotlyConfig = {MathJaxConfig: 'local'};\n",
|
|
" if (window.MathJax) {MathJax.Hub.Config({SVG: {font: \"STIX-Web\"}});}\n",
|
|
" if (typeof require !== 'undefined') {\n",
|
|
" require.undef(\"plotly\");\n",
|
|
" requirejs.config({\n",
|
|
" paths: {\n",
|
|
" 'plotly': ['https://cdn.plot.ly/plotly-latest.min']\n",
|
|
" }\n",
|
|
" });\n",
|
|
" require(['plotly'], function(Plotly) {\n",
|
|
" window._Plotly = Plotly;\n",
|
|
" });\n",
|
|
" }\n",
|
|
" </script>\n",
|
|
" "
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
},
|
|
{
|
|
"data": {
|
|
"text/html": [
|
|
" <script type=\"text/javascript\">\n",
|
|
" window.PlotlyConfig = {MathJaxConfig: 'local'};\n",
|
|
" if (window.MathJax) {MathJax.Hub.Config({SVG: {font: \"STIX-Web\"}});}\n",
|
|
" if (typeof require !== 'undefined') {\n",
|
|
" require.undef(\"plotly\");\n",
|
|
" requirejs.config({\n",
|
|
" paths: {\n",
|
|
" 'plotly': ['https://cdn.plot.ly/plotly-latest.min']\n",
|
|
" }\n",
|
|
" });\n",
|
|
" require(['plotly'], function(Plotly) {\n",
|
|
" window._Plotly = Plotly;\n",
|
|
" });\n",
|
|
" }\n",
|
|
" </script>\n",
|
|
" "
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
},
|
|
{
|
|
"name": "stderr",
|
|
"output_type": "stream",
|
|
"text": [
|
|
"../EvolutionaryAlgorithm/EvolutionaryAlgorithm.py:60: TqdmExperimentalWarning:\n",
|
|
"\n",
|
|
"Using `tqdm.autonotebook.tqdm` in notebook mode. Use `tqdm.tqdm` instead to force console mode (e.g. in jupyter console)\n",
|
|
"\n"
|
|
]
|
|
}
|
|
],
|
|
"source": [
|
|
"import EvolutionaryAlgorithm as EA"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 3,
|
|
"metadata": {},
|
|
"outputs": [],
|
|
"source": [
|
|
"def ingredient_nodes(ing_list):\n",
|
|
" d = {}\n",
|
|
" for ing in ing_list:\n",
|
|
" d[ing] = EA.IngredientNode(ing)\n",
|
|
" return d"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 4,
|
|
"metadata": {},
|
|
"outputs": [],
|
|
"source": [
|
|
"def act(d, act, ing):\n",
|
|
" a = EA.ActionNode(act)\n",
|
|
" \n",
|
|
" p_a = d[ing]\n",
|
|
" \n",
|
|
" while p_a.parent() is not None:\n",
|
|
" p_a = p_a.parent()\n",
|
|
" \n",
|
|
" a.add_child(p_a)"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 5,
|
|
"metadata": {},
|
|
"outputs": [],
|
|
"source": [
|
|
"def mix(d, ing_a, ing_b):\n",
|
|
" p_a = d[ing_a]\n",
|
|
" p_b = d[ing_b]\n",
|
|
" \n",
|
|
" while p_a.parent() is not None:\n",
|
|
" p_a = p_a.parent()\n",
|
|
" while p_b.parent() is not None:\n",
|
|
" p_b = p_b.parent()\n",
|
|
" \n",
|
|
" m = EA.MixNode()\n",
|
|
" m.add_child(p_a)\n",
|
|
" m.add_child(p_b)\n",
|
|
" \n",
|
|
" "
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 6,
|
|
"metadata": {},
|
|
"outputs": [],
|
|
"source": [
|
|
"def get_root(d):\n",
|
|
" parents = set()\n",
|
|
" for n in d:\n",
|
|
" p = d[n]\n",
|
|
" while p.parent() is not None:\n",
|
|
" p = p.parent()\n",
|
|
" parents.add(p)\n",
|
|
" \n",
|
|
" pp = list(parents)\n",
|
|
" if len(pp) == 1:\n",
|
|
" pp[0].simplify()\n",
|
|
" return pp[0]\n",
|
|
" \n",
|
|
" m = EA.MixNode()\n",
|
|
" for p in pp:\n",
|
|
" m.add_child(p)\n",
|
|
" m.simplify()\n",
|
|
" return m"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 7,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"image/svg+xml": [
|
|
"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\n",
|
|
"<!DOCTYPE svg PUBLIC \"-//W3C//DTD SVG 1.1//EN\"\n",
|
|
" \"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd\">\n",
|
|
"<!-- Generated by graphviz version 2.40.1 (20161225.0304)\n",
|
|
" -->\n",
|
|
"<!-- Title: %3 Pages: 1 -->\n",
|
|
"<svg width=\"871pt\" height=\"434pt\"\n",
|
|
" viewBox=\"0.00 0.00 870.85 433.82\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
|
|
"<g id=\"graph0\" class=\"graph\" transform=\"scale(1 1) rotate(0) translate(4 429.8234)\">\n",
|
|
"<title>%3</title>\n",
|
|
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-429.8234 866.8528,-429.8234 866.8528,4 -4,4\"/>\n",
|
|
"<!-- 15 -->\n",
|
|
"<g id=\"node1\" class=\"node\">\n",
|
|
"<title>15</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"536,-425.8234 416,-389.8234 536,-353.8234 656,-389.8234 536,-425.8234\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"522.5\" y=\"-393.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"526.5\" y=\"-393.6234\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"484\" y=\"-379.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.6000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 14 -->\n",
|
|
"<g id=\"node2\" class=\"node\">\n",
|
|
"<title>14</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"266\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"250\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"254\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">bake</text>\n",
|
|
"<text text-anchor=\"start\" x=\"214\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.7500</text>\n",
|
|
"</g>\n",
|
|
"<!-- 15->14 -->\n",
|
|
"<g id=\"edge1\" class=\"edge\">\n",
|
|
"<title>15->14</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M481.3615,-370.1017C437.6284,-354.3164 376.2051,-332.1458 330.1417,-315.5193\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"331.1516,-312.1629 320.5573,-312.0598 328.775,-318.7471 331.1516,-312.1629\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 9 -->\n",
|
|
"<g id=\"node9\" class=\"node\">\n",
|
|
"<title>9</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"456\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"439\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"443\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">wash</text>\n",
|
|
"<text text-anchor=\"start\" x=\"404\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 15->9 -->\n",
|
|
"<g id=\"edge8\" class=\"edge\">\n",
|
|
"<title>15->9</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M512.214,-360.8473C502.9332,-349.5415 492.2507,-336.5281 482.7073,-324.9023\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"485.3636,-322.622 476.3134,-317.1133 479.9531,-327.0634 485.3636,-322.622\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 6 -->\n",
|
|
"<g id=\"node11\" class=\"node\">\n",
|
|
"<title>6</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"675,-310.3675 559,-310.3675 559,-274.3675 675,-274.3675 675,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"596.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"600.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cheese</text>\n",
|
|
"<text text-anchor=\"start\" x=\"567\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 15->6 -->\n",
|
|
"<g id=\"edge10\" class=\"edge\">\n",
|
|
"<title>15->6</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M560.0834,-360.8473C571.2828,-347.3726 584.4983,-331.4722 595.3746,-318.3863\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"598.1051,-320.5768 601.8054,-310.6491 592.7218,-316.1024 598.1051,-320.5768\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 10 -->\n",
|
|
"<g id=\"node12\" class=\"node\">\n",
|
|
"<title>10</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"778\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"763.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"767.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">heat</text>\n",
|
|
"<text text-anchor=\"start\" x=\"726\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 15->10 -->\n",
|
|
"<g id=\"edge11\" class=\"edge\">\n",
|
|
"<title>15->10</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M587.322,-369.1555C625.4706,-353.7927 677.6365,-332.7849 717.7625,-316.6258\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"719.1989,-319.8206 727.1675,-312.8383 716.5839,-313.3273 719.1989,-319.8206\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 13 -->\n",
|
|
"<g id=\"node3\" class=\"node\">\n",
|
|
"<title>13</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"262,-230.9117 142,-194.9117 262,-158.9117 382,-194.9117 262,-230.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"248.5\" y=\"-198.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"252.5\" y=\"-198.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"210\" y=\"-184.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 14->13 -->\n",
|
|
"<g id=\"edge2\" class=\"edge\">\n",
|
|
"<title>14->13</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M264.949,-266.7622C264.6194,-258.7311 264.245,-249.6091 263.8762,-240.6244\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"267.3722,-240.4521 263.465,-230.6041 260.3781,-240.7393 267.3722,-240.4521\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 0 -->\n",
|
|
"<g id=\"node4\" class=\"node\">\n",
|
|
"<title>0</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"116,-115.4558 0,-115.4558 0,-79.4558 116,-79.4558 116,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"45.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"49.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">salt</text>\n",
|
|
"<text text-anchor=\"start\" x=\"8\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 13->0 -->\n",
|
|
"<g id=\"edge3\" class=\"edge\">\n",
|
|
"<title>13->0</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M215.7092,-172.7974C182.6136,-156.9869 138.2305,-135.784 104.9797,-119.8992\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"106.4471,-116.7214 95.9151,-115.5688 103.4296,-123.0376 106.4471,-116.7214\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 2 -->\n",
|
|
"<g id=\"node5\" class=\"node\">\n",
|
|
"<title>2</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"253.5,-115.4558 134.5,-115.4558 134.5,-79.4558 253.5,-79.4558 253.5,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"142.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"146.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mozarella cheese</text>\n",
|
|
"<text text-anchor=\"start\" x=\"144\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 13->2 -->\n",
|
|
"<g id=\"edge4\" class=\"edge\">\n",
|
|
"<title>13->2</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M241.2283,-165.1422C232.0888,-152.0437 221.4384,-136.7799 212.5673,-124.066\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"215.343,-121.9275 206.7504,-115.7293 209.6023,-125.9331 215.343,-121.9275\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 3 -->\n",
|
|
"<g id=\"node6\" class=\"node\">\n",
|
|
"<title>3</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"388,-115.4558 272,-115.4558 272,-79.4558 388,-79.4558 388,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"308.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"312.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">noodle</text>\n",
|
|
"<text text-anchor=\"start\" x=\"280\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 13->3 -->\n",
|
|
"<g id=\"edge5\" class=\"edge\">\n",
|
|
"<title>13->3</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M282.7717,-165.1422C291.9112,-152.0437 302.5616,-136.7799 311.4327,-124.066\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"314.3977,-125.9331 317.2496,-115.7293 308.657,-121.9275 314.3977,-125.9331\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 8 -->\n",
|
|
"<g id=\"node7\" class=\"node\">\n",
|
|
"<title>8</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"491\" cy=\"-97.4558\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"477\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"481\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">dice</text>\n",
|
|
"<text text-anchor=\"start\" x=\"439\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 13->8 -->\n",
|
|
"<g id=\"edge6\" class=\"edge\">\n",
|
|
"<title>13->8</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M311.6896,-173.7652C347.221,-158.6441 395.1678,-138.2393 432.5413,-122.3342\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"433.9704,-125.5298 441.8013,-118.3934 431.2293,-119.0888 433.9704,-125.5298\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 1 -->\n",
|
|
"<g id=\"node8\" class=\"node\">\n",
|
|
"<title>1</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"549,-36 433,-36 433,0 549,0 549,-36\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"472.5\" y=\"-21.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"476.5\" y=\"-21.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">onion</text>\n",
|
|
"<text text-anchor=\"start\" x=\"441\" y=\"-7.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 8->1 -->\n",
|
|
"<g id=\"edge7\" class=\"edge\">\n",
|
|
"<title>8->1</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M491,-71.8782C491,-63.7122 491,-54.6289 491,-46.2824\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"494.5001,-46.2287 491,-36.2288 487.5001,-46.2288 494.5001,-46.2287\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 4 -->\n",
|
|
"<g id=\"node10\" class=\"node\">\n",
|
|
"<title>4</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"516,-212.9117 400,-212.9117 400,-176.9117 516,-176.9117 516,-212.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"433.5\" y=\"-198.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"437.5\" y=\"-198.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">spinach</text>\n",
|
|
"<text text-anchor=\"start\" x=\"408\" y=\"-184.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 9->4 -->\n",
|
|
"<g id=\"edge9\" class=\"edge\">\n",
|
|
"<title>9->4</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M456.5255,-266.7622C456.7994,-253.4123 457.1353,-237.0481 457.4172,-223.3105\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"460.9235,-223.0339 457.6295,-212.9642 453.925,-222.8902 460.9235,-223.0339\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 7 -->\n",
|
|
"<g id=\"node13\" class=\"node\">\n",
|
|
"<title>7</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"836,-212.9117 720,-212.9117 720,-176.9117 836,-176.9117 836,-212.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"739.5\" y=\"-198.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"743.5\" y=\"-198.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">spring onion</text>\n",
|
|
"<text text-anchor=\"start\" x=\"728\" y=\"-184.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 10->7 -->\n",
|
|
"<g id=\"edge12\" class=\"edge\">\n",
|
|
"<title>10->7</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M778,-266.7622C778,-253.4123 778,-237.0481 778,-223.3105\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"781.5001,-222.9641 778,-212.9642 774.5001,-222.9642 781.5001,-222.9641\"/>\n",
|
|
"</g>\n",
|
|
"</g>\n",
|
|
"</svg>\n"
|
|
],
|
|
"text/plain": [
|
|
"<graphviz.dot.Digraph at 0x7ff21d8a9150>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
},
|
|
{
|
|
"data": {
|
|
"text/markdown": [
|
|
"**Ingredients**:\n",
|
|
" * spring onion\n",
|
|
" * noodle\n",
|
|
" * salt\n",
|
|
" * spinach\n",
|
|
" * mozarella cheese\n",
|
|
" * cheese\n",
|
|
" * onion\n",
|
|
"\n",
|
|
"\n",
|
|
"**Instructions**:\n",
|
|
"\n",
|
|
"| Step | Instruction |\n",
|
|
"| ----:|:----------- |\n",
|
|
"| 1 | dice onion and mix it with salt, mozarella cheese and noodle. Then bake it. |\n",
|
|
"| 2 | wash spinach, heat spring onion and mix it with cheese and mix it together with the results of step 1. |\n"
|
|
],
|
|
"text/plain": [
|
|
"<IPython.core.display.Markdown object>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
}
|
|
],
|
|
"source": [
|
|
"# ingredients:\n",
|
|
"\n",
|
|
"d = ingredient_nodes([\n",
|
|
" \"salt\",\n",
|
|
" \"onion\",\n",
|
|
" \"mozarella cheese\",\n",
|
|
" \"noodle\",\n",
|
|
" \"spinach\",\n",
|
|
" \"cheese\",\n",
|
|
" \"cheese\",\n",
|
|
" \"spring onion\"\n",
|
|
"])\n",
|
|
"\n",
|
|
"act(d, \"dice\", \"onion\")\n",
|
|
"act(d, \"wash\", \"spinach\")\n",
|
|
"\n",
|
|
"act(d, \"heat\", \"spring onion\")\n",
|
|
"\n",
|
|
"mix(d, \"salt\", \"onion\")\n",
|
|
"mix(d, \"salt\", \"noodle\")\n",
|
|
"mix(d, \"salt\", \"mozarella cheese\")\n",
|
|
"act(d, \"bake\", \"noodle\")\n",
|
|
"\n",
|
|
"\n",
|
|
"r = get_root(d)\n",
|
|
"\n",
|
|
"display(r.dot())\n",
|
|
"display(r.to_instruction().to_markdown())\n"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 8,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"text/plain": [
|
|
"'lasagne_recipe.dot'"
|
|
]
|
|
},
|
|
"execution_count": 8,
|
|
"metadata": {},
|
|
"output_type": "execute_result"
|
|
}
|
|
],
|
|
"source": [
|
|
"r.dot().save(\"lasagne_recipe.dot\")"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {},
|
|
"source": [
|
|
"## Easy Fried Rice\n",
|
|
"https://www.yummly.com/recipe/Easy-Fried-Rice-2306391#directions"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {},
|
|
"source": [
|
|
"* Ingredients"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 9,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"image/svg+xml": [
|
|
"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\n",
|
|
"<!DOCTYPE svg PUBLIC \"-//W3C//DTD SVG 1.1//EN\"\n",
|
|
" \"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd\">\n",
|
|
"<!-- Generated by graphviz version 2.40.1 (20161225.0304)\n",
|
|
" -->\n",
|
|
"<!-- Title: %3 Pages: 1 -->\n",
|
|
"<svg width=\"1023pt\" height=\"629pt\"\n",
|
|
" viewBox=\"0.00 0.00 1022.71 628.74\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
|
|
"<g id=\"graph0\" class=\"graph\" transform=\"scale(1 1) rotate(0) translate(4 624.7351)\">\n",
|
|
"<title>%3</title>\n",
|
|
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-624.7351 1018.7056,-624.7351 1018.7056,4 -4,4\"/>\n",
|
|
"<!-- 83 -->\n",
|
|
"<g id=\"node1\" class=\"node\">\n",
|
|
"<title>83</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"634.8528,-620.7351 514.8528,-584.7351 634.8528,-548.7351 754.8528,-584.7351 634.8528,-620.7351\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"621.3528\" y=\"-588.5351\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"625.3528\" y=\"-588.5351\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"582.8528\" y=\"-574.5351\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.8947</text>\n",
|
|
"</g>\n",
|
|
"<!-- 67 -->\n",
|
|
"<g id=\"node2\" class=\"node\">\n",
|
|
"<title>67</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"370.8528,-505.2792 254.8528,-505.2792 254.8528,-469.2792 370.8528,-469.2792 370.8528,-505.2792\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"280.8528\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"284.8528\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">sesame oil</text>\n",
|
|
"<text text-anchor=\"start\" x=\"262.8528\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 83->67 -->\n",
|
|
"<g id=\"edge1\" class=\"edge\">\n",
|
|
"<title>83->67</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M569.9239,-568.091C518.1033,-554.4026 443.8423,-533.8795 379.8528,-512.7351 376.1053,-511.4967 372.2578,-510.1745 368.3928,-508.8081\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"369.3902,-505.4472 358.7959,-505.3435 367.0132,-512.0313 369.3902,-505.4472\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 82 -->\n",
|
|
"<g id=\"node3\" class=\"node\">\n",
|
|
"<title>82</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"473.8528\" cy=\"-487.2792\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"462.8528\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"466.8528\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">fry</text>\n",
|
|
"<text text-anchor=\"start\" x=\"421.8528\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.3750</text>\n",
|
|
"</g>\n",
|
|
"<!-- 83->82 -->\n",
|
|
"<g id=\"edge2\" class=\"edge\">\n",
|
|
"<title>83->82</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M595.0551,-560.6449C572.4309,-546.9501 543.986,-529.732 520.3392,-515.4182\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"521.9007,-512.2721 511.5335,-510.0879 518.2758,-518.2605 521.9007,-512.2721\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 62 -->\n",
|
|
"<g id=\"node18\" class=\"node\">\n",
|
|
"<title>62</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"692.8528,-505.2792 576.8528,-505.2792 576.8528,-469.2792 692.8528,-469.2792 692.8528,-505.2792\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"612.3528\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"616.3528\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">pepper</text>\n",
|
|
"<text text-anchor=\"start\" x=\"584.8528\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 83->62 -->\n",
|
|
"<g id=\"edge17\" class=\"edge\">\n",
|
|
"<title>83->62</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M634.8528,-548.723C634.8528,-537.777 634.8528,-525.9105 634.8528,-515.5511\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"638.3529,-515.4029 634.8528,-505.4029 631.3529,-515.4029 638.3529,-515.4029\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 61 -->\n",
|
|
"<g id=\"node19\" class=\"node\">\n",
|
|
"<title>61</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"826.8528,-505.2792 710.8528,-505.2792 710.8528,-469.2792 826.8528,-469.2792 826.8528,-505.2792\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"756.3528\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"760.3528\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">salt</text>\n",
|
|
"<text text-anchor=\"start\" x=\"718.8528\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 83->61 -->\n",
|
|
"<g id=\"edge18\" class=\"edge\">\n",
|
|
"<title>83->61</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M670.0597,-559.1297C690.4147,-544.3259 715.8663,-525.8154 735.838,-511.2903\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"738.0023,-514.0441 744.031,-505.3317 733.885,-508.3829 738.0023,-514.0441\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 69 -->\n",
|
|
"<g id=\"node20\" class=\"node\">\n",
|
|
"<title>69</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"929.8528\" cy=\"-487.2792\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"910.8528\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"914.8528\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">whisk</text>\n",
|
|
"<text text-anchor=\"start\" x=\"877.8528\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 83->69 -->\n",
|
|
"<g id=\"edge19\" class=\"edge\">\n",
|
|
"<title>83->69</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M692.0816,-565.829C741.0358,-549.6566 811.5458,-526.363 863.0689,-509.3419\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"864.386,-512.5929 872.7833,-506.1326 862.1901,-505.9462 864.386,-512.5929\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 81 -->\n",
|
|
"<g id=\"node4\" class=\"node\">\n",
|
|
"<title>81</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"473.8528,-425.8234 353.8528,-389.8234 473.8528,-353.8234 593.8528,-389.8234 473.8528,-425.8234\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"460.3528\" y=\"-393.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"464.3528\" y=\"-393.6234\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"421.8528\" y=\"-379.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.9545</text>\n",
|
|
"</g>\n",
|
|
"<!-- 82->81 -->\n",
|
|
"<g id=\"edge3\" class=\"edge\">\n",
|
|
"<title>82->81</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M473.8528,-461.6738C473.8528,-453.8102 473.8528,-444.9007 473.8528,-436.0982\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"477.3529,-435.883 473.8528,-425.883 470.3529,-435.883 477.3529,-435.883\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 66 -->\n",
|
|
"<g id=\"node5\" class=\"node\">\n",
|
|
"<title>66</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"209.8528,-310.3675 93.8528,-310.3675 93.8528,-274.3675 209.8528,-274.3675 209.8528,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"114.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"118.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">oyster sauce</text>\n",
|
|
"<text text-anchor=\"start\" x=\"101.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 81->66 -->\n",
|
|
"<g id=\"edge4\" class=\"edge\">\n",
|
|
"<title>81->66</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M408.9239,-373.1793C357.1033,-359.4909 282.8423,-338.9678 218.8528,-317.8234 215.1053,-316.5851 211.2578,-315.2628 207.3928,-313.8964\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"208.3902,-310.5355 197.7959,-310.4318 206.0132,-317.1196 208.3902,-310.5355\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 77 -->\n",
|
|
"<g id=\"node6\" class=\"node\">\n",
|
|
"<title>77</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"312.8528\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"295.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"299.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">saute</text>\n",
|
|
"<text text-anchor=\"start\" x=\"260.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 81->77 -->\n",
|
|
"<g id=\"edge5\" class=\"edge\">\n",
|
|
"<title>81->77</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M434.0551,-365.7332C411.4309,-352.0384 382.986,-334.8203 359.3392,-320.5065\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"360.9007,-317.3604 350.5335,-315.1762 357.2758,-323.3488 360.9007,-317.3604\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 65 -->\n",
|
|
"<g id=\"node13\" class=\"node\">\n",
|
|
"<title>65</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"531.8528,-310.3675 415.8528,-310.3675 415.8528,-274.3675 531.8528,-274.3675 531.8528,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"444.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"448.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">soy sauce</text>\n",
|
|
"<text text-anchor=\"start\" x=\"423.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 81->65 -->\n",
|
|
"<g id=\"edge12\" class=\"edge\">\n",
|
|
"<title>81->65</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M473.8528,-353.8113C473.8528,-342.8653 473.8528,-330.9988 473.8528,-320.6395\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"477.3529,-320.4912 473.8528,-310.4912 470.3529,-320.4912 477.3529,-320.4912\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 70 -->\n",
|
|
"<g id=\"node14\" class=\"node\">\n",
|
|
"<title>70</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"634.8528\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"618.8528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"622.8528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cook</text>\n",
|
|
"<text text-anchor=\"start\" x=\"582.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 81->70 -->\n",
|
|
"<g id=\"edge13\" class=\"edge\">\n",
|
|
"<title>81->70</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M513.6506,-365.7332C536.2748,-352.0384 564.7196,-334.8203 588.3664,-320.5065\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"590.4298,-323.3488 597.1722,-315.1762 586.8049,-317.3604 590.4298,-323.3488\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 71 -->\n",
|
|
"<g id=\"node16\" class=\"node\">\n",
|
|
"<title>71</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"822.8528\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"808.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"812.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">slice</text>\n",
|
|
"<text text-anchor=\"start\" x=\"770.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 81->71 -->\n",
|
|
"<g id=\"edge15\" class=\"edge\">\n",
|
|
"<title>81->71</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M536.247,-372.4002C596.4528,-355.5882 687.534,-330.1544 750.7995,-312.4879\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"752.0152,-315.7824 760.7053,-309.7218 750.1325,-309.0404 752.0152,-315.7824\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 76 -->\n",
|
|
"<g id=\"node7\" class=\"node\">\n",
|
|
"<title>76</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"312.8528,-230.9117 192.8528,-194.9117 312.8528,-158.9117 432.8528,-194.9117 312.8528,-230.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"299.3528\" y=\"-198.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"303.3528\" y=\"-198.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"260.8528\" y=\"-184.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 77->76 -->\n",
|
|
"<g id=\"edge6\" class=\"edge\">\n",
|
|
"<title>77->76</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M312.8528,-266.7622C312.8528,-258.8985 312.8528,-249.989 312.8528,-241.1865\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"316.3529,-240.9713 312.8528,-230.9713 309.3529,-240.9714 316.3529,-240.9713\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 68 -->\n",
|
|
"<g id=\"node8\" class=\"node\">\n",
|
|
"<title>68</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"84.8528\" cy=\"-97.4558\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"69.3528\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"73.3528\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">melt</text>\n",
|
|
"<text text-anchor=\"start\" x=\"32.8528\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 76->68 -->\n",
|
|
"<g id=\"edge7\" class=\"edge\">\n",
|
|
"<title>76->68</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M263.099,-173.645C227.707,-158.5171 180.0487,-138.1462 142.9167,-122.2745\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"144.2879,-119.0544 133.717,-118.3422 141.5365,-125.491 144.2879,-119.0544\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 59 -->\n",
|
|
"<g id=\"node10\" class=\"node\">\n",
|
|
"<title>59</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"303.8528,-115.4558 187.8528,-115.4558 187.8528,-79.4558 303.8528,-79.4558 303.8528,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"225.3528\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"229.3528\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">carrot</text>\n",
|
|
"<text text-anchor=\"start\" x=\"195.8528\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 76->59 -->\n",
|
|
"<g id=\"edge9\" class=\"edge\">\n",
|
|
"<title>76->59</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M292.2039,-164.8765C283.2067,-151.7895 272.7518,-136.5822 264.0509,-123.9262\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"266.8964,-121.887 258.347,-115.6294 261.1281,-125.8527 266.8964,-121.887\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 58 -->\n",
|
|
"<g id=\"node11\" class=\"node\">\n",
|
|
"<title>58</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"437.8528,-115.4558 321.8528,-115.4558 321.8528,-79.4558 437.8528,-79.4558 437.8528,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"367.3528\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"371.3528\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">pea</text>\n",
|
|
"<text text-anchor=\"start\" x=\"329.8528\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 76->58 -->\n",
|
|
"<g id=\"edge10\" class=\"edge\">\n",
|
|
"<title>76->58</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M333.5017,-164.8765C342.4989,-151.7895 352.9538,-136.5822 361.6547,-123.9262\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"364.5775,-125.8527 367.3587,-115.6294 358.8092,-121.887 364.5775,-125.8527\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 60 -->\n",
|
|
"<g id=\"node12\" class=\"node\">\n",
|
|
"<title>60</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"571.8528,-115.4558 455.8528,-115.4558 455.8528,-79.4558 571.8528,-79.4558 571.8528,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"478.3528\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"482.3528\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">garlic clove</text>\n",
|
|
"<text text-anchor=\"start\" x=\"463.8528\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 76->60 -->\n",
|
|
"<g id=\"edge11\" class=\"edge\">\n",
|
|
"<title>76->60</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M358.9663,-172.5533C391.457,-156.8001 434.8002,-135.7849 467.3723,-119.9921\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"469.2113,-122.9903 476.6824,-115.4781 466.1573,-116.6916 469.2113,-122.9903\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 56 -->\n",
|
|
"<g id=\"node9\" class=\"node\">\n",
|
|
"<title>56</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"142.8528,-36 26.8528,-36 26.8528,0 142.8528,0 142.8528,-36\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"64.3528\" y=\"-21.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"68.3528\" y=\"-21.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">butter</text>\n",
|
|
"<text text-anchor=\"start\" x=\"34.8528\" y=\"-7.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 68->56 -->\n",
|
|
"<g id=\"edge8\" class=\"edge\">\n",
|
|
"<title>68->56</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M84.8528,-71.8782C84.8528,-63.7122 84.8528,-54.6289 84.8528,-46.2824\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"88.3529,-46.2287 84.8528,-36.2288 81.3529,-46.2288 88.3529,-46.2287\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 63 -->\n",
|
|
"<g id=\"node15\" class=\"node\">\n",
|
|
"<title>63</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"692.8528,-212.9117 576.8528,-212.9117 576.8528,-176.9117 692.8528,-176.9117 692.8528,-212.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"621.8528\" y=\"-198.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"625.8528\" y=\"-198.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">rice</text>\n",
|
|
"<text text-anchor=\"start\" x=\"584.8528\" y=\"-184.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 70->63 -->\n",
|
|
"<g id=\"edge14\" class=\"edge\">\n",
|
|
"<title>70->63</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M634.8528,-266.7622C634.8528,-253.4123 634.8528,-237.0481 634.8528,-223.3105\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"638.3529,-222.9641 634.8528,-212.9642 631.3529,-222.9642 638.3529,-222.9641\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 64 -->\n",
|
|
"<g id=\"node17\" class=\"node\">\n",
|
|
"<title>64</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"880.8528,-212.9117 764.8528,-212.9117 764.8528,-176.9117 880.8528,-176.9117 880.8528,-212.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"804.3528\" y=\"-198.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"808.3528\" y=\"-198.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">onion</text>\n",
|
|
"<text text-anchor=\"start\" x=\"772.8528\" y=\"-184.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 71->64 -->\n",
|
|
"<g id=\"edge16\" class=\"edge\">\n",
|
|
"<title>71->64</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M822.8528,-266.7622C822.8528,-253.4123 822.8528,-237.0481 822.8528,-223.3105\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"826.3529,-222.9641 822.8528,-212.9642 819.3529,-222.9642 826.3529,-222.9641\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 57 -->\n",
|
|
"<g id=\"node21\" class=\"node\">\n",
|
|
"<title>57</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"987.8528,-407.8234 871.8528,-407.8234 871.8528,-371.8234 987.8528,-371.8234 987.8528,-407.8234\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"917.8528\" y=\"-393.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"921.8528\" y=\"-393.6234\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">egg</text>\n",
|
|
"<text text-anchor=\"start\" x=\"879.8528\" y=\"-379.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 69->57 -->\n",
|
|
"<g id=\"edge20\" class=\"edge\">\n",
|
|
"<title>69->57</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M929.8528,-461.6738C929.8528,-448.324 929.8528,-431.9598 929.8528,-418.2222\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"933.3529,-417.8758 929.8528,-407.8758 926.3529,-417.8759 933.3529,-417.8758\"/>\n",
|
|
"</g>\n",
|
|
"</g>\n",
|
|
"</svg>\n"
|
|
],
|
|
"text/plain": [
|
|
"<graphviz.dot.Digraph at 0x7f87485e4550>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
},
|
|
{
|
|
"data": {
|
|
"text/markdown": [
|
|
"**Ingredients**:\n",
|
|
" * oyster sauce\n",
|
|
" * carrot\n",
|
|
" * soy sauce\n",
|
|
" * onion\n",
|
|
" * butter\n",
|
|
" * sesame oil\n",
|
|
" * pepper\n",
|
|
" * egg\n",
|
|
" * rice\n",
|
|
" * salt\n",
|
|
" * garlic clove\n",
|
|
" * pea\n",
|
|
"\n",
|
|
"\n",
|
|
"**Instructions**:\n",
|
|
"\n",
|
|
"| Step | Instruction |\n",
|
|
"| ----:|:----------- |\n",
|
|
"| 1 | melt butter and mix it with carrot, pea and garlic clove. Then saute it. |\n",
|
|
"| 2 | cook rice, slice onion and mix it with oyster sauce and soy sauce and mix it together with the results of step 1. Then fry it. |\n",
|
|
"| 3 | whisk egg and mix it with sesame oil, pepper and salt and mix it together with the results of step 2. |\n"
|
|
],
|
|
"text/plain": [
|
|
"<IPython.core.display.Markdown object>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
}
|
|
],
|
|
"source": [
|
|
"# ingredients:\n",
|
|
"\n",
|
|
"d = ingredient_nodes([\n",
|
|
" \"butter\",\n",
|
|
" \"egg\",\n",
|
|
" \"pea\",\n",
|
|
" \"carrot\",\n",
|
|
" \"garlic clove\",\n",
|
|
" \"salt\",\n",
|
|
" \"pepper\",\n",
|
|
" \"rice\",\n",
|
|
" \"onion\",\n",
|
|
" \"soy sauce\",\n",
|
|
" \"oyster sauce\",\n",
|
|
" \"sesame oil\"\n",
|
|
"])\n",
|
|
"\n",
|
|
"# actions\n",
|
|
"\n",
|
|
"act(d, \"melt\", \"butter\")\n",
|
|
"act(d, \"whisk\", \"egg\")\n",
|
|
"act(d, \"cook\", \"rice\")\n",
|
|
"act(d, \"slice\", \"onion\")\n",
|
|
"mix(d, \"salt\", \"egg\")\n",
|
|
"mix(d, \"pepper\", \"egg\")\n",
|
|
"mix(d, \"butter\", \"garlic clove\")\n",
|
|
"mix (d, \"pea\", \"butter\")\n",
|
|
"mix (d, \"carrot\", \"butter\")\n",
|
|
"act(d, \"saute\", \"butter\")\n",
|
|
"mix (d, \"butter\", \"rice\")\n",
|
|
"mix (d, \"butter\", \"onion\")\n",
|
|
"mix (d, \"soy sauce\", \"butter\")\n",
|
|
"mix (d, \"oyster sauce\", \"butter\")\n",
|
|
"act(d, \"fry\", \"rice\")\n",
|
|
"\n",
|
|
"r = get_root(d)\n",
|
|
"\n",
|
|
"display(r.dot())\n",
|
|
"display(r.to_instruction().to_markdown())\n",
|
|
"with open(\"curated_rice_0.md\", \"w\") as f:\n",
|
|
" f.write(r.to_instruction().to_markdown().data)\n",
|
|
" f.close()"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {},
|
|
"source": [
|
|
"## Easy Lazy Day Lasagna\n",
|
|
"https://www.momontimeout.com/lazy-day-lasagna/?utm_campaign=yummly"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 10,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"image/svg+xml": [
|
|
"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\n",
|
|
"<!DOCTYPE svg PUBLIC \"-//W3C//DTD SVG 1.1//EN\"\n",
|
|
" \"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd\">\n",
|
|
"<!-- Generated by graphviz version 2.40.1 (20161225.0304)\n",
|
|
" -->\n",
|
|
"<!-- Title: %3 Pages: 1 -->\n",
|
|
"<svg width=\"804pt\" height=\"521pt\"\n",
|
|
" viewBox=\"0.00 0.00 803.85 520.74\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
|
|
"<g id=\"graph0\" class=\"graph\" transform=\"scale(1 1) rotate(0) translate(4 516.7351)\">\n",
|
|
"<title>%3</title>\n",
|
|
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-516.7351 799.8528,-516.7351 799.8528,4 -4,4\"/>\n",
|
|
"<!-- 97 -->\n",
|
|
"<g id=\"node1\" class=\"node\">\n",
|
|
"<title>97</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"326\" cy=\"-487.2792\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"310\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"314\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">bake</text>\n",
|
|
"<text text-anchor=\"start\" x=\"274\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 96 -->\n",
|
|
"<g id=\"node2\" class=\"node\">\n",
|
|
"<title>96</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"326,-425.8234 206,-389.8234 326,-353.8234 446,-389.8234 326,-425.8234\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"312.5\" y=\"-393.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"316.5\" y=\"-393.6234\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"274\" y=\"-379.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.9286</text>\n",
|
|
"</g>\n",
|
|
"<!-- 97->96 -->\n",
|
|
"<g id=\"edge1\" class=\"edge\">\n",
|
|
"<title>97->96</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M326,-461.6738C326,-453.8102 326,-444.9007 326,-436.0982\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"329.5001,-435.883 326,-425.883 322.5001,-435.883 329.5001,-435.883\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 88 -->\n",
|
|
"<g id=\"node3\" class=\"node\">\n",
|
|
"<title>88</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"116,-310.3675 0,-310.3675 0,-274.3675 116,-274.3675 116,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"16.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"20.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">ricotta cheese</text>\n",
|
|
"<text text-anchor=\"start\" x=\"8\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 96->88 -->\n",
|
|
"<g id=\"edge2\" class=\"edge\">\n",
|
|
"<title>96->88</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M270.4417,-370.2433C230.0279,-355.9222 174.0324,-335.918 125,-317.8234 121.5891,-316.5646 118.084,-315.2616 114.5506,-313.9408\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"115.7691,-310.6598 105.1769,-310.4213 113.3085,-317.2131 115.7691,-310.6598\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 86 -->\n",
|
|
"<g id=\"node4\" class=\"node\">\n",
|
|
"<title>86</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"250,-310.3675 134,-310.3675 134,-274.3675 250,-274.3675 250,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"156.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"160.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">pasta sauce</text>\n",
|
|
"<text text-anchor=\"start\" x=\"142\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 96->86 -->\n",
|
|
"<g id=\"edge3\" class=\"edge\">\n",
|
|
"<title>96->86</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M290.7931,-364.218C270.4381,-349.4142 244.9865,-330.9037 225.0148,-316.3786\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"226.9678,-313.4712 216.8218,-310.42 222.8505,-319.1324 226.9678,-313.4712\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 84 -->\n",
|
|
"<g id=\"node5\" class=\"node\">\n",
|
|
"<title>84</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"384,-310.3675 268,-310.3675 268,-274.3675 384,-274.3675 384,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"304.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"308.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">noodle</text>\n",
|
|
"<text text-anchor=\"start\" x=\"276\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 96->84 -->\n",
|
|
"<g id=\"edge4\" class=\"edge\">\n",
|
|
"<title>96->84</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M326,-353.8113C326,-342.8653 326,-330.9988 326,-320.6395\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"329.5001,-320.4912 326,-310.4912 322.5001,-320.4912 329.5001,-320.4912\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 89 -->\n",
|
|
"<g id=\"node6\" class=\"node\">\n",
|
|
"<title>89</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"527.5,-310.3675 402.5,-310.3675 402.5,-274.3675 527.5,-274.3675 527.5,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"410.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"414.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mozzarella cheese</text>\n",
|
|
"<text text-anchor=\"start\" x=\"415\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 96->89 -->\n",
|
|
"<g id=\"edge5\" class=\"edge\">\n",
|
|
"<title>96->89</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M362.1578,-364.4724C383.3674,-349.6019 410.0064,-330.9247 430.8578,-316.3054\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"432.9387,-319.121 439.1174,-310.5144 428.9201,-313.3894 432.9387,-319.121\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 93 -->\n",
|
|
"<g id=\"node7\" class=\"node\">\n",
|
|
"<title>93</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"630\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"605\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"609\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">simmer</text>\n",
|
|
"<text text-anchor=\"start\" x=\"578\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 96->93 -->\n",
|
|
"<g id=\"edge6\" class=\"edge\">\n",
|
|
"<title>96->93</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M384.2546,-371.1482C435.0555,-354.8625 508.777,-331.229 562.2113,-314.0991\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"563.4884,-317.3653 571.9425,-310.9795 561.3514,-310.6994 563.4884,-317.3653\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 92 -->\n",
|
|
"<g id=\"node8\" class=\"node\">\n",
|
|
"<title>92</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"630,-230.9117 510,-194.9117 630,-158.9117 750,-194.9117 630,-230.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"616.5\" y=\"-198.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"620.5\" y=\"-198.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"578\" y=\"-184.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 93->92 -->\n",
|
|
"<g id=\"edge7\" class=\"edge\">\n",
|
|
"<title>93->92</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M630,-266.7622C630,-258.8985 630,-249.989 630,-241.1865\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"633.5001,-240.9713 630,-230.9713 626.5001,-240.9714 633.5001,-240.9713\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 87 -->\n",
|
|
"<g id=\"node9\" class=\"node\">\n",
|
|
"<title>87</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"608,-115.4558 492,-115.4558 492,-79.4558 608,-79.4558 608,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"531\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"535\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">water</text>\n",
|
|
"<text text-anchor=\"start\" x=\"500\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 92->87 -->\n",
|
|
"<g id=\"edge8\" class=\"edge\">\n",
|
|
"<title>92->87</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M606.214,-165.9356C595.1528,-152.4609 582.1004,-136.5605 571.3584,-123.4746\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"574.0572,-121.246 565.007,-115.7374 568.6467,-125.6875 574.0572,-121.246\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 91 -->\n",
|
|
"<g id=\"node10\" class=\"node\">\n",
|
|
"<title>91</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"711\" cy=\"-97.4558\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"690\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"694\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">brown</text>\n",
|
|
"<text text-anchor=\"start\" x=\"659\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 92->91 -->\n",
|
|
"<g id=\"edge9\" class=\"edge\">\n",
|
|
"<title>92->91</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M654.0834,-165.9356C663.4801,-154.6298 674.2961,-141.6164 683.9589,-129.9906\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"686.7324,-132.1293 690.4326,-122.2016 681.349,-127.655 686.7324,-132.1293\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 85 -->\n",
|
|
"<g id=\"node11\" class=\"node\">\n",
|
|
"<title>85</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"769,-36 653,-36 653,0 769,0 769,-36\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"674\" y=\"-21.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"678\" y=\"-21.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">ground beef</text>\n",
|
|
"<text text-anchor=\"start\" x=\"661\" y=\"-7.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 91->85 -->\n",
|
|
"<g id=\"edge10\" class=\"edge\">\n",
|
|
"<title>91->85</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M711,-71.8782C711,-63.7122 711,-54.6289 711,-46.2824\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"714.5001,-46.2287 711,-36.2288 707.5001,-46.2288 714.5001,-46.2287\"/>\n",
|
|
"</g>\n",
|
|
"</g>\n",
|
|
"</svg>\n"
|
|
],
|
|
"text/plain": [
|
|
"<graphviz.dot.Digraph at 0x7f86ddd1ac90>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
},
|
|
{
|
|
"data": {
|
|
"text/markdown": [
|
|
"**Ingredients**:\n",
|
|
" * water\n",
|
|
" * mozzarella cheese\n",
|
|
" * pasta sauce\n",
|
|
" * ground beef\n",
|
|
" * ricotta cheese\n",
|
|
" * noodle\n",
|
|
"\n",
|
|
"\n",
|
|
"**Instructions**:\n",
|
|
"\n",
|
|
"| Step | Instruction |\n",
|
|
"| ----:|:----------- |\n",
|
|
"| 1 | brown ground beef and mix it with water. Then simmer it. |\n",
|
|
"| 2 | Mix ricotta cheese, pasta sauce, noodle and mozzarella cheese and mix it together with the results of step 1. Then bake it. |\n"
|
|
],
|
|
"text/plain": [
|
|
"<IPython.core.display.Markdown object>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
}
|
|
],
|
|
"source": [
|
|
"\n",
|
|
"d = ingredient_nodes([\n",
|
|
" \"noodle\",\n",
|
|
" \"ground beef\",\n",
|
|
" \"pasta sauce\",\n",
|
|
" \"water\",\n",
|
|
" \"ricotta cheese\",\n",
|
|
" \"mozzarella cheese\"\n",
|
|
"])\n",
|
|
"\n",
|
|
"# actions\n",
|
|
"\n",
|
|
"mix (d, \"noodle\", \"pasta sauce\")\n",
|
|
"act(d, \"brown\", \"ground beef\")\n",
|
|
"mix (d, \"water\", \"ground beef\")\n",
|
|
"act(d, \"simmer\", \"ground beef\")\n",
|
|
"mix (d, \"noodle\", \"ricotta cheese\")\n",
|
|
"mix (d, \"noodle\", \"mozzarella cheese\")\n",
|
|
"mix (d, \"noodle\", \"ground beef\")\n",
|
|
"act(d, \"bake\", \"noodle\")\n",
|
|
"\n",
|
|
"r = get_root(d)\n",
|
|
"\n",
|
|
"display(r.dot())\n",
|
|
"display(r.to_instruction().to_markdown())\n",
|
|
"with open(\"curated_noodle_0.md\", \"w\") as f:\n",
|
|
" f.write(r.to_instruction().to_markdown().data)\n",
|
|
" f.close()"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {},
|
|
"source": [
|
|
"## Firecracker Chicken\n",
|
|
"https://www.melskitchencafe.com/firecracker-chicken/?utm_campaign=yummly"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 11,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"image/svg+xml": [
|
|
"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\n",
|
|
"<!DOCTYPE svg PUBLIC \"-//W3C//DTD SVG 1.1//EN\"\n",
|
|
" \"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd\">\n",
|
|
"<!-- Generated by graphviz version 2.40.1 (20161225.0304)\n",
|
|
" -->\n",
|
|
"<!-- Title: %3 Pages: 1 -->\n",
|
|
"<svg width=\"956pt\" height=\"716pt\"\n",
|
|
" viewBox=\"0.00 0.00 956.00 715.65\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
|
|
"<g id=\"graph0\" class=\"graph\" transform=\"scale(1 1) rotate(0) translate(4 711.6468)\">\n",
|
|
"<title>%3</title>\n",
|
|
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-711.6468 952,-711.6468 952,4 -4,4\"/>\n",
|
|
"<!-- 125 -->\n",
|
|
"<g id=\"node1\" class=\"node\">\n",
|
|
"<title>125</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"560,-707.6468 440,-671.6468 560,-635.6468 680,-671.6468 560,-707.6468\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"546.5\" y=\"-675.4468\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"550.5\" y=\"-675.4468\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"508\" y=\"-661.4468\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.7778</text>\n",
|
|
"</g>\n",
|
|
"<!-- 122 -->\n",
|
|
"<g id=\"node2\" class=\"node\">\n",
|
|
"<title>122</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"290\" cy=\"-574.1909\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"274\" y=\"-577.9909\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"278\" y=\"-577.9909\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">bake</text>\n",
|
|
"<text text-anchor=\"start\" x=\"238\" y=\"-563.9909\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 125->122 -->\n",
|
|
"<g id=\"edge1\" class=\"edge\">\n",
|
|
"<title>125->122</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M505.3615,-651.9251C461.6284,-636.1398 400.2051,-613.9692 354.1417,-597.3427\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"355.1516,-593.9863 344.5573,-593.8832 352.775,-600.5705 355.1516,-593.9863\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 123 -->\n",
|
|
"<g id=\"node18\" class=\"node\">\n",
|
|
"<title>123</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"480\" cy=\"-574.1909\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"460.5\" y=\"-577.9909\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"464.5\" y=\"-577.9909\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">steam</text>\n",
|
|
"<text text-anchor=\"start\" x=\"428\" y=\"-563.9909\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 125->123 -->\n",
|
|
"<g id=\"edge17\" class=\"edge\">\n",
|
|
"<title>125->123</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M536.214,-642.6706C526.9332,-631.3649 516.2507,-618.3515 506.7073,-606.7256\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"509.3636,-604.4453 500.3134,-598.9367 503.9531,-608.8868 509.3636,-604.4453\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 100 -->\n",
|
|
"<g id=\"node20\" class=\"node\">\n",
|
|
"<title>100</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"699,-592.1909 583,-592.1909 583,-556.1909 699,-556.1909 699,-592.1909\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"622\" y=\"-577.9909\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"626\" y=\"-577.9909\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">water</text>\n",
|
|
"<text text-anchor=\"start\" x=\"591\" y=\"-563.9909\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 125->100 -->\n",
|
|
"<g id=\"edge19\" class=\"edge\">\n",
|
|
"<title>125->100</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M584.0834,-642.6706C595.2828,-629.1959 608.4983,-613.2956 619.3746,-600.2097\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"622.1051,-602.4001 625.8054,-592.4725 616.7218,-597.9258 622.1051,-602.4001\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 101 -->\n",
|
|
"<g id=\"node21\" class=\"node\">\n",
|
|
"<title>101</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"833,-592.1909 717,-592.1909 717,-556.1909 833,-556.1909 833,-592.1909\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"734.5\" y=\"-577.9909\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"738.5\" y=\"-577.9909\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cider vinegar</text>\n",
|
|
"<text text-anchor=\"start\" x=\"725\" y=\"-563.9909\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 125->101 -->\n",
|
|
"<g id=\"edge20\" class=\"edge\">\n",
|
|
"<title>125->101</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M607.9826,-649.8971C643.0876,-633.9846 690.5575,-612.4673 725.9172,-596.4393\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"727.4261,-599.5982 735.0891,-592.2819 724.5361,-593.2226 727.4261,-599.5982\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 121 -->\n",
|
|
"<g id=\"node3\" class=\"node\">\n",
|
|
"<title>121</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"286,-512.7351 166,-476.7351 286,-440.7351 406,-476.7351 286,-512.7351\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"272.5\" y=\"-480.5351\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"276.5\" y=\"-480.5351\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"234\" y=\"-466.5351\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.6923</text>\n",
|
|
"</g>\n",
|
|
"<!-- 122->121 -->\n",
|
|
"<g id=\"edge2\" class=\"edge\">\n",
|
|
"<title>122->121</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M288.949,-548.5855C288.6194,-540.5545 288.245,-531.4325 287.8762,-522.4478\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"291.3722,-522.2755 287.465,-512.4275 284.3781,-522.5626 291.3722,-522.2755\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 99 -->\n",
|
|
"<g id=\"node4\" class=\"node\">\n",
|
|
"<title>99</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"210,-397.2792 94,-397.2792 94,-361.2792 210,-361.2792 210,-397.2792\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"133.5\" y=\"-383.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"137.5\" y=\"-383.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">sugar</text>\n",
|
|
"<text text-anchor=\"start\" x=\"102\" y=\"-369.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 121->99 -->\n",
|
|
"<g id=\"edge3\" class=\"edge\">\n",
|
|
"<title>121->99</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M250.7931,-451.1297C230.4381,-436.3259 204.9865,-417.8154 185.0148,-403.2903\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"186.9678,-400.3829 176.8218,-397.3317 182.8505,-406.0441 186.9678,-400.3829\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 98 -->\n",
|
|
"<g id=\"node5\" class=\"node\">\n",
|
|
"<title>98</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"344,-397.2792 228,-397.2792 228,-361.2792 344,-361.2792 344,-397.2792\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"256.5\" y=\"-383.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"260.5\" y=\"-383.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">hot sauce</text>\n",
|
|
"<text text-anchor=\"start\" x=\"236\" y=\"-369.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 121->98 -->\n",
|
|
"<g id=\"edge4\" class=\"edge\">\n",
|
|
"<title>121->98</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M286,-440.723C286,-429.777 286,-417.9105 286,-407.5511\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"289.5001,-407.4029 286,-397.4029 282.5001,-407.4029 289.5001,-407.4029\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 119 -->\n",
|
|
"<g id=\"node6\" class=\"node\">\n",
|
|
"<title>119</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"447\" cy=\"-379.2792\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"431\" y=\"-383.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"435\" y=\"-383.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cook</text>\n",
|
|
"<text text-anchor=\"start\" x=\"395\" y=\"-369.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.6667</text>\n",
|
|
"</g>\n",
|
|
"<!-- 121->119 -->\n",
|
|
"<g id=\"edge5\" class=\"edge\">\n",
|
|
"<title>121->119</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M325.7978,-452.6449C348.4219,-438.9501 376.8668,-421.732 400.5136,-407.4182\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"402.577,-410.2605 409.3194,-402.0879 398.9521,-404.2721 402.577,-410.2605\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 118 -->\n",
|
|
"<g id=\"node7\" class=\"node\">\n",
|
|
"<title>118</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"447,-317.8234 327,-281.8234 447,-245.8234 567,-281.8234 447,-317.8234\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"433.5\" y=\"-285.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"437.5\" y=\"-285.6234\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"395\" y=\"-271.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.7333</text>\n",
|
|
"</g>\n",
|
|
"<!-- 119->118 -->\n",
|
|
"<g id=\"edge6\" class=\"edge\">\n",
|
|
"<title>119->118</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M447,-353.6738C447,-345.8102 447,-336.9007 447,-328.0982\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"450.5001,-327.883 447,-317.883 443.5001,-327.883 450.5001,-327.883\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 107 -->\n",
|
|
"<g id=\"node8\" class=\"node\">\n",
|
|
"<title>107</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"116,-202.3675 0,-202.3675 0,-166.3675 116,-166.3675 116,-202.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"27.5\" y=\"-188.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"31.5\" y=\"-188.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cornstach</text>\n",
|
|
"<text text-anchor=\"start\" x=\"8\" y=\"-174.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 118->107 -->\n",
|
|
"<g id=\"edge7\" class=\"edge\">\n",
|
|
"<title>118->107</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M372.0416,-268.2207C306.2772,-255.5401 208.3964,-234.8497 125,-209.8234 120.9106,-208.5962 116.7138,-207.2407 112.5118,-205.8132\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"113.3407,-202.3947 102.7459,-202.3787 111.0183,-208.9982 113.3407,-202.3947\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 105 -->\n",
|
|
"<g id=\"node9\" class=\"node\">\n",
|
|
"<title>105</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"250,-202.3675 134,-202.3675 134,-166.3675 250,-166.3675 250,-202.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"179.5\" y=\"-188.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"183.5\" y=\"-188.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">salt</text>\n",
|
|
"<text text-anchor=\"start\" x=\"142\" y=\"-174.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 118->105 -->\n",
|
|
"<g id=\"edge8\" class=\"edge\">\n",
|
|
"<title>118->105</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M394.1638,-261.6305C351.7136,-245.4068 292.2141,-222.6673 248.7571,-206.0589\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"249.7773,-202.702 239.1867,-202.4013 247.2782,-209.2407 249.7773,-202.702\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 112 -->\n",
|
|
"<g id=\"node10\" class=\"node\">\n",
|
|
"<title>112</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"353\" cy=\"-184.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"341.5\" y=\"-188.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"345.5\" y=\"-188.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cut</text>\n",
|
|
"<text text-anchor=\"start\" x=\"301\" y=\"-174.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 118->112 -->\n",
|
|
"<g id=\"edge9\" class=\"edge\">\n",
|
|
"<title>118->112</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M420.0634,-253.8964C408.7417,-242.1586 395.508,-228.4383 383.8017,-216.3016\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"386.2025,-213.7491 376.741,-208.9814 381.1642,-218.6088 386.2025,-213.7491\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 117 -->\n",
|
|
"<g id=\"node12\" class=\"node\">\n",
|
|
"<title>117</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"541\" cy=\"-184.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"526.5\" y=\"-188.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"530.5\" y=\"-188.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">heat</text>\n",
|
|
"<text text-anchor=\"start\" x=\"489\" y=\"-174.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 118->117 -->\n",
|
|
"<g id=\"edge11\" class=\"edge\">\n",
|
|
"<title>118->117</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M473.9366,-253.8964C485.2583,-242.1586 498.492,-228.4383 510.1983,-216.3016\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"512.8358,-218.6088 517.259,-208.9814 507.7975,-213.7491 512.8358,-218.6088\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 111 -->\n",
|
|
"<g id=\"node14\" class=\"node\">\n",
|
|
"<title>111</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"729\" cy=\"-184.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"710\" y=\"-188.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"714\" y=\"-188.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">whisk</text>\n",
|
|
"<text text-anchor=\"start\" x=\"677\" y=\"-174.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 118->111 -->\n",
|
|
"<g id=\"edge13\" class=\"edge\">\n",
|
|
"<title>118->111</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M503.0513,-262.4527C549.281,-246.4763 614.9347,-223.7871 663.5663,-206.9807\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"664.7465,-210.276 673.0548,-203.7015 662.4601,-203.6599 664.7465,-210.276\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 106 -->\n",
|
|
"<g id=\"node17\" class=\"node\">\n",
|
|
"<title>106</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"948,-202.3675 832,-202.3675 832,-166.3675 948,-166.3675 948,-202.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"867.5\" y=\"-188.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"871.5\" y=\"-188.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">pepper</text>\n",
|
|
"<text text-anchor=\"start\" x=\"840\" y=\"-174.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 118->106 -->\n",
|
|
"<g id=\"edge16\" class=\"edge\">\n",
|
|
"<title>118->106</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M529.0017,-270.3316C605.8206,-258.5792 723.4045,-238.0474 823,-209.8234 827.2911,-208.6073 831.6941,-207.2328 836.0935,-205.7679\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"837.374,-209.0284 845.6739,-202.4434 835.0791,-202.4153 837.374,-209.0284\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 104 -->\n",
|
|
"<g id=\"node11\" class=\"node\">\n",
|
|
"<title>104</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"411,-115.4558 295,-115.4558 295,-79.4558 411,-79.4558 411,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"308.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"312.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">chicken breast</text>\n",
|
|
"<text text-anchor=\"start\" x=\"303\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 112->104 -->\n",
|
|
"<g id=\"edge10\" class=\"edge\">\n",
|
|
"<title>112->104</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M353,-158.7612C353,-148.3964 353,-136.3917 353,-125.7674\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"356.5001,-125.7151 353,-115.7151 349.5001,-125.7151 356.5001,-125.7151\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 103 -->\n",
|
|
"<g id=\"node13\" class=\"node\">\n",
|
|
"<title>103</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"599,-115.4558 483,-115.4558 483,-79.4558 599,-79.4558 599,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"511\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"515\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">canola oil</text>\n",
|
|
"<text text-anchor=\"start\" x=\"491\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 117->103 -->\n",
|
|
"<g id=\"edge12\" class=\"edge\">\n",
|
|
"<title>117->103</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M541,-158.7612C541,-148.3964 541,-136.3917 541,-125.7674\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"544.5001,-125.7151 541,-115.7151 537.5001,-125.7151 544.5001,-125.7151\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 110 -->\n",
|
|
"<g id=\"node15\" class=\"node\">\n",
|
|
"<title>110</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"729\" cy=\"-97.4558\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"714.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"718.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">beat</text>\n",
|
|
"<text text-anchor=\"start\" x=\"677\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 111->110 -->\n",
|
|
"<g id=\"edge14\" class=\"edge\">\n",
|
|
"<title>111->110</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M729,-158.7612C729,-150.7873 729,-141.8428 729,-133.303\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"732.5001,-133.1794 729,-123.1795 725.5001,-133.1795 732.5001,-133.1794\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 108 -->\n",
|
|
"<g id=\"node16\" class=\"node\">\n",
|
|
"<title>108</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"787,-36 671,-36 671,0 787,0 787,-36\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"717\" y=\"-21.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"721\" y=\"-21.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">egg</text>\n",
|
|
"<text text-anchor=\"start\" x=\"679\" y=\"-7.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 110->108 -->\n",
|
|
"<g id=\"edge15\" class=\"edge\">\n",
|
|
"<title>110->108</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M729,-71.8782C729,-63.7122 729,-54.6289 729,-46.2824\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"732.5001,-46.2287 729,-36.2288 725.5001,-46.2288 732.5001,-46.2287\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 109 -->\n",
|
|
"<g id=\"node19\" class=\"node\">\n",
|
|
"<title>109</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"540,-494.7351 424,-494.7351 424,-458.7351 540,-458.7351 540,-494.7351\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"469\" y=\"-480.5351\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"473\" y=\"-480.5351\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">rice</text>\n",
|
|
"<text text-anchor=\"start\" x=\"432\" y=\"-466.5351\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 123->109 -->\n",
|
|
"<g id=\"edge18\" class=\"edge\">\n",
|
|
"<title>123->109</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M480.5255,-548.5855C480.7994,-535.2357 481.1353,-518.8715 481.4172,-505.1339\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"484.9235,-504.8573 481.6295,-494.7875 477.925,-504.7136 484.9235,-504.8573\"/>\n",
|
|
"</g>\n",
|
|
"</g>\n",
|
|
"</svg>\n"
|
|
],
|
|
"text/plain": [
|
|
"<graphviz.dot.Digraph at 0x7f86de2315d0>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
},
|
|
{
|
|
"data": {
|
|
"text/markdown": [
|
|
"**Ingredients**:\n",
|
|
" * water\n",
|
|
" * cornstach\n",
|
|
" * canola oil\n",
|
|
" * sugar\n",
|
|
" * hot sauce\n",
|
|
" * cider vinegar\n",
|
|
" * chicken breast\n",
|
|
" * egg\n",
|
|
" * pepper\n",
|
|
" * rice\n",
|
|
" * salt\n",
|
|
"\n",
|
|
"\n",
|
|
"**Instructions**:\n",
|
|
"\n",
|
|
"| Step | Instruction |\n",
|
|
"| ----:|:----------- |\n",
|
|
"| 1 | beat and whisk egg |\n",
|
|
"| 2 | cut chicken breast, heat canola oil and mix it with cornstach, salt and pepper and mix it together with the results of step 1. Then cook it. |\n",
|
|
"| 3 | Mix sugar and hot sauce and mix it together with the results of step 2. Then bake it. |\n",
|
|
"| 4 | steam rice and mix it with water and cider vinegar and mix it together with the results of step 3. |\n"
|
|
],
|
|
"text/plain": [
|
|
"<IPython.core.display.Markdown object>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
}
|
|
],
|
|
"source": [
|
|
"\n",
|
|
"d = ingredient_nodes([\n",
|
|
" \"hot sauce\",\n",
|
|
" \"sugar\",\n",
|
|
" \"water\",\n",
|
|
" \"cider vinegar\",\n",
|
|
" \"salt\",\n",
|
|
" \"canola oil\",\n",
|
|
" \"chicken breast\",\n",
|
|
" \"salt\",\n",
|
|
" \"pepper\",\n",
|
|
" \"cornstach\",\n",
|
|
" \"egg\",\n",
|
|
" \"rice\"\n",
|
|
" \n",
|
|
"])\n",
|
|
"\n",
|
|
"# actions\n",
|
|
"\n",
|
|
"act(d, \"beat\", \"egg\")\n",
|
|
"act(d, \"whisk\", \"egg\")\n",
|
|
"act(d, \"cut\", \"chicken breast\")\n",
|
|
"mix(d, \"chicken breast\", \"salt\")\n",
|
|
"mix(d, \"chicken breast\", \"pepper\")\n",
|
|
"mix(d, \"cornstach\", \"chicken breast\")\n",
|
|
"\n",
|
|
"mix(d, \"chicken breast\", \"egg\")\n",
|
|
"\n",
|
|
"act(d, \"heat\", \"canola oil\")\n",
|
|
"\n",
|
|
"mix(d, \"chicken breast\", \"canola oil\")\n",
|
|
"\n",
|
|
"act(d, \"cook\", \"chicken breast\")\n",
|
|
"\n",
|
|
"mix(d, \"sugar\", \"hot sauce\")\n",
|
|
"mix(d, \"hot sauce\", \"chicken breast\")\n",
|
|
"act(d, \"bake\", \"chicken breast\")\n",
|
|
"\n",
|
|
"act(d, \"steam\", \"rice\")\n",
|
|
"mix(d, \"chicken breast\", \"rice\")\n",
|
|
"\n",
|
|
"r = get_root(d)\n",
|
|
"\n",
|
|
"display(r.dot())\n",
|
|
"display(r.to_instruction().to_markdown())\n",
|
|
"with open(\"curated_rice_1.md\", \"w\") as f:\n",
|
|
" f.write(r.to_instruction().to_markdown().data)\n",
|
|
" f.close()"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {},
|
|
"source": [
|
|
"## Italian Drunken Noodles\n",
|
|
"https://www.yummly.com/recipe/Italian-Drunken-Noodles-1835835#directions"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 12,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"image/svg+xml": [
|
|
"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\n",
|
|
"<!DOCTYPE svg PUBLIC \"-//W3C//DTD SVG 1.1//EN\"\n",
|
|
" \"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd\">\n",
|
|
"<!-- Generated by graphviz version 2.40.1 (20161225.0304)\n",
|
|
" -->\n",
|
|
"<!-- Title: %3 Pages: 1 -->\n",
|
|
"<svg width=\"1010pt\" height=\"629pt\"\n",
|
|
" viewBox=\"0.00 0.00 1009.85 628.74\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
|
|
"<g id=\"graph0\" class=\"graph\" transform=\"scale(1 1) rotate(0) translate(4 624.7351)\">\n",
|
|
"<title>%3</title>\n",
|
|
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-624.7351 1005.8528,-624.7351 1005.8528,4 -4,4\"/>\n",
|
|
"<!-- 151 -->\n",
|
|
"<g id=\"node1\" class=\"node\">\n",
|
|
"<title>151</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"322.8528,-620.7351 202.8528,-584.7351 322.8528,-548.7351 442.8528,-584.7351 322.8528,-620.7351\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"309.3528\" y=\"-588.5351\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"313.3528\" y=\"-588.5351\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"270.8528\" y=\"-574.5351\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.6667</text>\n",
|
|
"</g>\n",
|
|
"<!-- 150 -->\n",
|
|
"<g id=\"node2\" class=\"node\">\n",
|
|
"<title>150</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"91.8528\" cy=\"-487.2792\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"73.8528\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"77.8528\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">drain</text>\n",
|
|
"<text text-anchor=\"start\" x=\"39.8528\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 151->150 -->\n",
|
|
"<g id=\"edge1\" class=\"edge\">\n",
|
|
"<title>151->150</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M272.7293,-563.5886C236.7652,-548.4159 188.1917,-527.9233 150.4364,-511.9949\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"151.6591,-508.712 141.085,-508.0496 148.9381,-515.1615 151.6591,-508.712\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 133 -->\n",
|
|
"<g id=\"node5\" class=\"node\">\n",
|
|
"<title>133</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"313.8528,-505.2792 197.8528,-505.2792 197.8528,-469.2792 313.8528,-469.2792 313.8528,-505.2792\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"239.8528\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"243.8528\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">basil</text>\n",
|
|
"<text text-anchor=\"start\" x=\"205.8528\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 151->133 -->\n",
|
|
"<g id=\"edge4\" class=\"edge\">\n",
|
|
"<title>151->133</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M302.2039,-554.6999C293.2067,-541.6129 282.7518,-526.4055 274.0509,-513.7496\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"276.8964,-511.7104 268.347,-505.4528 271.1281,-515.6761 276.8964,-511.7104\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 132 -->\n",
|
|
"<g id=\"node6\" class=\"node\">\n",
|
|
"<title>132</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"447.8528,-505.2792 331.8528,-505.2792 331.8528,-469.2792 447.8528,-469.2792 447.8528,-505.2792\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"366.3528\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"370.3528\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">parsley</text>\n",
|
|
"<text text-anchor=\"start\" x=\"339.8528\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 151->132 -->\n",
|
|
"<g id=\"edge5\" class=\"edge\">\n",
|
|
"<title>151->132</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M343.5017,-554.6999C352.4989,-541.6129 362.9538,-526.4055 371.6547,-513.7496\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"374.5775,-515.6761 377.3587,-505.4528 368.8092,-511.7104 374.5775,-515.6761\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 146 -->\n",
|
|
"<g id=\"node7\" class=\"node\">\n",
|
|
"<title>146</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"552.8528\" cy=\"-487.2792\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"527.8528\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"531.8528\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">simmer</text>\n",
|
|
"<text text-anchor=\"start\" x=\"500.8528\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.8571</text>\n",
|
|
"</g>\n",
|
|
"<!-- 151->146 -->\n",
|
|
"<g id=\"edge6\" class=\"edge\">\n",
|
|
"<title>151->146</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M372.7594,-563.5886C408.4459,-548.4675 456.6021,-528.0627 494.1388,-512.1576\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"495.5972,-515.3409 503.4392,-508.2168 492.8662,-508.8956 495.5972,-515.3409\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 149 -->\n",
|
|
"<g id=\"node3\" class=\"node\">\n",
|
|
"<title>149</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"84.8528\" cy=\"-389.8234\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"68.8528\" y=\"-393.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"72.8528\" y=\"-393.6234\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cook</text>\n",
|
|
"<text text-anchor=\"start\" x=\"32.8528\" y=\"-379.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 150->149 -->\n",
|
|
"<g id=\"edge2\" class=\"edge\">\n",
|
|
"<title>150->149</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M90.0136,-461.6738C89.2241,-450.682 88.2878,-437.6467 87.4309,-425.7165\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"90.9115,-425.3196 86.704,-415.5961 83.9295,-425.8212 90.9115,-425.3196\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 134 -->\n",
|
|
"<g id=\"node4\" class=\"node\">\n",
|
|
"<title>134</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"129.8528,-310.3675 13.8528,-310.3675 13.8528,-274.3675 129.8528,-274.3675 129.8528,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"38.8528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"42.8528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">egg noodle</text>\n",
|
|
"<text text-anchor=\"start\" x=\"21.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 149->134 -->\n",
|
|
"<g id=\"edge3\" class=\"edge\">\n",
|
|
"<title>149->134</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M81.4372,-364.218C79.6388,-350.736 77.4303,-334.1796 75.5867,-320.3591\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"79.0525,-319.8694 74.2609,-310.42 72.1139,-320.795 79.0525,-319.8694\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 145 -->\n",
|
|
"<g id=\"node8\" class=\"node\">\n",
|
|
"<title>145</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"553.8528,-425.8234 433.8528,-389.8234 553.8528,-353.8234 673.8528,-389.8234 553.8528,-425.8234\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"540.3528\" y=\"-393.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"544.3528\" y=\"-393.6234\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"501.8528\" y=\"-379.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.8947</text>\n",
|
|
"</g>\n",
|
|
"<!-- 146->145 -->\n",
|
|
"<g id=\"edge7\" class=\"edge\">\n",
|
|
"<title>146->145</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M553.1156,-461.6738C553.1962,-453.8102 553.2877,-444.9007 553.378,-436.0982\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"556.8799,-435.9184 553.4828,-425.883 549.8803,-435.8465 556.8799,-435.9184\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 143 -->\n",
|
|
"<g id=\"node9\" class=\"node\">\n",
|
|
"<title>143</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"232.8528\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"218.8528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"222.8528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">dice</text>\n",
|
|
"<text text-anchor=\"start\" x=\"180.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 145->143 -->\n",
|
|
"<g id=\"edge8\" class=\"edge\">\n",
|
|
"<title>145->143</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M493.8517,-371.607C439.4738,-355.0978 359.3423,-330.7699 302.2309,-313.4308\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"303.1451,-310.0506 292.5595,-310.4945 301.1115,-316.7487 303.1451,-310.0506\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 130 -->\n",
|
|
"<g id=\"node11\" class=\"node\">\n",
|
|
"<title>130</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"451.8528,-310.3675 335.8528,-310.3675 335.8528,-274.3675 451.8528,-274.3675 451.8528,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"360.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"364.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">white wine</text>\n",
|
|
"<text text-anchor=\"start\" x=\"343.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 145->130 -->\n",
|
|
"<g id=\"edge10\" class=\"edge\">\n",
|
|
"<title>145->130</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M513.8908,-365.4825C488.9125,-350.2683 456.918,-330.7805 432.2424,-315.7506\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"433.8702,-312.644 423.5091,-310.4311 430.2288,-318.6223 433.8702,-312.644\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 140 -->\n",
|
|
"<g id=\"node12\" class=\"node\">\n",
|
|
"<title>140</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"554.8528\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"537.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"541.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">saute</text>\n",
|
|
"<text text-anchor=\"start\" x=\"502.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 145->140 -->\n",
|
|
"<g id=\"edge11\" class=\"edge\">\n",
|
|
"<title>145->140</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M554.2223,-353.8113C554.3084,-345.4239 554.4,-336.496 554.486,-328.1199\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"557.9881,-327.9228 554.591,-317.8874 550.9884,-327.8509 557.9881,-327.9228\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 129 -->\n",
|
|
"<g id=\"node17\" class=\"node\">\n",
|
|
"<title>129</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"773.8528,-310.3675 657.8528,-310.3675 657.8528,-274.3675 773.8528,-274.3675 773.8528,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"680.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"684.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">garlic clove</text>\n",
|
|
"<text text-anchor=\"start\" x=\"665.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 145->129 -->\n",
|
|
"<g id=\"edge16\" class=\"edge\">\n",
|
|
"<title>145->129</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M593.8978,-365.7332C619.2662,-350.472 651.9079,-330.8355 677.0365,-315.7186\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"679.1624,-318.5243 685.9271,-310.3702 675.5539,-312.526 679.1624,-318.5243\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 137 -->\n",
|
|
"<g id=\"node18\" class=\"node\">\n",
|
|
"<title>137</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"876.8528\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"862.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"866.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">heat</text>\n",
|
|
"<text text-anchor=\"start\" x=\"824.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 145->137 -->\n",
|
|
"<g id=\"edge17\" class=\"edge\">\n",
|
|
"<title>145->137</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M613.8497,-371.7211C668.6065,-355.1998 749.5432,-330.7795 807.1499,-313.3984\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"808.3412,-316.6948 816.9039,-310.4554 806.3192,-309.9932 808.3412,-316.6948\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 131 -->\n",
|
|
"<g id=\"node10\" class=\"node\">\n",
|
|
"<title>131</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"290.8528,-212.9117 174.8528,-212.9117 174.8528,-176.9117 290.8528,-176.9117 290.8528,-212.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"209.8528\" y=\"-198.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"213.8528\" y=\"-198.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">tomato</text>\n",
|
|
"<text text-anchor=\"start\" x=\"182.8528\" y=\"-184.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 143->131 -->\n",
|
|
"<g id=\"edge9\" class=\"edge\">\n",
|
|
"<title>143->131</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M232.8528,-266.7622C232.8528,-253.4123 232.8528,-237.0481 232.8528,-223.3105\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"236.3529,-222.9641 232.8528,-212.9642 229.3529,-222.9642 236.3529,-222.9641\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 139 -->\n",
|
|
"<g id=\"node13\" class=\"node\">\n",
|
|
"<title>139</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"554.8528,-230.9117 434.8528,-194.9117 554.8528,-158.9117 674.8528,-194.9117 554.8528,-230.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"541.3528\" y=\"-198.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"545.3528\" y=\"-198.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"502.8528\" y=\"-184.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 140->139 -->\n",
|
|
"<g id=\"edge12\" class=\"edge\">\n",
|
|
"<title>140->139</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M554.8528,-266.7622C554.8528,-258.8985 554.8528,-249.989 554.8528,-241.1865\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"558.3529,-240.9713 554.8528,-230.9713 551.3529,-240.9714 558.3529,-240.9713\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 127 -->\n",
|
|
"<g id=\"node14\" class=\"node\">\n",
|
|
"<title>127</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"498.8528,-115.4558 382.8528,-115.4558 382.8528,-79.4558 498.8528,-79.4558 498.8528,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"428.3528\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"432.3528\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">salt</text>\n",
|
|
"<text text-anchor=\"start\" x=\"390.8528\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 139->127 -->\n",
|
|
"<g id=\"edge13\" class=\"edge\">\n",
|
|
"<title>139->127</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M523.4,-168.0235C506.6355,-153.6918 486.1534,-136.1822 469.7859,-122.19\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"471.9911,-119.4706 462.1157,-115.633 467.4425,-124.7914 471.9911,-119.4706\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 138 -->\n",
|
|
"<g id=\"node15\" class=\"node\">\n",
|
|
"<title>138</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"601.8528\" cy=\"-97.4558\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"587.8528\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"591.8528\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">dice</text>\n",
|
|
"<text text-anchor=\"start\" x=\"549.8528\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 139->138 -->\n",
|
|
"<g id=\"edge14\" class=\"edge\">\n",
|
|
"<title>139->138</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M570.1124,-163.2706C574.9555,-153.2281 580.3334,-142.077 585.2653,-131.8505\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"588.4497,-133.3047 589.6412,-122.777 582.1447,-130.2639 588.4497,-133.3047\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 128 -->\n",
|
|
"<g id=\"node16\" class=\"node\">\n",
|
|
"<title>128</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"659.8528,-36 543.8528,-36 543.8528,0 659.8528,0 659.8528,-36\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"579.3528\" y=\"-21.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"583.3528\" y=\"-21.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">pepper</text>\n",
|
|
"<text text-anchor=\"start\" x=\"551.8528\" y=\"-7.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 138->128 -->\n",
|
|
"<g id=\"edge15\" class=\"edge\">\n",
|
|
"<title>138->128</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M601.8528,-71.8782C601.8528,-63.7122 601.8528,-54.6289 601.8528,-46.2824\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"605.3529,-46.2287 601.8528,-36.2288 598.3529,-46.2288 605.3529,-46.2287\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 136 -->\n",
|
|
"<g id=\"node19\" class=\"node\">\n",
|
|
"<title>136</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"876.8528,-230.9117 756.8528,-194.9117 876.8528,-158.9117 996.8528,-194.9117 876.8528,-230.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"863.3528\" y=\"-198.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"867.3528\" y=\"-198.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"824.8528\" y=\"-184.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 137->136 -->\n",
|
|
"<g id=\"edge18\" class=\"edge\">\n",
|
|
"<title>137->136</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M876.8528,-266.7622C876.8528,-258.8985 876.8528,-249.989 876.8528,-241.1865\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"880.3529,-240.9713 876.8528,-230.9713 873.3529,-240.9714 880.3529,-240.9713\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 135 -->\n",
|
|
"<g id=\"node20\" class=\"node\">\n",
|
|
"<title>135</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"867.8528,-115.4558 751.8528,-115.4558 751.8528,-79.4558 867.8528,-79.4558 867.8528,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"784.8528\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"788.8528\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">olive oil</text>\n",
|
|
"<text text-anchor=\"start\" x=\"759.8528\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 136->135 -->\n",
|
|
"<g id=\"edge19\" class=\"edge\">\n",
|
|
"<title>136->135</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M856.2039,-164.8765C847.2067,-151.7895 836.7518,-136.5822 828.0509,-123.9262\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"830.8964,-121.887 822.347,-115.6294 825.1281,-125.8527 830.8964,-121.887\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 126 -->\n",
|
|
"<g id=\"node21\" class=\"node\">\n",
|
|
"<title>126</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"1001.8528,-115.4558 885.8528,-115.4558 885.8528,-79.4558 1001.8528,-79.4558 1001.8528,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"919.3528\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"923.3528\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">sausage</text>\n",
|
|
"<text text-anchor=\"start\" x=\"893.8528\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 136->126 -->\n",
|
|
"<g id=\"edge20\" class=\"edge\">\n",
|
|
"<title>136->126</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M897.5017,-164.8765C906.4989,-151.7895 916.9538,-136.5822 925.6547,-123.9262\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"928.5775,-125.8527 931.3587,-115.6294 922.8092,-121.887 928.5775,-125.8527\"/>\n",
|
|
"</g>\n",
|
|
"</g>\n",
|
|
"</svg>\n"
|
|
],
|
|
"text/plain": [
|
|
"<graphviz.dot.Digraph at 0x7f86ddd17050>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
},
|
|
{
|
|
"data": {
|
|
"text/markdown": [
|
|
"**Ingredients**:\n",
|
|
" * sausage\n",
|
|
" * egg noodle\n",
|
|
" * olive oil\n",
|
|
" * tomato\n",
|
|
" * parsley\n",
|
|
" * salt\n",
|
|
" * pepper\n",
|
|
" * basil\n",
|
|
" * garlic clove\n",
|
|
" * white wine\n",
|
|
"\n",
|
|
"\n",
|
|
"**Instructions**:\n",
|
|
"\n",
|
|
"| Step | Instruction |\n",
|
|
"| ----:|:----------- |\n",
|
|
"| 1 | cook and drain egg noodle |\n",
|
|
"| 2 | dice pepper and mix it with salt. Then saute it. |\n",
|
|
"| 3 | Mix olive oil and sausage. Then heat it. |\n",
|
|
"| 4 | dice tomato and mix it with white wine and garlic clove and mix it together with the results of step 2 and step 3. Then simmer it. |\n",
|
|
"| 5 | Mix basil and parsley and mix it together with the results of step 1 and step 4. |\n"
|
|
],
|
|
"text/plain": [
|
|
"<IPython.core.display.Markdown object>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
}
|
|
],
|
|
"source": [
|
|
"\n",
|
|
"d = ingredient_nodes([\n",
|
|
" \"sausage\",\n",
|
|
" \"salt\",\n",
|
|
" \"pepper\",\n",
|
|
" \"garlic clove\",\n",
|
|
" \"white wine\",\n",
|
|
" \"tomato\",\n",
|
|
" \"parsley\",\n",
|
|
" \"basil\",\n",
|
|
" \"egg noodle\",\n",
|
|
" \"olive oil\"\n",
|
|
"])\n",
|
|
"\n",
|
|
"# actions\n",
|
|
"\n",
|
|
"mix (d, \"olive oil\", \"sausage\")\n",
|
|
"act (d, \"heat\", \"sausage\")\n",
|
|
"act (d, \"dice\", \"pepper\")\n",
|
|
"mix (d, \"pepper\", \"salt\")\n",
|
|
"act (d, \"saute\", \"pepper\")\n",
|
|
"mix (d, \"pepper\", \"garlic clove\")\n",
|
|
"mix (d, \"white wine\", \"pepper\")\n",
|
|
"act (d, \"dice\", \"tomato\")\n",
|
|
"mix (d, \"tomato\", \"pepper\")\n",
|
|
"mix (d, \"sausage\", \"pepper\")\n",
|
|
"act (d, \"simmer\", \"sausage\")\n",
|
|
"mix (d, \"parsley\", \"pepper\")\n",
|
|
"mix (d, \"basil\", \"pepper\")\n",
|
|
"\n",
|
|
"act(d, \"cook\", \"egg noodle\")\n",
|
|
"act(d, \"drain\", \"egg noodle\")\n",
|
|
"\n",
|
|
"mix(d, \"egg noodle\", \"sausage\")\n",
|
|
"\n",
|
|
"r = get_root(d)\n",
|
|
"\n",
|
|
"display(r.dot())\n",
|
|
"display(r.to_instruction().to_markdown())\n",
|
|
"with open(\"curated_noodle_1.md\", \"w\") as f:\n",
|
|
" f.write(r.to_instruction().to_markdown().data)\n",
|
|
" f.close()"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {},
|
|
"source": [
|
|
"## Italian Pasta Salad\n",
|
|
"https://www.yummly.com/recipe/Italian-Pasta-Salad-9104504#directions"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 13,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"image/svg+xml": [
|
|
"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\n",
|
|
"<!DOCTYPE svg PUBLIC \"-//W3C//DTD SVG 1.1//EN\"\n",
|
|
" \"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd\">\n",
|
|
"<!-- Generated by graphviz version 2.40.1 (20161225.0304)\n",
|
|
" -->\n",
|
|
"<!-- Title: %3 Pages: 1 -->\n",
|
|
"<svg width=\"1144pt\" height=\"521pt\"\n",
|
|
" viewBox=\"0.00 0.00 1143.85 520.74\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
|
|
"<g id=\"graph0\" class=\"graph\" transform=\"scale(1 1) rotate(0) translate(4 516.7351)\">\n",
|
|
"<title>%3</title>\n",
|
|
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-516.7351 1139.8528,-516.7351 1139.8528,4 -4,4\"/>\n",
|
|
"<!-- 173 -->\n",
|
|
"<g id=\"node1\" class=\"node\">\n",
|
|
"<title>173</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"621.8528\" cy=\"-487.2792\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"588.3528\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"592.3528\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">refrigerate</text>\n",
|
|
"<text text-anchor=\"start\" x=\"569.8528\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.6250</text>\n",
|
|
"</g>\n",
|
|
"<!-- 172 -->\n",
|
|
"<g id=\"node2\" class=\"node\">\n",
|
|
"<title>172</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"621.8528,-425.8234 501.8528,-389.8234 621.8528,-353.8234 741.8528,-389.8234 621.8528,-425.8234\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"608.3528\" y=\"-393.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"612.3528\" y=\"-393.6234\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"569.8528\" y=\"-379.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.9630</text>\n",
|
|
"</g>\n",
|
|
"<!-- 173->172 -->\n",
|
|
"<g id=\"edge1\" class=\"edge\">\n",
|
|
"<title>173->172</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M621.8528,-461.6738C621.8528,-453.8102 621.8528,-444.9007 621.8528,-436.0982\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"625.3529,-435.883 621.8528,-425.883 618.3529,-435.883 625.3529,-435.883\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 162 -->\n",
|
|
"<g id=\"node3\" class=\"node\">\n",
|
|
"<title>162</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"84.8528\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"68.8528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"72.8528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">chop</text>\n",
|
|
"<text text-anchor=\"start\" x=\"32.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 172->162 -->\n",
|
|
"<g id=\"edge2\" class=\"edge\">\n",
|
|
"<title>172->162</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M538.0889,-378.8406C448.6476,-366.5013 302.996,-344.6461 178.8528,-317.8234 171.4988,-316.2344 163.8611,-314.4287 156.2606,-312.5296\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"156.8725,-309.0736 146.3173,-309.9896 155.1399,-315.8558 156.8725,-309.0736\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 163 -->\n",
|
|
"<g id=\"node6\" class=\"node\">\n",
|
|
"<title>163</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"272.8528\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"258.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"262.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">slice</text>\n",
|
|
"<text text-anchor=\"start\" x=\"220.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 172->163 -->\n",
|
|
"<g id=\"edge5\" class=\"edge\">\n",
|
|
"<title>172->163</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M559.4586,-372.4002C499.2528,-355.5882 408.1716,-330.1544 344.9062,-312.4879\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"345.5732,-309.0404 335.0003,-309.7218 343.6904,-315.7824 345.5732,-309.0404\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 166 -->\n",
|
|
"<g id=\"node8\" class=\"node\">\n",
|
|
"<title>166</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"460.8528\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"442.8528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"446.8528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">drain</text>\n",
|
|
"<text text-anchor=\"start\" x=\"408.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 172->166 -->\n",
|
|
"<g id=\"edge7\" class=\"edge\">\n",
|
|
"<title>172->166</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M582.0551,-365.7332C559.4309,-352.0384 530.986,-334.8203 507.3392,-320.5065\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"508.9007,-317.3604 498.5335,-315.1762 505.2758,-323.3488 508.9007,-317.3604\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 155 -->\n",
|
|
"<g id=\"node13\" class=\"node\">\n",
|
|
"<title>155</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"679.8528,-310.3675 563.8528,-310.3675 563.8528,-274.3675 679.8528,-274.3675 679.8528,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"601.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"605.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cheese</text>\n",
|
|
"<text text-anchor=\"start\" x=\"571.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 172->155 -->\n",
|
|
"<g id=\"edge12\" class=\"edge\">\n",
|
|
"<title>172->155</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M621.8528,-353.8113C621.8528,-342.8653 621.8528,-330.9988 621.8528,-320.6395\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"625.3529,-320.4912 621.8528,-310.4912 618.3529,-320.4912 625.3529,-320.4912\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 158 -->\n",
|
|
"<g id=\"node14\" class=\"node\">\n",
|
|
"<title>158</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"813.8528,-310.3675 697.8528,-310.3675 697.8528,-274.3675 813.8528,-274.3675 813.8528,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"729.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"733.3528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">dressing</text>\n",
|
|
"<text text-anchor=\"start\" x=\"705.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 172->158 -->\n",
|
|
"<g id=\"edge13\" class=\"edge\">\n",
|
|
"<title>172->158</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M657.0597,-364.218C677.4147,-349.4142 702.8663,-330.9037 722.838,-316.3786\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"725.0023,-319.1324 731.031,-310.42 720.885,-313.4712 725.0023,-319.1324\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 164 -->\n",
|
|
"<g id=\"node15\" class=\"node\">\n",
|
|
"<title>164</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"916.8528\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"902.8528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"906.8528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">dice</text>\n",
|
|
"<text text-anchor=\"start\" x=\"864.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 172->164 -->\n",
|
|
"<g id=\"edge14\" class=\"edge\">\n",
|
|
"<title>172->164</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M679.0816,-370.9174C728.0358,-354.7449 798.5458,-331.4513 850.0689,-314.4302\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"851.386,-317.6812 859.7833,-311.2209 849.1901,-311.0345 851.386,-317.6812\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 154 -->\n",
|
|
"<g id=\"node17\" class=\"node\">\n",
|
|
"<title>154</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"1135.8528,-310.3675 1019.8528,-310.3675 1019.8528,-274.3675 1135.8528,-274.3675 1135.8528,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"1054.8528\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"1058.8528\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">tomato</text>\n",
|
|
"<text text-anchor=\"start\" x=\"1027.8528\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 172->154 -->\n",
|
|
"<g id=\"edge16\" class=\"edge\">\n",
|
|
"<title>172->154</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M705.5582,-378.7848C785.0162,-367.2639 907.3481,-346.81 1010.8528,-317.8234 1015.1477,-316.6206 1019.5533,-315.2556 1023.9546,-313.7974\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"1025.2311,-317.0594 1033.5378,-310.4829 1022.943,-310.4438 1025.2311,-317.0594\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 161 -->\n",
|
|
"<g id=\"node4\" class=\"node\">\n",
|
|
"<title>161</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"84.8528\" cy=\"-205.4558\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"70.8528\" y=\"-209.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"74.8528\" y=\"-209.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">peel</text>\n",
|
|
"<text text-anchor=\"start\" x=\"32.8528\" y=\"-195.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 162->161 -->\n",
|
|
"<g id=\"edge3\" class=\"edge\">\n",
|
|
"<title>162->161</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M84.8528,-266.7612C84.8528,-258.7873 84.8528,-249.8428 84.8528,-241.303\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"88.3529,-241.1794 84.8528,-231.1795 81.3529,-241.1795 88.3529,-241.1794\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 153 -->\n",
|
|
"<g id=\"node5\" class=\"node\">\n",
|
|
"<title>153</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"142.8528,-126 26.8528,-126 26.8528,-90 142.8528,-90 142.8528,-126\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"53.3528\" y=\"-111.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"57.3528\" y=\"-111.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cucumber</text>\n",
|
|
"<text text-anchor=\"start\" x=\"34.8528\" y=\"-97.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 161->153 -->\n",
|
|
"<g id=\"edge4\" class=\"edge\">\n",
|
|
"<title>161->153</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M84.8528,-179.8505C84.8528,-166.5006 84.8528,-150.1364 84.8528,-136.3988\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"88.3529,-136.0524 84.8528,-126.0525 81.3529,-136.0525 88.3529,-136.0524\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 156 -->\n",
|
|
"<g id=\"node7\" class=\"node\">\n",
|
|
"<title>156</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"330.8528,-223.4558 214.8528,-223.4558 214.8528,-187.4558 330.8528,-187.4558 330.8528,-223.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"239.3528\" y=\"-209.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"243.3528\" y=\"-209.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">black olive</text>\n",
|
|
"<text text-anchor=\"start\" x=\"222.8528\" y=\"-195.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 163->156 -->\n",
|
|
"<g id=\"edge6\" class=\"edge\">\n",
|
|
"<title>163->156</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M272.8528,-266.7612C272.8528,-256.3964 272.8528,-244.3917 272.8528,-233.7674\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"276.3529,-233.7151 272.8528,-223.7151 269.3529,-233.7151 276.3529,-233.7151\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 165 -->\n",
|
|
"<g id=\"node9\" class=\"node\">\n",
|
|
"<title>165</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"460.8528\" cy=\"-205.4558\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"444.8528\" y=\"-209.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"448.8528\" y=\"-209.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cook</text>\n",
|
|
"<text text-anchor=\"start\" x=\"408.8528\" y=\"-195.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 166->165 -->\n",
|
|
"<g id=\"edge8\" class=\"edge\">\n",
|
|
"<title>166->165</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M460.8528,-266.7612C460.8528,-258.7873 460.8528,-249.8428 460.8528,-241.303\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"464.3529,-241.1794 460.8528,-231.1795 457.3529,-241.1795 464.3529,-241.1794\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 160 -->\n",
|
|
"<g id=\"node10\" class=\"node\">\n",
|
|
"<title>160</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"460.8528,-144 340.8528,-108 460.8528,-72 580.8528,-108 460.8528,-144\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"447.3528\" y=\"-111.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"451.3528\" y=\"-111.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"408.8528\" y=\"-97.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 165->160 -->\n",
|
|
"<g id=\"edge9\" class=\"edge\">\n",
|
|
"<title>165->160</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M460.8528,-179.8505C460.8528,-171.9868 460.8528,-163.0773 460.8528,-154.2748\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"464.3529,-154.0596 460.8528,-144.0596 457.3529,-154.0597 464.3529,-154.0596\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 152 -->\n",
|
|
"<g id=\"node11\" class=\"node\">\n",
|
|
"<title>152</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"451.8528,-36 335.8528,-36 335.8528,0 451.8528,0 451.8528,-36\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"376.3528\" y=\"-21.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"380.3528\" y=\"-21.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">pasta</text>\n",
|
|
"<text text-anchor=\"start\" x=\"343.8528\" y=\"-7.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 160->152 -->\n",
|
|
"<g id=\"edge10\" class=\"edge\">\n",
|
|
"<title>160->152</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M438.9145,-78.5306C430.7235,-67.5278 421.4815,-55.1131 413.5088,-44.4036\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"416.2104,-42.1713 407.4314,-36.2399 410.5954,-46.3513 416.2104,-42.1713\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 159 -->\n",
|
|
"<g id=\"node12\" class=\"node\">\n",
|
|
"<title>159</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"585.8528,-36 469.8528,-36 469.8528,0 585.8528,0 585.8528,-36\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"515.3528\" y=\"-21.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"519.3528\" y=\"-21.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">salt</text>\n",
|
|
"<text text-anchor=\"start\" x=\"477.8528\" y=\"-7.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 160->159 -->\n",
|
|
"<g id=\"edge11\" class=\"edge\">\n",
|
|
"<title>160->159</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M482.7911,-78.5306C490.9821,-67.5278 500.2242,-55.1131 508.1968,-44.4036\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"511.1102,-46.3513 514.2742,-36.2399 505.4952,-42.1713 511.1102,-46.3513\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 157 -->\n",
|
|
"<g id=\"node16\" class=\"node\">\n",
|
|
"<title>157</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"974.8528,-223.4558 858.8528,-223.4558 858.8528,-187.4558 974.8528,-187.4558 974.8528,-223.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"886.8528\" y=\"-209.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"890.8528\" y=\"-209.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">red onion</text>\n",
|
|
"<text text-anchor=\"start\" x=\"866.8528\" y=\"-195.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 164->157 -->\n",
|
|
"<g id=\"edge15\" class=\"edge\">\n",
|
|
"<title>164->157</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M916.8528,-266.7612C916.8528,-256.3964 916.8528,-244.3917 916.8528,-233.7674\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"920.3529,-233.7151 916.8528,-223.7151 913.3529,-233.7151 920.3529,-233.7151\"/>\n",
|
|
"</g>\n",
|
|
"</g>\n",
|
|
"</svg>\n"
|
|
],
|
|
"text/plain": [
|
|
"<graphviz.dot.Digraph at 0x7f86ddd1dd50>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
},
|
|
{
|
|
"data": {
|
|
"text/markdown": [
|
|
"**Ingredients**:\n",
|
|
" * dressing\n",
|
|
" * black olive\n",
|
|
" * tomato\n",
|
|
" * cheese\n",
|
|
" * red onion\n",
|
|
" * cucumber\n",
|
|
" * salt\n",
|
|
" * pasta\n",
|
|
"\n",
|
|
"\n",
|
|
"**Instructions**:\n",
|
|
"\n",
|
|
"| Step | Instruction |\n",
|
|
"| ----:|:----------- |\n",
|
|
"| 1 | peel and chop cucumber |\n",
|
|
"| 2 | Mix pasta and salt. Then cook it. |\n",
|
|
"| 3 | drain the result of step 2 |\n",
|
|
"| 4 | slice black olive, dice red onion and mix it with cheese, dressing and tomato and mix it together with the results of step 1 and step 3. Then refrigerate it. |\n"
|
|
],
|
|
"text/plain": [
|
|
"<IPython.core.display.Markdown object>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
}
|
|
],
|
|
"source": [
|
|
"\n",
|
|
"d = ingredient_nodes([\n",
|
|
" \"pasta\",\n",
|
|
" \"cucumber\",\n",
|
|
" \"tomato\",\n",
|
|
" \"cheese\",\n",
|
|
" \"black olive\",\n",
|
|
" \"red onion\",\n",
|
|
" \"dressing\",\n",
|
|
" \"salt\"\n",
|
|
"])\n",
|
|
"\n",
|
|
"# actions\n",
|
|
"\n",
|
|
"mix (d, \"salt\", \"pasta\")\n",
|
|
"act (d, \"peel\", \"cucumber\")\n",
|
|
"act (d, \"chop\", \"cucumber\")\n",
|
|
"act (d, \"slice\", \"black olive\")\n",
|
|
"act (d, \"dice\", \"red onion\")\n",
|
|
"act (d, \"cook\", \"pasta\")\n",
|
|
"act (d, \"drain\", \"pasta\")\n",
|
|
"mix (d, \"pasta\", \"cucumber\")\n",
|
|
"mix (d, \"pasta\", \"tomato\")\n",
|
|
"mix (d, \"pasta\", \"cheese\")\n",
|
|
"mix (d, \"pasta\", \"black olive\")\n",
|
|
"mix (d, \"pasta\", \"red onion\")\n",
|
|
"mix (d, \"pasta\", \"dressing\")\n",
|
|
"\n",
|
|
"act(d, \"refrigerate\", \"pasta\")\n",
|
|
"\n",
|
|
"r = get_root(d)\n",
|
|
"\n",
|
|
"display(r.dot())\n",
|
|
"display(r.to_instruction().to_markdown())\n",
|
|
"with open(\"curated_noodle_2.md\", \"w\") as f:\n",
|
|
" f.write(r.to_instruction().to_markdown().data)\n",
|
|
" f.close()"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {},
|
|
"source": [
|
|
"## Mexican Rice\n",
|
|
"https://www.homesicktexan.com/2008/06/with-beans-comes-rice.html"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 14,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"image/svg+xml": [
|
|
"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\n",
|
|
"<!DOCTYPE svg PUBLIC \"-//W3C//DTD SVG 1.1//EN\"\n",
|
|
" \"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd\">\n",
|
|
"<!-- Generated by graphviz version 2.40.1 (20161225.0304)\n",
|
|
" -->\n",
|
|
"<!-- Title: %3 Pages: 1 -->\n",
|
|
"<svg width=\"1147pt\" height=\"434pt\"\n",
|
|
" viewBox=\"0.00 0.00 1147.00 433.82\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
|
|
"<g id=\"graph0\" class=\"graph\" transform=\"scale(1 1) rotate(0) translate(4 429.8234)\">\n",
|
|
"<title>%3</title>\n",
|
|
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-429.8234 1143,-429.8234 1143,4 -4,4\"/>\n",
|
|
"<!-- 198 -->\n",
|
|
"<g id=\"node1\" class=\"node\">\n",
|
|
"<title>198</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"380,-425.8234 260,-389.8234 380,-353.8234 500,-389.8234 380,-425.8234\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"366.5\" y=\"-393.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"370.5\" y=\"-393.6234\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"328\" y=\"-379.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.9762</text>\n",
|
|
"</g>\n",
|
|
"<!-- 181 -->\n",
|
|
"<g id=\"node2\" class=\"node\">\n",
|
|
"<title>181</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"116,-310.3675 0,-310.3675 0,-274.3675 116,-274.3675 116,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"27\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"31\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">lime juice</text>\n",
|
|
"<text text-anchor=\"start\" x=\"8\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 198->181 -->\n",
|
|
"<g id=\"edge1\" class=\"edge\">\n",
|
|
"<title>198->181</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M315.0711,-373.1793C263.2505,-359.4909 188.9895,-338.9678 125,-317.8234 121.2525,-316.5851 117.405,-315.2628 113.54,-313.8964\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"114.5374,-310.5355 103.9431,-310.4318 112.1604,-317.1196 114.5374,-310.5355\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 186 -->\n",
|
|
"<g id=\"node3\" class=\"node\">\n",
|
|
"<title>186</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"219\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"203\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"207\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">chop</text>\n",
|
|
"<text text-anchor=\"start\" x=\"167\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 198->186 -->\n",
|
|
"<g id=\"edge2\" class=\"edge\">\n",
|
|
"<title>198->186</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M340.2022,-365.7332C317.5781,-352.0384 289.1332,-334.8203 265.4864,-320.5065\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"267.0479,-317.3604 256.6806,-315.1762 263.423,-323.3488 267.0479,-317.3604\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 184 -->\n",
|
|
"<g id=\"node5\" class=\"node\">\n",
|
|
"<title>184</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"438,-310.3675 322,-310.3675 322,-274.3675 438,-274.3675 438,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"367.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"371.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">salt</text>\n",
|
|
"<text text-anchor=\"start\" x=\"330\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 198->184 -->\n",
|
|
"<g id=\"edge4\" class=\"edge\">\n",
|
|
"<title>198->184</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M380,-353.8113C380,-342.8653 380,-330.9988 380,-320.6395\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"383.5001,-320.4912 380,-310.4912 376.5001,-320.4912 383.5001,-320.4912\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 194 -->\n",
|
|
"<g id=\"node6\" class=\"node\">\n",
|
|
"<title>194</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"541\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"525\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"529\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cook</text>\n",
|
|
"<text text-anchor=\"start\" x=\"489\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 198->194 -->\n",
|
|
"<g id=\"edge5\" class=\"edge\">\n",
|
|
"<title>198->194</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M419.7978,-365.7332C442.4219,-352.0384 470.8668,-334.8203 494.5136,-320.5065\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"496.577,-323.3488 503.3194,-315.1762 492.9521,-317.3604 496.577,-323.3488\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 189 -->\n",
|
|
"<g id=\"node14\" class=\"node\">\n",
|
|
"<title>189</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"838\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"825\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"829\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">boil</text>\n",
|
|
"<text text-anchor=\"start\" x=\"786\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 198->189 -->\n",
|
|
"<g id=\"edge13\" class=\"edge\">\n",
|
|
"<title>198->189</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M450.5588,-374.8095C533.794,-357.0982 671.805,-327.7314 758.6772,-309.2463\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"759.4347,-312.6635 768.4873,-307.1588 757.9778,-305.8168 759.4347,-312.6635\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 182 -->\n",
|
|
"<g id=\"node4\" class=\"node\">\n",
|
|
"<title>182</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"277,-212.9117 161,-212.9117 161,-176.9117 277,-176.9117 277,-212.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"194\" y=\"-198.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"198\" y=\"-198.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cilantro</text>\n",
|
|
"<text text-anchor=\"start\" x=\"169\" y=\"-184.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 186->182 -->\n",
|
|
"<g id=\"edge3\" class=\"edge\">\n",
|
|
"<title>186->182</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M219,-266.7622C219,-253.4123 219,-237.0481 219,-223.3105\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"222.5001,-222.9641 219,-212.9642 215.5001,-222.9642 222.5001,-222.9641\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 193 -->\n",
|
|
"<g id=\"node7\" class=\"node\">\n",
|
|
"<title>193</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"478,-230.9117 358,-194.9117 478,-158.9117 598,-194.9117 478,-230.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"464.5\" y=\"-198.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"468.5\" y=\"-198.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"426\" y=\"-184.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 194->193 -->\n",
|
|
"<g id=\"edge6\" class=\"edge\">\n",
|
|
"<title>194->193</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M524.7759,-267.2702C518.152,-257.0235 510.3389,-244.9374 503.0148,-233.6076\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"505.9054,-231.6319 497.5371,-225.134 500.0267,-235.4322 505.9054,-231.6319\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 179 -->\n",
|
|
"<g id=\"node8\" class=\"node\">\n",
|
|
"<title>179</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"147,-115.4558 31,-115.4558 31,-79.4558 147,-79.4558 147,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"53.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"57.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">garlic clove</text>\n",
|
|
"<text text-anchor=\"start\" x=\"39\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 193->179 -->\n",
|
|
"<g id=\"edge7\" class=\"edge\">\n",
|
|
"<title>193->179</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M403.0416,-181.309C337.2772,-168.6284 239.3964,-147.938 156,-122.9117 151.9106,-121.6845 147.7138,-120.329 143.5118,-118.9015\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"144.3407,-115.483 133.7459,-115.467 142.0183,-122.0865 144.3407,-115.483\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 185 -->\n",
|
|
"<g id=\"node9\" class=\"node\">\n",
|
|
"<title>185</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"250\" cy=\"-97.4558\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"236\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"240\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">dice</text>\n",
|
|
"<text text-anchor=\"start\" x=\"198\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 193->185 -->\n",
|
|
"<g id=\"edge8\" class=\"edge\">\n",
|
|
"<title>193->185</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M428.2462,-173.645C392.8542,-158.5171 345.1959,-138.1462 308.0638,-122.2745\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"309.435,-119.0544 298.8642,-118.3422 306.6837,-125.491 309.435,-119.0544\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 183 -->\n",
|
|
"<g id=\"node11\" class=\"node\">\n",
|
|
"<title>183</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"469,-115.4558 353,-115.4558 353,-79.4558 469,-79.4558 469,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"367.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"371.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">ground cumin</text>\n",
|
|
"<text text-anchor=\"start\" x=\"361\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 193->183 -->\n",
|
|
"<g id=\"edge10\" class=\"edge\">\n",
|
|
"<title>193->183</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M457.3511,-164.8765C448.3539,-151.7895 437.899,-136.5822 429.1981,-123.9262\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"432.0436,-121.887 423.4942,-115.6294 426.2753,-125.8527 432.0436,-121.887\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 177 -->\n",
|
|
"<g id=\"node12\" class=\"node\">\n",
|
|
"<title>177</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"603,-115.4558 487,-115.4558 487,-79.4558 603,-79.4558 603,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"520\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"524\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">olive oil</text>\n",
|
|
"<text text-anchor=\"start\" x=\"495\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 193->177 -->\n",
|
|
"<g id=\"edge11\" class=\"edge\">\n",
|
|
"<title>193->177</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M498.6489,-164.8765C507.6461,-151.7895 518.101,-136.5822 526.8019,-123.9262\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"529.7247,-125.8527 532.5058,-115.6294 523.9564,-121.887 529.7247,-125.8527\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 180 -->\n",
|
|
"<g id=\"node13\" class=\"node\">\n",
|
|
"<title>180</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"737,-115.4558 621,-115.4558 621,-79.4558 737,-79.4558 737,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"656\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"660\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">tomato</text>\n",
|
|
"<text text-anchor=\"start\" x=\"629\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 193->180 -->\n",
|
|
"<g id=\"edge12\" class=\"edge\">\n",
|
|
"<title>193->180</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M524.1135,-172.5533C556.6042,-156.8001 599.9474,-135.7849 632.5195,-119.9921\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"634.3585,-122.9903 641.8296,-115.4781 631.3045,-116.6916 634.3585,-122.9903\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 178 -->\n",
|
|
"<g id=\"node10\" class=\"node\">\n",
|
|
"<title>178</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"308,-36 192,-36 192,0 308,0 308,-36\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"231.5\" y=\"-21.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"235.5\" y=\"-21.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">onion</text>\n",
|
|
"<text text-anchor=\"start\" x=\"200\" y=\"-7.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 185->178 -->\n",
|
|
"<g id=\"edge9\" class=\"edge\">\n",
|
|
"<title>185->178</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M250,-71.8782C250,-63.7122 250,-54.6289 250,-46.2824\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"253.5001,-46.2287 250,-36.2288 246.5001,-46.2288 253.5001,-46.2287\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 188 -->\n",
|
|
"<g id=\"node15\" class=\"node\">\n",
|
|
"<title>188</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"880,-230.9117 760,-194.9117 880,-158.9117 1000,-194.9117 880,-230.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"866.5\" y=\"-198.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"870.5\" y=\"-198.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"828\" y=\"-184.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 189->188 -->\n",
|
|
"<g id=\"edge14\" class=\"edge\">\n",
|
|
"<title>189->188</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M848.9254,-267.0166C852.9449,-257.6898 857.6098,-246.8655 862.0837,-236.4842\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"865.3713,-237.6992 866.1148,-227.1305 858.9428,-234.9287 865.3713,-237.6992\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 175 -->\n",
|
|
"<g id=\"node16\" class=\"node\">\n",
|
|
"<title>175</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"871,-115.4558 755,-115.4558 755,-79.4558 871,-79.4558 871,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"770.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"774.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">chicken broth</text>\n",
|
|
"<text text-anchor=\"start\" x=\"763\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 188->175 -->\n",
|
|
"<g id=\"edge15\" class=\"edge\">\n",
|
|
"<title>188->175</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M859.3511,-164.8765C850.3539,-151.7895 839.899,-136.5822 831.1981,-123.9262\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"834.0436,-121.887 825.4942,-115.6294 828.2753,-125.8527 834.0436,-121.887\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 176 -->\n",
|
|
"<g id=\"node17\" class=\"node\">\n",
|
|
"<title>176</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"1005,-115.4558 889,-115.4558 889,-79.4558 1005,-79.4558 1005,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"926.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"930.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">butter</text>\n",
|
|
"<text text-anchor=\"start\" x=\"897\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 188->176 -->\n",
|
|
"<g id=\"edge16\" class=\"edge\">\n",
|
|
"<title>188->176</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M900.6489,-164.8765C909.6461,-151.7895 920.101,-136.5822 928.8019,-123.9262\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"931.7247,-125.8527 934.5058,-115.6294 925.9564,-121.887 931.7247,-125.8527\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 174 -->\n",
|
|
"<g id=\"node18\" class=\"node\">\n",
|
|
"<title>174</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"1139,-115.4558 1023,-115.4558 1023,-79.4558 1139,-79.4558 1139,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"1068\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"1072\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">rice</text>\n",
|
|
"<text text-anchor=\"start\" x=\"1031\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 188->174 -->\n",
|
|
"<g id=\"edge17\" class=\"edge\">\n",
|
|
"<title>188->174</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M926.1135,-172.5533C958.6042,-156.8001 1001.9474,-135.7849 1034.5195,-119.9921\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"1036.3585,-122.9903 1043.8296,-115.4781 1033.3045,-116.6916 1036.3585,-122.9903\"/>\n",
|
|
"</g>\n",
|
|
"</g>\n",
|
|
"</svg>\n"
|
|
],
|
|
"text/plain": [
|
|
"<graphviz.dot.Digraph at 0x7f86ddd34e90>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
},
|
|
{
|
|
"data": {
|
|
"text/markdown": [
|
|
"**Ingredients**:\n",
|
|
" * onion\n",
|
|
" * cilantro\n",
|
|
" * olive oil\n",
|
|
" * lime juice\n",
|
|
" * ground cumin\n",
|
|
" * tomato\n",
|
|
" * butter\n",
|
|
" * rice\n",
|
|
" * salt\n",
|
|
" * garlic clove\n",
|
|
" * chicken broth\n",
|
|
"\n",
|
|
"\n",
|
|
"**Instructions**:\n",
|
|
"\n",
|
|
"| Step | Instruction |\n",
|
|
"| ----:|:----------- |\n",
|
|
"| 1 | dice onion and mix it with garlic clove, ground cumin, olive oil and tomato. Then cook it. |\n",
|
|
"| 2 | Mix chicken broth, butter and rice. Then boil it. |\n",
|
|
"| 3 | chop cilantro and mix it with lime juice and salt and mix it together with the results of step 1 and step 2. |\n"
|
|
],
|
|
"text/plain": [
|
|
"<IPython.core.display.Markdown object>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
}
|
|
],
|
|
"source": [
|
|
"\n",
|
|
"d = ingredient_nodes([\n",
|
|
" \"rice\",\n",
|
|
" \"chicken broth\",\n",
|
|
" \"butter\",\n",
|
|
" \"olive oil\",\n",
|
|
" \"onion\",\n",
|
|
" \"garlic clove\",\n",
|
|
" \"tomato\",\n",
|
|
" \"lime juice\",\n",
|
|
" \"cilantro\",\n",
|
|
" \"ground cumin\",\n",
|
|
" \"salt\"\n",
|
|
"])\n",
|
|
"\n",
|
|
"# actions\n",
|
|
"\n",
|
|
"act(d, \"dice\", \"onion\")\n",
|
|
"act(d, \"chop\", \"cilantro\")\n",
|
|
"\n",
|
|
"mix (d, \"rice\", \"chicken broth\")\n",
|
|
"mix (d, \"rice\", \"butter\")\n",
|
|
"act (d, \"boil\", \"rice\")\n",
|
|
"\n",
|
|
"mix (d, \"olive oil\", \"onion\")\n",
|
|
"mix (d, \"garlic clove\", \"onion\")\n",
|
|
"mix (d, \"tomato\", \"onion\")\n",
|
|
"mix (d, \"ground cumin\", \"onion\")\n",
|
|
"act (d, \"cook\", \"onion\")\n",
|
|
"\n",
|
|
"mix (d, \"rice\", \"onion\")\n",
|
|
"mix (d, \"lime juice\", \"onion\")\n",
|
|
"mix (d, \"cilantro\", \"onion\")\n",
|
|
"\n",
|
|
"\n",
|
|
"r = get_root(d)\n",
|
|
"\n",
|
|
"display(r.dot())\n",
|
|
"display(r.to_instruction().to_markdown())\n",
|
|
"with open(\"curated_rice_2.md\", \"w\") as f:\n",
|
|
" f.write(r.to_instruction().to_markdown().data)\n",
|
|
" f.close()"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {},
|
|
"source": [
|
|
"## One Pot Cheesy Taco Pasta\n",
|
|
"http://www.motherthyme.com/2016/07/one-pot-cheesy-taco-pasta.html?utm_campaign=yummly"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 15,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"image/svg+xml": [
|
|
"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\n",
|
|
"<!DOCTYPE svg PUBLIC \"-//W3C//DTD SVG 1.1//EN\"\n",
|
|
" \"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd\">\n",
|
|
"<!-- Generated by graphviz version 2.40.1 (20161225.0304)\n",
|
|
" -->\n",
|
|
"<!-- Title: %3 Pages: 1 -->\n",
|
|
"<svg width=\"1014pt\" height=\"629pt\"\n",
|
|
" viewBox=\"0.00 0.00 1014.00 628.74\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
|
|
"<g id=\"graph0\" class=\"graph\" transform=\"scale(1 1) rotate(0) translate(4 624.7351)\">\n",
|
|
"<title>%3</title>\n",
|
|
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-624.7351 1010,-624.7351 1010,4 -4,4\"/>\n",
|
|
"<!-- 221 -->\n",
|
|
"<g id=\"node1\" class=\"node\">\n",
|
|
"<title>221</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"460,-620.7351 340,-584.7351 460,-548.7351 580,-584.7351 460,-620.7351\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"446.5\" y=\"-588.5351\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"450.5\" y=\"-588.5351\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"408\" y=\"-574.5351\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.7500</text>\n",
|
|
"</g>\n",
|
|
"<!-- 205 -->\n",
|
|
"<g id=\"node2\" class=\"node\">\n",
|
|
"<title>205</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"116,-505.2792 0,-505.2792 0,-469.2792 116,-469.2792 116,-505.2792\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"37.5\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"41.5\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cheese</text>\n",
|
|
"<text text-anchor=\"start\" x=\"8\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 221->205 -->\n",
|
|
"<g id=\"edge1\" class=\"edge\">\n",
|
|
"<title>221->205</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M383.3367,-571.6771C314.8954,-559.2134 212.2833,-538.5345 125,-512.7351 120.9055,-511.5248 116.705,-510.1817 112.5004,-508.763\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"113.3251,-505.3435 102.7303,-505.3428 111.0122,-511.9504 113.3251,-505.3435\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 210 -->\n",
|
|
"<g id=\"node3\" class=\"node\">\n",
|
|
"<title>210</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"219\" cy=\"-487.2792\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"203\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"207\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">chop</text>\n",
|
|
"<text text-anchor=\"start\" x=\"167\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 221->210 -->\n",
|
|
"<g id=\"edge2\" class=\"edge\">\n",
|
|
"<title>221->210</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M408.8901,-564.0672C370.8991,-548.7043 318.9488,-527.6966 278.9886,-511.5375\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"280.2053,-508.2542 269.6225,-507.75 277.581,-514.7437 280.2053,-508.2542\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 209 -->\n",
|
|
"<g id=\"node5\" class=\"node\">\n",
|
|
"<title>209</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"438,-505.2792 322,-505.2792 322,-469.2792 438,-469.2792 438,-505.2792\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"343.5\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"347.5\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">tortilla chip</text>\n",
|
|
"<text text-anchor=\"start\" x=\"330\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 221->209 -->\n",
|
|
"<g id=\"edge4\" class=\"edge\">\n",
|
|
"<title>221->209</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M436.214,-555.759C425.1528,-542.2843 412.1004,-526.3839 401.3584,-513.298\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"404.0572,-511.0694 395.007,-505.5608 398.6467,-515.5108 404.0572,-511.0694\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 211 -->\n",
|
|
"<g id=\"node6\" class=\"node\">\n",
|
|
"<title>211</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"541\" cy=\"-487.2792\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"525\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"529\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">chop</text>\n",
|
|
"<text text-anchor=\"start\" x=\"489\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 221->211 -->\n",
|
|
"<g id=\"edge5\" class=\"edge\">\n",
|
|
"<title>221->211</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M484.0834,-555.759C493.4801,-544.4532 504.2961,-531.4398 513.9589,-519.814\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"516.7324,-521.9527 520.4326,-512.025 511.349,-517.4783 516.7324,-521.9527\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 219 -->\n",
|
|
"<g id=\"node8\" class=\"node\">\n",
|
|
"<title>219</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"729\" cy=\"-487.2792\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"716\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"720\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">boil</text>\n",
|
|
"<text text-anchor=\"start\" x=\"677\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.8333</text>\n",
|
|
"</g>\n",
|
|
"<!-- 221->219 -->\n",
|
|
"<g id=\"edge7\" class=\"edge\">\n",
|
|
"<title>221->219</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M514.4362,-565.0134C558.0073,-549.2281 619.2031,-527.0575 665.0959,-510.431\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"666.435,-513.6685 674.6448,-506.9715 664.0506,-507.0871 666.435,-513.6685\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 207 -->\n",
|
|
"<g id=\"node19\" class=\"node\">\n",
|
|
"<title>207</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"948,-505.2792 832,-505.2792 832,-469.2792 948,-469.2792 948,-505.2792\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"864\" y=\"-491.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"868\" y=\"-491.0792\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">avocado</text>\n",
|
|
"<text text-anchor=\"start\" x=\"840\" y=\"-477.0792\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 221->207 -->\n",
|
|
"<g id=\"edge18\" class=\"edge\">\n",
|
|
"<title>221->207</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M540.2252,-572.7834C614.3963,-560.8039 727.2779,-540.2033 823,-512.7351 827.2871,-511.5048 831.6871,-510.1201 836.0845,-508.6482\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"837.3692,-511.907 845.6618,-505.3129 835.067,-505.2964 837.3692,-511.907\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 206 -->\n",
|
|
"<g id=\"node4\" class=\"node\">\n",
|
|
"<title>206</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"277,-407.8234 161,-407.8234 161,-371.8234 277,-371.8234 277,-407.8234\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"196\" y=\"-393.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"200\" y=\"-393.6234\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">tomato</text>\n",
|
|
"<text text-anchor=\"start\" x=\"169\" y=\"-379.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 210->206 -->\n",
|
|
"<g id=\"edge3\" class=\"edge\">\n",
|
|
"<title>210->206</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M219,-461.6738C219,-448.324 219,-431.9598 219,-418.2222\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"222.5001,-417.8758 219,-407.8758 215.5001,-417.8759 222.5001,-417.8758\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 208 -->\n",
|
|
"<g id=\"node7\" class=\"node\">\n",
|
|
"<title>208</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"595,-407.8234 479,-407.8234 479,-371.8234 595,-371.8234 595,-407.8234\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"512\" y=\"-393.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"516\" y=\"-393.6234\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cilantro</text>\n",
|
|
"<text text-anchor=\"start\" x=\"487\" y=\"-379.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 211->208 -->\n",
|
|
"<g id=\"edge6\" class=\"edge\">\n",
|
|
"<title>211->208</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M539.949,-461.6738C539.4011,-448.324 538.7295,-431.9598 538.1656,-418.2222\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"541.6482,-417.7239 537.7409,-407.8758 534.6541,-418.011 541.6482,-417.7239\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 218 -->\n",
|
|
"<g id=\"node9\" class=\"node\">\n",
|
|
"<title>218</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"733,-425.8234 613,-389.8234 733,-353.8234 853,-389.8234 733,-425.8234\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"719.5\" y=\"-393.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"723.5\" y=\"-393.6234\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"681\" y=\"-379.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.7500</text>\n",
|
|
"</g>\n",
|
|
"<!-- 219->218 -->\n",
|
|
"<g id=\"edge8\" class=\"edge\">\n",
|
|
"<title>219->218</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M730.051,-461.6738C730.3806,-453.6428 730.755,-444.5208 731.1238,-435.5361\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"734.6219,-435.6509 731.535,-425.5158 727.6278,-435.3638 734.6219,-435.6509\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 203 -->\n",
|
|
"<g id=\"node10\" class=\"node\">\n",
|
|
"<title>203</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"550,-310.3675 434,-310.3675 434,-274.3675 550,-274.3675 550,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"476\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"480\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">salsa</text>\n",
|
|
"<text text-anchor=\"start\" x=\"442\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 218->203 -->\n",
|
|
"<g id=\"edge9\" class=\"edge\">\n",
|
|
"<title>218->203</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M681.8901,-369.1555C641.9804,-353.0168 586.6657,-330.6485 546.0291,-314.2159\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"547.1371,-310.8887 536.5543,-310.3844 544.5128,-317.3781 547.1371,-310.8887\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 215 -->\n",
|
|
"<g id=\"node11\" class=\"node\">\n",
|
|
"<title>215</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"653\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"635\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"639\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">drain</text>\n",
|
|
"<text text-anchor=\"start\" x=\"601\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 218->215 -->\n",
|
|
"<g id=\"edge10\" class=\"edge\">\n",
|
|
"<title>218->215</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M709.214,-360.8473C699.9332,-349.5415 689.2507,-336.5281 679.7073,-324.9023\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"682.3636,-322.622 673.3134,-317.1133 676.9531,-327.0634 682.3636,-322.622\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 202 -->\n",
|
|
"<g id=\"node17\" class=\"node\">\n",
|
|
"<title>202</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"872,-310.3675 756,-310.3675 756,-274.3675 872,-274.3675 872,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"795\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"799\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">water</text>\n",
|
|
"<text text-anchor=\"start\" x=\"764\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 218->202 -->\n",
|
|
"<g id=\"edge16\" class=\"edge\">\n",
|
|
"<title>218->202</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M757.0834,-360.8473C768.2828,-347.3726 781.4983,-331.4722 792.3746,-318.3863\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"795.1051,-320.5768 798.8054,-310.6491 789.7218,-316.1024 795.1051,-320.5768\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 204 -->\n",
|
|
"<g id=\"node18\" class=\"node\">\n",
|
|
"<title>204</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"1006,-310.3675 890,-310.3675 890,-274.3675 1006,-274.3675 1006,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"930.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"934.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">pasta</text>\n",
|
|
"<text text-anchor=\"start\" x=\"898\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 218->204 -->\n",
|
|
"<g id=\"edge17\" class=\"edge\">\n",
|
|
"<title>218->204</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M780.9826,-368.0737C816.0876,-352.1612 863.5575,-330.6439 898.9172,-314.6159\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"900.4261,-317.7748 908.0891,-310.4585 897.5361,-311.3992 900.4261,-317.7748\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 214 -->\n",
|
|
"<g id=\"node12\" class=\"node\">\n",
|
|
"<title>214</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"653\" cy=\"-205.4558\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"637\" y=\"-209.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"641\" y=\"-209.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cook</text>\n",
|
|
"<text text-anchor=\"start\" x=\"601\" y=\"-195.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 215->214 -->\n",
|
|
"<g id=\"edge11\" class=\"edge\">\n",
|
|
"<title>215->214</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M653,-266.7612C653,-258.7873 653,-249.8428 653,-241.303\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"656.5001,-241.1794 653,-231.1795 649.5001,-241.1795 656.5001,-241.1794\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 213 -->\n",
|
|
"<g id=\"node13\" class=\"node\">\n",
|
|
"<title>213</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"653,-144 533,-108 653,-72 773,-108 653,-144\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"639.5\" y=\"-111.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"643.5\" y=\"-111.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"601\" y=\"-97.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 214->213 -->\n",
|
|
"<g id=\"edge12\" class=\"edge\">\n",
|
|
"<title>214->213</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M653,-179.8505C653,-171.9868 653,-163.0773 653,-154.2748\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"656.5001,-154.0596 653,-144.0596 649.5001,-154.0597 656.5001,-154.0596\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 201 -->\n",
|
|
"<g id=\"node14\" class=\"node\">\n",
|
|
"<title>201</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"577,-36 461,-36 461,0 577,0 577,-36\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"479\" y=\"-21.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"483\" y=\"-21.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">black pepper</text>\n",
|
|
"<text text-anchor=\"start\" x=\"469\" y=\"-7.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 213->201 -->\n",
|
|
"<g id=\"edge13\" class=\"edge\">\n",
|
|
"<title>213->201</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M615.6735,-82.93C596.4671,-70.0301 573.1837,-54.3921 554.28,-41.6955\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"556.1859,-38.7595 545.9331,-36.0894 552.283,-44.5705 556.1859,-38.7595\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 200 -->\n",
|
|
"<g id=\"node15\" class=\"node\">\n",
|
|
"<title>200</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"711,-36 595,-36 595,0 711,0 711,-36\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"640.5\" y=\"-21.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"644.5\" y=\"-21.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">salt</text>\n",
|
|
"<text text-anchor=\"start\" x=\"603\" y=\"-7.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 213->200 -->\n",
|
|
"<g id=\"edge14\" class=\"edge\">\n",
|
|
"<title>213->200</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M653,-71.9121C653,-63.3433 653,-54.3253 653,-46.1692\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"656.5001,-46.0539 653,-36.0539 649.5001,-46.0539 656.5001,-46.0539\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 199 -->\n",
|
|
"<g id=\"node16\" class=\"node\">\n",
|
|
"<title>199</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"845,-36 729,-36 729,0 845,0 845,-36\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"750\" y=\"-21.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"754\" y=\"-21.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">ground beef</text>\n",
|
|
"<text text-anchor=\"start\" x=\"737\" y=\"-7.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 213->199 -->\n",
|
|
"<g id=\"edge15\" class=\"edge\">\n",
|
|
"<title>213->199</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M690.3265,-82.93C709.5329,-70.0301 732.8163,-54.3921 751.72,-41.6955\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"753.717,-44.5705 760.0669,-36.0894 749.8141,-38.7595 753.717,-44.5705\"/>\n",
|
|
"</g>\n",
|
|
"</g>\n",
|
|
"</svg>\n"
|
|
],
|
|
"text/plain": [
|
|
"<graphviz.dot.Digraph at 0x7f86ddd17e90>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
},
|
|
{
|
|
"data": {
|
|
"text/markdown": [
|
|
"**Ingredients**:\n",
|
|
" * tortilla chip\n",
|
|
" * water\n",
|
|
" * salsa\n",
|
|
" * cilantro\n",
|
|
" * tomato\n",
|
|
" * cheese\n",
|
|
" * black pepper\n",
|
|
" * salt\n",
|
|
" * pasta\n",
|
|
" * ground beef\n",
|
|
" * avocado\n",
|
|
"\n",
|
|
"\n",
|
|
"**Instructions**:\n",
|
|
"\n",
|
|
"| Step | Instruction |\n",
|
|
"| ----:|:----------- |\n",
|
|
"| 1 | Mix black pepper, salt and ground beef. Then cook it. |\n",
|
|
"| 2 | drain the result of step 1 |\n",
|
|
"| 3 | Mix salsa, water and pasta and mix it together with the results of step 2. Then boil it. |\n",
|
|
"| 4 | chop tomato, chop cilantro and mix it with cheese, tortilla chip and avocado and mix it together with the results of step 3. |\n"
|
|
],
|
|
"text/plain": [
|
|
"<IPython.core.display.Markdown object>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
}
|
|
],
|
|
"source": [
|
|
"\n",
|
|
"d = ingredient_nodes([\n",
|
|
" \"ground beef\",\n",
|
|
" \"salt\",\n",
|
|
" \"black pepper\",\n",
|
|
" \"water\",\n",
|
|
" \"salsa\",\n",
|
|
" \"pasta\",\n",
|
|
" \"cheese\",\n",
|
|
" \"tomato\",\n",
|
|
" \"avocado\",\n",
|
|
" \"cilantro\",\n",
|
|
" \"tortilla chip\"\n",
|
|
"])\n",
|
|
"\n",
|
|
"# actions\n",
|
|
"\n",
|
|
"act (d, \"chop\", \"tomato\")\n",
|
|
"act (d, \"chop\", \"cilantro\")\n",
|
|
"\n",
|
|
"mix (d, \"ground beef\", \"salt\")\n",
|
|
"mix (d, \"ground beef\", \"black pepper\")\n",
|
|
"act (d, \"cook\", \"ground beef\")\n",
|
|
"act (d, \"drain\", \"ground beef\")\n",
|
|
"\n",
|
|
"mix (d, \"ground beef\", \"salsa\")\n",
|
|
"mix (d, \"ground beef\", \"water\")\n",
|
|
"mix (d, \"ground beef\", \"pasta\")\n",
|
|
"\n",
|
|
"act(d, \"boil\", \"pasta\")\n",
|
|
"\n",
|
|
"mix (d, \"cheese\", \"pasta\")\n",
|
|
"\n",
|
|
"\n",
|
|
"r = get_root(d)\n",
|
|
"\n",
|
|
"display(r.dot())\n",
|
|
"display(r.to_instruction().to_markdown())\n",
|
|
"with open(\"curated_noodle_3.md\", \"w\") as f:\n",
|
|
" f.write(r.to_instruction().to_markdown().data)\n",
|
|
" f.close()"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {},
|
|
"source": [
|
|
"## Spanish Rice and Beans\n",
|
|
"https://www.yummly.com/recipe/Spanish-Rice-and-Beans-814#directions"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 16,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"image/svg+xml": [
|
|
"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\n",
|
|
"<!DOCTYPE svg PUBLIC \"-//W3C//DTD SVG 1.1//EN\"\n",
|
|
" \"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd\">\n",
|
|
"<!-- Generated by graphviz version 2.40.1 (20161225.0304)\n",
|
|
" -->\n",
|
|
"<!-- Title: %3 Pages: 1 -->\n",
|
|
"<svg width=\"634pt\" height=\"542pt\"\n",
|
|
" viewBox=\"0.00 0.00 633.85 541.82\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
|
|
"<g id=\"graph0\" class=\"graph\" transform=\"scale(1 1) rotate(0) translate(4 537.8234)\">\n",
|
|
"<title>%3</title>\n",
|
|
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-537.8234 629.8528,-537.8234 629.8528,4 -4,4\"/>\n",
|
|
"<!-- 238 -->\n",
|
|
"<g id=\"node1\" class=\"node\">\n",
|
|
"<title>238</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"298,-533.8234 178,-497.8234 298,-461.8234 418,-497.8234 298,-533.8234\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"284.5\" y=\"-501.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"288.5\" y=\"-501.6234\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"246\" y=\"-487.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.6364</text>\n",
|
|
"</g>\n",
|
|
"<!-- 229 -->\n",
|
|
"<g id=\"node2\" class=\"node\">\n",
|
|
"<title>229</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"108\" cy=\"-400.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"90\" y=\"-404.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"94\" y=\"-404.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">drain</text>\n",
|
|
"<text text-anchor=\"start\" x=\"56\" y=\"-390.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 238->229 -->\n",
|
|
"<g id=\"edge1\" class=\"edge\">\n",
|
|
"<title>238->229</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M253.4534,-474.9743C225.5431,-460.6584 189.4479,-442.1442 160.1974,-427.1409\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"161.4552,-423.8525 150.96,-422.4028 158.2604,-430.081 161.4552,-423.8525\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 237 -->\n",
|
|
"<g id=\"node4\" class=\"node\">\n",
|
|
"<title>237</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"298\" cy=\"-400.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"282\" y=\"-404.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"286\" y=\"-404.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cook</text>\n",
|
|
"<text text-anchor=\"start\" x=\"246\" y=\"-390.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 238->237 -->\n",
|
|
"<g id=\"edge3\" class=\"edge\">\n",
|
|
"<title>238->237</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M298,-461.8113C298,-453.4239 298,-444.496 298,-436.1199\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"301.5001,-435.8873 298,-425.8874 294.5001,-435.8874 301.5001,-435.8873\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 227 -->\n",
|
|
"<g id=\"node14\" class=\"node\">\n",
|
|
"<title>227</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"517,-418.3675 401,-418.3675 401,-382.3675 517,-382.3675 517,-418.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"443\" y=\"-404.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"447\" y=\"-404.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">salsa</text>\n",
|
|
"<text text-anchor=\"start\" x=\"409\" y=\"-390.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 238->227 -->\n",
|
|
"<g id=\"edge13\" class=\"edge\">\n",
|
|
"<title>238->227</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M337.7978,-473.7332C363.0096,-458.472 395.4498,-438.8355 420.4233,-423.7186\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"422.5166,-426.5428 429.259,-418.3702 418.8918,-420.5544 422.5166,-426.5428\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 228 -->\n",
|
|
"<g id=\"node3\" class=\"node\">\n",
|
|
"<title>228</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"162,-320.9117 46,-320.9117 46,-284.9117 162,-284.9117 162,-320.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"66.5\" y=\"-306.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"70.5\" y=\"-306.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">kidney bean</text>\n",
|
|
"<text text-anchor=\"start\" x=\"54\" y=\"-292.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 229->228 -->\n",
|
|
"<g id=\"edge2\" class=\"edge\">\n",
|
|
"<title>229->228</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M106.949,-374.7622C106.4011,-361.4123 105.7295,-345.0481 105.1656,-331.3105\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"108.6482,-330.8122 104.7409,-320.9642 101.6541,-331.0993 108.6482,-330.8122\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 236 -->\n",
|
|
"<g id=\"node5\" class=\"node\">\n",
|
|
"<title>236</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"300,-338.9117 180,-302.9117 300,-266.9117 420,-302.9117 300,-338.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"286.5\" y=\"-306.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"290.5\" y=\"-306.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"248\" y=\"-292.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.5556</text>\n",
|
|
"</g>\n",
|
|
"<!-- 237->236 -->\n",
|
|
"<g id=\"edge4\" class=\"edge\">\n",
|
|
"<title>237->236</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M298.5255,-374.7622C298.6869,-366.8985 298.8697,-357.989 299.0503,-349.1865\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"302.554,-349.0411 299.26,-338.9713 295.5554,-348.8974 302.554,-349.0411\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 226 -->\n",
|
|
"<g id=\"node6\" class=\"node\">\n",
|
|
"<title>226</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"116,-223.4558 0,-223.4558 0,-187.4558 116,-187.4558 116,-223.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"10.5\" y=\"-209.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"14.5\" y=\"-209.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">vegetable broth</text>\n",
|
|
"<text text-anchor=\"start\" x=\"8\" y=\"-195.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 236->226 -->\n",
|
|
"<g id=\"edge5\" class=\"edge\">\n",
|
|
"<title>236->226</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M248.678,-282.2438C208.6027,-266.1051 153.0585,-243.7368 112.2533,-227.3042\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"113.3227,-223.9618 102.7392,-223.4728 110.7078,-230.455 113.3227,-223.9618\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 232 -->\n",
|
|
"<g id=\"node7\" class=\"node\">\n",
|
|
"<title>232</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"219\" cy=\"-205.4558\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"204.5\" y=\"-209.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"208.5\" y=\"-209.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">heat</text>\n",
|
|
"<text text-anchor=\"start\" x=\"167\" y=\"-195.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 236->232 -->\n",
|
|
"<g id=\"edge6\" class=\"edge\">\n",
|
|
"<title>236->232</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M275.9166,-273.9356C266.5199,-262.6298 255.7039,-249.6164 246.0411,-237.9906\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"248.651,-235.655 239.5674,-230.2016 243.2676,-240.1293 248.651,-235.655\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 225 -->\n",
|
|
"<g id=\"node11\" class=\"node\">\n",
|
|
"<title>225</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"438,-223.4558 322,-223.4558 322,-187.4558 438,-187.4558 438,-223.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"344.5\" y=\"-209.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"348.5\" y=\"-209.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">garlic clove</text>\n",
|
|
"<text text-anchor=\"start\" x=\"330\" y=\"-195.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 236->225 -->\n",
|
|
"<g id=\"edge10\" class=\"edge\">\n",
|
|
"<title>236->225</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M323.786,-273.9356C334.8472,-260.4609 347.8996,-244.5605 358.6416,-231.4746\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"361.3533,-233.6875 364.993,-223.7374 355.9428,-229.246 361.3533,-233.6875\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 230 -->\n",
|
|
"<g id=\"node12\" class=\"node\">\n",
|
|
"<title>230</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"541\" cy=\"-205.4558\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"525\" y=\"-209.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"529\" y=\"-209.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">chop</text>\n",
|
|
"<text text-anchor=\"start\" x=\"489\" y=\"-195.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 236->230 -->\n",
|
|
"<g id=\"edge11\" class=\"edge\">\n",
|
|
"<title>236->230</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M351.1099,-282.2438C389.1009,-266.881 441.0512,-245.8732 481.0114,-229.7141\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"482.419,-232.9203 490.3775,-225.9266 479.7947,-226.4308 482.419,-232.9203\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 231 -->\n",
|
|
"<g id=\"node8\" class=\"node\">\n",
|
|
"<title>231</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"219,-144 99,-108 219,-72 339,-108 219,-144\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"205.5\" y=\"-111.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"209.5\" y=\"-111.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"167\" y=\"-97.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 232->231 -->\n",
|
|
"<g id=\"edge7\" class=\"edge\">\n",
|
|
"<title>232->231</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M219,-179.8505C219,-171.9868 219,-163.0773 219,-154.2748\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"222.5001,-154.0596 219,-144.0596 215.5001,-154.0597 222.5001,-154.0596\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 222 -->\n",
|
|
"<g id=\"node9\" class=\"node\">\n",
|
|
"<title>222</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"210,-36 94,-36 94,0 210,0 210,-36\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"142.5\" y=\"-21.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"146.5\" y=\"-21.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">oil</text>\n",
|
|
"<text text-anchor=\"start\" x=\"102\" y=\"-7.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 231->222 -->\n",
|
|
"<g id=\"edge8\" class=\"edge\">\n",
|
|
"<title>231->222</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M197.0617,-78.5306C188.8707,-67.5278 179.6287,-55.1131 171.656,-44.4036\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"174.3576,-42.1713 165.5786,-36.2399 168.7426,-46.3513 174.3576,-42.1713\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 223 -->\n",
|
|
"<g id=\"node10\" class=\"node\">\n",
|
|
"<title>223</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"344,-36 228,-36 228,0 344,0 344,-36\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"273\" y=\"-21.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"277\" y=\"-21.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">rice</text>\n",
|
|
"<text text-anchor=\"start\" x=\"236\" y=\"-7.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 231->223 -->\n",
|
|
"<g id=\"edge9\" class=\"edge\">\n",
|
|
"<title>231->223</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M240.9383,-78.5306C249.1293,-67.5278 258.3713,-55.1131 266.344,-44.4036\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"269.2574,-46.3513 272.4214,-36.2399 263.6424,-42.1713 269.2574,-46.3513\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 224 -->\n",
|
|
"<g id=\"node13\" class=\"node\">\n",
|
|
"<title>224</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"599,-126 483,-126 483,-90 599,-90 599,-126\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"505\" y=\"-111.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"509\" y=\"-111.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">white onion</text>\n",
|
|
"<text text-anchor=\"start\" x=\"491\" y=\"-97.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 230->224 -->\n",
|
|
"<g id=\"edge12\" class=\"edge\">\n",
|
|
"<title>230->224</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M541,-179.8505C541,-166.5006 541,-150.1364 541,-136.3988\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"544.5001,-136.0524 541,-126.0525 537.5001,-136.0525 544.5001,-136.0524\"/>\n",
|
|
"</g>\n",
|
|
"</g>\n",
|
|
"</svg>\n"
|
|
],
|
|
"text/plain": [
|
|
"<graphviz.dot.Digraph at 0x7f86ddd25190>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
},
|
|
{
|
|
"data": {
|
|
"text/markdown": [
|
|
"**Ingredients**:\n",
|
|
" * white onion\n",
|
|
" * salsa\n",
|
|
" * rice\n",
|
|
" * vegetable broth\n",
|
|
" * kidney bean\n",
|
|
" * garlic clove\n",
|
|
" * oil\n",
|
|
"\n",
|
|
"\n",
|
|
"**Instructions**:\n",
|
|
"\n",
|
|
"| Step | Instruction |\n",
|
|
"| ----:|:----------- |\n",
|
|
"| 1 | Mix oil and rice. Then heat it. |\n",
|
|
"| 2 | chop white onion and mix it with vegetable broth and garlic clove and mix it together with the results of step 1. Then cook it. |\n",
|
|
"| 3 | drain kidney bean and mix it with salsa and mix it together with the results of step 2. |\n"
|
|
],
|
|
"text/plain": [
|
|
"<IPython.core.display.Markdown object>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
}
|
|
],
|
|
"source": [
|
|
"\n",
|
|
"d = ingredient_nodes([\n",
|
|
" \"oil\",\n",
|
|
" \"rice\",\n",
|
|
" \"white onion\",\n",
|
|
" \"garlic clove\",\n",
|
|
" \"vegetable broth\",\n",
|
|
" \"salsa\",\n",
|
|
" \"kidney bean\"\n",
|
|
"])\n",
|
|
"\n",
|
|
"# actions\n",
|
|
"act (d, \"drain\", \"kidney bean\")\n",
|
|
"act (d, \"chop\", \"white onion\")\n",
|
|
"\n",
|
|
"mix (d, \"rice\", \"oil\")\n",
|
|
"act(d, \"heat\", \"rice\")\n",
|
|
"\n",
|
|
"mix(d, \"rice\", \"white onion\")\n",
|
|
"mix (d, \"rice\", \"garlic clove\")\n",
|
|
"mix (d, \"rice\", \"garlic clove\")\n",
|
|
"\n",
|
|
"mix (d, \"vegetable broth\", \"rice\")\n",
|
|
"\n",
|
|
"act (d, \"cook\", \"rice\")\n",
|
|
"\n",
|
|
"r = get_root(d)\n",
|
|
"\n",
|
|
"display(r.dot())\n",
|
|
"display(r.to_instruction().to_markdown())\n",
|
|
"with open(\"curated_rice_3.md\", \"w\") as f:\n",
|
|
" f.write(r.to_instruction().to_markdown().data)\n",
|
|
" f.close()"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {},
|
|
"source": [
|
|
"## Vegan Curried Rice\n",
|
|
"https://www.yummly.com/recipe/Vegan-Curried-Rice-2319743#directions"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 17,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"image/svg+xml": [
|
|
"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\n",
|
|
"<!DOCTYPE svg PUBLIC \"-//W3C//DTD SVG 1.1//EN\"\n",
|
|
" \"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd\">\n",
|
|
"<!-- Generated by graphviz version 2.40.1 (20161225.0304)\n",
|
|
" -->\n",
|
|
"<!-- Title: %3 Pages: 1 -->\n",
|
|
"<svg width=\"1117pt\" height=\"434pt\"\n",
|
|
" viewBox=\"0.00 0.00 1116.85 433.82\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
|
|
"<g id=\"graph0\" class=\"graph\" transform=\"scale(1 1) rotate(0) translate(4 429.8234)\">\n",
|
|
"<title>%3</title>\n",
|
|
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-429.8234 1112.8528,-429.8234 1112.8528,4 -4,4\"/>\n",
|
|
"<!-- 260 -->\n",
|
|
"<g id=\"node1\" class=\"node\">\n",
|
|
"<title>260</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"299,-425.8234 179,-389.8234 299,-353.8234 419,-389.8234 299,-425.8234\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"285.5\" y=\"-393.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"289.5\" y=\"-393.6234\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"247\" y=\"-379.6234\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.9167</text>\n",
|
|
"</g>\n",
|
|
"<!-- 245 -->\n",
|
|
"<g id=\"node2\" class=\"node\">\n",
|
|
"<title>245</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"116,-310.3675 0,-310.3675 0,-274.3675 116,-274.3675 116,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"35.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"39.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">pepper</text>\n",
|
|
"<text text-anchor=\"start\" x=\"8\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 260->245 -->\n",
|
|
"<g id=\"edge1\" class=\"edge\">\n",
|
|
"<title>260->245</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M247.8901,-369.1555C207.9804,-353.0168 152.6657,-330.6485 112.0291,-314.2159\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"113.1371,-310.8887 102.5543,-310.3844 110.5128,-317.3781 113.1371,-310.8887\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 251 -->\n",
|
|
"<g id=\"node3\" class=\"node\">\n",
|
|
"<title>251</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"219\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"203\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"207\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">cook</text>\n",
|
|
"<text text-anchor=\"start\" x=\"167\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 260->251 -->\n",
|
|
"<g id=\"edge2\" class=\"edge\">\n",
|
|
"<title>260->251</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M275.214,-360.8473C265.9332,-349.5415 255.2507,-336.5281 245.7073,-324.9023\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"248.3636,-322.622 239.3134,-317.1133 242.9531,-327.0634 248.3636,-322.622\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 244 -->\n",
|
|
"<g id=\"node5\" class=\"node\">\n",
|
|
"<title>244</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"438,-310.3675 322,-310.3675 322,-274.3675 438,-274.3675 438,-310.3675\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"367.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"371.5\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">salt</text>\n",
|
|
"<text text-anchor=\"start\" x=\"330\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 260->244 -->\n",
|
|
"<g id=\"edge4\" class=\"edge\">\n",
|
|
"<title>260->244</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M323.0834,-360.8473C334.2828,-347.3726 347.4983,-331.4722 358.3746,-318.3863\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"361.1051,-320.5768 364.8054,-310.6491 355.7218,-316.1024 361.1051,-320.5768\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 259 -->\n",
|
|
"<g id=\"node6\" class=\"node\">\n",
|
|
"<title>259</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"541\" cy=\"-292.3675\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"530\" y=\"-296.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"534\" y=\"-296.1675\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">fry</text>\n",
|
|
"<text text-anchor=\"start\" x=\"489\" y=\"-282.1675\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.7143</text>\n",
|
|
"</g>\n",
|
|
"<!-- 260->259 -->\n",
|
|
"<g id=\"edge5\" class=\"edge\">\n",
|
|
"<title>260->259</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M350.322,-369.1555C388.4706,-353.7927 440.6365,-332.7849 480.7625,-316.6258\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"482.1989,-319.8206 490.1675,-312.8383 479.5839,-313.3273 482.1989,-319.8206\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 247 -->\n",
|
|
"<g id=\"node4\" class=\"node\">\n",
|
|
"<title>247</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"277,-212.9117 161,-212.9117 161,-176.9117 277,-176.9117 277,-212.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"206\" y=\"-198.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"210\" y=\"-198.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">rice</text>\n",
|
|
"<text text-anchor=\"start\" x=\"169\" y=\"-184.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 251->247 -->\n",
|
|
"<g id=\"edge3\" class=\"edge\">\n",
|
|
"<title>251->247</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M219,-266.7622C219,-253.4123 219,-237.0481 219,-223.3105\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"222.5001,-222.9641 219,-212.9642 215.5001,-222.9642 222.5001,-222.9641\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 258 -->\n",
|
|
"<g id=\"node7\" class=\"node\">\n",
|
|
"<title>258</title>\n",
|
|
"<polygon fill=\"#d5e8d4\" stroke=\"#d5e8d4\" points=\"541,-230.9117 421,-194.9117 541,-158.9117 661,-194.9117 541,-230.9117\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"527.5\" y=\"-198.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"531.5\" y=\"-198.7117\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">mix</text>\n",
|
|
"<text text-anchor=\"start\" x=\"489\" y=\"-184.7117\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 0.9048</text>\n",
|
|
"</g>\n",
|
|
"<!-- 259->258 -->\n",
|
|
"<g id=\"edge6\" class=\"edge\">\n",
|
|
"<title>259->258</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M541,-266.7622C541,-258.8985 541,-249.989 541,-241.1865\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"544.5001,-240.9713 541,-230.9713 537.5001,-240.9714 544.5001,-240.9713\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 241 -->\n",
|
|
"<g id=\"node8\" class=\"node\">\n",
|
|
"<title>241</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"143,-115.4558 27,-115.4558 27,-79.4558 143,-79.4558 143,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"49.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"53.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">garlic clove</text>\n",
|
|
"<text text-anchor=\"start\" x=\"35\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:0.5000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 258->241 -->\n",
|
|
"<g id=\"edge7\" class=\"edge\">\n",
|
|
"<title>258->241</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M457.2946,-183.8731C377.8367,-172.3522 255.5048,-151.8983 152,-122.9117 147.7051,-121.7089 143.2995,-120.3439 138.8983,-118.8857\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"139.9098,-115.5322 129.315,-115.5712 137.6217,-122.1477 139.9098,-115.5322\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 239 -->\n",
|
|
"<g id=\"node9\" class=\"node\">\n",
|
|
"<title>239</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"277,-115.4558 161,-115.4558 161,-79.4558 277,-79.4558 277,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"194\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"198\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">olive oil</text>\n",
|
|
"<text text-anchor=\"start\" x=\"169\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 258->239 -->\n",
|
|
"<g id=\"edge8\" class=\"edge\">\n",
|
|
"<title>258->239</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M476.0711,-178.2676C424.2505,-164.5793 349.9895,-144.0562 286,-122.9117 282.2525,-121.6734 278.405,-120.3511 274.54,-118.9847\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"275.5374,-115.6238 264.9431,-115.5201 273.1604,-122.2079 275.5374,-115.6238\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 249 -->\n",
|
|
"<g id=\"node10\" class=\"node\">\n",
|
|
"<title>249</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"380\" cy=\"-97.4558\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"364\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"368\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">chop</text>\n",
|
|
"<text text-anchor=\"start\" x=\"328\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 258->249 -->\n",
|
|
"<g id=\"edge9\" class=\"edge\">\n",
|
|
"<title>258->249</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M501.2022,-170.8215C478.5781,-157.1267 450.1332,-139.9086 426.4864,-125.5948\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"428.0479,-122.4487 417.6806,-120.2645 424.423,-128.4371 428.0479,-122.4487\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 240 -->\n",
|
|
"<g id=\"node12\" class=\"node\">\n",
|
|
"<title>240</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"599,-115.4558 483,-115.4558 483,-79.4558 599,-79.4558 599,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"520.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"524.5\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">ginger</text>\n",
|
|
"<text text-anchor=\"start\" x=\"491\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 258->240 -->\n",
|
|
"<g id=\"edge11\" class=\"edge\">\n",
|
|
"<title>258->240</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M541,-158.8996C541,-147.9536 541,-136.0871 541,-125.7278\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"544.5001,-125.5795 541,-115.5795 537.5001,-125.5795 544.5001,-125.5795\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 250 -->\n",
|
|
"<g id=\"node13\" class=\"node\">\n",
|
|
"<title>250</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"702\" cy=\"-97.4558\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"686\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"690\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">chop</text>\n",
|
|
"<text text-anchor=\"start\" x=\"650\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 258->250 -->\n",
|
|
"<g id=\"edge12\" class=\"edge\">\n",
|
|
"<title>258->250</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M580.7978,-170.8215C603.4219,-157.1267 631.8668,-139.9086 655.5136,-125.5948\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"657.577,-128.4371 664.3194,-120.2645 653.9521,-122.4487 657.577,-128.4371\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 246 -->\n",
|
|
"<g id=\"node15\" class=\"node\">\n",
|
|
"<title>246</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"921,-115.4558 805,-115.4558 805,-79.4558 921,-79.4558 921,-115.4558\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"844\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"848\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">water</text>\n",
|
|
"<text text-anchor=\"start\" x=\"813\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 258->246 -->\n",
|
|
"<g id=\"edge14\" class=\"edge\">\n",
|
|
"<title>258->246</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M605.9289,-178.2676C657.7495,-164.5793 732.0105,-144.0562 796,-122.9117 799.7475,-121.6734 803.595,-120.3511 807.46,-118.9847\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"808.8396,-122.2079 817.0569,-115.5201 806.4626,-115.6238 808.8396,-122.2079\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 252 -->\n",
|
|
"<g id=\"node16\" class=\"node\">\n",
|
|
"<title>252</title>\n",
|
|
"<ellipse fill=\"#dae8fc\" stroke=\"#dae8fc\" cx=\"1024\" cy=\"-97.4558\" rx=\"84.7059\" ry=\"25.4118\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"1008\" y=\"-101.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"1012\" y=\"-101.2558\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">chop</text>\n",
|
|
"<text text-anchor=\"start\" x=\"972\" y=\"-87.2558\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score: 1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 258->252 -->\n",
|
|
"<g id=\"edge15\" class=\"edge\">\n",
|
|
"<title>258->252</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M619.2471,-182.3554C698.0742,-169.2547 823.0157,-147.2561 930,-122.9117 937.2789,-121.2554 944.8431,-119.4132 952.3777,-117.4985\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"953.4335,-120.8407 962.2392,-114.9492 951.6815,-114.0635 953.4335,-120.8407\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 242 -->\n",
|
|
"<g id=\"node11\" class=\"node\">\n",
|
|
"<title>242</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"438,-36 322,-36 322,0 438,0 438,-36\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"359.5\" y=\"-21.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"363.5\" y=\"-21.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">carrot</text>\n",
|
|
"<text text-anchor=\"start\" x=\"330\" y=\"-7.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 249->242 -->\n",
|
|
"<g id=\"edge10\" class=\"edge\">\n",
|
|
"<title>249->242</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M380,-71.8782C380,-63.7122 380,-54.6289 380,-46.2824\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"383.5001,-46.2287 380,-36.2288 376.5001,-46.2288 383.5001,-46.2287\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 243 -->\n",
|
|
"<g id=\"node14\" class=\"node\">\n",
|
|
"<title>243</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"760,-36 644,-36 644,0 760,0 760,-36\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"676.5\" y=\"-21.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"680.5\" y=\"-21.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">broccoli</text>\n",
|
|
"<text text-anchor=\"start\" x=\"652\" y=\"-7.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 250->243 -->\n",
|
|
"<g id=\"edge13\" class=\"edge\">\n",
|
|
"<title>250->243</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M702,-71.8782C702,-63.7122 702,-54.6289 702,-46.2824\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"705.5001,-46.2287 702,-36.2288 698.5001,-46.2288 705.5001,-46.2287\"/>\n",
|
|
"</g>\n",
|
|
"<!-- 248 -->\n",
|
|
"<g id=\"node17\" class=\"node\">\n",
|
|
"<title>248</title>\n",
|
|
"<polygon fill=\"#ffe6cc\" stroke=\"#ffe6cc\" points=\"1082,-36 966,-36 966,0 1082,0 1082,-36\"/>\n",
|
|
"<text text-anchor=\"start\" x=\"999.5\" y=\"-21.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\"> </text>\n",
|
|
"<text text-anchor=\"start\" x=\"1003.5\" y=\"-21.8\" font-family=\"Times,serif\" font-weight=\"bold\" font-size=\"14.00\" fill=\"#000000\">spinach</text>\n",
|
|
"<text text-anchor=\"start\" x=\"974\" y=\"-7.8\" font-family=\"Times,serif\" font-size=\"14.00\" fill=\"#000000\">node score:1.0000</text>\n",
|
|
"</g>\n",
|
|
"<!-- 252->248 -->\n",
|
|
"<g id=\"edge16\" class=\"edge\">\n",
|
|
"<title>252->248</title>\n",
|
|
"<path fill=\"none\" stroke=\"#000000\" d=\"M1024,-71.8782C1024,-63.7122 1024,-54.6289 1024,-46.2824\"/>\n",
|
|
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"1027.5001,-46.2287 1024,-36.2288 1020.5001,-46.2288 1027.5001,-46.2287\"/>\n",
|
|
"</g>\n",
|
|
"</g>\n",
|
|
"</svg>\n"
|
|
],
|
|
"text/plain": [
|
|
"<graphviz.dot.Digraph at 0x7f86ddd2c9d0>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
},
|
|
{
|
|
"data": {
|
|
"text/markdown": [
|
|
"**Ingredients**:\n",
|
|
" * carrot\n",
|
|
" * water\n",
|
|
" * olive oil\n",
|
|
" * ginger\n",
|
|
" * pepper\n",
|
|
" * rice\n",
|
|
" * broccoli\n",
|
|
" * salt\n",
|
|
" * garlic clove\n",
|
|
" * spinach\n",
|
|
"\n",
|
|
"\n",
|
|
"**Instructions**:\n",
|
|
"\n",
|
|
"| Step | Instruction |\n",
|
|
"| ----:|:----------- |\n",
|
|
"| 1 | chop carrot, chop broccoli, chop spinach and mix it with garlic clove, olive oil, ginger and water. Then fry it. |\n",
|
|
"| 2 | cook rice and mix it with pepper and salt and mix it together with the results of step 1. |\n"
|
|
],
|
|
"text/plain": [
|
|
"<IPython.core.display.Markdown object>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
}
|
|
],
|
|
"source": [
|
|
"\n",
|
|
"d = ingredient_nodes([\n",
|
|
" \"olive oil\",\n",
|
|
" \"ginger\",\n",
|
|
" \"garlic clove\",\n",
|
|
" \"carrot\",\n",
|
|
" \"broccoli\",\n",
|
|
" \"salt\",\n",
|
|
" \"pepper\",\n",
|
|
" \"water\",\n",
|
|
" \"rice\",\n",
|
|
" \"spinach\"\n",
|
|
"])\n",
|
|
"\n",
|
|
"# actions\n",
|
|
"act(d, \"chop\", \"carrot\")\n",
|
|
"act(d, \"chop\", \"broccoli\")\n",
|
|
"act(d, \"cook\",\"rice\")\n",
|
|
"act(d, \"chop\", \"spinach\")\n",
|
|
"\n",
|
|
"mix(d, \"olive oil\", \"ginger\")\n",
|
|
"mix(d, \"olive oil\", \"garlic clove\")\n",
|
|
"mix(d, \"olive oil\", \"carrot\")\n",
|
|
"mix(d, \"olive oil\", \"broccoli\")\n",
|
|
"mix(d, \"olive oil\", \"water\")\n",
|
|
"mix(d, \"olive oil\", \"spinach\")\n",
|
|
"\n",
|
|
"act(d, \"fry\", \"olive oil\")\n",
|
|
"\n",
|
|
"r = get_root(d)\n",
|
|
"\n",
|
|
"display(r.dot())\n",
|
|
"display(r.to_instruction().to_markdown())\n",
|
|
"with open(\"curated_rice_4.md\", \"w\") as f:\n",
|
|
" f.write(r.to_instruction().to_markdown().data)\n",
|
|
" f.close()"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {},
|
|
"source": [
|
|
"## Vegetable Ramen Pad Thai\n",
|
|
"https://www.yummly.com/recipe/Vegetable-Ramen-Pad-Thai-2067502#directions"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": 18,
|
|
"metadata": {},
|
|
"outputs": [
|
|
{
|
|
"data": {
|
|
"text/markdown": [
|
|
"**Ingredients**:\n",
|
|
" * vegetable\n",
|
|
" * water\n",
|
|
" * peanut butter\n",
|
|
" * teriyaki sauce\n",
|
|
" * vegetable oil\n",
|
|
" * ramen noodle\n",
|
|
" * sriacha sauce\n",
|
|
"\n",
|
|
"\n",
|
|
"**Instructions**:\n",
|
|
"\n",
|
|
"| Step | Instruction |\n",
|
|
"| ----:|:----------- |\n",
|
|
"| 1 | heat water and mix it with ramen noodle. Then cook it. |\n",
|
|
"| 2 | drain the result of step 1 |\n",
|
|
"| 3 | Mix vegetable and vegetable oil. Then cook it. |\n",
|
|
"| 4 | Mix peanut butter, teriyaki sauce and sriacha sauce and mix it together with the results of step 2 and step 3. |\n"
|
|
],
|
|
"text/plain": [
|
|
"<IPython.core.display.Markdown object>"
|
|
]
|
|
},
|
|
"metadata": {},
|
|
"output_type": "display_data"
|
|
}
|
|
],
|
|
"source": [
|
|
"\n",
|
|
"d = ingredient_nodes([\n",
|
|
" \"ramen noodle\",\n",
|
|
" \"vegetable oil\",\n",
|
|
" \"vegetable\",\n",
|
|
" \"teriyaki sauce\",\n",
|
|
" \"water\",\n",
|
|
" \"peanut butter\",\n",
|
|
" \"sriacha sauce\"\n",
|
|
"])\n",
|
|
"\n",
|
|
"# actions\n",
|
|
"act(d, \"heat\", \"water\")\n",
|
|
"mix(d, \"ramen noodle\", \"water\")\n",
|
|
"act(d, \"cook\", \"ramen noodle\")\n",
|
|
"act(d, \"drain\", \"ramen noodle\")\n",
|
|
"\n",
|
|
"mix (d, \"vegetable oil\", \"vegetable\")\n",
|
|
"act(d, \"cook\", \"vegetable\")\n",
|
|
"\n",
|
|
"mix (d, \"vegetable\", \"ramen noodle\")\n",
|
|
"\n",
|
|
"\n",
|
|
"r = get_root(d)\n",
|
|
"\n",
|
|
"#display(r.dot()) # ← cannot plot tree because some ingredients are unknown!\n",
|
|
"display(r.to_instruction().to_markdown())\n",
|
|
"with open(\"curated_noodle_4.md\", \"w\") as f:\n",
|
|
" f.write(r.to_instruction().to_markdown().data)\n",
|
|
" f.close()"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": null,
|
|
"metadata": {},
|
|
"outputs": [],
|
|
"source": []
|
|
}
|
|
],
|
|
"metadata": {
|
|
"kernelspec": {
|
|
"display_name": "Python 3",
|
|
"language": "python",
|
|
"name": "python3"
|
|
},
|
|
"language_info": {
|
|
"codemirror_mode": {
|
|
"name": "ipython",
|
|
"version": 3
|
|
},
|
|
"file_extension": ".py",
|
|
"mimetype": "text/x-python",
|
|
"name": "python",
|
|
"nbconvert_exporter": "python",
|
|
"pygments_lexer": "ipython3",
|
|
"version": "3.7.5"
|
|
}
|
|
},
|
|
"nbformat": 4,
|
|
"nbformat_minor": 4
|
|
}
|