ORIGINAL SYNTHETIC LABORATORIES
Make the failure visible.
Six additional laboratories extend the existing Python, algorithms, web/data, mathematics/data, machine-learning and applied-AI courses. Use synthetic data in a local temporary directory.
Download the runnable Python lab kit
Run and investigate
- Save
labkit.pyon a computer with Python 3. The kit uses only the standard library. - Run
python labkit.pyorpython3 labkit.py. Six reference test groups should pass. - Read the corresponding course unit. Predict what will happen before changing the fixture.
- Introduce the specified fault, observe a failing assertion, explain the mechanism and restore the contract.
- Keep the command, Python version, changed input, expected result and observed result in a run log.
Courses and experiments
- Python: atomic export and failure recovery — preserve a prior report after invalid late input, conflicting IDs and an injected write failure.
- Algorithms: duplicate keys and binary-search boundaries — compare lower-bound results with an independent standard-library reference.
- Web/data: authorization, stale versions and rollback — inspect a sequential SQLite reference transaction, then implement and test concurrent requests in your chosen web stack.
- Mathematics/data: group leakage and future features — enforce disjoint entity groups and prediction-time feature availability.
- Machine learning: threshold costs and honest evaluation — reconcile counts, ratios, undefined metrics and selection boundaries.
- Applied AI: permission-separated retrieval — test six normal, missing, stale, conflicting, injection and cross-tenant fixtures, plus execution-time revocation.
Interpret the results precisely
The kit is a small executable reference, not a production service or a language-model benchmark. It makes no external requests and sends no messages. The SQLite fixture demonstrates sequential version checks and rollback; it does not establish a PostgreSQL isolation guarantee or test a real web server under concurrency. The retrieval fixture tests deterministic boundaries, not whether a model will always resist injection. Extend the tests in the relevant course before making a broader claim.