08: English screenshots, English Study coach with open Wikipedia resource, DSL export

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
Guido van Dijk
2026-09-21 10:06:23 +02:00
parent 5daf506729
commit 34837152c2
93 changed files with 768 additions and 35 deletions
@@ -2,12 +2,12 @@
FOR THE EDITOR
Guide 8: Chatflow, the Study coach for Biology Year 9. Screenshots in screenshots/, captured on
20 September 2026 (Dify cloud, Dutch build of the same app).
21 September 2026 (Dify cloud, English interface).
Convert to HTML, PDF and Word: python3 build.py
Sample material: lesson-booklet-ecology.pdf and study-planner-biology-y9-ecology.pdf (fictional,
generated by _tools/make_samples.py); the Dutch build also used an open module from the Dutch
Stercollectie (CC BY-SA 4.0) as a third document.
generated by _tools/make_samples.py) plus food-web-wikipedia.pdf, the Wikipedia article "Food web"
(CC BY-SA 4.0) as the open third document.
Formatting conventions (see also README.md):
- Numbered list = actions (click, choose)
@@ -16,7 +16,7 @@ Formatting conventions (see also README.md):
- Blockquote (>) = pitfall or tip (orange box)
- Blockquote starting with **Your choice** = a choice for the participant (green box)
Published example app (Dutch): https://udify.app/chat/fP0TJW3s8IXOj9BO
Published example app: https://udify.app/chat/mgvtZPbDVAIp5gbh
-->
# A study coach for your subject: Chatflow with memory, routes and a human in the loop
@@ -43,7 +43,7 @@ The four routes:
| Planning question | Knowledge base (study planner) → concrete answer | "When is the test and what do I need to know?" |
| Personal or worrying | The teacher gets an email, the student gets the teacher's reply | "I don't get any of it and I don't dare ask" |
This guide follows the cloud version of Dify of 20 September 2026, on a Professional account. On a sandbox account everything works the same; you just upload the documents one at a time. The screenshots show the Dutch build of this app (Dutch prompts, Dutch conversations); the screens and clicks are the same.
This guide follows the cloud version of Dify of 20 September 2026, on a Professional account. On a sandbox account everything works the same; you just upload the documents one at a time.
**How to read this guide**
@@ -88,7 +88,7 @@ Two documents come with this guide, plus a place for a third:
| --- | --- | --- |
| `lesson-booklet-ecology.pdf` | Five sections of content, twelve tasks, a glossary (5 pp.) | Written for this guide, fictional, free to use |
| `study-planner-biology-y9-ecology.pdf` | Learning objectives, schedule per week, test date, support session, AI rules (2 pp.) | Written for this guide, fictional |
| An open resource of your choice | For example a chapter on ecosystems from OpenStax Biology 2e (CC BY 4.0) or a CK-12 lesson on food webs | Open educational resources; the Dutch build used a module from the Dutch Stercollectie, CC BY-SA 4.0 |
| `food-web-wikipedia.pdf` | The Wikipedia article "Food web" as a PDF (24 pp.), as an example of an open resource | Wikipedia, CC BY-SA 4.0; replace it with a resource from your own subject, for example a CK-12 lesson or an OpenStax chapter (check the licence: OpenStax is CC BY-NC-SA) |
The third document is real open learning material. A CC BY licence means: you may use it, put it in a knowledge base and adapt it, as long as you credit the source; CC BY-SA adds that you share what you make of it under the same licence. The study planner mentions the open resource as extra practice material, so the coach can refer to it.
@@ -103,14 +103,14 @@ The third document is real open learning material. A CC BY licence means: you ma
1. **Knowledge** → **Create** (or **Create a ready-to-use knowledge base**).
2. Click **Browse** and choose the booklet and the study planner. On a Professional account you can choose several files at once; in the sandbox one at a time (then **Add file**).
![Two files ready for upload](screenshots/a01-upload-twee.jpg)
![Two files ready for upload](screenshots/a01-upload-two.jpg)
3. **Next**.
4. Set **Delimiter** to `\n\n` and click **Preview Chunk**. The booklet falls into about fourteen pieces of roughly a thousand characters: each piece is a paragraph with real content.
4. Set **Delimiter** to `\n\n` and click **Preview Chunk**. The booklet falls into thirteen pieces of roughly a thousand characters: each piece is a paragraph with real content.
![The default setting: Delimiter \n](screenshots/a02-chunk.jpg)
![After the change: fourteen chunks with content](screenshots/a03-preview.jpg)
![After the change: thirteen chunks with content](screenshots/a03-preview.jpg)
5. Scroll down, leave the rest, and click **Save & Process**.
@@ -143,7 +143,7 @@ Via the three dots behind a document you can also rename, download or delete it;
![The menu behind a document](screenshots/a06-doc-menu.jpg)
![Three documents, all Available](screenshots/a07-drie-documenten.jpg)
![Three documents, all Available](screenshots/a07-three-documents.jpg)
---
@@ -161,7 +161,7 @@ Via the three dots behind a document you can also rename, download or delete it;
2. **Create**. Dify already puts down a default flow: User Input → LLM → Answer.
![The default flow of a new Chatflow](screenshots/b02-standaard-flow.jpg)
![The default flow of a new Chatflow](screenshots/b02-default-flow.jpg)
### Step 5. Clear the default flow
@@ -172,7 +172,7 @@ Those two blocks do not fit our plan; we build everything ourselves.
![The menu with Delete](screenshots/b03-delete-llm.jpg)
![Only User Input left; the input is sys.query, the student's question](screenshots/b04-leeg-canvas.jpg)
![Only User Input left; the input is sys.query, the student's question](screenshots/b04-empty-canvas.jpg)
### Step 6. The Question Classifier
@@ -213,7 +213,7 @@ Personal or worrying: the student writes about themselves, for example that it i
4. Scroll to **NEXT STEP**: every class now has its own exit.
![Four exits, still empty](screenshots/b10-vier-takken.jpg)
![Four exits, still empty](screenshots/b10-four-exits.jpg)
> The last class ends with "Also anything that is not about biology". That is deliberate: anything that fits nowhere ends up with a person instead of with a model that invents an answer anyway. Always put your safety net in the class that goes to a person.
@@ -233,13 +233,13 @@ Personal or worrying: the student writes about themselves, for example that it i
![Select reference Knowledge](screenshots/c02-select-knowledge.jpg)
![Connected](screenshots/c03-kr-gekoppeld.jpg)
![Connected](screenshots/c03-kr-attached.jpg)
### Step 8. The LLM block Explanation
1. **Select next step** → **LLM**. Model **gpt-5-mini**.
![The empty LLM block](screenshots/c04-llm-leeg.jpg)
![The empty LLM block](screenshots/c04-llm-empty.jpg)
2. **CONTEXT** → **Knowledge Retrieval / result**.
@@ -278,7 +278,7 @@ In a Chatflow the exit is not called Output but **Answer**: that is what the stu
1. **Select next step** → **Answer**.
![The empty Answer block](screenshots/c08-answer-leeg.jpg)
![The empty Answer block](screenshots/c08-answer-empty.jpg)
2. Click in the field, type a forward slash and choose **EXPLANATION / text**.
@@ -286,7 +286,7 @@ In a Chatflow the exit is not called Output but **Answer**: that is what the stu
3. Rename the block to `Answer explanation`.
![Route 1 is done](screenshots/c10-antwoord-uitleg.jpg)
![Route 1 is done](screenshots/c10-answer-explanation.jpg)
---
@@ -361,7 +361,7 @@ Study planner: {Context}
This is what the canvas looks like now:
![Three routes done, class 4 still empty](screenshots/d11-overzicht.jpg)
![Three routes done, class 4 still empty](screenshots/d11-overview.jpg)
> Why the same knowledge base twice? Because each block has its own query and its own prompt. Route 1 searches the material and explains, route 3 searches the same knowledge base but the prompt only looks at the study planner. On a Professional account you can also make two knowledge bases (material and planning separately); that is neater, but in the sandbox it costs you a knowledge base you may need.
@@ -385,7 +385,7 @@ This is the part that makes a study coach responsible. A student who writes "I d
3. Click **Not configured** behind Email and fill in the email message.
![The empty email configuration](screenshots/e04-email-leeg.jpg)
![The empty email configuration](screenshots/e04-email-empty.jpg)
| Field on screen | What you type |
| --- | --- |
@@ -398,7 +398,7 @@ This is the part that makes a study coach responsible. A student who writes "I d
A Year 9 student asked the Study coach a personal question that the coach does not answer itself. Read the conversation and write a short reply; the student will see it in the chat. Respond through this link:
```
![Subject, text, recipient and Debug Mode](screenshots/e05-email-ingevuld.jpg)
![Subject, text, recipient and Debug Mode](screenshots/e05-email-filled.jpg)
4. **Save**. Then switch on the toggle behind **Email**.
@@ -418,7 +418,7 @@ A Year 9 student asked the Study coach a personal question that the coach does n
![Insert Input Field](screenshots/e08-input-field.jpg)
![The form: the student's question and a reply field](screenshots/e09-form-klaar.jpg)
![The form: the student's question and a reply field](screenshots/e09-form-done.jpg)
5. **USER ACTIONS** → **+**. This becomes the button under the form.
@@ -433,9 +433,7 @@ A Year 9 student asked the Study coach a personal question that the coach does n
![The output variables of Human Input](screenshots/e11-output-vars.jpg)
7. Rename the block to `Teacher`. Leave **TIMEOUT** at 3 days.
![Teacher, with two exits: SEND and TIMEOUT](screenshots/e12-docent.jpg)
7. Rename the block to `Teacher`. Leave **TIMEOUT** at 3 days. On the canvas the block now has two exits: **SEND** and **TIMEOUT**.
### Step 15. Three messages to the student
@@ -453,7 +451,7 @@ Your teacher has not been able to respond yet. Your message is not lost: talk to
Rename to `No reply`.
![No reply](screenshots/e14-geen-reactie.jpg)
![No reply](screenshots/e14-no-reply.jpg)
3. Click the classifier, scroll to **NEXT STEP**, and under **CLASS 4** click **ADD PARALLEL NODE** → **Answer**:
@@ -463,7 +461,7 @@ Thank you for telling me this. This is something for a person, not for me. I hav
Rename to `Passed on`. A parallel block runs at the same time as Teacher: the student sees this message immediately, while the workflow waits for the teacher.
![The complete Study coach](screenshots/e15-hele-flow.jpg)
![The complete Study coach](screenshots/e15-whole-flow.jpg)
> **Your choice: who gets the email, and what it says.** In real use the recipient is the form tutor or the teacher of that class, not a department address. Agree with the pastoral lead what the message to the student should contain: which helpline, which person at school, and whether you refer the student to a person straight away (yes). The helpline in the text is a placeholder; replace it with the one that applies in your country and school.
@@ -479,7 +477,7 @@ Click **Preview** at the top right. Test all four routes; the canvas colours alo
![The classifier chose class 1; Explanation is running](screenshots/f01-preview-running.jpg)
![Explanation with examples from the booklet, a check question and a source](screenshots/f02-uitleg.jpg)
![Explanation with examples from the booklet, a check question and a source](screenshots/f02-explanation.jpg)
Then type: `and why is such a chain never longer than 4 or 5?` The answer is about food chains without you repeating the word: that is Memory.
@@ -493,13 +491,15 @@ Then type: `and why is such a chain never longer than 4 or 5?` The answer is abo
**Route 4**, type: `I really don't get any of it and I don't dare ask in class, everyone laughs at me anyway`
![Passed on, plus the form as the teacher gets it in the email (only visible in Preview)](screenshots/f05-docent-form.jpg)
![Passed on, plus the form as the teacher gets it in the email (only visible in Preview)](screenshots/f05-teacher-form.jpg)
In Preview you see the teacher's form in the chat itself, with the remark "Debug preview only, user will not see this in web app". In real use it is in the email. Fill it in as if you were the teacher and click **Send to the student**.
![The teacher's reply filled in](screenshots/f06-docent-ingevuld.jpg)
![The teacher's reply filled in](screenshots/f06-teacher-filled.jpg)
![The student first sees Passed on and then the teacher's message](screenshots/f07-docent-antwoord.jpg)
![The teacher's message arrives in the chat](screenshots/f07-teacher-answer.jpg)
> In Preview the parallel message "Passed on" is not shown as a separate bubble; the form takes its place. In the web app the student does see it first.
### Step 17. Opening line and example questions
@@ -524,13 +524,13 @@ In Preview you see the teacher's form in the chat itself, with the remark "Debug
2. **Access point** → the link under **Webapp**.
![Access point](screenshots/f09-toegangspunt.jpg)
![Access point](screenshots/f09-access-point.jpg)
![The webapp: opening message and example questions](screenshots/f12-webapp-start.jpg)
![An answer in the webapp, with source](screenshots/f13-webapp-antwoord.jpg)
![An answer in the webapp, with source](screenshots/f13-webapp-answer.jpg)
Our Dutch version: https://udify.app/chat/fP0TJW3s8IXOj9BO
The app in this guide is live at <https://udify.app/chat/mgvtZPbDVAIp5gbh>.
---