Refactored document generation to function again. However, the risk matrix on the front page is not completed.