Skip to main content
Glama

Suggest Curves for Items

suggest_curves_for_items
Read-only

Which existing demand curve fits these items best? Derives the items' observed 12-month seasonal shape from their sales history and ranks the tenant's seasonal curves by cosine similarity to it (best fit first, 0..1). Use before apply_demand_curve_to_items to pick a curve for a batch of items; when hasSignal is false the items have too little history to compare — judge individual items with get_item_seasonal_shape instead. Item ids come from list_items. The ids must belong to the targeted catalog: a client-pinned credential profiles its own client's items, and an operator (unpinned) credential profiles the house catalog unless clientId targets a client's items. Max 500 ids per call (the shape is computed from a bounded freshest-item sample, so a representative batch is enough).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "itemIds": "<itemIds>"
    },
    "name": "suggest_curves_for_items"
  }
}

Input Schema

NameRequiredDescriptionDefault
itemIdsYesItem ids (GUIDs) to profile, max 500 per call.
clientIdNoOptional client id (GUID) for operator (unpinned) credentials on 3PL tenants: profiles that client's items instead of the house catalog — get ids from list_clients. Client-pinned credentials omit this; the credential decides.

Output Schema

NameRequiredDescriptionDefault
okNo
hasSignalNo
suggestionsNo
notFoundHintNo
notFoundCountNo
observedShapeNo
matchedItemCountNo
contributingItemCountNo

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 this a safe read (readOnlyHint=true, destructiveHint=false), so the bar is low, yet the description adds real context: the ranking is best-fit-first on a 0..1 scale, the shape comes from a bounded freshest-item sample, and the credential/catalog scoping rules (client-pinned vs operator, house catalog by default, clientId override) are disclosed. It stops short of describing the tie-breaking or ordering guarantees of equal-similarity curves.

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 core question, then routing guidance, then auth scoping, then the id limit — a sensible priority order with no filler sentences. It is a dense single block, though, and the catalog-membership rule and the 500-id cap are stated twice in slightly different wording.

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?

An output schema exists, so return values need not be explained, yet the description still tells the agent what to expect (ranked curves, 0..1, hasSignal flag) and what to do when the signal is absent. For a read-only, two-parameter tool this is complete enough to call correctly on the first attempt.

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%, so both parameters are already documented, and the description largely restates itemIds' 500-id cap and clientId's pinning behavior rather than adding new meaning. It does add the useful rationale that a representative batch suffices because the shape is computed from a bounded sample, but that is a marginal gain 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?

Opens with a specific question-form verb and resource: derives a 12-month seasonal shape from sales history and ranks the tenant's existing curves by cosine similarity. It explicitly contrasts with both siblings (apply_demand_curve_to_items as the follow-up, get_item_seasonal_shape as the per-item fallback), so an agent can distinguish it without opening 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 Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives an explicit call sequence ('Use before apply_demand_curve_to_items'), an explicit exclusion path ('when hasSignal is false... judge individual items with get_item_seasonal_shape instead'), and names where ids come from (list_items). Both when-to-use and when-not-to-use are stated.

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