Templates
Create, edit, generate, and maintain document templates with variables, a generation wizard, and history.
Last updated:
Templates turn repeatable documents — form letters, standard contracts, typical pleadings, forms — into reusable formats with variables that auto-fill from matter, client, lawyer, firm, or party data. The difference between drafting the same pleading from scratch twenty times and generating it in thirty seconds is exactly this module.
Anatomy of the template library
The main page splits into two views:
| View | What it's for | | --- | --- | | Template library | Firm templates: create, edit, clone, delete, generate documents. | | My documents | Documents you generated, ready to download or duplicate as new. |
Each template appears as a card with name, category, short description, and quick actions: Generate, Edit, Clone, Delete.
Creating a template
Open 'New template' in the library
Set name, description, and category. The category helps with later filtering.
Write the content in the editor
The editor supports formatting (bold, lists, headings) and pasting from other tools. Variables use double braces:
{{client.name}},{{matter.alias}},{{date|format:MMMM d, yyyy}}.Define user variables
Some variables auto-fill from system data (client, matter, current lawyer). Others require user input at generation — define those in the variable manager with name, visible label, type (text, number, date, select), and whether they are required.
Save and preview
Before publishing, run a preview with sample data. Preview does not generate or save anything — it just shows how the rendered document would look.
Variable syntax
Variables follow Mustache/Handlebars-style syntax. The most useful forms:
{{client.name}} → Client name
{{matter.title}} → Matter title
{{matter.alias}} → Human-readable matter alias
{{user.name}} → Current lawyer name
{{firm.legalName}} → Firm legal name
{{date|format:MMMM d, yyyy}} → Formatted date
{{amount|currency:HNL}} → Amount formatted in currency
{{#if condition}}…{{/if}} → Conditional block
{{#each list}}…{{/each}} → Loop over a list
Filters (|format:, |currency:) transform the value before display. Conditionals and loops allow more complex templates: showing a spouse section only if the client is married, or iterating over case parties.
Generating a document from a template
Select the template
From the library, click Generate on the template you want. The wizard opens.
Set the context
Pick the matter and/or client. The system uses this to auto-fill system-derived variables.
Fill in manual variables
The wizard walks through each variable that needs user input step by step. Required variables block progress if empty.
Final preview
Before generating, the wizard shows a preview with all values applied. If something looks wrong (a misformatted date, an incomplete name), go back to the right step and fix it.
Generate and save
On confirm, the system generates the document, saves it as a new matter document with metadata inherited from the template (category, type), and records it in the template's generation history.
Generation history
Every template keeps a paginated history of documents generated from it, with date, generating user, associated matter or client, and a link to the resulting document. Useful for:
- Audit usage: how many times has the template been used, by whom, on which matters.
- Spot templates nobody uses anymore (archive candidates).
- React when a template changes: see what documents were generated before the change and need review.
Clone to vary
When a new template is very similar to an existing one, cloning is faster than starting fresh. The cloned template keeps content, variables, and configuration, ready for tweaking. Useful for variants (polite collection letter, firm collection letter, final demand letter) without restarting from a blank page each time.
My documents: personal drafts
The My documents tab shows documents the user uploaded or generated as quick drafts. Unlike matter documents, these are personal to the user: they do not appear in the firm archive and are not visible to the team. Useful for:
- Drafts in progress not yet ready to associate with a matter.
- Personal test templates.
- Bridge documents while you decide where to store them definitively.
To bring a personal document into the firm archive, upload it to the corresponding matter as a regular document.
Templates vs. documents vs. notifications
Three similar concepts not to confuse:
| Concept | What for | | --- | --- | | Templates (this module) | Documents generated from a reusable format: contracts, letters, pleadings. | | Documents | Matter or client files: each one unique, lives in its folder. | | Notification templates | Automated system messages ("invoice issued" email, deadline reminder). Edited under Settings → Notifications, not here. |
Good practices
- Name templates clearly — "Professional services contract (monthly)" beats "Contract 1".
- Categorize — use category as a filter so the team finds them fast.
- Document variables — the visible label should explain what is expected, not just the internal name.
- Version consciously — when changing a template, consider cloning and keeping the old one with a suffix (
Contract v1,Contract v2 (2026)). - Review history periodically — templates with no use in 6 months are archive or refactor candidates.