Skip to main content
Glama

pack_office_document

Repack unpacked Office document directories into .docx, .pptx, or .xlsx files, removing XML whitespace and optionally validating with LibreOffice.

Instructions

Pack a directory back into an Office document (.docx, .pptx, .xlsx). Removes pretty-printing whitespace from XML before packing. Can optionally validate the document before saving.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
input_dirYesDirectory containing unpacked Office document
output_fileYesPath for the output Office file
validateNoValidate the document after packing (requires LibreOffice)
forceNoSkip validation and pack anyway
Behavior3/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 disclosure. It effectively describes the core behavior (packing with whitespace removal) and an optional feature (validation with LibreOffice requirement), but lacks details on error handling, performance implications, or what happens if validation fails. It does not contradict any annotations, but could be more comprehensive for a tool that modifies files.

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 front-loaded with the main purpose in the first sentence, followed by additional details in a logical flow. Every sentence earns its place by adding useful information (whitespace removal, optional validation), with no redundant or vague phrasing. It is appropriately sized for a tool with four parameters.

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?

Given the tool's moderate complexity (file transformation with optional validation), no annotations, and no output schema, the description is reasonably complete. It covers the core operation and key optional behavior, but could improve by mentioning output expectations or error cases. It adequately supports tool selection and basic invocation, though not fully exhaustive.

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%, so the schema already documents all parameters thoroughly. The description adds minimal value beyond the schema by implying the tool's purpose relates to the parameters, but does not provide additional semantics, constraints, or examples for parameter usage. Baseline 3 is appropriate as the schema does the heavy lifting.

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 the specific action ('Pack a directory back into an Office document') with precise resource types (.docx, .pptx, .xlsx) and distinguishes from sibling tools like 'unpack_office_document' by describing the reverse operation. It also mentions additional processing ('Removes pretty-printing whitespace from XML before packing') that further clarifies its unique purpose.

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

Usage Guidelines4/5

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

The description provides clear context for when to use this tool: after unpacking an Office document (implied by 'pack a directory back into') and when needing to create a valid Office file from unpacked content. However, it does not explicitly state when NOT to use it or name specific alternatives among siblings, such as when to use 'validate_office_document' separately versus the optional validation here.

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/shjanjua/pptx-mcp-server'

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