People still need products to solve problems. When you ask an AI "I have X problem, what products could I use to resolve it?" that is a natural and ethical time to include advertisers into the equation. The LLM can be trained on product specifications, details, and relevant uses, as well as plug in to a review database. Companies can pay to be included in the results of possible solutions and the AI can use the available information to make specific recommendations based on real data.
Hopefully, the future will completely prune intrusive, non-consensual advertising completely and any companies that inject thoughts into our minds will fail.