Skip to main content
Glama
Systemores AI Agent & MCP Security Auditor

Systemores AI Agent & MCP Security Auditor

Measure Cognitive Throughput Drag

systemores_measure_drag
Read-onlyIdempotent

Calculates single-turn throughput and cost efficiency from prompt length, response length, and latency, returning characters per millisecond, cognitive efficiency, drag rating, and token-cost rating.

Instructions

Calculates single-turn throughput and cost efficiency from scalar promptLength, responseLength, and latencyMs (>= 1), returning characterPerMs, cognitiveEfficiencyScore (0.1–1.0), dragRating (HIGH above 2500ms), and estimatedTokenCostRating (EXPENSIVE above 4000 combined chars). Free, deterministic, stateless local math with no API key required. Use for quick single-turn latency/length math; use systemores_analyze_trace_telemetry for multi-span OpenTelemetry JSON traces or systemores_evaluate_drift for multi-turn behavioral consistency.

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": {
      "promptLength": "<promptLength>",
      "responseLength": "<responseLength>",
      "latencyMs": "<latencyMs>"
    },
    "name": "systemores_measure_drag"
  }
}

Input Schema

NameRequiredDescriptionDefault
latencyMsYesThe end-to-end response latency in milliseconds. Must be >= 1.
promptLengthYesThe character length of the prompt sent to the agent.
responseLengthYesThe character length of the agent's response.

Output Schema

NameRequiredDescriptionDefault
dragRatingYes
characterPerMsYes
cognitiveEfficiencyScoreYes
estimatedTokenCostRatingYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.2.2
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "characterPerMs": {
      +      "type": "number"
      +    },
      +    "cognitiveEfficiencyScore": {
      +      "type": "number"
      +    },
      +    "dragRating": {
      +      "enum": [
      +        "EFFICIENT",
      +        "HIGH"
      +      ],
      +      "type": "string"
      +    },
      +    "estimatedTokenCostRating": {
      +      "enum": [
      +        "OPTIMIZED",
      +        "EXPENSIVE"
      +      ],
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "characterPerMs",
      +    "dragRating",
      +    "estimatedTokenCostRating",
      +    "cognitiveEfficiencyScore"
      +  ],
      +  "type": "object"
      +}
  2. First observedv1.1.3

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive, closed-world, so the safety profile is covered. The description still earns credit by adding that the math is free, deterministic, stateless, and needs no API key, plus the concrete rating thresholds — context structured fields do not carry. It stops short of describing failure modes for invalid input beyond restating the latencyMs >= 1 constraint.

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?

Two dense sentences, front-loaded with the calculation and then the routing guidance; every clause carries information. The output-field list is somewhat redundant given the output schema exists, which keeps it from a 5.

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?

For a three-scalar deterministic calculator with a rich annotation set and an output schema, nothing needed to call it correctly is missing: inputs, units, constraints, thresholds, determinism, and sibling routing are all stated.

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 baseline is 3, but the description adds derived meaning the schema lacks: latencyMs above 2500ms yields dragRating HIGH, and combined promptLength + responseLength above 4000 chars yields EXPENSIVE. That tells the agent how inputs map to outputs, not just their units.

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: "Calculates single-turn throughput and cost efficiency" from three named scalars. It immediately distinguishes itself from systemores_analyze_trace_telemetry (multi-span OTel traces) and systemores_evaluate_drift (multi-turn consistency), so an agent can select 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?

Explicit when-to-use ("quick single-turn latency/length math") paired with two named alternatives and the conditions that select them (multi-span telemetry, multi-turn drift). No inference about routing is required.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.