Skip to main content
Glama

log_template

Log a saved meal by name with optional portion scaling, then return logged items and daily totals versus targets. Use when the user names a saved meal instead of describing food.

Instructions

Log a saved meal by name, optionally scaled. Use when the user names a saved meal instead of describing food. Returns meal_id, the logged items, and the day's totals vs. targets.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "name": "<name>",
      "request_id": "<request_id>"
    },
    "name": "log_template"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYesSaved meal name, as in list_templates
scaleNoPortion multiplier, e.g. 1.5 for a big plate
eaten_atNoISO 8601. No offset means local time. Omit for now.
meal_typeNoOmit to infer from local time of day
request_idYesFresh UUID per write; reuse it only when retrying

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full behavioral burden. It usefully discloses the return payload (meal_id, logged items, day's totals vs targets) and implies a write, but says nothing about what happens when the name does not resolve, whether the write is idempotent, or permission/precondition requirements. Adequate but leaves meaningful gaps for an unannotated mutation.

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?

Three tight sentences: purpose first, disambiguation second, return contract last. No filler, no repetition of the schema, and the most decision-relevant information is front-loaded.

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?

An output schema exists, so the brief return summary is a bonus rather than a necessity, and the schema fully covers the five parameters. The remaining shortfall is behavioral rather than structural: with no annotations, failure handling and preconditions for a write are unaddressed.

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 name, scale, eaten_at, meal_type, and request_id are all documented in structured fields; the baseline is 3. The description adds only the loose phrase "optionally scaled" and no semantics beyond what the schema already provides.

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 and resource ("Log a saved meal by name") plus an optional capability (scaled), and the second sentence draws an explicit line against logging described food, which distinguishes it from log_meal. An agent can pick this tool without inspecting the schema.

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

Usage Guidelines4/5

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

"Use when the user names a saved meal instead of describing food" is a concrete selection condition that implicitly routes free-text food to a sibling. It stops short of naming the alternative tool or stating when not to use this one, so it is clear but not fully exhaustive.

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