Skip to main content
Glama

messages_create

Generate a completion from an Anthropic messages-shaped request using the host agent's own model via MCP sampling, so no API key or external model access is required.

Instructions

Generate a completion from an Anthropic messages-shaped request. The completion is produced by the host agent's own model via MCP sampling. No API key is used or needed: the connected agent is the model.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modelNoModel alias; agent-default means the host's own model.agent-default
systemNoSystem prompt as text or text blocks.
messagesYesUser/assistant messages in order.
max_tokensNoMaximum tokens to generate.
temperatureNoSampling temperature, if the host honors it.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

A3.8/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does disclose the genuinely surprising mechanic: the completion is produced by the host agent's own model via MCP sampling and no API key is involved. That is the key behavioral fact an agent would otherwise get wrong. It stops short of covering latency, determinism, or whether model/temperature are actually honored.

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?

Three short sentences, each load-bearing, with the purpose front-loaded and the sampling/auth clarification immediately after. No filler.

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

Completeness4/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, and the description covers the unusual sampling behavior and auth model. What remains thin is the relationship to the sibling tools, which matters for selection in a three-tool space.

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 100% and every parameter (model, system, messages, max_tokens, temperature) is already documented in the schema, so baseline 3 applies. The description adds no format or naming detail beyond what the schema provides.

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 ('Generate a completion') and pins down the request shape ('Anthropic messages-shaped'). It does not however differentiate itself from the sibling chat_complete, which reads superficially the same, so an agent gains no routing signal from the description alone.

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 only implied: the 'no API key is used or needed' line suggests when this is preferable (sampling through the host agent rather than a keyed API), but there is no explicit when-to-use/when-not or comparison against chat_complete or list_models.

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

Deploy Server

Other Tools