Different scrolling strategies for a conversational chat application

I’m creating an app for performing Q/A on documents. I’m trying to show the document in one column and the chat in a second column.
I managed to stop the scrolling of the main container, but this generated a side-effect, when I ask a new question, the right column should scroll to the lowest item, while the left column should stay fixed.

The app is deployed here: https://lfoppiano-document-qa-develop.hf.space/
you can just open, upload a PDF and ask few questions, and you will see immediately.

The feature to show the PDF is in the following branch: GitHub - lfoppiano/document-qa at pdf-render

I’m using python 3.9 and streamlit 1.27.2