Skip to main content
Glama

log_lab_results

Log one or more blood test or biomarker results. Use when the user shares lab values — copy-pasted from a Quest/LabCorp PDF, typed from a paper report, or described from a photo of their results.

GLUCOSE ROUTING: use this tool for glucose only when it is an actual lab/blood-draw result or part of a reported lab panel. Finger-stick, CGM, home meter, wearable, Apple Health, or Health Connect glucose — including a manual correction to daily glucose — belongs in log_wearable as blood_glucose_mg_dl, not here.

REQUIRED WORKFLOW: 1) call list_lab_markers for canonical names and LOINC codes. 2) for each marker the user provides, find the best match and use its canonical marker_name and loinc_code. 3) if no match exists, use the name as stated and omit loinc_code.

If the user says they have lab results but hasn't shared them, prompt: "You can paste the text from your lab report PDF, or upload a photo of the results page — I'll parse all the values at once."

INFER — do not ask: date (look for a collection/drawn date in the pasted text, default today), panel_name (from list_lab_markers for matched markers, infer for unmatched), flag (extract from the report if present: "H", "L", "HH", "LL", "A"), ref_range_low/high (parse from the report if shown), lab_name (from the report header, same for all markers in a visit).

FASTING: fasting_status is only 'fasting' or 'non_fasting' when the user explicitly states it ("I fasted for this", "hadn't eaten"). Never infer it from time of day, a meal mention in notes, or the draw being in the morning — omit the field (leaves it unknown) whenever it wasn't stated. report_date (when the lab reported results, if given separately from the collection date) and draw_id (only when the user is adding a marker to a draw already logged in this conversation) are also optional, omit otherwise.

Submit all markers from a single lab visit in one call.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultsYesArray of individual lab marker results. Required — submit all markers from the visit in a single call.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYesHuman-readable result text returned by the tool.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / results / items / properties / draw_id / description
      Previous value: -"Groups this marker with others from the same draw. See FASTING above. Optional."New value: +"Opaque label of your choosing to group this marker with others from the same draw, normalized server-side. See FASTING above. Optional."
  2. Changed3 schema fields changed
    • addedInput schema / properties / results / items / properties / draw_id
      Added value: +{
      +  "description": "Groups this marker with others from the same draw. See FASTING above. Optional.",
      +  "type": "string"
      +}
    • addedInput schema / properties / results / items / properties / fasting_status
      Added value: +{
      +  "description": "See FASTING above. Optional, omit to leave unknown.",
      +  "enum": [
      +    "fasting",
      +    "non_fasting",
      +    "unknown"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / results / items / properties / report_date
      Added value: +{
      +  "description": "Report/result date, if stated separately from the collection date. Format: YYYY-MM-DD. See FASTING above. Optional.",
      +  "type": "string"
      +}
  3. First observed

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already indicate readOnlyHint=false, destructiveHint=false, idempotentHint=false, so the mutation profile is known. The description adds valuable behavioral context: it mandates a required workflow (list_lab_markers first), specifies inference rules (date, panel_name, flag, ref_range, lab_name), and clarifies fasting_status handling with explicit never-infer rules. It also states that all markers from a single visit should be submitted in one call. This goes well beyond the annotations.

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?

The description is long but every section earns its place: purpose, glucose routing, required workflow, prompting, inference rules, fasting rules, and batching instruction. It is well-structured with clear section headers (GLUCOSE ROUTING, REQUIRED WORKFLOW, INFER, FASTING) and front-loads the core purpose. It could be slightly tighter, but the density of actionable guidance justifies the length.

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 tool with one array parameter and a rich nested schema, the description covers all the operational context an agent needs: when to use it, how to prepare canonical names, what to infer, what to ask, and how to batch. The output schema exists, so return values don't need explanation. The only minor gap is that it doesn't describe what the response looks like, but the output schema covers that. This is complete for the tool's complexity.

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?

Schema description coverage is 100%, so the baseline is 3. The description adds significant meaning beyond the schema: it explains the canonical marker_name/loinc_code workflow, defines when to omit loinc_code, clarifies fasting_status semantics (only 'fasting'/'non_fasting' when explicitly stated, omit otherwise), and explains draw_id usage. It also clarifies that report_date and draw_id are optional and when to include them. This is meaningful added value over the schema.

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?

The description opens with a specific verb and resource: 'Log one or more blood test or biomarker results.' It then immediately distinguishes itself from log_wearable by routing finger-stick/CGM/home meter glucose to that sibling. This is a clear, specific purpose statement that differentiates the tool from its closest alternative.

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?

The description provides explicit when-to-use guidance: use for lab/blood-draw results, and explicitly excludes finger-stick, CGM, home meter, wearable, Apple Health, and Health Connect glucose, directing those to log_wearable. It also specifies the required workflow (call list_lab_markers first) and the prompt to use when the user hasn't shared results yet. This is exemplary usage guidance.

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.