Skip to main content
Glama

Review a program draft

review_program_draft
Read-only

Server-side checklist for an unsaved DRAFT training program: it takes the same WorkoutDocument that import_document would take, and verifies day references resolve, every exercise is identifiable, rep ranges make sense, and, in 'coached' mode, that each exercise has a starting weight (or calibration note), matches the user's equipment, does not load an active injury (by the exercise's movement pattern and primary muscles) and respects session length / weekly days.

program_mode='preserve' is for the user's OWN program brought in from a file. The same structural errors are refused, but a missing weight is accepted as a fact about their program, and an equipment or schedule mismatch comes back as a warning rather than a violation. The mode matches the one passed to import_document.

Returns {ok, mode, violations, warnings, unresolved, notes}. unresolved lists fields the file never stated; they are left empty, not inferred. Saves nothing: no profile, intake state, goal or coaching history is created or changed.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
documentYes
program_modeNocoached

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed22 schema fields changed
    • changedInput schema / properties / document / properties / body_metrics / items / properties / bodyweight_kg / description
      Previous value: -"Body weight in kilograms. Convert pounds first (1 lb = 0.4536 kg)."New value: +"Body weight in kilograms (1 lb = 0.4536 kg)."
    • changedInput schema / properties / document / properties / body_metrics / items / properties / id / description
      Previous value: -"Leave empty when recording a measurement the user gives you: the entry is then keyed by its date. An id marks an entry copied from a source document (an export, a spreadsheet); import_document manages those, and recording the same id twice fails."New value: +"Absent for a measurement the user states in conversation: that entry is keyed by its date. An id marks an entry copied from a source document (an export, a spreadsheet); import_document manages those, and recording the same id twice fails."
    • changedInput schema / properties / document / properties / exercises / items / properties / category / description
      Previous value: -"What kind of work this is. `cardio` and `mobility` deposit no muscle load at all, so never use them for resistance work — a stretch or a run tagged `compound` lights up the muscle map for days."New value: +"What kind of work this is. `cardio` and `mobility` deposit no muscle load, so they do not describe resistance work; a stretch or a run tagged `compound` shows on the muscle map for days."
    • changedInput schema / properties / document / properties / exercises / items / properties / dose_unit / description
      Previous value: -"What this exercise is dosed in: 'reps' (the usual case), 'seconds' for holds and carries (plank, dead hang, farmer's walk), or 'minutes' for cardio. It says what the rep range and every logged set's number mean — a 60-second plank is not 60 reps."New value: +"What this exercise is dosed in: 'reps' (the usual case), 'seconds' for holds and carries (plank, dead hang, farmer's walk), or 'minutes' for cardio. It is the unit of the planned target; a logged set keeps reps in `reps` and time in `duration_sec` whatever it is, so a 60-second plank is never 60 reps."
    • changedInput schema / properties / document / properties / exercises / items / properties / long_length / description
      Previous value: -"True when the target muscle is loaded in a stretched position (RDL, incline curl, Nordic curl); false when the stretched half is removed (rack pull, hip thrust, cable kickback). Its residual load persists longer in the muscle load model. Leave null only when you genuinely cannot tell from the movement."New value: +"True when the target muscle is loaded in a stretched position (RDL, incline curl, Nordic curl); false when the stretched half is removed (rack pull, hip thrust, cable kickback). Its residual load persists longer in the muscle load model. Null means unclassified, and the model then infers it from the movement pattern."
    • changedInput schema / properties / document / properties / exercises / items / properties / movement_pattern / description
      Previous value: -"The pattern the movement belongs to (squat, hinge, horizontal_push, …). Keep it the same across variations of one lift: it is how the model judges whether a muscle is already accustomed to that pattern."New value: +"The pattern the movement belongs to (squat, hinge, horizontal_push, …). Variations of one lift share a pattern: the load model judges from it whether a muscle is already accustomed to that pattern, and injury checks match on it."
    • changedInput schema / properties / document / properties / exercises / items / properties / pool_slug / description
      Previous value: -"The `slug` of the matching entry from search_exercise_pool, when this exercise comes from the curated pool. Set it whenever a pool entry matches — it keeps one movement under one identity even if the display name is later edited or translated."New value: +"The `slug` of the matching entry from search_exercise_pool, for an exercise that matches a curated pool entry. It keeps one movement under one identity even if the display name is later edited or translated."
    • changedInput schema / properties / document / properties / exercises / items / properties / primary_muscles / description
      Previous value: -"The muscles the exercise is done FOR — the prime movers. These alone are counted against the weekly MEV/MAV set landmarks, so list the target, not everything the movement involves."New value: +"The muscles the exercise is done FOR, the prime movers; assisting and stabilising muscles are the secondary and tertiary lists. Only these count against the weekly MEV/MAV set landmarks."
    • changedInput schema / properties / document / properties / exercises / items / properties / secondary_muscles / description
      Previous value: -"Muscles that assist meaningfully but are not the target (triceps on a bench press). They count in the muscle load model at a reduced weight. Never repeat a primary muscle here."New value: +"Muscles that assist meaningfully but are not the target (triceps on a bench press). They count in the muscle load model at a reduced weight. The list excludes the primary muscles."
    • changedInput schema / properties / document / properties / exercises / items / properties / tertiary_muscles / description
      Previous value: -"Stabilisers and minor assistance (abs on a standing press). They count at a further reduced weight. Never repeat a muscle already listed as primary or secondary; leave empty when unsure."New value: +"Stabilisers and minor assistance (abs on a standing press). They count at a further reduced weight. The list excludes primary and secondary muscles; empty means unspecified."
    • changedInput schema / properties / document / properties / sessions / items / properties / date / description
      Previous value: -"The calendar date the workout happened, in the USER's timezone. Today only when the conversation is plainly about the session they just did. For anything logged after the fact, take the date from what the user said ('last Tuesday') and ask when that is unclear — never derive one from the server's clock. Everything time-based (weekly volume, the muscle load model, the consistency level) is anchored on it."New value: +"The calendar date the workout happened, in the USER's timezone: the day they did it, which for a session logged after the fact ('last Tuesday') is not today, and which the server's UTC clock does not know. Everything time-based (weekly volume, the muscle load model, the consistency level) is anchored on it."
    • changedInput schema / properties / document / properties / sessions / items / properties / entries / items / properties / exercise_id / description
      Previous value: -"Catalog id of the exercise performed. Reuse an id the user already has (`exercise_catalog` in the coaching context, or list_exercises), otherwise a `slug` from search_exercise_pool verbatim. Minting a synonym for a movement that already has an id splits that movement's history in two."New value: +"Catalog id of the exercise performed: an id from the user's catalog (`exercise_catalog` in the coaching context, or list_exercises) or a `slug` from search_exercise_pool, character for character. A new id for a movement that already has one splits that movement's history in two."
    • changedInput schema / properties / document / properties / sessions / items / properties / entries / items / properties / sets / items / properties / distance_m / description
      Previous value: -"Metres covered, for a carry or an interval the user measured that way ('farmer's walk, 30 metres'). Use it instead of duration_sec when what they said was a distance, not a time; fill both only when they gave both."New value: +"Metres covered, for a carry or an interval the user measured that way ('farmer's walk, 30 metres'). Both distance_m and duration_sec are present only when both were measured."
    • changedInput schema / properties / document / properties / sessions / items / properties / entries / items / properties / sets / items / properties / duration_sec / description
      Previous value: -"Seconds under load for a hold or carry (plank, dead hang, farmer's walk), or the duration of a timed interval. Isometric work is dosed in seconds, not reps. Use it when the user gave a time; when they gave a distance instead, use distance_m."New value: +"Seconds under load for a hold or carry (plank, dead hang, farmer's walk), or the duration of a timed interval. Isometric work is dosed in seconds, not reps. A distance-measured carry or interval is distance_m instead."
    • changedInput schema / properties / document / properties / sessions / items / properties / entries / items / properties / sets / items / properties / is_per_side / description
      Previous value: -"True when the set was done one side at a time. Log it as ONE set whose `reps` holds ONE side's count — never doubled, never split into two sets — and set this flag so the number is read the way it was meant. A timed one-sided hold or carry is per-side too: fill duration_sec, leave reps empty. Logging the same exercise both ways stops it comparing to itself."New value: +"True when the set was done one side at a time. Such a set is ONE record whose `reps` (or duration_sec, for a one-sided hold or carry) is ONE side's count, neither doubled nor split into two sets. An exercise recorded both ways does not compare with itself."
    • changedInput schema / properties / document / properties / sessions / items / properties / entries / items / properties / sets / items / properties / reps / description
      Previous value: -"Reps actually completed. On a per-side set give ONE side's count and set is_per_side — never the doubled total, never two sets. Leave empty for a timed hold or carry and use duration_sec instead."New value: +"Reps actually completed. On a per-side set (is_per_side) this is ONE side's count: not the doubled total, and not split into two sets. Empty for a timed hold or carry, whose dose is duration_sec."
    • changedInput schema / properties / document / properties / sessions / items / properties / entries / items / properties / sets / items / properties / rir / description
      Previous value: -"Reps left in the tank at the end of the set; 0 means taken to failure. Fill it only when the user says how close to failure they got ('had two left', 'went to failure'); a bare 'that was hard' or 'felt easy' is not a number — leave it empty rather than guessing one. It is what tells the model the set's load fades slower."New value: +"Reps left in the tank at the end of the set as the user stated it ('had two left', 'went to failure' = 0); a bare 'that was hard' or 'felt easy' states no number, and then the field is empty. It is what tells the model the set's load fades slower."
    • changedInput schema / properties / document / properties / sessions / items / properties / entries / items / properties / sets / items / properties / rpe / description
      Previous value: -"Perceived effort 0-10 — the same question as rir on the other scale (RPE 10 = RIR 0). Use it when the user talks in RPE; rir wins when both are given."New value: +"Perceived effort 0-10 — the same question as rir on the other scale (RPE 10 = RIR 0). It holds a value the user gave in RPE; when both are present, rir takes precedence."
    • changedInput schema / properties / document / properties / sessions / items / properties / entries / items / properties / sets / items / properties / set_id / description
      Previous value: -"The client's own stable id for this set, if it has one. Only the AIm app sends this: it lets a later correction be traced to the set that moved, because set_number is renumbered when a set is removed. Other clients have none and leave it out."New value: +"The client's own stable id for this set, if it has one. Only the AIm app sends this: it lets a later correction be traced to the set that moved, because set_number is renumbered when a set is removed. Absent from other clients."
    • changedInput schema / properties / document / properties / sessions / items / properties / entries / items / properties / sets / items / properties / type / description
      Previous value: -"`working` for real sets. Mark ramp-up sets `warmup`: they are excluded from volume, weekly set counts and the muscle load model, so logging them as working inflates every number the coach reads back. A drop set is not one set: log each weight stage as its own entry in the order performed, the lighter stages `dropset`."New value: +"`working` for real sets, `warmup` for ramp-up sets: warm-ups are excluded from volume, weekly set counts and the muscle load model, and counted as working they inflate every number read back. A drop set is several records, one per weight stage in the order performed, the lighter stages typed `dropset`."
    • changedInput schema / properties / document / properties / sessions / items / properties / entries / items / properties / sets / items / properties / weight_kg / description
      Previous value: -"Load in kilograms: the whole bar for barbell work, ONE dumbbell or kettlebell for dumbbell work. Omit for unloaded bodyweight sets; give only the added weight when the user hangs a plate off a belt."New value: +"Load in kilograms: the whole bar for barbell work, ONE dumbbell or kettlebell for dumbbell work. Absent for unloaded bodyweight sets; for weighted bodyweight work (a plate on a belt) it is the added weight only."
    • changedInput schema / properties / document / properties / sessions / items / properties / start_time / description
      Previous value: -"When the session started, with timezone offset, if the user actually said. Omit it rather than inventing a plausible time."New value: +"When the session started, with timezone offset, as the user stated it; absent when they did not say."
  2. Changed1 schema field changed
    • addedInput schema / properties / document / properties / day_templates / items / properties / blocks / items / properties / items / items / properties / id
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null
      +}
  3. Changed1 schema field changed
    • changedInput schema / properties / document / properties / sessions / items / properties / entries / items / properties / sets / items / properties / set_id / description
      Previous value: -"The client's own stable id for this set, if it has one. Only the AIm app sends this: it lets a later correction be traced to the set that moved, because set_number is renumbered when a set is removed. Never invent one — omit it."New value: +"The client's own stable id for this set, if it has one. Only the AIm app sends this: it lets a later correction be traced to the set that moved, because set_number is renumbered when a set is removed. Other clients have none and leave it out."
  4. Changed9 schema fields changed
    • addedInput schema / properties / document / properties / body_metrics / items / properties / athlete_id / description
      Added value: +"Ignored when recording: every entry belongs to the signed-in user."
    • addedInput schema / properties / document / properties / body_metrics / items / properties / body_fat_pct / description
      Added value: +"Body-fat percentage, 0 to 100."
    • addedInput schema / properties / document / properties / body_metrics / items / properties / bodyweight_kg / description
      Added value: +"Body weight in kilograms. Convert pounds first (1 lb = 0.4536 kg)."
    • addedInput schema / properties / document / properties / body_metrics / items / properties / custom_fields / description
      Added value: +"Anything worth keeping that has no field above, such as `resting_hr`. Stored and exported, not displayed."
    • addedInput schema / properties / document / properties / body_metrics / items / properties / date / description
      Added value: +"Day the measurement was taken, YYYY-MM-DD in the user's own calendar. Without an id there is one entry per day: recording the same date again adds to that day's entry, overwriting only the fields and keys you send."
    • addedInput schema / properties / document / properties / body_metrics / items / properties / id / description
      Added value: +"Leave empty when recording a measurement the user gives you: the entry is then keyed by its date. An id marks an entry copied from a source document (an export, a spreadsheet); import_document manages those, and recording the same id twice fails."
    • addedInput schema / properties / document / properties / body_metrics / items / properties / measurements / description
      Added value: +"Circumferences in centimetres, keyed `<site>_cm`. The app shows `chest_cm`, `arm_cm`, `waist_cm` and `thigh_cm`; any other site is stored but not displayed."
    • addedInput schema / properties / document / properties / body_metrics / items / properties / notes / description
      Added value: +"Context the user gave with the number (fasted, evening, after travel)."
    • addedInput schema / properties / document / properties / body_metrics / items / properties / source / description
      Added value: +"Where the number came from, free text: `scale`, `tape`, `dexa`, `smart_scale`"
  5. Changed2 schema fields changed
    • addedInput schema / properties / document / properties / sessions / items / properties / entries / items / properties / sets / items / properties / set_id
      Added value: +{
      +  "anyOf": [
      +    {
      +      "maxLength": 128,
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "The client's own stable id for this set, if it has one. Only the AIm app sends this: it lets a later correction be traced to the set that moved, because set_number is renumbered when a set is removed. Never invent one — omit it."
      +}
    • addedInput schema / properties / program_mode
      Added value: +{
      +  "default": "coached",
      +  "enum": [
      +    "coached",
      +    "preserve"
      +  ],
      +  "type": "string"
      +}
  6. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already declare readOnlyHint=true and openWorldHint=false, and the description adds substantial context beyond that: it explicitly states 'Saves nothing: no profile, intake state, goal or coaching history is created or changed', and it discloses the mode-dependent severity behavior (warning vs violation) that is not visible in any structured field.

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?

Purpose and the mode distinction are front-loaded, and every sentence conveys information (checks performed, mode semantics, return shape, no side effects). It reads as two dense paragraphs rather than a scannable structure, but there is little waste.

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 nested-document validator with an output schema, the description is complete: it covers what is validated, the two modes, the output fields (even though an output schema exists), and the absence of side effects. Nothing an agent needs to invoke it correctly is missing.

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?

Top-level schema coverage is 0%, so the description carries the burden. It defines program_mode's two values in behavioral terms (coached vs preserve) and explains that `document` is the same WorkoutDocument import_document consumes, plus documents the 'unresolved' return field. This meaningfully compensates for the missing top-level parameter descriptions.

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 ('server-side checklist for an unsaved DRAFT training program') and enumerates exactly what it verifies (day references, exercise identifiability, rep ranges, equipment, injury and session-length checks). It also explicitly distinguishes itself from import_document by noting it takes the same WorkoutDocument, so an agent can tell them apart without opening a 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?

Gives clear context for the two modes: 'coached' for validation with violations, and program_mode='preserve' for a user's own file where structural errors are still refused but weight/equipment/schedule issues downgrade to warnings. It ties the mode to the one passed to import_document. It stops short of an explicit 'call this before import_document' imperative or a when-not-to-use statement.

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.