Skip to main content
Glama

Translate Detect Language

translate_detect_language
Read-onlyIdempotent

Detect the language of a text string. Returns an array of detected languages with confidence scores.

Example tool call

This call uses example arguments supplied in the tool’s input schema.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "text": "Hola, ¿cómo estás?"
    },
    "name": "translate_detect_language"
  }
}

Input Schema

NameRequiredDescriptionDefault
textYesThe text whose language should be detected

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • addedOutput schema / oneOf
      Added value: +[
      +  {
      +    "properties": {
      +      "detections": {
      +        "description": "Array of detected languages with confidence scores",
      +        "items": {
      +          "properties": {
      +            "confidence": {
      +              "description": "Confidence score for the detection",
      +              "type": "number"
      +            },
      +            "language": {
      +              "description": "Detected language code",
      +              "type": "string"
      +            }
      +          },
      +          "required": [
      +            "language",
      +            "confidence"
      +          ],
      +          "type": "object"
      +        },
      +        "type": "array"
      +      },
      +      "found": {
      +        "description": "Present and true on an answer; a miss is the found:false branch.",
      +        "enum": [
      +          true
      +        ],
      +        "type": "boolean"
      +      },
      +      "text": {
      +        "description": "The input text that was analyzed",
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "text",
      +      "detections"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "description": "A miss or an unavailable upstream: found:false with a reason and a hint (the shape check-found-false-schemas.mjs expects).",
      +    "properties": {
      +      "found": {
      +        "enum": [
      +          false
      +        ],
      +        "type": "boolean"
      +      }
      +    },
      +    "required": [
      +      "found"
      +    ],
      +    "type": "object"
      +  }
      +]
    • removedOutput schema / properties
      Removed value: -{
      -  "detections": {
      -    "description": "Array of detected languages with confidence scores",
      -    "items": {
      -      "properties": {
      -        "confidence": {
      -          "description": "Confidence score for the detection",
      -          "type": "number"
      -        },
      -        "language": {
      -          "description": "Detected language code",
      -          "type": "string"
      -        }
      -      },
      -      "required": [
      -        "language",
      -        "confidence"
      -      ],
      -      "type": "object"
      -    },
      -    "type": "array"
      -  },
      -  "text": {
      -    "description": "The input text that was analyzed",
      -    "type": "string"
      -  }
      -}
    • removedOutput schema / required
      Removed value: -[
      -  "text",
      -  "detections"
      -]
  2. Added

TDQS

A3.6/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, and openWorldHint, so the safety profile is covered. The description adds the response shape (array of languages with confidence scores), but says nothing about behavior on mixed-language or very short input.

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 short sentences, front-loaded with the operation and followed by the return shape. No filler or redundant restatement of the title.

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 simple one-parameter read-only tool with an output schema present, this is nearly complete. The only gap is guidance on how the tool behaves with ambiguous or mixed-language text, which an agent might reasonably want.

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?

There is a single required parameter with 100% schema description coverage, so the schema already documents 'text' fully. The description adds no format constraints or length limits beyond what the schema provides, making the baseline 3 appropriate.

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: 'Detect the language of a text string.' This clearly distinguishes it from translate_translate (translation) and translate_list_languages (catalog listing), though it never names those siblings explicitly.

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 by the purpose statement — there is no explicit when-to-use or when-not-to-use guidance, and no mention of alternatives such as translate_translate when the detected language needs follow-up action.

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.