Don't get me wrong, there are a lot more iterations of tool + prompt + agent flow updates we can and will do to make things even better, and the models will keep getting better themselves, but the task is non-trivial. If you download the raw HTML of a webpage, it's a messy jungle, and frankly impressive that the models are capable of doing anything useful with it
In order for us to be able to execute your scripts that do powerful things (send notifications, save to local storage, download things, etc.), our extension needs to have those permissions itself. Google doesn't have any way for us to say our extension itself only requires permissions x, y, z but give this user script permissions j, k, l.
Your browsing/page data is yours. That data is only accessed when you explicitly request to generate a script (i.e. can't generate a script to modify a page without seeing that page).