Skip to main content
Glama

Total a recipe

calculate_recipe
Read-only

Total and per-serving calories and macros for a list of ingredients. Each ingredient needs a food_id from search_foods and a gram weight.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
servingsNoHow many servings to divide the totals into
ingredientsYesIngredients as food_id and grams

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.6/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=true and destructiveHint=false, so the safe read-only nature is covered. The description adds the useful behavioral fact that calculation requires search_foods-derived IDs and gram weights, but says nothing about failure behavior (e.g., unknown food_id) or which macros are returned beyond 'macros'.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two tight sentences, front-loaded with what is computed and followed by the input requirement. No filler and nothing redundant.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With an output schema present, the description need not explain return values, and it adequately covers purpose and inputs. It could be slightly more complete about invalid-ingredient handling or how servings affects per-serving output, but it is sufficient for correct invocation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema already documents grams, food_id, and servings. The description restates the food_id source and gram weighting and hints at per-serving output, but adds no syntax or constraint detail beyond the schema — baseline 3.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource: totals and per-serving calories/macros for a list of ingredients, which clearly separates it from get_food_nutrition (single food) and calculate_portion. It never explicitly names a sibling it is not, so it falls just short of full sibling differentiation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It gives a concrete prerequisite workflow — 'Each ingredient needs a food_id from search_foods' — which tells the agent to call search_foods first. However, it offers no when-to-use vs calculate_portion or calculate_macro_targets guidance, so usage is only implied.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources