Hi Hyeuk,
I see what you are trying to do. The idea of letting people to use the engine as a library has been a design goal for the engine from day one. However, one thing is theory, another is practice.
In practice until now the engine has been so complex and evolving so fast that it has been effectively impossible to use it as a library. The users would have to change their scripts at every
release to cope with the evolution. The situation with hazardlib and the Hazard Modeller Toolkit is much better, since they are mostly stable, but for what concerns the risk part things are still changing
instance the classical calculator is now mostly stable and I anticipate that the risk calculators (except the event based ones) will become mostly stable in a few months. Then it will become
possible for us to write tutorials on how to use the engine as a library, and I could tell you how to fix your script. Now I cannot because we are still in a fluid phase.
Having said that, we very much appreciate your efforts, since you are effectively acting as a beta tester for the fine points of the engine. Thanks!
Please keep up the good work,
Michele