Skip to main content
Glama

set_document_language

Set the default language of a Word document by providing a BCP-47 language tag such as 'en-US' or 'fr-FR'.

Instructions

Set the default document language.

Writes the BCP-47 language tag into the default paragraph style's run properties (w:rPr/w:lang) in word/styles.xml.

Args: language_code: BCP-47 language tag, e.g. "en-US", "fr-FR", "de-DE".

Returns: {"language": language_code}

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
language_codeYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

With no annotations provided, the description carries full burden. It discloses that the tool modifies the underlying XML (styles.xml) and sets the language in the default paragraph style. This reveals the broader scope (not just a property change) and the return value. It lacks details on reversibility or permissions, but is strong for a simple mutation tool.

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 efficiently structured: a one-sentence purpose, a technical detail (useful for transparency), and a list of args/returns. Every sentence adds value. No unnecessary words, and the format is easy to parse.

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 simplicity (one required parameter, no nested objects), the description fully covers its behavior, parameter format, and return value. The implementation detail provides extra context. No output schema exists, but the return format is specified. For this tool, the description is complete.

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?

The input schema has 0% description coverage, so the description must compensate. It provides the parameter name with a clear type (BCP-47 language tag) and three concrete examples (en-US, fr-FR, de-DE). This adds enough semantic meaning for correct invocation, despite no additional constraints or enums.

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 clearly states it sets the 'default document language' and explains the specific mechanism (writes to default paragraph style's run properties in styles.xml). This distinguishes it from sibling tools like set_run_language, which operate on specific runs, making the purpose unambiguous.

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?

The description provides usage examples for language codes but does not explicitly state when to use this tool versus alternatives like set_run_language. The context of 'default document language' implies document-wide application, but no direct comparison or exclusion criteria are given.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Arvindh95Censof/grp-docx-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server