Great observations and references @jpfr.
Learning for the AI does not have to be from real world experiences only. Simulated/controlled emergency situations would help as well! Further even if the 2K lines of code stretches a bit more to deal with unknown situations that isn't so bad either