Skip to main content
Glama

set_nutrient_target

Idempotent

Set or remove the user's OWN daily target for one vitamin, mineral or other tracked nutrient. Use ONLY when the user explicitly asks to set, change or remove their own target ("set my vitamin D target to 50 mcg"). Never call it on your own initiative, to apply a recommendation, or to act on a lab result. A user target is the user's personal preference, never a clinical prescription; do not present it as one. It replaces the reference intake for that nutrient in every nutrient view. Calories and macros are goals, not nutrient targets.

REQUIRED: target_value and unit unless remove is true. Ask for the unit if the user gave none; never guess mcg vs IU or mg vs g. An omitted upper_limit means the reference upper limit applies. remove=true deletes the user's target so the reference intake applies again.

nutrient accepts a name/alias, or the id (1-44) from get_nutrient_summary's nutrient id dictionary -- pass whichever a prior get_nutrient_summary/get_nutrient_history/get_nutrient_contributors compact reply already gave you.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
unitNoUnit the user stated, e.g. mg, mcg, IU, g.
notesNoWhy the user set it, in their words. Kept when omitted.
removeNotrue deletes the user's target for this nutrient. Default false.
nutrientYesNutrient name or alias, e.g. "vitamin_d", "magnesium", "b12" -- or its dictionary id (1-44, e.g. "24" for vitamin_d).
upper_limitNoThe user's own daily ceiling in unit, at least target_value.
target_valueNoDaily target amount in unit.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYesHuman-readable result text returned by the tool.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.8/5.0
Behavior5/5

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

Beyond the annotations (readOnlyHint=false, idempotentHint=true, destructiveHint=false), it discloses consequential behavior: the target 'replaces the reference intake for that nutrient in every nutrient view,' remove=true restores the reference intake, and an omitted upper_limit falls back to the reference upper limit.

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

Conciseness4/5

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

Front-loaded with the purpose and the hardest constraint (only on explicit request), then grouped into a schema-behavior paragraph and a nutrient-identifier paragraph. It is longer than most tool descriptions but nearly every sentence carries a distinct constraint, so little is wasted.

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

Completeness5/5

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

An output schema exists so return values need no explanation, and the description covers the remaining risk surface for a 6-param write tool: required-field conditions, unit ambiguity, default semantics for upper_limit, removal behavior, and cross-tool identifier sourcing.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, but the description genuinely adds meaning: it warns never to guess unit (mcg vs IU, mg vs g), explains that remove=true deletes the target, and tells the agent nutrient may be an id from get_nutrient_summary's dictionary. It stops short of restating notes/upper_limit semantics in depth, so it sits just above baseline.

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

Purpose5/5

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

States a specific verb+resource ('Set or remove the user's OWN daily target for one vitamin, mineral or other tracked nutrient') and explicitly demarcates itself from siblings: 'Calories and macros are goals, not nutrient targets,' ruling out create_goal/update_goal and set_supplement_nutrients.

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

Usage Guidelines5/5

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

Gives explicit when ('ONLY when the user explicitly asks to set, change or remove their own target') and when-not ('Never call it on your own initiative, to apply a recommendation, or to act on a lab result'), plus the framing constraint that a target is a preference, not a prescription.

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.