Quantity extraction
Handles integers, decimals, fractions (¼ ⅓ ¾), unicode quantities, and written numbers. 2¼ becomes 2.25 — reliably.
RecipeParse turns any messy ingredient string into clean, structured JSON — quantities, units, names, prep state, confidence scores. One API call. Done.
# TODO: handle "2¼ cups" — breaks regex # TODO: "115g" vs "115 g" vs "115 grams" # TODO: "unsalted butter, melted" — which part is the name? # TODO: "a handful of" — what unit is THAT?? 🔥 def parse_ingredient(text): # 3 weeks of regex hell patterns = [ r'(\d+)\s*(cup|cups|tsp|tbsp)', r'(\d+(?:\.\d+)?)\s*(g|kg|oz|lb)', # ... 200 more patterns, all fragile ] # Confidence: unknown # Unit tests: 0 # Tech debt: infinite
POST an array of ingredient strings — exactly as they appear. Fractions, unicode, parenthetical notes — all fine.
Our model identifies quantities, units, names, and prep states. A validator normalises units and scores confidence.
Get back structured data with canonical IDs, normalised units, confidence scores, and optional product matches.
Handles integers, decimals, fractions (¼ ⅓ ¾), unicode quantities, and written numbers. 2¼ becomes 2.25 — reliably.
Converts "tsp", "teaspoon", "teaspoons" to one canonical unit. Full metric and imperial, including mixed-unit strings.
Every ingredient gets a consistent snake_case ID. unsalted_butter, every time. Consistent across every call.
"melted", "finely chopped", "at room temperature" — all split into a dedicated preparation field. Ready for your UI.
Every parsed ingredient gets a 0–1 confidence score. Flag low-confidence results for human review. Always know when to trust the data.
Links method steps back to parsed ingredients with character-level spans. Know exactly where "butter" appears in instructions.
Match ingredients against a branded product catalogue with fuzzy matching — ranked by confidence. Built for grocery integrations.
Identical ingredient lists return instantly at zero cost. Keyed by a hash of the sorted ingredient array — zero stale-data risk.
General food APIs treat parsing as an afterthought. We built the whole thing around it.
| Feature | RecipeParse | Spoonacular | Edamam | Zestful |
|---|---|---|---|---|
| Ingredient-only parsing | ✓ | Partial | Partial | ✓ |
| Confidence scores | ✓ | ✗ | ✗ | ✗ |
| Step ↔ ingredient linking | ✓ | ✗ | ✗ | ✗ |
| Product enrichment | ✓ | ✗ | ✗ | ✗ |
| SHA-256 smart caching | ✓ | ✗ | ✗ | ✗ |
| Developer-friendly terms | ✓ | Partial | Partial | ✓ |
| Starting price | $0 / month | $29 / month | $29 / month | $79 / month |
Simple, transparent pricing. No contracts, no lock-in. Your parsed data is yours forever.
FREE
Try it with no commitment.
STARTER
For indie developers and small projects.
PRO
For production apps with serious volume.
Need higher limits? Talk to us about Enterprise → · Metered overages at $0.04 / parse beyond plan limits.
One call to POST /api/v1/parse/ingredients consumes one parse credit, regardless of how many ingredients are in the array. Cached responses cost zero credits.
Yes. Unlike Spoonacular and Edamam, RecipeParse uses developer-friendly terms. You own your parsed output. Store it, transform it, build commercial products on top of it.
All common formats: integers, decimals, unicode fractions (¼ ⅓ ¾), written numbers ("one"), mixed units ("1 lb 4 oz"), ranges ("2–3 cups"), and preparation descriptors ("finely chopped").
Python and JavaScript/TypeScript SDKs launch with the API. Both are open-source. You can also use the REST API directly with any HTTP client — standard JSON with Bearer token auth.
Our model returns a per-ingredient confidence score (0–1). In testing, 94%+ of parses score above 0.9. Filter on confidence to decide when to flag for human review.
Product enrichment matches parsed ingredients against a branded catalogue with fuzzy matching, returning ranked candidates. Useful for grocery-list and shopping-cart integrations.