Skip to main content
Glama

Last Price

infer_feature_contract

Read-onlyIdempotent

Propose a feature contract from sample pricing requests: nested objects are flattened by path, lists reduced to counts, sums, maxima and has-value flags, numbers binned, and fields that identify someone left out, each with the reason. Nothing is stored; save the result with set_feature_contract. Needs a Last Price credential with routing read scope.

Input Schema

NameRequiredDescriptionDefault
opt_inNoThe customer segment and geo fields are used only when listed here, as in buyer-aware pricing.
bucketsNoBins for each number, at its quantiles. Default 4.
samplesYesSample request contexts, as sent to compute_price in context, metadata included. Not stored.
min_coverageNoShare of samples a field must appear in. Default 0.05.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnly/idempotent/non-destructive, and the description reinforces rather than contradicts that with 'Nothing is stored' plus the auth scope requirement. It also discloses the actual transformation policy (flatten by path, lists to counts/sums/maxima/has-value flags, numbers binned, PII-identifying fields dropped), which annotations alone would never convey.

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?

Front-loaded with the action, then the transformation rules, then the storage/auth caveats. Dense — the first sentence packs five clauses — but each clause carries behavioral information rather than filler.

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?

With no output schema, the description still signals the return shape ('each with the reason'), covers the mutation boundary, and names the credential scope. What's missing is anything about failure modes or sample-size limits (the schema caps at 1000), but the essentials for correct invocation are present.

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 is 3, but the description adds real meaning beyond field docs: it explains what binning means for 'buckets', why some fields are excluded, and that samples are 'as sent to compute_price... not stored'. It does not explicitly tie the opt-in segment/geo behavior to its parameter, which keeps it at 4.

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?

Opens with a specific verb and resource ('Propose a feature contract from sample pricing requests') and immediately distinguishes itself from the sibling that persists it ('save the result with set_feature_contract'). An agent can tell this apart from set_feature_contract/get_feature_contract without reading any 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?

States the workflow position clearly: this is the dry-run proposal step and set_feature_contract is the persistence step ('Nothing is stored'). Also gives the prerequisite ('Needs a Last Price credential with routing read scope'). No explicit exclusion cases, so it falls just short of a 5.

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