com.wallbrew/brew-bot

A quick, dirty way to get randomized beer recipes

https://github.com/wall-brew-co/brew-bot

Science Score: 44.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (13.7%) to scientific vocabulary

Keywords

beer beer-recipes brewing clojure-library clojurescript-library randomized-beer-recipes

Keywords from Contributors

hack interpretability mesh robust standardization parallel distributed projection yolov5 pde
Last synced: 6 months ago · JSON representation ·

Repository

A quick, dirty way to get randomized beer recipes

Basic Info
Statistics
  • Stars: 11
  • Watchers: 2
  • Forks: 4
  • Open Issues: 1
  • Releases: 0
Topics
beer beer-recipes brewing clojure-library clojurescript-library randomized-beer-recipes
Created over 6 years ago · Last pushed 6 months ago
Metadata Files
Readme Changelog Contributing License Code of conduct Citation Codeowners Security

README.md

brew-bot - The algorithmic beer recipe generator

Clojars Project cljdoc badge GitHub Twitter Follow

We’re making beer. I’m the brewery! Bender Bending Rodriguez from Futurama

A Clojure(Script) library to create randomized beer recipes!

The beta release of our SPA is now available!

This repository follows the guidelines and standards of the Wall Brew Open Source Policy.

Installation

A deployed copy of the most recent version of brew-bot can be found on clojars. To use it, add the following as a dependency in your project.clj file:

Clojars Project

The next time you build your application, Leiningen or deps.edn should pull it automatically. Alternatively, you may clone or fork the repository to work with it directly.

Dependencies

This library heavily relies upon the common-beer-format and returns all recipes and ingredients to match its specification. Therefore, all arguments passed to functions in brew-bot are normalized to these standards as well. Most importantly, it assumes measurements are provided in the International System of Units, also known as the modern metric system. Since many brewing applications, especially those based in America, operate on Imperial Measurements, you may wish to add brewtility to any applications consuming this library to assist with conversions between systems of measure.

Usage

All functions necessary to generate a recipe are provided in the core namespace.

```clj (:require [brew-bot.core :refer :all])

(def fermentables (select-fermentables))

(def hops (select-hops :random))

(def yeast (select-yeasts :random {:count-cutoff 1}))

(def my-random-recipe (ingredients->cbf-recipe-template fermentables hops yeast)) ```

Each of the three functions select-fermentables, select-hops, and select-yeasts support multiple arities:

  • Zero - Selects ingredients completely randomly across the full set provided by common-beer-format
  • One - Given a strategy, select ingredients from the full set provided by common-beer-format
  • Two - Given a strategy and a map of options, select ingredients with fine-grained control.

These are the currently supported strategies:

  • :random - Select ingredients at random with an even probability of selection and with replacement
  • :weighted - Select ingredients with a provided selection probability and with replacement. For example, {:galaxy 15.0, :el-dorado 5.0, :topaz 1.0}. In this example, galaxy hops have a 71.43% chance of being selected (15.0 / (15.0 + 5.0 + 1.0)).

These are the currently supported options:

  • amount-cutoff - The maximum weight, in kilograms, of fermentable ingredients to select. Defaults to 2.26796 kilograms (5 pounds)
  • count-cutoff - The maximum number of unique ingredients to allow.
  • selection-weights - A map from ingredient names to probability weights. e.g. {:amber-liquid-extract 5.0 :biscuit-malt 15.0 ...}. Only applicable for the :weighted strategy
  • default-weight - A probability weight to fall back to for ingredients not specified in selection-weights. Only applicable for the :weighted strategy

Additionally, per ingredient type, you may focus the possible ingredient selections. Hops also support two additional options for determining when hops are added and their primary use case.

Fermentables

  • include-adjuncts? - A boolean switch to include adjuncts in the list of selectable ingredients. Defaults to true
  • include-dry-extracts? - A boolean switch to include dry extracts in the list of selectable ingredients. Defaults to true
  • include-extracts? - A boolean switch to include extracts in the list of selectable ingredients. Defaults to true
  • include-grains? - A boolean switch to include grains in the list of selectable ingredients. Defaults to true
  • include-sugars? - A boolean switch to include sugars in the list of selectable ingredients. Defaults to true

Hops

  • timing-strategy - A keyword from the set #{:random :weighted :inferred} to determine how hop timings and uses should be selected. Defaults to :random
  • time-weights - A map from hop addition times to weights. e.g. {120 60.0 45 15.0 ...}
  • use-weights - A map from hop use names to weights. e.g. {"boil" 60 ...}
  • include-aroma? - A boolean switch to include aromatic hops. Defaults to true
  • include-bittering? - A boolean switch to include bittering hops. Defaults to true
  • include-both? - A boolean switch to include dual-purpose hops. Defaults to true

Yeasts

  • include-brewtek? - A boolean switch to include yeasts from Brewtek. Defaults to true
  • include-dcl-fermentis? - A boolean switch to include yeasts from DCL Fermentis. Defaults to true
  • include-lallemand? - A boolean switch to include yeasts from Lallemand. Defaults to true
  • include-white-labs? - A boolean switch to include yeasts from White Labs. Defaults to true
  • include-wyeast? - A boolean switch to include yeasts from Wyeast. Defaults to true

Testing

doo, a Leiningen plugin used to run ClojureScript tests in many JS environments, is already in project.clj. Karma is used as the test runner, and is included in package.json.

To install Karma, simply install the Node package:

shell npm install

Then build the application and run the tests:

shell lein test-build

The tests will also execute on the JVM, to ensure the library is compatible for both runtime environments.

Contributors

The GitHub profile pictures of all current contributors. Clicking this image will lead you to the GitHub contribution graph.

License

Copyright © Wall Brew Co

This software is provided for free, public use as outlined in the MIT License

Citation (CITATION.cff)

# This CITATION.cff file was generated with cffinit.
# Visit https://bit.ly/cffinit to generate yours today!

cff-version: 1.2.0
title: brew-bot
message: Please cite this software using this metadata.
type: software
authors:
  - given-names: Nick
    family-names: Nichols
    email: nichols1991@gmail.com
    orcid: 'https://orcid.org/0000-0002-8267-3211'
identifiers:
  - type: url
    value: >-
      https://github.com/Wall-Brew-Co/brew-bot/releases/tag/v3.0.0
    description: brew-bot v3.0.0 Release
repository-code: 'https://github.com/Wall-Brew-Co/brew-bot'
repository-artifact: 'https://clojars.org/com.wallbrew/brew-bot'
abstract: 'A quick, dirty way to get randomized beer recipes'
license: MIT

GitHub Events

Total
  • Delete event: 69
  • Push event: 87
  • Pull request review event: 11
  • Pull request review comment event: 7
  • Pull request event: 123
  • Create event: 54
Last Year
  • Delete event: 69
  • Push event: 87
  • Pull request review event: 11
  • Pull request review comment event: 7
  • Pull request event: 123
  • Create event: 54

Committers

Last synced: 9 months ago

All Time
  • Total Commits: 417
  • Total Committers: 9
  • Avg Commits per committer: 46.333
  • Development Distribution Score (DDS): 0.695
Past Year
  • Commits: 116
  • Committers: 3
  • Avg Commits per committer: 38.667
  • Development Distribution Score (DDS): 0.267
Top Committers
Name Email Commits
renovate[bot] 2****] 127
Nick Nichols n****s@r****m 107
Nick A. Nichols n****1@g****m 102
Brew Bot 8****t 58
dependabot[bot] 4****] 18
github-actions[bot] 4****] 2
Stepan Anchugov k****1@g****m 1
ImgBotApp I****p@g****m 1
Dareknotderek 3****k 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 6 months ago

All Time
  • Total issues: 11
  • Total pull requests: 330
  • Average time to close issues: 3 months
  • Average time to close pull requests: 8 days
  • Total issue authors: 3
  • Total pull request authors: 6
  • Average comments per issue: 0.45
  • Average comments per pull request: 0.15
  • Merged pull requests: 277
  • Bot issues: 4
  • Bot pull requests: 231
Past Year
  • Issues: 0
  • Pull requests: 141
  • Average time to close issues: N/A
  • Average time to close pull requests: about 21 hours
  • Issue authors: 0
  • Pull request authors: 4
  • Average comments per issue: 0
  • Average comments per pull request: 0.01
  • Merged pull requests: 134
  • Bot issues: 0
  • Bot pull requests: 107
Top Authors
Issue Authors
  • nnichols (7)
  • github-actions[bot] (2)
  • renovate[bot] (2)
Pull Request Authors
  • renovate[bot] (269)
  • WallBrewBot (87)
  • dependabot[bot] (48)
  • nnichols (35)
  • github-actions[bot] (10)
  • imgbot[bot] (1)
Top Labels
Issue Labels
enhancement (3) good first issue (2) TODO (2) branch: master (2) type: todo (2) dependencies (2) automated (2) help wanted (1) tooling (1)
Pull Request Labels
dependencies (318) automated (314) dotfiles (116) restricted (111) clojure (79) synchronize (73) documentation (12) github_actions (10) clojurescript (9) source code (8) test code (6) javascript (4) test-dependencies (4) java (2) tooling (1)

Packages

  • Total packages: 1
  • Total downloads:
    • clojars 135 total
  • Total dependent packages: 0
  • Total dependent repositories: 1
  • Total versions: 7
  • Total maintainers: 1
clojars.org: com.wallbrew/brew-bot

A library to generate randomized beer recipes.

  • Versions: 7
  • Dependent Packages: 0
  • Dependent Repositories: 1
  • Downloads: 135 Total
Rankings
Dependent packages count: 8.1%
Dependent repos count: 14.0%
Forks count: 20.6%
Stargazers count: 30.1%
Average: 33.3%
Downloads: 93.5%
Maintainers (1)
Last synced: 6 months ago