LoopKit uses a static model for only 4 supported DIAs.
I'd propose replacing the algorithm with the curve found in oref0/openaps:
https://github.com/nightscout/cgm-remote-monitor/blob/master/lib/plugins/iob.js
https://github.com/openaps/oref0/blob/master/lib/iob/calculate.js
This gives a much smoother curve at the end of the action duration.

Especially visible in the derivatives of the functions
