Skip to main content
Glama

glama_chat_completion

Send chat messages to the Glama gateway and receive completion responses. Specify messages, model, and optional settings to get AI-generated replies.

Instructions

Run a chat completion against the Glama gateway. messages is an array of {role, content} objects.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modelNoe.g. openai/gpt-4o, anthropic/claude-2
messagesYes
max_tokensNo
temperatureNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

C2.7/5.0
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral transparency. It only states the action and mentions the messages structure. It does not disclose whether this is a blocking call, whether it supports streaming, any authentication requirements, rate limits, or error behavior. This is a significant gap for a tool that likely makes network calls and returns a completion.

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?

The description is a single sentence, which is concise and front-loaded with the purpose. It avoids unnecessary verbiage and is structurally clean. However, it is so brief that it omits critical details, but that is more about completeness than conciseness. As a structure, it is efficient.

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

Completeness2/5

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

The tool has four parameters, one required, and no output schema. Given this complexity, the description needs to explain the return value, error handling, and usage context. It only mentions the messages structure and nothing else. It is incomplete for an agent to call correctly, especially without annotations to cover safety or behavior.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is low at 25% (only 'model' has a brief example, not a semantic description). The description adds a note about the 'messages' structure, but that is already in the schema. It does not explain the meaning or expected format of 'model', 'max_tokens', or 'temperature' beyond what the schema provides. Since coverage is low, the description should compensate but fails to do so.

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?

The description states a clear verb and resource: 'Run a chat completion against the Glama gateway.' This clearly conveys the tool's primary function. However, it does not explicitly differentiate from the sibling 'glama_stream_completion', which also performs chat completions but likely in streaming mode. The name implies non-streaming, but that is not stated, so the purpose is clear but lacks explicit sibling differentiation.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives like 'glama_stream_completion' or when not to use it. There are no conditions, prerequisites, or comparisons. The agent is left to infer usage from the name alone, which is insufficient for a tool with multiple siblings.

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