LUSID generates holdings on demand for a portfolio by replaying the stored history of transactions in accordance with their transaction types.