Thank you Beppe! All this is super useful.
At the moment, I settled on just S&P 500 stocks for classification.
Also, I modified the Python S&P 500 script above to write directly into the AmiBroker\Data\Watchlists\S&P 500.tls, so I can update S&P with one click.
The only small inconvenience is that now, as I used the AmiBroker Tools --> "Update US symbol list adn categories", my database is populated with ~6500 symbols. In order to update just the S&P 500, i.e 500 or so symbols, I cannot use Auto-Update from Tools, as I will have to wait probbaly a very, very long time. So, I have to go directly to AmiQuote and point it to the S&P 500.tls file for update. But, all in all, this is nothing and I think now I haev solved both of my issues in a very effcient way. Efficient means 2 clicks way