Hi Kathleen,
When Tools.Addrootcasusecomment is place in the OnPeriodEnd method, then it is called for each and every period for which the contract is effective. And depending on selected granularities this can have a big effect and this is why you are seeing over 1100 comments.
I would protect the Tools.Addrootcasusecomment with a boolean flag to prevent it being triggered multiple times
Best regards,
Peter