SP Addin or SP framework?

Copper Contributor
I'm trying to understand the difference between the SP add-ins and SP Framework. I need to refactor a Django app on SP online. The web app does the following:

Takes input from the user into a form (mostly y/n) questions
based on the responses generates a pdf document which is returned to the user plus a .docx document which is stored on SP (the end user has no access to the .docx)
Potentially sends an email to notify other stakeholders
Now, if I have to implement it on SP, I understand that the full logic will be in the client, while at the moment for example part of the logic runs in Python.

The form itself should not be an issue. I was wondering how to generate the pdf and the docx. Is that possible using SP workflows? Or should I use Power Automate? I mean, how to properly populate a HTML/word template and then convert it to Pdf if we have no access to server side code? Thanks
2 Replies
Certainly not an expert around this, but found a link and thought of sharing, using flow:

My two cents here:
(1) Go for SPFx for the FrontEnd
(2) Go for Power Automate Flows or Azure Functions / Azure APIs for the Business Logic you may need in your Apps