Lab: The Ask workflow, its sessions and its jobs
Module 8 · Lab · About 70 minutes · Needs: lessons 1 to 4 of this module, and the Module 7 lab (or nothing: Step 1 rebuilds Modules 1 to 7)
What you are building
Gareth's question from Lesson 1 now has an answer in code. This lab puts the four lessons' files into the repository unchanged and joins them: Lesson 1's state machine runs on Module 6's permissioned retriever and Module 7's residency-filtered chain; each turn of a session carries Lesson 2's history and Lesson 3's memory and is checkpointed after every step; Lesson 4's jobs run a whole night for six tenants on RQ. ADR-005 records the background-work decision.
The new files are northdesk/ask_ports.py, northdesk/ask_turn.py, northdesk/digest.py, tests/test_workflow.py and tests/test_jobs.py. One cell calls your provider; every number quoted comes from a scripted model, fakeredis or no model at all. Open a new Colab notebook, module-08-lab.ipynb, and run each cell in order.