Skip to main content
Glama

Assemble a contract

contract_assemble

Assemble a contract from library clauses into .docx or markdown, leaving omitted variables as bracketed prompts to avoid invented data.

Instructions

Call this tool to build a contract from library clauses as .docx or markdown. A variable you omit stays as a bracketed prompt, never invented. clause_ids order is document order. Free: 8 clauses.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
titleYesDocument title, for example 'Service Agreement - Beta Corp'
clientNoClient name; also fills the {{client}} variable
formatNodocx (default) or markdown; the document opens with the not-legal-advice line either way
valuesNoValues for the {{variables}} in the chosen clauses, for example {"fee":"4500","late_fee_percent":"2"}. Any variable you leave out stays in the document as a bracketed prompt such as [late fee percent], never as an invented value
out_pathNoWhere to write the file. Default: the server data directory, under a name built from the client and the title
overwriteNoReplace out_path if a file is already there. Without it an existing file is never touched
categoriesNoInstead of ids: every clause in these categories, ordered by category. Free tier: up to 8 clauses per document
clause_idsNoClause ids in the order they should appear; this is the document order. Free tier: up to 8 clauses per document

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.20.0

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does well: it discloses that omitted variables become bracketed prompts ('never invented'), that clause_ids order determines document order, that the free tier is capped at 8 clauses, and that the document includes a not-legal-advice line regardless of format (via the format param). It also notes that overwrite=false protects existing files. These are meaningful behavioral traits beyond schema, though it doesn't mention output details or error handling.

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 brief (two sentences plus a short clause about free tier) and front-loads the main action. It avoids redundancy with the schema, though the list of free-tier limits could be organized more cleanly. It's structured well enough for an agent to parse quickly.

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 complexity (8 params, nested object) and no output schema, the description covers key call‑time concerns: variable handling, ordering, format, overwrite safety, and free-tier caps. It does not explain the return value or error conditions, but for a file-writing tool that may be acceptable. Overall, it provides sufficient context for an agent to make a correct call.

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?

Schema coverage is 100%, so the baseline is 3, but the description adds value on top: it explains the consequence of omitting values (bracketed prompts), clarifies 'clause_ids order' as document order, and specifies that categories are an alternative to ids. It also gives examples for values and default out_path behavior, which are not fully in the schema. This lifts it above the baseline.

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 states a specific verb ('build') and resource ('contract from library clauses') with output formats ('.docx or markdown'). It clearly differentiates from sibling tools, which focus on clause management, licensing, and variables, leaving assembly as the 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?

While it does not explicitly list sibling alternatives, the description's 'Call this tool to build a contract' establishes the primary use case, and the free-tier clause limit provides a practical constraint. The mention of 'clause_ids order is document order' clarifies assembly behavior, implicitly distinguishing from clause_export. It lacks explicit 'when not to use' guidance, but the context is clear enough.

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

Deploy Server

Other Tools