Overview
With Dynamic Language, Administrators create rules within Draft templates (Our Paper) that dynamically insert, update or remove language based on the agreement’s context.
Dynamic Language reduces the need for Administrators to create and manage multiple templates with slight variations for each use case, minimizing ambiguity for Drafters.
If at least one Single-selection answer type is selected during token mapping or agreement detail field configuration, an additional step for Dynamic Language will be enabled during the Draft template creation process.
For a full video walkthrough take a look at our Academy content here.
Limitations
Dynamic Language was designed to support the most common use cases for language replacement:
- Updating a particular term for a given scenario
- Replacing a responsible party name in a certain scenario
- Indicating if auto-renew language is applicable or not.
Dynamic Language was not designed to allow users to programmatically manipulate document files in parity with the capabilities offered by full-fledged document editing tools such as Microsoft Word, Google Docs, etc. Such as:
- Remove/update/change full pages or document sections based on conditional question responses.
- Insert/replace images or tables based on conditional question responses.
Dynamic Language - as with any programmatic .docx file manipulation process - is an inherently complex feature which introduces the potential for unintended changes to the final Word document created by end users.
To mitigate these risks - Dynamic Language officially supports the following use cases only:
- Updating text within a single line or paragraph.
- Updating text within a single list element/row/table cell.
- Removing an entire table from the document.
- Updating text which includes a token.
- Updating and removing a single list element.
- Removing multiple list elements.
- Removing multiple paragraphs from a document.
There are some additional key points to consider when applying Dynamic Language conditions, listed below:
- If Dynamic Language is created using a mapped Global Term from Analyze, updating this term will remove any Dynamic Language conditions applied.
- Dynamic Language can only be applied to single-select token or agreement questions.
- To avoid unexpected system behavior, users should not apply overlapping Dynamic Language conditions to the same section of text.
-
Dynamic Language cannot currently be applied to text selections containing:
- Hyperlinks
- Pictures
Dynamic Language Best Practices
As with any programmatic document manipulation, it is always safer to work from a baseline template which has more information than you need and remove unnecessary information.
For example:
- Instead of dynamically inserting a clause based on a condition, setup the template to include the clause and remove it if it is not needed.
- Instead of dynamically inserting a new paragraph that contains complex bold, italics, and underline formatting into a document, setup the template to include the paragraph and remove it if it is not needed.
-
It is a best practice to remove any existing content controls from the template file before uploading it to Finalize. This will ensure that the system can correctly detect the conditions you want to apply and save said conditions without any unforeseen errors. To remove an existing content control from a Word Doc you need to:
- Open the document in Microsoft Word
- Find the area of the document you have an existing content control applied
- It is a best practice to remove any comments or tracked changes from the template file before uploading it to Finalize. This will ensure that the system can correctly detect the conditions you want to apply and save said conditions without any unforeseen errors.
-
- Right-click and select 'Remove Content Control'
Following these best practices will help to ensure that the end result of the document that is generated during agreement creation is formatted correctly and generated without unexpected errors.
Dynamic Language Error Handling
Due to the complexity involved in correctly inserting Dynamic Language conditions - users may occasionally encounter the following error message when attempting to save a condition.
This error message indicates that there is machine-readable (but not human-readable) code embedded into the document that is incompatible with applying a Dynamic Language condition. To work around this error - users must perform the following steps:
- Download the template file from Finalize.
- Select the body of text where the error is being shown when attempting to add a Dynamic Language condition.
- Copy the selected text.
- Paste > Paste Special > Paste as Unformatted text.
- Save and re-upload the new template file.
This will remove any hidden document structuring code in the selected text - This will allow a Dynamic Language condition to be applied.
Supported Dynamic Language Use Cases
Updating text within a single line or paragraph.
Users are able to highlight text within a single line or paragraph and apply either an update or remove condition. Within a single paragraph, only the text highlighted will be modified when an agreement is generated.
Updating text within a single list element/row/table cell.
Users can select text within a list item and update or remove that text. Within a single list item, only the text highlighted will be modified when an agreement is generated.
Users can select text within a table cell and update or remove that text. Within a single table cell only the text highlighted will be modified when an agreement is generated.
Warning: attempting to remove all content from a particular table cell, column, or row using Dynamic Language will cause errors in the underlying document structure, which will cause agreements created by this template to become corrupted .docx files.
Removing an entire table from the document.
Users can select document sections that include an entire table and elect to remove that table from the document.
Warning: attempting to remove a table by highlighting every cell individually instead of selecting the entire table will cause agreements created by this template to become corrupted .docx files.
Updating text which includes a token.
Users can select text that includes a token and apply a condition to update or remove the text.
Care must be taken if replacing a token value within an update condition to type the token value EXACTLY as it appears in the list of token options users will answer, otherwise, the token will not update correctly when the agreement is generated.
It is recommended to pre-fill all needed tokens for a document in the template up-front, and use dynamic language to remove the tokens which are conditionally not required.
If a token only appears in a document once and will be removed during agreement creation via a dynamically applied condition, then that token should be marked as optional in the workflow. Users drafting agreements can then simply skip that token option and the agreement will be generated correctly.
Updating and removing multiple paragraphs from a document.
Users are able to select spanning multiple paragraphs to apply a dynamic condition to. Users can update or remove multiple paragraphs from a document at once.
When multiple paragraphs are selected then users must either remove or update the entirety of BOTH paragraphs. Users may enter line breaks in the text condition they wish to update, which will be honored once the agreement is created.
It is always suggested to set up templates with as many variations of language that are needed as possible and then use dynamic language to REMOVE options that are not needed. This helps to programmatically ensure a more predictable and cleanly formatted document.
Updating and removing a single list element.
Users are able to dynamically remove a single-list element using dynamic language if it is not needed. When these conditions are applied, the highlighted part of the list will be deleted during agreement creation will be deleted and the rest of the list will react automatically.
In the example below, if we remove the second amendment using dynamic language, then when the agreement is created the list will be shown as:
- Congress shall make no law respecting an establishment of religion, or prohibiting the free exercise thereof; or abridging the freedom of speech, or of the press; or the right of the people peaceably to assemble, and to petition the government for a redress of grievances.
- No soldier shall, in time of peace be quartered in any house, without the consent of the owner, nor in time of war, but in a manner to be prescribed by law.
- The right of the people to be secure in their persons, houses, papers, and effects, against unreasonable searches and seizures, shall not be violated, and no warrants shall issue, but upon probable cause, supported by oath or affirmation, and particularly describing the place to be searched, and the persons or things to be seized.
Users are also able to update single list items using dynamic language. In these cases the entire text for this particular list item will be replaced during agreement creation, and the rest of the list formatting/numbering will be maintained.
Removing multiple list elements.
Users are able to dynamically remove multiple-list elements using dynamic language if they are not needed. When these conditions are applied, the highlighted parts of the list will be deleted during agreement creation will be deleted and the rest of the list will react automatically.
In the example below, if we remove the second and third amendments using dynamic language, then when the agreement is created the list will be shown as:
- Congress shall make no law respecting an establishment of religion, or prohibiting the free exercise thereof; or abridging the freedom of speech, or of the press; or the right of the people peaceably to assemble, and to petition the government for a redress of grievances.
- The right of the people to be secure in their persons, houses, papers, and effects, against unreasonable searches and seizures, shall not be violated, and no warrants shall issue, but upon probable cause, supported by oath or affirmation, and particularly describing the place to be searched, and the persons or things to be seized.
Note: although the option to Update language is enabled - this is not officially supported by Finalize and will lead to unexpected results during agreement creation.
If users need to update/remove multiple parts of an ordered list then it is recommended to apply the relevant condition to each list item - in order to get more predictable results during agreement creation and allow more flexibility for future template changes.