Practicals · Day 4
APIs, evidence and agent workflows
Four practical sessions move from one API request to repeatable analysis, checked writing, and a controlled comparison of agent systems.
Day 4 lecture
.ipynb file directly. No Day 4 dataset is hosted here: the notebooks retrieve public source data when they run. Folder downloads contain only notebooks, setup files, and the agent mission files.The four sessions
Call a public API, keep model keys outside the notebook, send one model request, calculate its cost, and compare model routes on the same labelled task.
Download the complete BIS speech archive in the notebook, filter by date, year, month, and country or author text, chart explicit climate references over time, and run an optional LLM-labelled pilot.
Retrieve economic indicators, validate and chart the data, give a writer model a compact evidence table, and use a second provider to identify claims that need human review.
Give Claude Code and OpenCode with DeepSeek the same scrape–analyse–visualise–report mission. Compare delivered files with common acceptance checks before judging quality.
Shared setup
Create one Python environment for the notebooks. Copy the environment template to .env, add only the keys needed for the selected session, and start Jupyter from the practical folder. A hidden one-session key prompt is available when .env is absent.
Practical 04 additionally requires Claude Code for Run A and Node.js plus OpenCode for Run B. If only one system is available, run it and compare outputs with another group.
Setup files
What the sequence teaches
- understand the request and response before using a model API;
- compare models on the same task using quality, latency, and cost;
- keep evidence, model outputs, and provenance connected;
- use a second check to prioritise human review;
- evaluate agent deliverables rather than accepting an agent's completion message.