Live data from Hacker News

Show HN: An API for scraping recipe web pages

choppingboard.recipes

31–40 of 113 posts

Re: Show HN: An API for scraping recipe web pages

#31
post #19

Earlier quoted context omitted.

There is a standard of sorts, if you trust Google: https://developers.google.com/search/docs/data-types/recipes

This standard is not unique to Google. It's part of the Schema.org initiative to add semantics to the web. The full definition is here: http://schema.org/Recipe The biggest problem with it, imho, is the lack of a proper definition of ingredients. An ingredient is just a plain string containing the unit, amount and name and sometimes an extra note. Having a quadruple instead of a string would make this standard a lot…

I was surprised to find that bbc.co.uk/food uses the Recipe schema. Made scraping it much easier when there was some talk about canning it a couple of years back.

Re: Show HN: An API for scraping recipe web pages

#32

This really seems to be an exercise in 'structuring recipe data' rather than the ins-and-outs of scraping. Seems like a much-needed task; is there anything approaching a 'standard' for recipe data already? "ingredients": [ "600g pineapple, peeled, chopped" ] This seems like a prime candidate for improvement; something like the following would seem to be more useful: "ingredients": [{ "ingredient": "pineapple", "quant…

Two things that would be so nice would be easy scaling, and unit conversion (even better if that's automatic)

I created http://www.recipastely.com/ to simplify recipe conversion between us and iso units a few years back. It's not perfect but it seems to work fine for me.

Re: Show HN: An API for scraping recipe web pages

#33
post #31

Earlier quoted context omitted.

This standard is not unique to Google. It's part of the Schema.org initiative to add semantics to the web. The full definition is here: http://schema.org/Recipe The biggest problem with it, imho, is the lack of a proper definition of ingredients. An ingredient is just a plain string containing the unit, amount and name and sometimes an extra note. Having a quadruple instead of a string would make this standard a lot…

I was surprised to find that bbc.co.uk/food uses the Recipe schema. Made scraping it much easier when there was some talk about canning it a couple of years back.

    > I was surprised to find that
    > bbc.co.uk/food uses the Recipe
    > schema
Gotta say, having worked at the Beeb, this doesn't surprise me at all. Amazing what marginal-value technical itches can be scratched when commercial pressure is eased off...

Re: Show HN: An API for scraping recipe web pages

#36
post #20

Earlier quoted context omitted.

> I don't think it's quite as simple as 'double quantities of everything to serve 4 people instead of 2' It usually is though. Cooking times however don't tend to scale predictably (except for microwaves).

> "It usually is though. Cooking times however don't tend to scale predictably (except for microwaves)." Not sure I agree. In my very limited experience, I have found that cooking times for microwaves do not scale predictably. For example warming up 2 packs of something seems to use less than double the amount of time for 1. I have had issues in the past of doubling or tripling the cooking time for double/triple the…

> warming up 2 packs of something seems to use less than double the amount of time for 1

This makes sense. When you see a microwave rated as 750 W, that's assuming there is a sufficient load inside the oven that can absorb all that RF energy. Usually there's not, maybe your food can just absorb 400 W, and when you double the amount of food maybe it can absorb 600 W.

Mainly this is because the outer ~3 cm of food is what absorbs RF energy, heating of the rest of the food is through thermal conduction.

Re: Show HN: An API for scraping recipe web pages

#38

This really seems to be an exercise in 'structuring recipe data' rather than the ins-and-outs of scraping. Seems like a much-needed task; is there anything approaching a 'standard' for recipe data already? "ingredients": [ "600g pineapple, peeled, chopped" ] This seems like a prime candidate for improvement; something like the following would seem to be more useful: "ingredients": [{ "ingredient": "pineapple", "quant…

Heh, I once tried to make a DSL to cope with recipes from cookingforengineers.com e.g. their lovely recipe cards [1] . I totally failed to make anything decent!. The combining of multiple steps etc. was just painful!. In the linked site above, that recipe is so straight forward, I'd love to see how it copes with [1] below. [1] http://www.cookingforengineers.com/recipe/127/Shepherds-Pie-...

Those cards are genius. They perfectly illustrate what you can do parallel to other things rather than having to re-read and re-interpret the written instructions continuously.

Re: Show HN: An API for scraping recipe web pages

#39

This really seems to be an exercise in 'structuring recipe data' rather than the ins-and-outs of scraping. Seems like a much-needed task; is there anything approaching a 'standard' for recipe data already? "ingredients": [ "600g pineapple, peeled, chopped" ] This seems like a prime candidate for improvement; something like the following would seem to be more useful: "ingredients": [{ "ingredient": "pineapple", "quant…

Two things that would be so nice would be easy scaling, and unit conversion (even better if that's automatic)

For unit conversion to metric, I made a browser plugin: https://github.com/falk-hueffner/metric-cooking It can also convert from volume to mass, e.g. annotate "3/4 cup plus 2 tablespoons packed light-brown sugar" with "[190 g]". It's a bit hacky (basically a giant regexp) but works nicely for me.

Re: Show HN: An API for scraping recipe web pages

#40

This really seems to be an exercise in 'structuring recipe data' rather than the ins-and-outs of scraping. Seems like a much-needed task; is there anything approaching a 'standard' for recipe data already? "ingredients": [ "600g pineapple, peeled, chopped" ] This seems like a prime candidate for improvement; something like the following would seem to be more useful: "ingredients": [{ "ingredient": "pineapple", "quant…

A nice use-case seen on the recipe website "Marmiton" is a widget to ajust ingredients quantity to the target number of eaters.

You can see it here[1] for example, "Ingrédients / Nombre de personnes", lower in the right column.

[1] http://www.marmiton.org/recettes/recette_courgettes-farcies-...

Post reply on HN