Skip to main content
Glama

Test a prompt across models

test_prompt

Use this when someone has a prompt (pasted, or one their app sends) and wants to know which model does it best or cheapest, how models such as GPT, Claude and Gemini compare on it, or whether a cheaper model would do. Runs it on realistic cases across several models and checks every answer. Do not use for general questions about models with no prompt to test. A prompt without {{variables}} is fine: the part that changes is found and varied. Cases and checks are drafted if left out. Spends credit, never more than max_spend_usd by estimate. Returns a test_id at once: call get_test for the results. Each call starts a new paid test, so don't call it again to follow one. Set mode to image for image generation prompts and visual checks.

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": {
      "prompt": "<prompt>"
    },
    "name": "test_prompt"
  }
}

Input Schema

NameRequiredDescriptionDefault
modeNoSet to conversation for a multi-turn test or image for image generation. Omit for text.
nameNoA short name, like Support triage.
casesNoRealistic inputs, up to 50: each {values: {variable: text}}, or, for a prompt without variables, the example as plain text.
toolsNoFor a conversation test, up to 8 dummy tools the agent can call. Nothing real is ever run: each call gets back the result written for it.
checksNoYes/no statements a good answer meets. In a conversation test a statement is judged against the whole transcript, and an item can also be a rule: {kind, tier, tool, args, first, then, min, max}, where kind is one of resolved, called, not_called, before, turns, valid_calls, no_loop and tier is must or stretch.
modelsNoIDs from list_models, up to 50, or names as the person said them (gpt, claude, gemini-4, sonnet), each matched to the newest model of its family. Default: a starting mix. For image tests, omit to compare all image models or send exact endpoint IDs (fal-ai/flux-2, fal-ai/recraft/v4/text-to-image, ideogram/v4).
promptYesThe prompt as it is used. Parts that change from one use to the next can be {{snake_case}} variables; with none, the changing part is found and made one.
systemNoThe system prompt, if any.
contextNoOptional shared context: docs or a brief the app gives the model beside the prompt, the same for every case. Sent first in the system message as reference material, or in place of {{context}} if the prompt has it. Drafting and the judge read it as what the prompt is for. Up to 50,000 characters; it is sent with every call, so it counts in the cost. For several, send contexts instead.
contextsNoInstead of context: up to 8 named contexts, for an app that sends one of several briefs or document sets. Each case gets one: its own (the case's context, by name), else the default. Every version and model gets the same one for the same case. Each up to 50,000 characters, 100,000 in all. Drafted cases are spread across them.
scenariosNoFor a conversation test, up to 12: one person with one thing they want.
image_sizeNo
user_modelNoFor a conversation test: the model that plays the user, the same for every model tested. Any id list_models gives; a default is used if left out.
image_checksNo
max_spend_usdNoLimit for this test. Default 50, or 2 from a chat app, never above the credit left. Models are left out, dearest first, to fit.
default_contextNoThe context a case that names none gets, by name: the first by default, or "none".
images_per_caseNo
writing_samplesNoOptional: the person's own writing (posts, emails, passages as they wrote them), at least 20 for a style check. get_test then compares the answers' habits (length, lines, emoji, punctuation, repeated phrases) with theirs. Kept private with the test, up to 500 samples of 2,000 characters each.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / writing_samples
      Added value: +{
      +  "description": "Optional: the person's own writing (posts, emails, passages as they wrote them), at least 20 for a style check. get_test then compares the answers' habits (length, lines, emoji, punctuation, repeated phrases) with theirs. Kept private with the test, up to 500 samples of 2,000 characters each.",
      +  "items": {
      +    "type": "string"
      +  },
      +  "maxItems": 500,
      +  "type": "array"
      +}
  2. Changed6 schema fields changed
    • addedInput schema / properties / image_checks
      Added value: +{
      +  "additionalProperties": false,
      +  "properties": {
      +    "aspect_ratio": {
      +      "items": {
      +        "type": "integer"
      +      },
      +      "maxItems": 2,
      +      "minItems": 2,
      +      "type": "array"
      +    },
      +    "dimensions": {
      +      "items": {
      +        "type": "integer"
      +      },
      +      "maxItems": 2,
      +      "minItems": 2,
      +      "type": "array"
      +    },
      +    "max_bytes": {
      +      "type": "integer"
      +    },
      +    "palette": {
      +      "description": "Up to eight #RRGGBB colours.",
      +      "items": {
      +        "type": "string"
      +      },
      +      "type": "array"
      +    },
      +    "required_text": {
      +      "type": "string"
      +    }
      +  },
      +  "type": "object"
      +}
    • addedInput schema / properties / image_size
      Added value: +{
      +  "enum": [
      +    "square",
      +    "portrait",
      +    "landscape"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / images_per_case
      Added value: +{
      +  "maximum": 3,
      +  "minimum": 1,
      +  "type": "integer"
      +}
    • changedInput schema / properties / mode / description
      Previous value: -"\"conversation\" tests an agent prompt over whole conversations with a simulated user. Then prompt is the agent's prompt, sent as the system prompt as written, scenarios take the place of cases, and nothing is drafted."New value: +"Set to conversation for a multi-turn test or image for image generation. Omit for text."
    • changedInput schema / properties / mode / enum
      Previous value: -[
      -  "conversation"
      -]New value: +[
      +  "conversation",
      +  "image"
      +]
    • changedInput schema / properties / models / description
      Previous value: -"IDs from list_models, up to 50, or names as the person said them (gpt, claude, gemini-4, sonnet), each matched to the newest model of its family. Default: a starting mix."New value: +"IDs from list_models, up to 50, or names as the person said them (gpt, claude, gemini-4, sonnet), each matched to the newest model of its family. Default: a starting mix. For image tests, omit to compare all image models or send exact endpoint IDs (fal-ai/flux-2, fal-ai/recraft/v4/text-to-image, ideogram/v4)."
  3. Changed5 schema fields changed
    • changedInput schema / properties / cases / description
      Previous value: -"Realistic inputs, up to 50."New value: +"Realistic inputs, up to 50: each {values: {variable: text}}, or, for a prompt without variables, the example as plain text."
    • changedInput schema / properties / cases / items / type
      Previous value: -"object"New value: +[
      +  "object",
      +  "string"
      +]
    • changedInput schema / properties / max_spend_usd / description
      Previous value: -"Limit for this test. Default 50. Models are left out, dearest first, to fit."New value: +"Limit for this test. Default 50, or 2 from a chat app, never above the credit left. Models are left out, dearest first, to fit."
    • changedInput schema / properties / models / description
      Previous value: -"Model IDs from list_models, up to 50. Default: a starting mix."New value: +"IDs from list_models, up to 50, or names as the person said them (gpt, claude, gemini-4, sonnet), each matched to the newest model of its family. Default: a starting mix."
    • changedInput schema / properties / prompt / description
      Previous value: -"The user prompt, with {{variables}}."New value: +"The prompt as it is used. Parts that change from one use to the next can be {{snake_case}} variables; with none, the changing part is found and made one."
  4. Changed1 schema field changed
    • changedInput schema / properties / models / description
      Previous value: -"Model IDs from list_models, up to 6. Default: a starting mix."New value: +"Model IDs from list_models, up to 50. Default: a starting mix."
  5. Changed1 schema field changed
    • changedInput schema / properties / cases / description
      Previous value: -"Realistic inputs, up to 24."New value: +"Realistic inputs, up to 50."
  6. Changed5 schema fields changed
    • addedInput schema / properties / cases / items / properties / context
      Added value: +{
      +  "description": "The name of the context this case gets, or \"none\". Left out: the default.",
      +  "type": "string"
      +}
    • addedInput schema / properties / context
      Added value: +{
      +  "description": "Optional shared context: docs or a brief the app gives the model beside the prompt, the same for every case. Sent first in the system message as reference material, or in place of {{context}} if the prompt has it. Drafting and the judge read it as what the prompt is for. Up to 50,000 characters; it is sent with every call, so it counts in the cost. For several, send contexts instead.",
      +  "type": "string"
      +}
    • addedInput schema / properties / contexts
      Added value: +{
      +  "description": "Instead of context: up to 8 named contexts, for an app that sends one of several briefs or document sets. Each case gets one: its own (the case's context, by name), else the default. Every version and model gets the same one for the same case. Each up to 50,000 characters, 100,000 in all. Drafted cases are spread across them.",
      +  "items": {
      +    "properties": {
      +      "name": {
      +        "description": "Like Retail brief.",
      +        "type": "string"
      +      },
      +      "text": {
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "name",
      +      "text"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
    • addedInput schema / properties / default_context
      Added value: +{
      +  "description": "The context a case that names none gets, by name: the first by default, or \"none\".",
      +  "type": "string"
      +}
    • changedInput schema / properties / max_spend_usd / description
      Previous value: -"Limit for this test. Default 5. Models are left out, dearest first, to fit."New value: +"Limit for this test. Default 50. Models are left out, dearest first, to fit."
  7. Changed8 schema fields changed
    • changedInput schema / properties / checks / description
      Previous value: -"Yes/no statements a good answer meets."New value: +"Yes/no statements a good answer meets. In a conversation test a statement is judged against the whole transcript, and an item can also be a rule: {kind, tier, tool, args, first, then, min, max}, where kind is one of resolved, called, not_called, before, turns, valid_calls, no_loop and tier is must or stretch."
    • addedInput schema / properties / checks / items / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "object"
      +  }
      +]
    • removedInput schema / properties / checks / items / type
      Removed value: -"string"
    • changedInput schema / properties / max_spend_usd / description
      Previous value: -"Limit for this test. Default 1. Models are left out, dearest first, to fit."New value: +"Limit for this test. Default 5. Models are left out, dearest first, to fit."
    • addedInput schema / properties / mode
      Added value: +{
      +  "description": "\"conversation\" tests an agent prompt over whole conversations with a simulated user. Then prompt is the agent's prompt, sent as the system prompt as written, scenarios take the place of cases, and nothing is drafted.",
      +  "enum": [
      +    "conversation"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / scenarios
      Added value: +{
      +  "description": "For a conversation test, up to 12: one person with one thing they want.",
      +  "items": {
      +    "properties": {
      +      "goal": {
      +        "description": "What the simulated user wants.",
      +        "type": "string"
      +      },
      +      "knows": {
      +        "description": "Facts they have. They give one only when the agent asks.",
      +        "type": "string"
      +      },
      +      "notes": {
      +        "description": "What a good conversation does, for the judge.",
      +        "type": "string"
      +      },
      +      "opening": {
      +        "description": "Their first message. Written for them if left out.",
      +        "type": "string"
      +      },
      +      "results": {
      +        "description": "Up to 8: what a tool returns in this scenario instead of its usual result: {tool, result, args}. With args, only for calls whose arguments include them.",
      +        "items": {
      +          "type": "object"
      +        },
      +        "type": "array"
      +      },
      +      "turns": {
      +        "description": "Most turns allowed. Default 8, at most 12.",
      +        "type": "integer"
      +      },
      +      "who": {
      +        "description": "Who they are and how they write.",
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "goal"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
    • addedInput schema / properties / tools
      Added value: +{
      +  "description": "For a conversation test, up to 8 dummy tools the agent can call. Nothing real is ever run: each call gets back the result written for it.",
      +  "items": {
      +    "properties": {
      +      "description": {
      +        "description": "What it does. The agent reads this.",
      +        "type": "string"
      +      },
      +      "name": {
      +        "type": "string"
      +      },
      +      "parameters": {
      +        "description": "A JSON schema for its arguments.",
      +        "type": "object"
      +      },
      +      "result": {
      +        "description": "What every call gets back, unless a scenario sets another."
      +      }
      +    },
      +    "required": [
      +      "name"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
    • addedInput schema / properties / user_model
      Added value: +{
      +  "description": "For a conversation test: the model that plays the user, the same for every model tested. Any id list_models gives; a default is used if left out.",
      +  "type": "string"
      +}
  8. Changed1 schema field changed
    • changedInput schema / properties / cases / description
      Previous value: -"Realistic inputs, up to 12."New value: +"Realistic inputs, up to 24."
  9. First observed

TDQS

A4.9/5.0
Behavior5/5

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

Beyond the annotations, the description discloses the paid nature of the operation, the max_spend_usd safeguard, and the asynchronous workflow returning a test_id immediately. It also clarifies that omitting cases and checks causes them to be drafted, which materially affects what the tool will do.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with the selection condition and then covers cost, return behavior, and mode selection. For an 18-parameter tool with nested objects, the length is justified and no sentence is clearly redundant.

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?

Given the tool's complexity, the absence of an output schema, and the high schema coverage, the description supplies the missing operational context: async results via get_test, credit spending, drafting defaults, image mode, and conversation support. An agent has enough information to decide when and how to call it.

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 description coverage is high at 83%, so most parameter meaning is already documented. The description still adds useful semantics for key parameters, including how model names are matched, default model selection, context limits, and how max_spend_usd causes models to be dropped from the test.

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?

The description states a specific action and outcome: it runs a prompt on realistic cases across several models and checks every answer to find which model does it best or cheapest. It explicitly distinguishes the tool from general model questions and from get_test, which retrieves results instead of starting a test.

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?

It gives explicit when-to-use guidance (someone has a prompt and wants model comparison or cost optimization) and when-not-to-use guidance (general model questions with no prompt to test). It also directs follow-up to get_test and warns that each call starts a new paid test rather than following an existing one.

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.