The AppleTV device has two AppleTV apps... one is the actual AppleTV+ app which only allows you to watch Apple original content of that service (which is only accessible from within the AppleTV app), and the other is the AppleTV app, which is storefront-based app which allows you to see content across multiple services, even if you are not subscribed to them (this is found on the main page of your device... where system tools and the like reside). Because of this, it can potentially offer you a free view of a show from a subscription service in lieu of say a season pass purchase for example.
To ensure that you are indeed watching the content from the source that you wish to view it from, it is best to use said app associated with it. So for example, the Paramount+ app if you are subscribed to the service (TOS entire library exists on that service) or the TV Shows app if you own an iTunes purchased season of that show.
The AppleTV app is designed to sell you content to watch... it's a storefront. While it may allow you to watch what's next in your viewing habits... it's not necessarily "smart" enough to select the correct source for that content.
So when you say you were watching it from your library... that would mean you would not be selecting the AppleTV app at all in order to watch it. If you enter the AppleTV app, you are not selecting your library to watch it from.
Of course I do not own any iTunes purchased content, so I can't say whether Apple is allowing advertising on purchased content. I doubt that is the case. Free content on the other hand always comes with advertising for the service providing said content.