Skip to main content
Glama

Calculate upholstery fabric quantity

calculate_fabric
Read-only

Work out how much fabric a reupholstery job needs, in metres and yards. Use this whenever someone asks how much fabric, cloth or material to buy for a chair, sofa, stool, headboard or cushion. Two ways to call it: give a piece name for a rule-of-thumb figure, or give a list of panels with their measurements for a proper cut-list estimate. Handles non-standard fabric widths and pattern repeats. Returns a buy-this-much figure rounded up to the half metre, because cloth is cut in practical lengths.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "calculate_fabric"
  }
}

Input Schema

NameRequiredDescriptionDefault
pieceNoFurniture type, e.g. "wing-back armchair", "3-seat sofa", "drop-in dining seat", "footstool". Options: drop-in dining seat, stuffover dining chair, carver dining armchair, bedroom slipper chair, nursing chair, tub chair, club armchair, wing-back armchair, recliner armchair, loveseat, 2-seat sofa, 3-seat sofa, 4-seat sofa, corner sofa, chaise longue, dressing-table stool, footstool, window seat cushion, large ottoman, headboard single, headboard double, headboard king, deep-buttoned headboard double
panelsNoOptional. Measured panels for an accurate estimate. Overrides "piece" if given.
fabric_width_cmNoRoll width. Default 137 cm, the usual UK upholstery width. American 54-inch cloth is the same thing.
seam_allowance_cmNoTurnings added to every edge of every panel in measured mode. Default 5 cm.
pattern_repeat_allowanceNoMultiplier for matching a pattern. 1 = plain cloth (default). Trade allowances: 1.10 for a repeat up to 20 cm, 1.15 for 20-40 cm, 1.25 for 40-70 cm.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already declare this a safe read-only, non-open-world calculation, and the description adds real context beyond that: output is a buy-this-much figure rounded up to the half metre, non-standard fabric widths and pattern repeats are handled, and the panels mode supersedes a piece name. It does not say what happens when both piece and panels are omitted, which matters since every parameter is optional.

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?

Four tight sentences, front-loaded with the core purpose, then usage triggers, then mode selection, then the rounding caveat with its rationale. Every sentence carries information an agent needs and nothing is repeated.

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?

Covers purpose, modes, defaults and result shape for a five-parameter calculation tool with no output schema. The one gap is behaviour when neither piece nor panels is supplied, given that zero parameters are required.

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%, so the baseline would be 3, but the description adds meaning the schema does not: the distinction between a rule-of-thumb estimate from a piece name and a cut-list estimate from measured panels, and that panels override piece. Defaults and trade pattern-repeat values are left to the schema, appropriately.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource (work out fabric quantity) plus units (metres and yards) and covered furniture types. It is clear what it computes, though it never names a sibling such as calculate_leather to distinguish material-specific calculators from this one.

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 an explicit trigger ("use this whenever someone asks how much fabric, cloth or material to buy") and enumerates the object types it applies to. It also explains the two invocation modes and which to prefer, but offers no when-not-to-use guidance or alternatives for other materials.

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