That's great to know about the rhino docs integration. I know Patrick pretty well.
In this case I built it myself.
The client provided a template CSV file and I built Autoindex routines to populate a dedicated file cabinet where I write the rows for the base invoice and the gl coding detail rows from the table field.
Then i use the sorting order for the result list to arrange and group the rows so that the CSV file that you get when you export the result list conforms to the provided sample.