Skip to main content
Glama

Corrected (adjusted) age for a premature baby

corrected_age
Read-onlyIdempotent

The corrected age of a baby born before 37 weeks: the age since birth minus the weeks the baby was early. Use it for 'what is my preemie's corrected / adjusted age', for reading milestones, and for choosing the age at which to plot growth. Takes the birth date and the gestational age at birth and returns the corrected age, the age since birth, the original due date, and the date by which correction usually stops (about 24 months since birth). Before the due date there is no corrected age, and the result says how many days remain. A baby born at 37 weeks or later needs no correction. Dates are calendar dates (YYYY-MM-DD).

Input Schema

NameRequiredDescriptionDefault
asOfNoThe date to calculate the age on, YYYY-MM-DD. Defaults to today in UTC; pass the user's own date to avoid being a day off near midnight.
localeNoLanguage for the disclaimer and any clinician note. Pass the language you will answer the user in: these are clinical safety texts written by a physician, and they should reach the reader as written rather than translated by the model.en
birthDateYesDate of birth, YYYY-MM-DD.
gestationalDaysNoExtra days beyond the completed weeks. A baby born at 32 weeks and 3 days: 3.
gestationalWeeksYesCompleted weeks of pregnancy at birth. A baby born at 32 weeks and 3 days: 32.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / locale / description
      Previous value: -"Language for the disclaimer and any clinician note. Pass the language you will answer the user in: these are clinical safety texts written by a paediatrician, and they should reach the reader as written rather than translated by the model."New value: +"Language for the disclaimer and any clinician note. Pass the language you will answer the user in: these are clinical safety texts written by a physician, and they should reach the reader as written rather than translated by the model."
  2. First observed

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive, closed-world. The description adds substantive domain behavior: correction typically stops around 24 months, before the due date there is no corrected age and the result reports days remaining. It doesn't explain error or edge behavior for out-of-range inputs, but adds meaningful context beyond annotations.

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?

Front-loads the core definition, then use cases, then edge conditions and date format. Four sentences, each carrying information; no redundancy with the title beyond what is needed for precision.

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 calculation tool with no output schema, the description covers definition, use cases, edge cases (before due date and >=37 weeks), the output fields, and the date format. Enough for an agent to invoke correctly and interpret results.

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% with detailed parameter descriptions already present (asOf default and midnight caveat, locale purpose, birthDate, gestationalDays/week). The description mentions birthDate and gestationalWeeks and the concept of weeks early, which aligns with the schema, but adds no parameter-level detail beyond it. Baseline 3 is consistent with high schema coverage.

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 precise resource (corrected/adjusted age for premature babies), defines the calculation ('age since birth minus the weeks the baby was early'), and explicitly scopes that babies born at 37 weeks or later need no correction. This distinguishes it from child_age and other age-related siblings.

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 concrete use cases: answering 'what is my preemie's corrected/adjusted age', reading milestones, and choosing the age at which to plot growth. States exclusions clearly (before due date no corrected age; 37 weeks or later no correction).

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