Merged PR 5371: Flagging w. random predictor + DWH connection improvements + restructure

Connecting to DWH:
* Any existing notebook (AB, Flagging & Template) now have an initial simplified block to connect to the DWH. This is done to handle the DRY, as we're going to start adding more and more experiment notebooks very soon (and we have already 4 notebooks).
* This reads from a new `utils/dwh_utils.py` in which we handle the connection and test it accordingly.
* This also requires an optional `settings.json` path configuration to avoid warnings (not errors) when reading from `dwh_utils`.

Flagging:
* All flagging notebooks now go within the folder `data_driven_risk_assessment`. The already existing notebook `flagging_performance_monitoring` has also been moved here.
* There's a new `experiments` folder to store the different experiments on flagging.
* A new notebook has been added containing a straight-forward baseline: a random predictor, which randomly flags as risk bookings on a test set based on the observed booking claim rate on a previous train dataset.

I confirm that all existing notebooks work well after the connection changes.

Once merged, or to review, you will need to re-install requirements.txt as I added sklearn.

Related work items: #30804
This commit is contained in:
Oriol Roqué Paniagua 2025-06-10 05:59:12 +00:00
parent 2662f994f0
commit 38f63afbf7
8 changed files with 634 additions and 533 deletions

3
.vscode/settings.json vendored Normal file
View file

@ -0,0 +1,3 @@
{
"python.analysis.extraPaths": ["./data-jupyter-notebooks/utils"]
}