Skip to main content
Glama

compute_commission

Compute a sales-commission engagement under ASC 340-40 (incremental cost to obtain a contract). Give the commission amount, the benefit period it amortizes over, and how many months have elapsed; it classifies the cost, then capitalizes a recoverable commission and amortizes it straight-line — returning the capitalized asset, amortization to date, the period expense, and the net carrying amount. This is a capitalized asset and an amortization schedule, NOT revenue. It refuses (asks) if recoverability or the amount is unclear. The result is recorded on the engagement file; a principal signs before the workpapers are delivered.

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": {
      "engagement_id": "<engagement_id>",
      "commission_usd": "<commission_usd>",
      "benefit_months": "<benefit_months>",
      "months_elapsed": "<months_elapsed>"
    },
    "name": "compute_commission"
  }
}

Input Schema

NameRequiredDescriptionDefault
engagement_idYesThe commission engagement (opened via open_engagement, classified as a commission).
benefit_monthsYesThe benefit period over which it amortizes, in months.
commission_usdYesThe commission — the incremental cost to obtain the contract.
months_elapsedYesMonths elapsed into the benefit period at this close.
expected_to_be_recoveredNoWhether the cost is expected to be recovered (340-40-25-1). Omit if unknown and it will ask.
elect_practical_expedientNoSet true ONLY if the entity has ELECTED the ≤1-year practical expedient (340-40-25-4) to expense a commission that amortizes within a year. Omit/false → a ≤12-month commission CAPITALIZES (25-1); the expedient is a disclosed election, never auto-applied.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • removedInput schema / properties / contract_terminated
      Removed value: -{
      -  "description": "Set true if the underlying contract was TERMINATED early. The remaining capitalized asset can't simply finish amortizing — it triggers an ASC 340-40-35-3 impairment assessment, raised as an open item rather than closed clean.",
      -  "type": "boolean"
      -}
    • removedInput schema / properties / remaining_consideration_usd
      Removed value: -{
      -  "description": "On a terminated contract, the consideration the entity still expects to receive (340-40-35-3(a)). Omit if none/unknown and the full carrying amount is flagged for impairment review.",
      -  "type": "number"
      -}
  2. First observed

TDQS

A4.4/5.0
Behavior5/5

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

Goes well beyond the annotations (readOnlyHint false, destructiveHint false): it discloses classification-capitalize-amortize sequencing, straight-line method, the exact return figures, an ask-instead-of-guess behavior on ambiguity, persistence to the engagement file, and a principal sign-off gate before workpapers are delivered. That is precisely the write-side and workflow context the annotations cannot express.

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?

Purpose, inputs, outputs, and the not-revenue guardrail are front-loaded in the first two sentences, with refusal and sign-off behavior trailing. It is dense but each clause carries information; the closing workpaper-delivery sentence is slightly peripheral to invocation but still relevant.

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?

With no output schema, the description compensates by enumerating the returned values (capitalized asset, amortization to date, period expense, net carrying amount). For a six-parameter computation tool with a write step and a signing gate, nothing an agent needs to invoke it correctly is missing.

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 all six parameters are already documented, and the description largely restates the three numeric inputs already defined in the schema. It adds no marginal meaning for expected_to_be_recovered or elect_practical_expedient; the baseline 3 applies when the schema carries the weight.

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 ('Compute a sales-commission engagement') and anchors it to ASC 340-40, then explicitly distinguishes it from the revenue siblings with 'This is a capitalized asset and an amortization schedule, NOT revenue.' An agent can separate it from compute_revenue_contract without opening either 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?

Tells the caller exactly what to supply (commission amount, benefit period, months elapsed) and describes a refusal path: 'It refuses (asks) if recoverability or the amount is unclear.' The exclusions are clear (not revenue) but it never names the alternative tool to use when the item is revenue, so routing is one-directional rather than fully explicit.

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