-
Notifications
You must be signed in to change notification settings - Fork 812
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Specify sub items ingredient, amount, note for each ingredient in Recipe #882
Comments
also, unit of measure, as in: 3 cups olive oil = |
This might be interesting as well: / Arvid 2015-11-07 17:35 GMT+01:00 Ryan B. Harvey notifications@github.com:
|
You could use https://schema.org/TypeAndQuantityNode for this - if we extended the range of recipeIngredient to include it: typeOfGood: "Banana" |
+1 |
It looks like data-vocabulary used to allow The New York Times article hints at some of the possible complexity, like "4 tablespoons melted nonhydrogenated margarine, melted coconut oil or canola oil". Another issue would be with branded ingredients like "Heinz® Ketchup": do you include the brand in the ingredient name or no? Recipe sites tend to know when an entire ingredient statement starts and ends (it's often the basis of a bulleted list), but further parsing the ingredient statement can introduce ambiguity. I like the idea of having a means of specifying more sub-structure, but I just wonder if the real-world ingredients fall easily into this pattern. The NYT article made it sound like quite a tedious process and I wonder if any other recipe sites go to that much trouble. |
As long as one leaves the possibility to not use these "sub-items", one could just not specify them in cases where it is too tricky. In regards to current usage, I know some recipe sites link the |
Having something like the old http://data-vocabulary.org/RecipeIngredient with amount, unit and name seems kinda obvious to me. I'm a bit disappointed that schema.org still does not support this use case. |
Nearly 3 years on, what is the preferred way to represent recipe ingredients using structured data? We need to represent quantity and price, to be able to do things like:
Just write them as type I tried looking at a WordPress plugin to see how they support unit conversion and I think they do it outside of the JSON-LD, through the page markup <span data-normalized="200" data-fraction="" data-original="200" class="wpurp-recipe-ingredient-quantity">200</span>
<span data-original="g" class="wpurp-recipe-ingredient-unit">g</span> |
I can process and parse all the information on a Recipe, but ingredients required me to use CRFsuite and train with a data set to figure out that "2 tablespoons sugar" is "amount: 2, measure: tablespoon, ingredient: sugar". The whole point to structured markup is so a machine can easily understand the content without resorting to natural language processing, but
What do we need to do to get this issue actually looked at by someone with authority to change the standard? |
@tisdall I went around the pretty glaring oversight by using
Normally we'd say a baking sheet is a supply, and rolled oats is an ingredient. |
@akaleeroy - That's interesting, but then there's still the possibly difficult task of matching up (BTW, In that Reddit post it says that schema "made a trade-off between machine readability and ease of authoring", but the general principle in other fields is you can use a complex object (like a |
@tisdall The arguments you made are exactly why I'm also in favor of changing the (To flog this to death... baking sheet can stand for baking parchment – disposable, something you buy and run out of, hence |
Is there nothing that can be done to expedite this change? |
This issue is being tagged as Stale due to inactivity. |
This is still a problem 7 years later and shouldn't be closed as stale. If there are no plans to address this, then there should be plans to extend the standard to allow ad-hoc definitions for more specific, machine-readable types. The main argument against this seems to be "people don't use structured data for ingredients" which isn't particularly compelling because the goal is to enforce generators to use structured ingredients. |
Also "more people would use structured data for ingredients if it was standardized" 🤷 |
It would be nice to be able to specify i.e.:
3 smashed bananas =
amount: 3
ingredient: banana
note: smashed
The text was updated successfully, but these errors were encountered: