Produce node
The Produce node runs a published AI flow that generates a document, such as a summary letter, and saves it to the patient's record.
The Produce node (code name Artifact) runs a live AI flow and saves the document it produces to the patient's record. Use it for generated documents such as a discharge summary, a referral letter or a care-plan handout.
AI flows are not built in the journey builder. Only flows that are active and published can be picked here; your implementation team can tell you which flows are ready for journeys.
When to use it
- A document should be generated automatically at a point in the journey.
- Later steps need that document, for example a Reach email that attaches it through Document reference.
Configuration
Field | What it does | Options and default |
|---|---|---|
Label, Notes | See Label and Notes. | — |
Flow | The AI flow to run. Required: Pick a live, published flow. | Only active flows with a published version are listed. |
Artifact type | The document type, from your tenant vocabulary. Becomes the document's category on the patient record. Required. | Your artifact types. When none exist, the panel shows No artifact types yet — they are defined in the tenant vocabulary. |
Artifact name | The name the document is saved under. Required. | Free text. |
How the flow runs | Whether the flow runs at once or in the background. | Now (default) or In the background. Shown read-only when the step is run by a scheduler. |
Waiting card | Waits for: The AI flow to produce the document. This step always waits for the document. | Cannot be changed. |
Time limit (seconds) | Required. How long to wait for the document. Counted from the moment the flow starts. | A number of seconds. |
Inputs (Advanced) | Values passed to the flow. Each row has an Input name and an Expression. Add a row with Add input. | Plain text boxes. Start expressions with |
Skip this step when…, If this step is already in the past (Advanced) | See the overview. | — |
The Waiting card also says No reminder is sent on this step. and This step raises no tasks.
Outcomes and branches
Pick one of these in the connection editor's Outcome list:
Outcome | When |
|---|---|
Document produced | The flow finished and the document was saved. |
Document failed | The flow failed, or produced no document. |
Timed out | The time limit ran out first. The Waiting card shows this path as timed_out. |
What happens when it runs
- The flow runs with the values in Inputs.
- When the flow finishes in time and produces a document, the document is saved to the patient's documents under the Artifact name and Artifact type, and the step ends with Document produced.
- If the flow fails or produces no document, the step ends with Document failed. If the time limit runs out first, it ends with Timed out.
- If the Artifact type has since been removed from your tenant vocabulary, the step fails and staff can see the failure on the patient's run.
Patients see nothing at this step. Staff see the new document on the patient's record; see The patient profile.
Example
Discharge summary emailed to the patient.
- Produce step
discharge_summary: Flow Discharge summary, Artifact type Discharge summary, Artifact name Discharge summary, How the flow runs In the background, Time limit (seconds) 900. - Inputs:
visit_id→initial.visit_id. - Connect Document produced to a Reach email whose Document reference points at the document produced by
discharge_summary. Connect Document failed and Timed out to an Engage task for the doctor to write it by hand.
Tips
- Use In the background for flows that can take more than a few seconds.
- The Inputs boxes do not offer expression suggestions. Check the spelling of each expression.
- The node can host an AI Aide, which can fill the Artifact name and the inputs. See AI Aide node.
Last updated on
Sign node
The Sign node collects legal e-signatures on a PDF template from patients, relatives, doctors or staff, in stages, with a coordinator for problems.
Engage node
The Engage node raises a task for a role, person or team at a centre, and can wait for the answer staff give before the journey continues.