Creating Templated Documents

A common use case for AI agents is to create nicely fomatted Documents, Slides, and Spreadsheets. This is useful for template contracts, proposals, presentations, posters, and much more.

The general construct for all of these is called "Copy and Fill in {{Placeholders}}", and this article will show you how to do it.

Copy Doc and Replace Placeholders

If you want to create a template of a Google Doc or a PDF, this is the way to do it.

First, you need to create your template Google Doc. In that Google Doc, you can use any styling and formatting you want. The most important thing you need to do in that document is to set up the "placeholders" that will be dynamically replaced in your workflow. Each placeholder will be added with {{ }} curly braces around it. Here's a screenshot of a very simple template document.

Simple template document with 3 placeholders: Title, Author, and Date

Now, you can use the "Copy doc and fill in {{placeholders}}" automation.

Navigating to Copy doc and fill in {{placeholders}} in the step menu

When you create the step, you'll see an option to fill in the value for each placeholder dynamically based on an existing value in your workflow.

Filling in the placeholders based on the values from the trigger.

Finally, when you run the workflow, you'll get a new document with the placeholders replaced:

Starting a sample manual trigger to fill in placeholders.
The newly created document with placeholders replaced

Last updated

Was this helpful?