Skip to main content
Glama

Calculate GP

calculate_gp
Read-onlyIdempotent

UK gross profit (GP) calculator for food and drink. mode 'gp_from_price': give cost_ex_vat and selling_price_inc_vat to get GP % and GP per sale (VAT is removed first, as UK hospitality measures it). mode 'price_from_gp': give cost_ex_vat and target_gp_pct to get the menu price needed.

Input Schema

NameRequiredDescriptionDefault
modeYesgp_from_price or price_from_gp.
cost_ex_vatYesCost of one item/portion, ex-VAT.
vat_rate_pctNoVAT rate. Default 20; use 0 for zero-rated items.
target_gp_pctNoTarget GP %. Required for price_from_gp.
selling_price_inc_vatNoMenu price inc VAT. Required for gp_from_price.

Output Schema

NameRequiredDescriptionDefault
modeYes
gp_pctYes
verdictYes
more_infoYes
cost_ex_vatYes
gross_profitYes
vat_rate_pctYes
food_cost_pctYes
net_price_ex_vatYes
selling_price_inc_vatYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint/idempotentHint/non-destructive, so the safety profile is covered. The description adds real behavioral context beyond that: VAT is stripped before GP is computed because 'UK hospitality measures it' this way, which explains the internal calculation order an agent could not infer from the schema.

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?

Two sentences, front-loaded with the tool's identity and domain, then the two modes in parallel structure. No filler and nothing that could be dropped without losing signal.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists, so return values need not be described, and annotations carry the safety profile. Both modes are fully specified; the only gap is that vat_rate_pct is never referenced in prose, leaving the zero-rated override discoverable only via the schema.

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 coverage is 100% and the schema already flags mode-conditional requirements, but the description adds the mode→parameter pairing in one compact statement and clarifies that selling_price_inc_vat is VAT-inclusive while cost_ex_vat is not. It omits any mention of vat_rate_pct and its default of 20.

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 and resource ('UK gross profit (GP) calculator for food and drink') and immediately enumerates its two operating modes. An agent can distinguish this pure calculator from the recipe/costing siblings (cost_recipe, build_prep_list) without opening the 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 per-mode usage conditions: 'gp_from_price' with cost_ex_vat + selling_price_inc_vat, 'price_from_gp' with cost_ex_vat + target_gp_pct. It does not state when to prefer this over sibling tools like cost_recipe, nor any exclusions, so it stops short of full routing 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.

Resources