Skip to main content
Glama

Read a diary day

get_day
Read-onlyIdempotent

Read a specific day's diary: meals, logged foods, totals, activities, notes, and tag IDs. Use it to get row IDs needed for updating, moving, or removing items.

Instructions

Read one diary day: per meal its meal_key (the slot other tools take), meal_name (the name the user gave it) and every logged food (row_id, food_type, product_id or recipe_id, name, measure_id, measure_name and measure_quantity, weight in g, energy in kcal, protein/fat/carbohydrate/fiber/sugars/salt in g, eaten); per-meal and day totals; and logged activities (row_id, name, energy in kcal burned); note, the user's own text for the day (null without one), and tags_ids, the ids of its note tags. What the user ate is eaten_totals (rows ticked as eaten); when it is 0 but totals is not, the rows are logged without the tick, so use totals and say so. totals counts every row, planned or eaten. Burned energy is not subtracted. Read the day first to get the row_ids that update_item, move_item and remove_items take. A PRODUCT or RECIPE row's product_id or recipe_id is the food_id that add_food takes, with its food_type, measure_id and measure_quantity as quantity.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dateYesDay as YYYY-MM-DD; when the user says today, yesterday, this week or a weekday, call get_today and count from its date.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
okYes
dataNo
errorNodescribe_error() of what went wrong; docs/AGENTS.md, Results and errors.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.2/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint and openWorldHint=false, so safety is covered. The description does add real behavior beyond that: the eaten_totals=0-but-totals-nonzero fallback, the statement that burned energy is not subtracted, and the null-without-a-note rule. However, with an output schema present it mostly describes the payload rather than the tool's operational behavior.

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 resource and purpose, and every later clause encodes a rule (field mapping, totals caveat, row_id handoff). It is efficient for the amount of information, though enumerating every returned column in a single run-on sentence partly duplicates the output schema.

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?

For a read tool whose annotations and output schema already cover safety and return shape, the description supplies the remaining cross-tool glue: row_ids for update_item/move_item/remove_items, food_id handoff to add_food, and the totals-vs-eaten_totals rule. Nothing needed to call it correctly is missing.

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?

There is a single date parameter and schema description coverage is 100%, including the get_today counting rule, so the schema already carries the semantics. The description adds nothing about the date argument itself, only about the returned fields, so baseline 3 applies.

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 (read) and resource (one diary day) and immediately enumerates the scope: meals, foods, totals, activities, note and tags. It is clearly distinguishable from siblings like get_today, get_range_summary or get_report, which are day-adjacent but different aggregations.

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?

Explicitly prescribes sequencing: 'Read the day first to get the row_ids that update_item, move_item and remove_items take', and explains which field (food_id/food_type/measure_id/measure_quantity) feeds add_food. It also gives in-context guidance on choosing eaten_totals vs totals with the exact edge case that selects between them.

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