Skip to content

Commit 0b2636c

Browse files
Merge pull request #536 from SuffolkLITLab/copilot/document-expanded-interview-metadata
Document the expanded interview metadata block
2 parents 6fb2706 + 9efcd16 commit 0b2636c

File tree

1 file changed

+78
-34
lines changed

1 file changed

+78
-34
lines changed

docs/authoring/weaver_code_anatomy.md

Lines changed: 78 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -51,43 +51,87 @@ metadata:
5151
---
5252
```
5353

54-
## AssemblyLine metadata
54+
## Interview metadata and metadata for publishing on CourtFormsOnline
5555

56-
The AssemblyLine metadata block has different, AssemblyLine specific metadata that doesn't fit in the normal [metadata block](#metadata). Additionally, data in this block isn't overwritten if it's included in another interview.
56+
Current AssemblyLine interviews use an expanded [metadata block](https://docassemble.org/docs/initial.html#metadata) that includes additional fields beyond the basic `title` and `short title`. This expanded metadata helps organizations better categorize, describe, and manage their interviews.
57+
58+
:::info
59+
The `interview_metadata` variable used in older AssemblyLine interviews is now deprecated. New interviews should include all metadata directly in the `metadata` block as shown below.
60+
:::
5761

5862
```yml
59-
mandatory: True
60-
code: |
61-
interview_metadata # make sure we initialize the object
62-
if not defined("interview_metadata['a_258e_motion_for_impoundment']"):
63-
interview_metadata.initializeObject('a_258e_motion_for_impoundment')
64-
interview_metadata['a_258e_motion_for_impoundment'].update({
65-
"al_weaver_version": "0.82",
66-
"generated on": "2021-05-28",
67-
"title": "209a 258e motion for impoundment",
68-
"short title": "209a 258e motion for impoundment",
69-
"description": "209a 258e motion for impoundment",
70-
"original_form": "",
71-
"allowed courts": [
72-
"Land Court",
73-
],
74-
"categories": [
75-
"BE-04-00-00-00",
76-
],
77-
"logic block variable": "a_258e_motion_for_impoundment",
78-
"attachment block variable": "a_258e_motion_for_impoundment_attachment",
79-
"typical role": "plaintiff",
80-
})
63+
metadata:
64+
title: |
65+
209a 258e motion for impoundment
66+
short title: |
67+
209a 258e motion for impoundment
68+
description: |
69+
This interview helps you fill out a form to ask the court to keep
70+
certain information in your case private (impounded).
71+
can_I_use_this_form: |
72+
You can use this form if you want to ask the court to keep some
73+
information in your case private. This might include personal
74+
information or details about your case.
75+
before_you_start: |
76+
Before you start, gather information about what specific details
77+
you want the court to keep private and why this is necessary.
78+
maturity: production
79+
estimated_completion_minutes: 15
80+
estimated_completion_delta: 5
81+
languages:
82+
- en
83+
help_page_url: https://www.mass.gov/info-details/impoundment
84+
help_page_title: Information about Impoundment
85+
LIST_topics:
86+
- BE-04-00-00-00
87+
tags:
88+
- BE-04-00-00-00
89+
jurisdiction: NAM-US-US+MA
90+
original_form: https://www.mass.gov/forms/motion-for-impoundment
91+
original_form_published_on: 2021-01-01
92+
review_date: 2024-01-01
93+
form_titles:
94+
- Motion for Impoundment
95+
form_numbers:
96+
- MPC-123
97+
fees:
98+
- Filing fee: 0.00
99+
update_notes: |
100+
Form created in 2021. Last reviewed 2024 with no changes needed.
81101
---
82102
```
83103

84-
1. `title`, `short title`, and `description` allow your organization's site to show more information about your form and to organize your forms more easily.
85-
1. `original_form` is a link to the original, fillable PDF form that this interview is automating, if it exists.
86-
1. 🚧 `allowed courts` allows your code to decide which courts to let the user pick from when they need to pick their court, usually used in conjunction with [ALThemeTemplate](https://github.com/SuffolkLITLab/docassemble-ALThemeTemplate).
87-
1. `categories` is the [LIST taxonomy](https://taxonomy.legal/) code for this interview, which can be used by your organization to organize your interviews.
88-
1. `attachment block variable` used to be used in the code that sends documents to courts, but now the [ALDocument object block](../components/AssemblyLine/al_document#aldocument-objects) is used instead.
89-
1. `logic block variable` should also no longer be used.
90-
1. `typical role`: controls which questions the user gets asked about themselves and other parties.
104+
### Expanded metadata fields
105+
106+
1. **Basic information fields:**
107+
- `title` and `short title`: Control the interview name in browser tabs and saved interview lists
108+
- `description`: A detailed explanation of what the interview does and helps accomplish
109+
- `can_I_use_this_form`: Helps users determine if this is the right form for their situation
110+
- `before_you_start`: Information users should gather or consider before beginning
111+
112+
2. **Technical and administrative fields:**
113+
- `maturity`: The development status (`production`, `development`, or `testing`)
114+
- `estimated_completion_minutes`: How long most users take to complete the interview
115+
- `estimated_completion_delta`: The typical variation in completion time (±)
116+
- `languages`: List of language codes for available translations (e.g., `en`, `es`)
117+
- `review_date`: When the interview should next be reviewed for updates
118+
119+
3. **Help and reference fields:**
120+
- `help_page_url`: Link to additional help resources
121+
- `help_page_title`: Display name for the help page link
122+
- `original_form`: URL to the original blank form being automated
123+
- `original_form_published_on`: Publication date of the original form
124+
125+
4. **Classification and organization:**
126+
- `LIST_topics`: [LIST taxonomy](https://taxonomy.legal/) codes (preferred method)
127+
- `tags`: Fallback taxonomy codes if LIST_topics isn't available
128+
- `jurisdiction`: Geographic scope using jurisdiction codes
129+
- `form_titles`: Human-readable names of forms included
130+
- `form_numbers`: Official form numbers, if assigned
131+
- `fees`: Filing fees and other costs
132+
133+
5. **Maintenance and updates:**
134+
- `update_notes`: Record of changes and review history
91135

92136
## Main intro page
93137
Adds this text to the organization's intro page that appears at the beginning of every interview. This lets your user know right away that they have gotten to the right (or wrong) form. Note that this can (and should) be a more direct and detailed call to action, e.g. ("File a \_\_\_\_" or "Ask the court for \_\_\_\_"), rather than a simple short title, like the short title in the [metadata block](#metadata).
@@ -131,8 +175,8 @@ The full interview order block will look something like this. We'll go over each
131175
```yml
132176
id: interview_order_a_258e_motion_for_impoundment
133177
code: |
134-
# Set the allowed courts for this interview
135-
allowed_courts = interview_metadata["a_258e_motion_for_impoundment"]["allowed courts"]
178+
# Set the allowed courts for this interview (if needed)
179+
# allowed_courts = ["Probate and Family Court", "District Court"]
136180
nav.set_section("review_a_258e_motion_for_impoundment")
137181
user_role ="plaintiff"
138182
user_ask_role = "plaintiff"
@@ -147,7 +191,7 @@ code: |
147191
---
148192
```
149193

150-
1. `allowed_courts` allows the developer to limit which courts the person filling out the form can pick from, making it easier for them to pick the right court. By default, it's using the same values that are in the [metadata block](#assemblyline-metadata).
194+
1. `allowed_courts` allows the developer to limit which courts the person filling out the form can pick from, making it easier for them to pick the right court. This is now configured directly in the interview code as shown above, rather than using the deprecated `interview_metadata` approach. This is currently used only in Massachusetts court forms.
151195
1. `nav.set_section()` comes after `al_intro_screen` and `a_258e_motion_for_impoundment_intro` so that the user can't click to edit their answers before they've actually been asked any questions.
152196
1. `user_role` and `user_ask_role` tell AssemblyLine which questions to ask about the main party and opposing parties listed on the form. These should be the same as the `typical role`. However, if `typical role` is `unknown`, then the `user_ask_role` variable will be here instead, and will ask the user what role they have in the case.
153197

0 commit comments

Comments
 (0)