Hi everyone! Gram v1.1.0 is now available. This release brings a few practical additions I’ve been working on lately, mainly around recipe importing, nutritional bases, and ingredient database tooling.

Here is a quick overview of what’s new.

YouTube & Shorts Import

You can now pass a YouTube video or Shorts URL to gram import. It uses Gemini’s multimodal video support to analyze the video and audio, extracting steps, ingredients, and timings directly into a .gram recipe file.

I’ve also added duration and token cost previews upfront (along with a --max-duration safety limit) so you don’t accidentally burn through tokens on long videos.

Nutrition per Portion & per 100 g

Nutritional data is no longer limited to whole-recipe totals. You can now view values:

  • Per portion: if you define portions: in the frontmatter, the per-portion nutrition stays fixed even when scaling yields.
  • Per 100 g: calculated from the total assembled raw weight.

You can switch bases via --nutrition <auto|total|per-portion|per-100g> in the CLI (gram view, gram export, gram print), or using the toggle in the web playground and VS Code preview.

Interactive DB Enrichment & Sanity Checks

To make managing ingredients.yaml less tedious and error-prone:

  • Step-by-step review: gram db enrich now walks you through an interactive prompt to check, edit, or reject AI proposals before saving.
  • Physical coherence checks: gram db validate now checks calorie estimates against Atwater factors and warns about impossible densities or sub-macros.
  • Provenance: Values accepted directly from the AI are tagged with # [LLM] in ingredients.yaml so you know where they came from.

AI Model & Provider Options

All AI-assisted commands (gram import, gram db lint, gram db enrich) now support --model, --provider, and --pick-model flags to easily test different models without touching your global config file.


Other Fixes & Tweaks

  • Import safety: Added checks to prevent gram import from writing corrupted files if the model cuts off mid-step. Progress logs now go to stderr, keeping piped output (> recipe.gram) clean.
  • Shopping list: Fixed a bug where composite ingredients with & were listed twice.
  • Percentages in mass totals: Ingredients defined with relative percentages (like @water{60% @&flour}) are now properly included in total weights.

For the detailed list of changes and commit history, head over to the Changelog. As always, feedback is very welcome!