Skip to main content
Glama

Privi Agent Survival & Premium

AI token cost estimator

privi_token_cost
Read-only

Estimate cost using explicitly supplied token quantities and per-million rates; no provider pricing assumed.

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": {
      "input_tokens": "<input_tokens>",
      "output_tokens": "<output_tokens>",
      "input_usd_per_million": "<input_usd_per_million>",
      "output_usd_per_million": "<output_usd_per_million>"
    },
    "name": "privi_token_cost"
  }
}

Input Schema

NameRequiredDescriptionDefault
input_tokensYes
output_tokensYes
input_usd_per_millionYes
output_usd_per_millionYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already establish readOnly and closed-world behavior, so the bar is lower; the description usefully adds that this is a pure computation over supplied numbers with no external pricing lookup. It does not describe the formula, rounding, or currency of the result, which would be the genuinely valuable additions.

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?

A single front-loaded sentence with no filler; the qualifier about provider pricing is placed where it is most useful. Nothing is redundant.

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

Completeness3/5

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

For a simple read-only calculator the inputs are adequately covered, but there is no output schema and the description never says what comes back (a single total, a breakdown, a currency). That leaves a real gap for an agent deciding whether to call it.

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 description coverage is 0%, so the description has to carry parameter meaning. "Per-million rates" clarifies the unit that raw property names like input_usd_per_million leave ambiguous (per 1K vs per 1M), but it adds nothing about token units or whether rates may be zero.

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 ("Estimate cost") and names the inputs it uses (token quantities and per-million rates). The clause "no provider pricing assumed" distinguishes it from price-lookup siblings such as privi_pro_model_cost_estimate, though it does so implicitly rather than by name.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

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

Usage is implied: call it when you already have token counts and your own rates. The exclusion (don't use it if you expect provider pricing to be looked up) is only hinted at, and no alternative tool is named.

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