Workflow: setting up targets, then registration fields

Two set-up jobs, done in order. First you build the selection targets — the demographic categories and how many of each you want — without thinking about the registration form at all. Then you build the registration fields, and make sure that between them they can supply the data every target needs.

Targets and registration fields are independent structures. A target does not name a field, and a field does not name a target. They meet in one place only: the check that asks “can every target get its value from the data this form collects?” — either from a field whose name and options match the target, or from a derived field that computes it.

That is why targets come first. You agree the categories with the client in target-shaped language, and only afterwards work out what to ask people on the form.

Precondition Hub / list you return to Target action Field action Choice Form contents Check / warning Outcome

The two boxes

flowchart LR
    classDef pre    fill:#d7ccc8,stroke:#5d4037,color:#0b0c0c
    classDef target fill:#fad7a8,stroke:#b58840,color:#0b0c0c
    classDef field  fill:#c8e6c9,stroke:#2e7d32,color:#0b0c0c
    classDef done   fill:#e1bee7,stroke:#6a1b9a,color:#0b0c0c

    P(["Number-to-select<br/>already agreed"]):::pre

    subgraph BOX1["Box 1 - set up and manage targets"]
        direction TB
        T1["Add a target<br/>e.g. Gender"]:::target
        T2["Add its target values<br/>Male, Female, Non-binary"]:::target
        T3["Now or later: percentages,<br/>min and max, source URL,<br/>comments"]:::target
        T1 --> T2 --> T3
    end

    subgraph BOX2["Box 2 - set up registration fields"]
        direction TB
        F1["Add sections"]:::field
        F2["Add fields to the sections"]:::field
        F3["Confirm every target can get<br/>its data - directly, or from<br/>a derived field"]:::field
        F1 --> F2 --> F3
    end

    G["Generate the<br/>registration form"]:::done

    P --> BOX1 --> BOX2 --> G

    click T1 "#flow-targets" "Flow 1 - targets"
    click T2 "#flow-targets" "Flow 1 - targets"
    click T3 "#flow-targets" "Flow 1 - targets"
    click F1 "#flow-fields" "Flow 2 - registration fields"
    click F2 "#flow-fields" "Flow 2 - registration fields"
    click F3 "#coverage-detail" "The coverage check"
            

Click a box to jump to the flow that expands it. Box 2 branches a long way, so it is broken into four further flow charts below.

Flow 1 — Set up and manage targets

The core of this is two steps: add a target, add its values. Everything else is optional and can happen at set-up time or months later as ordinary management, so it is drawn as a fan-out from the targets list you keep coming back to.

flowchart LR
    classDef pre    fill:#d7ccc8,stroke:#5d4037,color:#0b0c0c
    classDef hub    fill:#cce2f7,stroke:#1d70b8,color:#0b0c0c
    classDef target fill:#fad7a8,stroke:#b58840,color:#0b0c0c
    classDef decide fill:#f8bbd0,stroke:#ad1457,color:#0b0c0c
    classDef form   fill:#f3f2f1,stroke:#505a5f,color:#0b0c0c
    classDef check  fill:#fff7d6,stroke:#b58840,color:#0b0c0c

    S(["Number-to-select is set"]):::pre
    A["Add a target<br/>e.g. Gender"]:::target
    V["Add target values<br/>e.g. Male, Female, Non-binary"]:::target
    HUB(["Targets list"]):::hub

    S --> A --> V --> HUB
    HUB -->|"another target"| A
    HUB -->|"another value"| V

    P["Set or edit the percentage<br/>for each target value"]:::target
    CALC["Auto-calculates min and max:<br/>min = floor(percentage × number-to-select)<br/>max = ceil(percentage × number-to-select)"]:::form
    SUM{"Do the percentages for<br/>this target add up to<br/>close to 100.0?"}:::decide
    WARN["Show a warning<br/>(does not block you)"]:::check

    HUB --> P --> CALC --> SUM
    SUM -->|"no"| WARN --> HUB
    SUM -->|"yes"| HUB

    MM["Directly set min and max<br/>on a target value"]:::target
    BREAK["Breaks the auto-calculate link<br/>for that value: later changes to the<br/>percentage or to number-to-select<br/>no longer move its min and max"]:::form
    VC["Add or edit a comment on the<br/>target value - usually why the<br/>min and max were set by hand"]:::target

    HUB --> MM --> BREAK --> VC --> HUB

    URL["Add a source URL to the target<br/>where the percentages came from"]:::target
    TC["Add or edit a comment on the target<br/>usually about the source"]:::target
    HUB --> URL --> HUB
    HUB --> TC --> HUB

    DV["Delete a target value"]:::target
    DT["Delete a target<br/>and all of its values, comments and URL"]:::target
    HUB --> DV --> HUB
    HUB --> DT --> HUB

    CHK["Check the targets"]:::check
    C1["against number-to-select"]:::form
    C2["against the registration fields<br/>if any exist yet"]:::form
    C3["against the pool of respondents<br/>if any exist yet"]:::form
    HUB --> CHK
    CHK --> C1
    CHK --> C2
    CHK --> C3

    click A "#add-target-detail" "Adding a target"
    click V "#add-target-detail" "Adding target values"
    click P "#percent-detail" "Percentages and the auto-calculate link"
    click CALC "#percent-detail" "Percentages and the auto-calculate link"
    click SUM "#percent-detail" "Percentages and the auto-calculate link"
    click WARN "#percent-detail" "Percentages and the auto-calculate link"
    click MM "#minmax-detail" "Setting min and max by hand"
    click BREAK "#minmax-detail" "Setting min and max by hand"
    click VC "#minmax-detail" "Setting min and max by hand"
    click URL "#provenance-detail" "Recording where the numbers came from"
    click TC "#provenance-detail" "Recording where the numbers came from"
    click DV "#delete-detail" "Deleting targets and values"
    click DT "#delete-detail" "Deleting targets and values"
    click CHK "#check-targets-detail" "The check targets button"
    click C1 "#check-targets-detail" "The check targets button"
    click C2 "#check-targets-detail" "The check targets button"
    click C3 "#check-targets-detail" "The check targets button"
            

Click any box to jump to its details.

Add a target, then its values

A target is a category you want to stratify on: gender, age_bracket, region. A target value is one of the buckets inside it: Male, Female, Non-binary.

This is the whole minimum. A target with values, and nothing else filled in, is a valid target — the percentages, min/max, URL and comments can all wait.

Percentages, and how min and max are calculated from them

For each target value you enter the percentage of the assembly that should fall in that bucket. From the percentage and the already-agreed number-to-select, the min and max are calculated automatically:

Because both are derived, changing the percentage or changing the number-to-select will move the min and max for every value that still has its auto-calculate link intact.

The percentages for a single target should add up to about 100.0. If they don't, a warning is shown — but it is only a warning. Rounding in published statistics means the total is often 99.9 or 100.1, and there are legitimate reasons for a bigger gap, so this never blocks you.

Setting min and max by hand — and breaking the link

You can type a min and max directly onto a target value instead of letting them be calculated. Doing so permanently breaks the auto-calculate link for that value: from then on, editing the percentage or the number-to-select will not touch its min and max.

The link is per target value, not per target — one hand-set value in a target does not detach the others.

This is exactly why target values carry their own comment field. A hand-set min/max is a decision someone made for a reason, and six weeks later nobody remembers the reason. Write it down next to the number.

Source URL and comments on the target

The target itself carries two pieces of provenance:

Deleting a target or a target value
The “check the targets” button

A single button that runs the sanity checks that are possible at that moment. Which ones can run depends on what else exists yet:

Because targets are set up before either fields or respondents exist, the first run of this button will usually only be able to do the first check. That's expected — it is a button you come back to.

Flow 2 — Set up registration fields

Fields live in named sections, and sections are what the respondent sees as headed groups on the form. Most of this flow is ordinary list management; the three big entry points — add a field, add common fields, create fields from a target — each get their own chart below.

flowchart LR
    classDef pre    fill:#d7ccc8,stroke:#5d4037,color:#0b0c0c
    classDef hub    fill:#cce2f7,stroke:#1d70b8,color:#0b0c0c
    classDef field  fill:#c8e6c9,stroke:#2e7d32,color:#0b0c0c
    classDef decide fill:#f8bbd0,stroke:#ad1457,color:#0b0c0c
    classDef check  fill:#fff7d6,stroke:#b58840,color:#0b0c0c
    classDef done   fill:#e1bee7,stroke:#6a1b9a,color:#0b0c0c

    S(["Targets exist"]):::pre
    SEC["Add a section<br/>just give it a name"]:::field
    HUB(["Sections and their fields"]):::hub

    S --> SEC --> HUB
    HUB -->|"another section"| SEC

    RS["Reorder sections"]:::field
    DS["Delete a section"]:::field
    HUB --> RS --> HUB
    HUB --> DS --> HUB

    NF["Add a new field<br/>button sits inside each section,<br/>so the section is already known"]:::field
    CF["Add common fields"]:::field
    TF["Create field(s) from target(s)"]:::field
    CP["Copy fields from another assembly"]:::field

    HUB --> NF -.->|"flow 3"| HUB
    HUB --> CF -.->|"flow 5"| HUB
    HUB --> TF -.->|"flow 6"| HUB
    HUB --> CP --> HUB

    MV["Move a field to another section"]:::field
    RF["Reorder fields within a section"]:::field
    HUB --> MV --> HUB
    HUB --> RF --> HUB

    CHK{"Can every target get its<br/>data from these fields?"}:::check
    MISS["Warning: target X has no source -<br/>no matching field and no derived field"]:::check
    GEN["Generate the registration form<br/>it becomes the live web page"]:::done

    HUB --> CHK
    CHK -->|"no"| MISS --> HUB
    CHK -->|"yes"| GEN

    click SEC "#sections-detail" "Sections"
    click RS "#sections-detail" "Sections"
    click DS "#sections-detail" "Sections"
    click NF "#flow-addfield" "Flow 3 - add a new field"
    click CF "#flow-common" "Flow 5 - add common fields"
    click TF "#flow-fromtarget" "Flow 6 - create fields from a target"
    click CP "#copy-detail" "Copying fields from another assembly"
    click MV "#arrange-detail" "Moving and reordering fields"
    click RF "#arrange-detail" "Moving and reordering fields"
    click CHK "#coverage-detail" "The coverage check"
    click MISS "#coverage-detail" "The coverage check"
    click GEN "#generate-detail" "Generating the form"
            

Dotted arrows lead to a flow chart of their own, further down the page.

Sections

A section has a name and nothing else. It groups fields on the registration page and gives the respondent a heading — Eligibility, Contact details, About you, Consent are the usual four.

Sections can be reordered and deleted. There is an unresolved question about what deleting a section does to the fields inside it — see open questions.

Moving and reordering fields

Two separate operations: reordering fields within a section, and moving a field between sections. Neither changes the field itself — this is purely about how the form reads to the person filling it in.

Copying fields from another assembly

Assemblies repeat. Rather than rebuild a near-identical set of sections and fields, copy them from an assembly you have already run and edit the differences.

Note that a copied derived field carries assumptions with it: an age-brackets field brings its boundaries, a postcode mapping brings its uploaded CSV. Those may not match this assembly's targets, so the coverage check matters more after a copy, not less.

The coverage check — does every target have data?

This is the single point where the two independent structures are compared. For each target, it asks whether the registration fields can produce a value for it. There are exactly two ways they can:

  1. Directly — there is a field whose name matches the target's name and whose options match the target's values. A gender field offering Male / Female / Non-binary satisfies a gender target with those three values.
  2. Via a derived field — a calculated field named after the target computes the value from one or more real form fields. Date of birth becomes age_bracket; postcode becomes region.

If neither exists for some target, the check reports it. Whether this is a button you press or something that runs automatically on every save is still open — the diagram draws it as a gate, which is true either way.

Generating the registration form

Once the fields are set, the registration form can be generated and served as the public web page. Derived fields never appear on it — they are computed after submission, from the fields that do.

Flow 3 — Add a new field

The button lives inside a section, so which section you are adding to is never asked. Everything after that hangs off the field type: pick the type, and you get that type's form.

flowchart LR
    classDef hub    fill:#cce2f7,stroke:#1d70b8,color:#0b0c0c
    classDef field  fill:#c8e6c9,stroke:#2e7d32,color:#0b0c0c
    classDef decide fill:#f8bbd0,stroke:#ad1457,color:#0b0c0c
    classDef form   fill:#f3f2f1,stroke:#505a5f,color:#0b0c0c
    classDef done   fill:#e1bee7,stroke:#6a1b9a,color:#0b0c0c

    B(["Add field, inside a section"]):::hub
    T{"Choose the field type"}:::decide
    B --> T

    CB["Checkbox"]:::field
    CH["Choice of options"]:::field
    TX["Text"]:::field
    NU["Text (numeric)"]:::field
    DA["Date"]:::field
    CA["Calculated from another field"]:::field

    T --> CB
    T --> CH
    T --> TX
    T --> NU
    T --> DA
    T --> CA

    CBF["Name<br/>Question text<br/>Help text (optional)<br/>Must the respondent tick it?"]:::form
    CHF["Name<br/>Question text<br/>Help text (optional)<br/>Text for each option<br/>Help text per option (optional)<br/>Form type: auto / radio buttons / dropdown"]:::form
    TXF["Name<br/>Question text<br/>Help text (optional)"]:::form
    NUF["Name<br/>Question text<br/>Help text (optional)<br/>Minimum (optional)<br/>Maximum (optional)"]:::form
    DAF["Name<br/>Question text<br/>Help text (optional)<br/>Full date or year only<br/>Minimum (default 1900-01-01)<br/>Maximum (default start of this year)"]:::form
    CAF["Its own multi-step form<br/>see flow 4"]:::form

    CB --> CBF
    CH --> CHF
    TX --> TXF
    NU --> NUF
    DA --> DAF
    CA --> CAF

    SAVE["Save - the field appears<br/>in that section"]:::done
    CBF --> SAVE
    CHF --> SAVE
    TXF --> SAVE
    NUF --> SAVE
    DAF --> SAVE
    CAF -.->|"flow 4"| SAVE

    click CB "#checkbox-detail" "Checkbox fields"
    click CBF "#checkbox-detail" "Checkbox fields"
    click CH "#choice-detail" "Choice of options"
    click CHF "#choice-detail" "Choice of options"
    click NU "#numeric-detail" "Numeric text"
    click NUF "#numeric-detail" "Numeric text"
    click DA "#date-detail" "Date fields"
    click DAF "#date-detail" "Date fields"
    click CA "#flow-calc" "Flow 4 - calculated fields"
    click CAF "#flow-calc" "Flow 4 - calculated fields"
            
Checkbox — the only field that can be optional

Every other field type is required on the registration form. A checkbox is the one type where you choose: must the respondent tick it to submit, or is ticking it genuinely their choice?

Choice of options — and the “auto” form type

Each option has its own text and, optionally, its own help text. The form type controls how it renders:

This is also the type that a map-more-to-fewer derived field reads from, and the type an exact copy from a target produces.

Text (numeric)

A text field constrained to numbers, with an optional minimum and maximum. Both are optional — leave them blank for an unbounded number.

Date — full date or year only

Used mainly for date of birth. You choose whether to ask for a full date or just a year, which matters: year-only is less intrusive to ask for, but gives an age that can be a year out.

The minimum defaults to 1900-01-01 and the maximum to the start of the current year, which between them reject the obvious typos.

A date field is the usual input for an age-ranges derived field.

Flow 4 — Calculated (derived) fields

A calculated field never appears on the registration page. It exists to turn what you did ask into what the target needs, and it is computed when someone registers.

flowchart TD
    classDef hub    fill:#cce2f7,stroke:#1d70b8,color:#0b0c0c
    classDef field  fill:#c8e6c9,stroke:#2e7d32,color:#0b0c0c
    classDef decide fill:#f8bbd0,stroke:#ad1457,color:#0b0c0c
    classDef form   fill:#f3f2f1,stroke:#505a5f,color:#0b0c0c
    classDef done   fill:#e1bee7,stroke:#6a1b9a,color:#0b0c0c

    S(["Field type: calculated from another field<br/>never shown on the registration page"]):::hub
    N["Name - pick from the list of target names.<br/>Normally it should match a target name."]:::form
    T{"Which calculation?"}:::decide
    S --> N --> T

    AG["Age ranges"]:::field
    MP["Map more options to fewer"]:::field
    PC["Map postcode to value"]:::field
    T --> AG
    T --> MP
    T --> PC

    AGF["Minimum age (default 16)<br/>Age boundaries, comma separated (default 30,45,60)<br/>Maximum age (default 100)<br/>Date to calculate age on (default today)"]:::form
    AGB["Button: work out the minimum age and the<br/>boundaries from the target with the matching name"]:::form
    AG --> AGF
    AGB -.->|"fills in"| AGF

    MPO["Text for each option<br/>button: copy the options from the matching target"]:::form
    MPI["Field to map from - choose one of the<br/>fields of type 'choice of options'"]:::form
    MPM["One dropdown per registration option;<br/>its choices are the target values.<br/>Every one has to be filled in."]:::form
    MP --> MPO --> MPI --> MPM

    PCO["Text for each option<br/>button: copy the options from the matching target"]:::form
    PCI["Field to use as input<br/>default: postcode"]:::form
    PCU["Upload a CSV mapping file:<br/>column 1 is the postcode, column 2 is the value.<br/>Can be thousands of rows."]:::form
    PC --> PCO --> PCI --> PCU

    SAVE["Save"]:::done
    AGF --> SAVE
    MPM --> SAVE
    PCU --> SAVE

    click AG "#agerange-detail" "Age ranges"
    click AGF "#agerange-detail" "Age ranges"
    click AGB "#agerange-detail" "Age ranges"
    click MP "#mapfewer-detail" "Map more options to fewer"
    click MPO "#mapfewer-detail" "Map more options to fewer"
    click MPI "#mapfewer-detail" "Map more options to fewer"
    click MPM "#mapfewer-detail" "Map more options to fewer"
    click PC "#postcode-detail" "Map postcode to value"
    click PCO "#postcode-detail" "Map postcode to value"
    click PCI "#postcode-detail" "Map postcode to value"
    click PCU "#postcode-detail" "Map postcode to value"
    click N "#derived-detail" "Why derived fields exist"
            
Why derived fields exist at all

Because the best question to ask a respondent is often not the shape you want to stratify on. Three recurring cases:

In all three cases you set up the target first, in target language, and only later work out which real question can feed it.

Age ranges

Date-of-birth fields go on the registration form. When someone registers, the system calculates their age and drops them into a bucket.

The bucket boundaries come from four numbers:

InputDefault
Minimum age16
Age boundaries (comma separated)30,45,60
Maximum age100
Date to calculate age ontoday

Worked example: minimum 16, maximum 100, boundaries 22,30,55 gives four brackets:

There is a button to work out the minimum age and the boundaries from the target with the matching name, so you don't retype what you already entered on the targets side.

Date to calculate age on defaults to today, but for an assembly you usually want the age people will be at the event, not at registration — so this is often set to the first assembly date.

Map more options to fewer

For when the form offers plenty of options and the target has few. Ethnicity is the standard case: 10 options on the form, 4 target buckets.

  1. Early on, you created the target with its 4 values.
  2. Now you create the field that will be on the form — a choice of options field with 10 options.
  3. Then you create this derived field: pick the target it feeds, and pick the registration field it maps from.
  4. You get one dropdown per registration option; each dropdown lists the target values. Every option must be assigned.

When someone registers, the system looks their answer up in that saved table and sets the target value accordingly.

Note the ordering constraint: the field you map from has to exist before you can build the mapping, because you pick it from a list of existing “choice of options” fields.

Map postcode to value (large mappings)

For when the form has a free-text box and the target has a small set of values, with a big lookup table in between. Postcode to region is the standard case.

  1. Enter the target values (or copy them from the matching target).
  2. Name the registration field this is based on — defaults to postcode.
  3. Upload a CSV with two columns. Each row is one postcode and the value it maps to. There can be thousands of rows.

The column titles should match the field name and the target name — postcode and region in this example.

When someone registers, the system looks their postcode up in the saved table and sets the target value.

Worth checking against the data-retention rules. The project's GDPR position is that no long-term copies of uploaded files are kept. A postcode-to-region CSV is reference data rather than personal data, so it is probably fine to store — but it arrives through a file upload, which is exactly the path that rule is about. Worth a decision rather than an assumption.

Flow 5 — Add common fields

A shortcut past the blank page. Almost every assembly needs the same eligibility, contact, and consent fields, so they are offered as a checklist rather than built one at a time.

flowchart TD
    classDef hub    fill:#cce2f7,stroke:#1d70b8,color:#0b0c0c
    classDef field  fill:#c8e6c9,stroke:#2e7d32,color:#0b0c0c
    classDef form   fill:#f3f2f1,stroke:#505a5f,color:#0b0c0c
    classDef done   fill:#e1bee7,stroke:#6a1b9a,color:#0b0c0c

    B(["Add common fields"]):::hub
    M["Pop-up: the common fields, grouped into<br/>standard sections. Each has a description<br/>and a checkbox."]:::form
    B --> M

    E["Eligibility<br/>can_attend - I can attend all dates<br/>eligible - I am eligible to attend"]:::form
    C["Contact details<br/>first_name, last_name, email, phone,<br/>address_line_1, address_line_2, city, postcode"]:::form
    A["About you<br/>gender, date_of_birth, year_of_birth"]:::form
    K["Consent<br/>consent - store my data per the linked policy<br/>stay_on_db (optional) - contact me about future events"]:::form

    M --> E
    M --> C
    M --> A
    M --> K

    ACC["Tick the ones you want, click Accept"]:::field
    E --> ACC
    C --> ACC
    A --> ACC
    K --> ACC

    RES["The chosen fields appear<br/>in your list of fields"]:::done
    ED["Edit any of them afterwards<br/>like any other field"]:::field
    ACC --> RES --> ED

    click M "#common-detail" "The common fields list"
    click E "#common-detail" "The common fields list"
    click C "#common-detail" "The common fields list"
    click A "#common-detail" "The common fields list"
    click K "#common-detail" "The common fields list"
            
The starter list
SectionFieldNote
Eligibilitycan_attend“I can attend all dates”
eligible“I am eligible to attend”
Contact detailsfirst_name
last_name
email
phone
address_line_1
address_line_2
city
postcodeOften also the input to a derived region field
About yougender
date_of_birth
year_of_birthAlternative to date_of_birth, not an addition to it
Consentconsent“I consent to you storing my data in accordance with a linked policy”
stay_on_dbOptional checkbox — “Keep my details and contact me about similar events in the future”

These are a starting point, not a fixed set. Once added they are ordinary fields: rename them, move them between sections, change the question text.

Flow 6 — Create field(s) from a target

The other way round from flow 3: instead of building a field and hoping it lines up with a target, start from the target and let it fill in what it can. This is the fastest route to a form that passes the coverage check.

flowchart TD
    classDef hub    fill:#cce2f7,stroke:#1d70b8,color:#0b0c0c
    classDef field  fill:#c8e6c9,stroke:#2e7d32,color:#0b0c0c
    classDef decide fill:#f8bbd0,stroke:#ad1457,color:#0b0c0c
    classDef form   fill:#f3f2f1,stroke:#505a5f,color:#0b0c0c
    classDef done   fill:#e1bee7,stroke:#6a1b9a,color:#0b0c0c

    B(["Create field(s) from target(s)"]):::hub
    L["One button per target.<br/>Greyed out if a matching field already exists."]:::form
    H{"How should the field be created?"}:::decide
    B --> L --> H

    EX["Exact copy"]:::field
    AG["Age ranges"]:::field
    MP["Map more options to fewer"]:::field
    PC["Map postcode to value"]:::field
    H --> EX
    H --> AG
    H --> MP
    H --> PC

    EXF["The 'choice of options' form, with the name and<br/>options pre-filled from the target.<br/>You still fill in question text, help text and form type."]:::form
    EX --> EXF

    AGD["Choose the date field to use as input:<br/>an existing date field, or create one now"]:::form
    AGA["Minimum age and age boundaries are auto-filled<br/>from the target - error if they cannot be worked out"]:::form
    AGO["You fill in the rest,<br/>e.g. the date to calculate age on"]:::form
    AG --> AGD --> AGA --> AGO

    MPT["The target is already known"]:::form
    MPF["Choose the field to map from"]:::form
    MPM["Set up the mapping: one dropdown per<br/>registration option, choices are the target values"]:::form
    MP --> MPT --> MPF --> MPM

    PCO["Options copied from the target"]:::form
    PCI["Field to use as input<br/>default: postcode"]:::form
    PCU["Upload the CSV mapping file"]:::form
    PC --> PCO --> PCI --> PCU

    SAVE["Save - the field(s) appear<br/>and the target is now covered"]:::done
    EXF --> SAVE
    AGO --> SAVE
    MPM --> SAVE
    PCU --> SAVE

    click EX "#exactcopy-detail" "Exact copy"
    click EXF "#exactcopy-detail" "Exact copy"
    click AG "#agerange-detail" "Age ranges"
    click AGD "#agerange-detail" "Age ranges"
    click AGA "#agerange-detail" "Age ranges"
    click AGO "#agerange-detail" "Age ranges"
    click MP "#mapfewer-detail" "Map more options to fewer"
    click MPT "#mapfewer-detail" "Map more options to fewer"
    click MPF "#mapfewer-detail" "Map more options to fewer"
    click MPM "#mapfewer-detail" "Map more options to fewer"
    click PC "#postcode-detail" "Map postcode to value"
    click PCO "#postcode-detail" "Map postcode to value"
    click PCI "#postcode-detail" "Map postcode to value"
    click PCU "#postcode-detail" "Map postcode to value"
            
Exact copy

The simplest route: the target's name and values become a choice of options field's name and options. Gender in, gender out.

What it cannot fill in is the human half — the question text the respondent reads, the help text, and whether it renders as radios or a dropdown. Those are still yours to write.

Open questions

Things the description above doesn't settle, drawn out here rather than quietly decided in a diagram.

  1. Maximum age. The age-range form is described in two places with two different lists — one has minimum age, boundaries and calculation date; the other adds a maximum age defaulting to 100. The diagrams show maximum age, because the worked example (16, 100, boundaries 22,30,55) needs it to produce a top bracket of 55–99. Confirm it belongs on the form.
  2. Coverage check: button or automatic? Drawn as a gate, which is true whether it's a button or runs on every save. A button is honest about cost and lets you work in a broken state; automatic means nobody forgets. The likely answer is both — run automatically and show a persistent warning banner, with a button for the fuller cross-check against respondents.
  3. Deleting a section that has fields in it. Does it delete the fields, refuse until the section is empty, or move them somewhere? Refusing is the safest and least surprising, but it makes tidying up tedious.
  4. Deleting a target that a derived field feeds. A derived field is named after a target and may have copied that target's options. Deleting the target leaves the field orphaned. Warn, block, or allow and let the coverage check complain?
  5. Ordering constraint on “map more to fewer”. You pick the field to map from out of a list of existing “choice of options” fields, so that field must be created first. Flow 6 partly solves this for age ranges by letting you create the date field inline; the same escape hatch may be worth having here.
  6. CSV validation on the postcode mapping. The column titles “should match” the field and target names. Is that enforced, or advisory? And what happens at registration when a postcode isn't in the table at all — reject the submission, or record an unmapped value?
  7. Percentage tolerance. “Close to 100.0” needs a number. Published statistics routinely total 99.9 or 100.1 through rounding, so the threshold has to allow that without waving through a genuine mistake.

Glossary

Target
A category the selection stratifies on — gender, age_bracket, region. Holds target values, an optional source URL and an optional comment.
Target value
One bucket within a target — Male, 16-29, North London. Holds a percentage, a min and a max, and an optional comment.
Number-to-select
How many people the assembly needs. Agreed before any of this, and the multiplier that turns percentages into a min and max.
The live connection from a target value's percentage to its min and max. Intact by default; broken permanently for that value the moment you type a min or max by hand.
Section
A named group of fields. Becomes a heading on the registration page.
Field
One question on the registration form — or, for a calculated field, one value computed from the answers rather than asked for.
Derived (calculated) field
A field that never appears on the form. It takes one or more real fields and produces the value a target needs: date of birth to age_bracket, ten ethnicity options to four, postcode to region. See flow 4.