Skip to main content
Glama

build_program

Read-only

Personalized workout plan, meal plan and macros from a real personal trainer's rules (coach Mat, MTFIT), not generic AI output, for fat loss, weight loss, recomp or muscle gain. Built from the rules coach Mat (MTFIT) uses with his in-person and online clients, backed by 10 years of his own training (160 to 215 lb at about 10 to 12% body fat). Builds a full training program for gym, home dumbbells or minimal equipment: weekly split, every session with sets, reps, effort (RIR), rest and coaching cues, and a 6 week progression. Adds nutrition targets: calories, protein, carbs, fat (macros) and example meals, for fat loss / weight loss, body recomposition or muscle gain. Metric or US units. Returns readable text plus the whole plan as structured JSON. Handles injuries and medical conditions with a conservative plan. Same inputs always give the same plan. Keep program_state for adjust_program. Call get_intake_questions (free) first to know what to ask. For adults 18+. General fitness guidance, not medical advice. Terms: https://mtfit-mcp.mtfit-mcp.workers.dev/terms

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": {
      "goal": "<goal>",
      "days_per_week": "<days_per_week>",
      "session_minutes": "<session_minutes>",
      "equipment": "<equipment>",
      "experience": "<experience>",
      "age": "<age>"
    },
    "name": "build_program"
  }
}

Input Schema

NameRequiredDescriptionDefault
ageYesAge in years. Required. Under 18 gets no program.
sexNoNeeded for nutrition targets.
goalYesThe person's goal.
activityNoActivity outside training. Needed for nutrition targets.
ease_intoNoBody parts to ease into: those days start lighter and shorter.
equipmentYesminimal = one dumbbell, bands, bodyweight.
height_cmNoHeight in centimetres. Needed for nutrition targets. Or send height_ft and height_in.
height_ftNoHeight, feet part (US units). Use with height_in.
height_inNoHeight, inches part (with height_ft), or total height in inches if height_ft is not sent.
weight_kgNoBody weight in kilograms. Needed for nutrition targets. Or send weight_lb.
weight_lbNoBody weight in pounds (US units).
experienceYesbeginner = under 1 year, intermediate = 1 to 3 years, advanced = 3+ years.
food_likesNoFoods the person likes, comma separated. Include 'vegetarian' or 'vegan' if that applies.
prioritizeNoBody parts to prioritize.
days_per_weekYesTraining days per week, 3 to 7 (7 is planned as 6 plus a rest day).
food_dislikesNoFoods to avoid, comma separated.
session_minutesYesMinutes available per session. Any number: the plan uses the nearest fitting length (30, 45, 60 or 75+).
injuries_or_painNoAny injury or pain, in the person's words. Triggers the conservative plan.
does_other_cardioNoDoes the person already do any cardio outside these sessions? If false, a cardio finisher is added whatever the goal.
medical_conditionsNoPregnancy, heart condition or any other medical condition. Triggers the conservative plan.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed15 schema fields changed
    • removedInput schema / properties / days_per_week / anyOf
      Removed value: -[
      -  {
      -    "const": 3,
      -    "type": "number"
      -  },
      -  {
      -    "const": 4,
      -    "type": "number"
      -  },
      -  {
      -    "const": 5,
      -    "type": "number"
      -  },
      -  {
      -    "const": 6,
      -    "type": "number"
      -  }
      -]
    • changedInput schema / properties / days_per_week / description
      Previous value: -"Training days per week, 3 to 6."New value: +"Training days per week, 3 to 7 (7 is planned as 6 plus a rest day)."
    • addedInput schema / properties / days_per_week / maximum
      Added value: +7
    • addedInput schema / properties / days_per_week / minimum
      Added value: +3
    • addedInput schema / properties / days_per_week / type
      Added value: +"integer"
    • changedInput schema / properties / height_cm / description
      Previous value: -"Height in centimetres. Needed for nutrition targets."New value: +"Height in centimetres. Needed for nutrition targets. Or send height_ft and height_in."
    • addedInput schema / properties / height_ft
      Added value: +{
      +  "description": "Height, feet part (US units). Use with height_in.",
      +  "maximum": 7,
      +  "minimum": 3,
      +  "type": "integer"
      +}
    • addedInput schema / properties / height_in
      Added value: +{
      +  "description": "Height, inches part (with height_ft), or total height in inches if height_ft is not sent.",
      +  "maximum": 95,
      +  "minimum": 0,
      +  "type": "number"
      +}
    • removedInput schema / properties / session_minutes / anyOf
      Removed value: -[
      -  {
      -    "const": 30,
      -    "type": "number"
      -  },
      -  {
      -    "const": 45,
      -    "type": "number"
      -  },
      -  {
      -    "const": 60,
      -    "type": "number"
      -  },
      -  {
      -    "const": 75,
      -    "type": "number"
      -  }
      -]
    • changedInput schema / properties / session_minutes / description
      Previous value: -"Session length in minutes. Use 75 for 75 or more."New value: +"Minutes available per session. Any number: the plan uses the nearest fitting length (30, 45, 60 or 75+)."
    • addedInput schema / properties / session_minutes / maximum
      Added value: +240
    • addedInput schema / properties / session_minutes / minimum
      Added value: +15
    • addedInput schema / properties / session_minutes / type
      Added value: +"integer"
    • changedInput schema / properties / weight_kg / description
      Previous value: -"Body weight in kilograms. Needed for nutrition targets."New value: +"Body weight in kilograms. Needed for nutrition targets. Or send weight_lb."
    • addedInput schema / properties / weight_lb
      Added value: +{
      +  "description": "Body weight in pounds (US units).",
      +  "maximum": 660,
      +  "minimum": 77,
      +  "type": "number"
      +}
  2. First observed

TDQS

A4.4/5.0
Behavior5/5

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

Adds substantial behavior beyond readOnlyHint/openWorldHint: determinism ("Same inputs always give the same plan"), output shape (readable text plus structured JSON), a conservative-plan branch triggered by injuries_or_pain and medical_conditions, the state artifact needed by adjust_program, and a scope disclaimer with terms URL. No contradiction with the readOnly annotation, since the tool computes a plan rather than mutating any resource.

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?

Content is dense and purposeful, but front-loading is weak: the first ~40 words are marketing positioning ("not generic AI output", coach credentials, "160 to 215 lb at about 10 to 12% body fat") while the actionable instruction to call get_intake_questions first sits in the final third. Some redundancy ("fat loss / weight loss" repeated, coach Mat named twice).

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?

With 20 parameters and no output schema, the description does the work the schema cannot: it states the return format, the safety branch for injuries and medical conditions, the adult-only scope, the determinism guarantee, and how the produced state feeds adjust_program. Nothing an agent needs in order to call it and route the result 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?

Schema coverage is 100%, so the baseline is 3 and the schema already explains goals, equipment, unit systems and the nearest-fitting session length. The description adds only light framing ("metric or US units", goal set restated, "not medical advice") and no new semantics for the 20 parameters beyond what the schema documents.

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?

Names a specific verb and concrete deliverables (weekly split, per-session sets/reps/RIR/rest, 6-week progression, calories/macros/example meals) and constrains the domain (gym / home dumbbells / minimal equipment, fat loss / recomp / muscle gain). An agent can tell this apart from calculate_macros and swap_exercise on the strength of the text alone.

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 a clear prerequisite ("Call get_intake_questions (free) first to know what to ask") and a downstream handoff ("Keep program_state for adjust_program"), plus an eligibility rule (adults 18+). It never states when NOT to use it or how it differs from the calculate_macros sibling for pure macro requests, so it falls short of full alternative routing.

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