Migrating Homebrew Recipes
May 1st, 2013, by Kyle (Backend Dev)
Brewtoad took great care in migrating recipes from Hopville. This extra attention was required because Hopville handles ingredients differently than Brewtoad.
With Hopville, any user was free to create a custom ingredient that would be immediately available to all other users. This has the potential to create inconsistent ingredient records in the database.
To minimize that inconsistency, Brewtoad makes the distinction between system ingredients, and custom ingredients. System ingredients can only be created and edited by an administrator and are visible to all users. Custom ingredients, on the other hand, can be created by anybody. Custom ingredients are only visible (in the recipe editor) to the user that created them.
We realize there are certain advantages to having a single public repository of ingredients. We feel strongly, however, that having a carefully curated database of ingredients–using the names as defined by the maltsters, hop farmers, and yeast laboratories–is a better direction to take.
We’ve also gone to great lengths to only include in our ingredient database those ingredients which are for sale in each supplier’s catalog. This means that if a Brewtoad recipe uses all system ingredients, you can be reasonably confident that you’ll be able to actually brew it. We think this is really important.
Ideally, we want as many recipes as possible to be using as many system ingredients as possible. To this end, we’ve designed a two-phase approach that attempts to match incoming Hopville ingredients with their Brewtoad equivalents.
Phase 1 involves mapping – by hand – the most popular Hopville ingredients to their Brewtoad equivalents. If the ingredient in question isn’t found in these lookup tables, we move on to phase 2.
Phase 2 involves an ingredient matching heuristic that intelligently decides whether or not an incoming ingredient matches an existing system ingredient.
This heuristic checks the incoming ingredient against each existing system ingredient and uses the Jaro-Winkler distance between the two ingredient names, as well as the difference between each of the ingredients properties (weighted to prefer properties which are used directly by the recipe editor).
If, after phase 2, we’re still not convinced that the incoming ingredient matches something already in our ingredient database, we bite the bullet and create a new custom ingredient.
In turn, we can’t promise your recipes will come into Brewtoad using exactly the same ingredients as they used on Hopville. What we can promise, however, is that when we match an incoming Hopville ingredient to an existing Brewtoad system ingredient, we’re doing so with a high degree of confidence.
Exceptions to the Rule: Chocolate Malt
NOTE: Turns out there is a chocolate malt with a color of 475 °L manufactured by Bairds in the UK (thanks Jandhi!) In response, we’ve added as many Bairds malts as we could find to the ingredient database, so much of the following no longer applies. The point that Hopville’s ingredient database contains a lot of impossible to source and/or incorrect ingredients still applies, however (issues with matching ingredients 1:1 were not strictly related to chocolate malt).
While we’ve tried our best to map incoming Hopville ingredients with their Brewtoad equivalents as accurately as possible, there are, of course, a few exceptions.
Consider chocolate malt, one of the most popular ingredients on Hopville and used in over 12k recipes. On Hopville, this ingredient has a color of 475 °L. That’s dark!
On Brewtoad, however, we don’t have a chocolate malt with a color of 475 °L and We’re unable to find any chocolate malt for sale, online or at my LHBS, with a color of 475 °L. It just doesn’t exist.
So what are our options?
We could create a new chocolate malt with a color of 475 °L and map all incoming chocolate malts to it. But if you can’t even buy chocolate malt that dark, what would be the point? We’d just end up with 12k recipes which nobody could brew without substituting a different chocolate malt.
The other option, and the one we ultimately settled on, is to map the Hopville chocolate malt (475 °L) to ours (350 °L). This means that all of those 12k recipes which used chocolate malt on Hopville will now be a little lighter than they were before. Ultimately, we’d rather err on the side of accuracy, even if that means “changing” some recipes.
- If you create a variant of a recipe which uses custom ingredients, those custom ingredients will be copied and assigned to you. If enough users start using copies of the same custom ingredient, we consolidate all of these into a single reference and promote it to a system ingredient.
- If there’s a maltster, hop farm, or yeast laboratory you don’t see listed, email email@example.com with a copy of their catalog and we’ll add the inventory.