Skip to main content
Glama

Create moderation

create_moderation
Read-only

Check single or multiple texts for potentially harmful content with an OpenAI moderation model and return flagged status plus per-category flags and scores.

Instructions

Check text for potentially harmful content using an OpenAI moderation model. Returns, for each input, whether it was flagged plus per-category flags and scores

Input Schema

NameRequiredDescriptionDefault
inputYesText (or array of texts) to classify
modelYesOpenAI model to use for moderation

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.1.2

TDQS

A3.8/5.0
Behavior4/5

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

readOnlyHint=true already declares the safety profile, and the description adds real value by disclosing the return shape: per-input flagged status plus per-category flags and scores. With no output schema, this return-format disclosure is important. It stops short of covering rate limits, model availability, or error behavior.

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?

Two sentences, zero waste, with the action front-loaded and the return shape immediately following. Nothing extraneous and nothing padded.

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?

For a two-parameter read-only tool with no output schema, the description covers purpose and return values well. The main remaining gap is the required 'model' parameter — no example or guidance on valid model names is given anywhere.

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 coverage is 100%, so both parameters are already documented. The description adds only a slight hint that input may be batched ('for each input'), which is already conveyed by the anyOf array in the schema. Baseline 3 applies.

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+resource ('check text for potentially harmful content using an OpenAI moderation model') and distinguishes itself from siblings like create_embeddings or generate_text by naming the moderation task. It does not explicitly name alternatives, but the purpose is unmistakable.

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 — the agent can infer this is the tool for safety/moderation checks — but there is no explicit when-to-use or when-not-to-use guidance, and no advice on how to pick the model parameter, which is required.

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