/cooklang:report-authoringfrom cooklang
Writes and runs custom Jinja2 report templates over Cooklang recipes (.cook) or meal plans (.menu) via the Cook MCP server's render_report tool — for computed values, cost estimates, or custom summaries.
Ships in cooklang. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Needs the Cook MCP server (tools like render_report and write_config). If these tools are missing, the Cook MCP server isn't connected: if you installed the cooklang plugin or extension, check that its cook server is running (e.g. /mcp) or reinstall it; otherwise add it from https://github.com/cook-md/cook-mcp. Do not compute report values by hand instead.
Author and run Jinja2 report templates over the user's recipes with the
render_report tool — or reuse a saved one — then answer from the output or
present the report. Use this skill when the user wants a computed value
(ingredient counts, a scaled printout), a custom report or summary, or a new
report template. For nutrition or dietitian-style evaluations, follow the
nutrition-reports skill instead.
Templates that don't call nutrition functions render locally, with no login.
Datastore values live in YAML files under db/; cook-mcp has no tool that
writes them, so ask the user to add data there (or use your client's file
tools).
render_report renders one template against one .cook recipe or .menu
plan and returns { "rendered", "checks", "resolve_failures" }, or an error
naming the template line. It never edits files.
Arguments — the template, exactly one of:
template — inline Jinja2 source, for drafts and one-off reports.template_path — a saved template file, relative to the collection root
(e.g. reports/cost.md.jinja). Prefer it whenever a suitable saved
template exists.The input, exactly one of:
input_path — a .cook or .menu file as list_recipes returned it (kind
inferred from the extension).input — inline Cooklang text, with kind ("cook" or "menu").Optional:
scale — recipe scale factor (default 1). Scales .cook recipes only, not
.menu quantities.base_path — folder that @./ references resolve from; defaults to the
collection root, which is almost always right.Within a template you have:
ingredients — list; each item has .name and .quantity.metadata — recipe metadata, including metadata.title and any custom keys.scale — the numeric scale factor..menu input: plan — the plan's days and meals with their expanded
ingredients (a menu is read through plan.*, not ingredients).Collection data:
aisled(ingredients) — groups ingredients by store aisle from
config/aisle.conf: a map of aisle → items, unlisted items under other.
Use it with | items.excluding_pantry(ingredients) — drops ingredients already in
config/pantry.conf; from_pantry(ingredients) keeps only those.db('key.path') — reads the collection's YAML datastore, the db/ folder
at the root: db('eggs.shopping.price') is the price key of
db/eggs/shopping.yml. Use it for per-ingredient data the recipes don't
carry (prices, shelf life, densities). A missing key renders empty.Filters available:
sort(attribute='name'), default(...), round, join,
selectattr, items, length.titleize, humanize, upcase_first.number_with_precision, number_with_delimiter,
number_to_percentage, number_to_currency, format_price, numeric.Example — an ingredients list:
# {{ metadata.title | default("Ingredients") }}
{% for ingredient in ingredients | sort(attribute='name') -%}
- {{ ingredient.name }}{% if ingredient.quantity %}: {{ ingredient.quantity }}{% endif %}
{% endfor %}
Example — a cost estimate from the datastore, skipping what's in stock:
{% set ns = namespace(total=0) %}
{% for aisle, items in aisled(excluding_pantry(ingredients)) | items %}
## {{ aisle | titleize }}
{% for i in items -%}
{% set price = db(i.name ~ '.shopping.price') %}
- {{ i.name }}{% if price %}: {{ price | format_price }}{% set ns.total = ns.total + price %}{% endif %}
{% endfor %}
{% endfor %}
**Estimated total:** {{ ns.total | format_price }}
For a plain shopping list, use the shopping_list tool rather than a template:
it merges duplicates across recipes, groups by aisle and subtracts the pantry.
reports/ (CookCLI) or config/reports/ (Cook
Editor): list_recipes kind: "template" lists both. If one matches the request (read the name;
ask the user when it isn't conclusive), render it with template_path and
skip to step 4.render_report with template. If it errors, read the message
(minijinja reports the line), fix the template, and render again until it
renders cleanly.rendered and
reply with the answer. To present a report, show the rendered markdown to
the user as it came back.When the user wants to keep a report, save the template as a .jinja file:
reports/ (CookCLI)
or config/reports/ (Cook Editor), whichever list_recipes
kind: "template" shows in use; default reports/. Subfolders are fine.weekly-cost.md.jinja -> markdown, menu.html.jinja -> HTML,
shopping.txt.jinja -> plain text.write_config (path e.g. reports/weekly-cost.md.jinja,
the full template as content), and tell the user where.template_path — never re-send the source
inline.Render inline for one-off questions; offer once to save a template, and save only if the user accepts.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub cooklang/cooklang-skills --plugin cooklang14 skills in this plugin
/cooklang-editingUse when writing a new Cooklang recipe or editing or fixing a .cook file - ingredients, cookware, timers, steps, sections, or resizing a recipe for good. For metadata/frontmatter changes use the metadata skill; to just show scaled amounts use scale-recipe. Not for meal plans (.menu) or importing from a URL/text./cooklang-validationUse when checking or validating Cooklang - one .cook recipe, a folder, or the whole collection - for syntax errors and broken references, or when asked to fix or clean up Cooklang (e.g. a stray ingredient list or unbraced multi-word names)./export-recipeUse when the user wants a Cooklang recipe (.cook) or meal plan (.menu) in another format - Markdown for a blog or notes, JSON or YAML for an app, plain text to paste or print, HTML, LaTeX - or a reusable export template. Not for importing into Cooklang (recipe-import)./meal-planningUse when building or editing a Cooklang meal plan (.menu file), weekly plans, multi-day menus, or matching servings across days. Not for a single recipe. With a numeric nutrition target ("35% protein", "1800 kcal/day"), screen candidates with nutrition-reports first, then build the plan here; nutrition-goals is only for changing an already-chosen recipe to hit a number./metadataUse when adding, normalizing, or fixing YAML frontmatter in Cooklang .cook recipes or .menu plans (title, tags, source, servings/yield, times, diet, locale, images), including converting old >> metadata lines and bulk metadata changes across a library./nutrition-goalsUse when the user wants to change AN EXISTING Cooklang recipe (.cook) or meal plan (.menu) so it hits numeric nutrition targets ("make this 600 kcal per serving", "get my week to 150 g protein a day", "more protein, same calories"). Measures with the Cook nutrition service, edits, and verifies. Not for evaluation-only questions (nutrition-reports), and not for picking or screening recipes that already meet a number (nutrition-reports screening, then meal-planning).Other plugins' skills for the same job