---
title: "Summary templates: turning questionnaire answers into text"
description: Summary templates turn a patient's answers on a questionnaire into a short piece of written text. When the patient submits the questionnaire, the…
---

[Skip to content](https://support-test.youwell.no/en-gb/support/solutions/articles/153000261767#main-content)

- [English - United Kingdom](https://support-test.youwell.no/en-gb/support/solutions/articles/153000261767)
- [Norwegian Bokmål](https://support-test.youwell.no/nb/support/solutions/articles/153000261767)

English - United Kingdom

Show submenu for translations

[Contact us](https://support-test.youwell.no/en-gb/kb-tickets/new?hsLang=en-gb) [My tickets](https://support-test.youwell.no/tickets?hsLang=en-gb)

[![Copy of Brukerstøtte Logo](https://support-test.youwell.no/hs-fs/hubfs/Copy%20of%20Brukerst%C3%B8tte%20Logo.png?width=177&height=80&name=Copy%20of%20Brukerst%C3%B8tte%20Logo.png)](https://youwell.no)

Open main navigation

Close main navigation

- - [English - United Kingdom](https://support-test.youwell.no/en-gb/support/solutions/articles/153000261767)
    - [Norwegian Bokmål](https://support-test.youwell.no/nb/support/solutions/articles/153000261767)

  English - United Kingdom
  
  Show submenu for translations
- [Contact us](https://support-test.youwell.no/en-gb/kb-tickets/new)
- [My tickets](https://support-test.youwell.no/tickets)

 How can we help you?

- There are no suggestions because the search field is empty.

1. [Youwell](https://support-test.youwell.no/en-gb?hsLang=en-gb)
2. [Program](https://support-test.youwell.no/en-gb/program?hsLang=en-gb)
3. [Content and elements](https://support-test.youwell.no/en-gb/program?hsLang=en-gb#content-and-elements)

# Summary templates: turning questionnaire answers into text

Summary templates turn a patient's answers on a questionnaire into a short piece of written text. When the patient submits the questionnaire, the therapist sees this generated summary at the top of the response instead of the raw list of questions and answers, and can copy it to the clipboard or print it to PDF. This article explains what the tool does, how to get a first summary working in a few minutes, and where to go when you want more control.

*Summary templates is an advanced tool. Simple summaries can be set up entirely from the composer described below. Anything beyond that, such as clinical rule tables or conditional wording, involves writing small templates by hand, and we recommend using the Youwell AI assistant or contacting Youwell support to help with the setup.*

**CONTENTS**

- [What summary templates do](https://support-test.youwell.no/en-gb/support/solutions/articles/153000261767#What-summary-templates-do)
- [Before you start](https://support-test.youwell.no/en-gb/support/solutions/articles/153000261767#Before-you-start)
- [Opening the composer](https://support-test.youwell.no/en-gb/support/solutions/articles/153000261767#Opening-the-composer)
- [The quickest way to a summary](https://support-test.youwell.no/en-gb/support/solutions/articles/153000261767#The-quickest-way-to-a-summary)
- [Testing the summary](https://support-test.youwell.no/en-gb/support/solutions/articles/153000261767#Testing-the-summary)
- [Adjusting the wording](https://support-test.youwell.no/en-gb/support/solutions/articles/153000261767#Adjusting-the-wording)
- [Writing templates by hand](https://support-test.youwell.no/en-gb/support/solutions/articles/153000261767#Writing-templates-by-hand)
- [What the therapist sees](https://support-test.youwell.no/en-gb/support/solutions/articles/153000261767#What-the-therapist-sees)
- [Conditional visibility](https://support-test.youwell.no/en-gb/support/solutions/articles/153000261767#Conditional-visibility)
- [Common pitfalls](https://support-test.youwell.no/en-gb/support/solutions/articles/153000261767#Common-pitfalls)
- [Getting help](https://support-test.youwell.no/en-gb/support/solutions/articles/153000261767#Getting-help)

### What summary templates do

A questionnaire page (a task) can carry a set of summary templates. Each template describes what the summary should say about one question, one answer option, or a piece of composed text, and one of them is the **final summary** that the therapist reads.

Typical uses:

- Turning twenty checkbox answers into two readable sentences for the therapist.
- Producing a draft reply or journal note that the therapist can review, copy and paste into a chat or a journal system.
- Encoding a clinical checklist ("if the patient reports X, check Y") as content that clinicians can edit themselves.

The text is generated by fixed rules that you define. There is no AI involved when the summary is produced, so the same answers always give the same summary. The same rules are used when a response is printed to PDF or sent to a journal system.

### Before you start

Build and save the questionnaire first: the content page, its questions and answer options. Summary templates describe an existing questionnaire, so the questions need to be in place before you begin.

Then give the questions and answer options meaningful, unique **keys** in the question editor. Keys are how the summary refers to an answer. If you leave them blank, the platform fills in Q01, Q02 and A01, A02 for you. Those work, but answer keys restart at A01 for every question, and the summary cannot tell two A01s apart. Rename answer options to keys that are unique across the whole page, for example *evening\_alcohol* rather than *A03*, before you start. You can read more about keys here: [Question keys and form IDs](https://support.youwell.no/en-gb/support/solutions/articles/153000244573).

### Opening the composer

In the portal, go to **Program**, open the programme, the module and the content page. In the page's **⋯ menu**, choose **Summary templates**. Once a page has at least one template, a summary icon also appears in the page header as a shortcut.

The composer has two panes:

- **Questionnaire** (left): the page's own structure as an outline, with each section, question and answer option. Every question is marked as **Described** or **Not described**, and the header shows how many of the questions the summary covers, for example *4 of 6 questions described*. Below the questions is a **Composed text** group for text that is not tied to a single question, and the **Final** row, which is what the therapist sees. Use the search field to find a row by key on long questionnaires.
- **Editor** (right): the text for whatever you have selected on the left, with a **Live output** preview above it and **Test answers** below.

The order in which rows are combined is worked out automatically from the questionnaire when you save. Only composed text can be reordered by hand.

### The quickest way to a summary

You do not need to write any templates to get a working summary. The composer can generate the standard rows for you.

1. Open **Summary templates** on the page.
2. Choose **Add all questions to summary** at the top of the outline. To do one question at a time instead, hover over a question in the outline and choose **Add to summary**.
3. Pick how each answer should read: 
     - **The answer on its own**: just the value, for example *Almost every night*.
     - **Question text: answer**: the question followed by the value, for example *How often do you wake up?: Almost every night*.
     - **A sentence I write myself**: your own wording, with  placed where the answer should go, for example *The patient reports waking .*
4. The dialog tells you how many rows it will create. Rows that already contain text are always left as they are, so you can run it again later to fill in any gaps.
5. Choose **Add**. A final summary row is created automatically if the page does not already have one, listing each described question in questionnaire order.

Free text, single choice, multiple choice, scale and rating questions can be generated. For single and multiple choice, the summary shows the text of the chosen option, not its key. If the dialog says a key *names more than one question*, two questions share an answer key; give those options unique keys on the question and try again.

### Testing the summary

Use **Test answers** at the bottom of the editor to answer the questions as a patient would. Nothing entered here is saved; it only drives the preview. **Live output** above shows the result as you type, and can be switched between **Whole summary** and **This row only**.

If a template refers to something that does not exist, the preview lists the errors and names the row they are in. **Save** is not available while an error stands, so a mistyped key cannot reach patients.

You can also open the page's **preview** (the eye icon in the page header). This shows the page as the patient sees it, with a live summary panel alongside that updates as you answer.

### Adjusting the wording

Select any row in the outline to edit its text:

- On an **answer option**, the field is *Text used when this option is chosen*. Change this to reword what the summary says when the patient picks that option.
- On a **question**, the field is *When answered, output*. This is the line the summary produces for that question.
- Under **Composed text**, you can add free-standing text that combines other rows, for example a heading, a fixed reminder, or a paragraph that only appears when a particular option was chosen.
- The **Final** row is the summary itself. Any composed text that uses variables can be promoted to become the summary with **Make this the summary**.

Below the text, **Uses** lists the rows the text reads. This is filled in from the template automatically and rarely needs editing.

The summary is formatted with Markdown. **\*\*bold\*\***, **### headings** and **- lists** work; HTML tags do not.

### Writing templates by hand

Templates use the Handlebars language. The generated rows are ordinary templates, so you can open any of them to see the pattern and adapt it. The most useful building blocks are:

|  | The answer to this row's own question or option. |
| --- | --- |
| **{{item.label}}** | The question text, or the answer option's text. |
|  | The answer to any question or option on the page. For an answer option it is true when that option was chosen. |
|  | The text produced by another template row. |
| **{** - [Administrator](https://support-test.youwell.no/en-gb/administrator?hsLang=en-gb#main-content) - [Settings](https://support-test.youwell.no/en-gb/administrator?hsLang=en-gb#settings) - [Admin Tools](https://support-test.youwell.no/en-gb/administrator?hsLang=en-gb#admin-tools) - [Reports](https://support-test.youwell.no/en-gb/administrator?hsLang=en-gb#reports) - [General](https://support-test.youwell.no/en-gb/general?hsLang=en-gb#main-content) - [Get started!](https://support-test.youwell.no/en-gb/general?hsLang=en-gb#get-started) - [Program](https://support-test.youwell.no/en-gb/program?hsLang=en-gb#main-content) - [Creating a new program](https://support-test.youwell.no/en-gb/program?hsLang=en-gb#creating-a-new-program) - [Program Timeline](https://support-test.youwell.no/en-gb/program?hsLang=en-gb#program-timeline) - [Program Settings](https://support-test.youwell.no/en-gb/program?hsLang=en-gb#program-settings) - [Content and elements](https://support-test.youwell.no/en-gb/program?hsLang=en-gb#content-and-elements) - [Additional Registrations](https://support-test.youwell.no/en-gb/program?hsLang=en-gb#additional-registrations) - [Calendar](https://support-test.youwell.no/en-gb/calendar?hsLang=en-gb#main-content) - [Get started with Calendar](https://support-test.youwell.no/en-gb/calendar?hsLang=en-gb#get-started-with-calendar) - [Templates, groups & custom calendars](https://support-test.youwell.no/en-gb/calendar?hsLang=en-gb#templates-groups-custom-calendars) - [Calendar administration](https://support-test.youwell.no/en-gb/calendar?hsLang=en-gb#calendar-administration) - [Appointments](https://support-test.youwell.no/en-gb/calendar?hsLang=en-gb#appointments) - [Following Up Patients](https://support-test.youwell.no/en-gb/following-up-patients?hsLang=en-gb#main-content) - [Patient Page](https://support-test.youwell.no/en-gb/following-up-patients?hsLang=en-gb#patient-page) - [Patient List](https://support-test.youwell.no/en-gb/following-up-patients?hsLang=en-gb#patient-list) - [Patient App](https://support-test.youwell.no/en-gb/patient-app?hsLang=en-gb#main-content) **- [Patient App](https://support-test.youwell.no/en-gb/patient-app?hsLang=en-gb#patient-app) - [Mobile App](https://support-test.youwell.no/en-gb/patient-app?hsLang=en-gb#mobile-app)** **[![youwell\_logo\_Gray](https://support-test.youwell.no/hs-fs/hubfs/youwell_logo_Gray.png?width=124&height=50&name=youwell_logo_Gray.png "youwell_logo_Gray")](https://support-test.youwell.no/?hsLang=en-gb)** **© Youwell AS** |  |