What you are describing is a smart Collection based upon keywords. The concept of "virtual tag" or "virtual keyword" does not exist in Lightroom. So a Smart Collection is the only way to achieve what you want in Lightroom Classic.
And "keyword" is the correct terminology to use inside the Lightroom environment. Keyword is an ITPC Field. A tag in EXIF terminology is an identifier for various metadata Fields including The ITPC Keyword. When talking about image files, we use the term Keyword to avoid confusion.
Ok, keywords then. Most applications call them tags. Whatever floats your boat
Collections have the great disadvantage of being unable to "apply" it to a folder, like you can by filtering on a keyword. On top of that, yes, I know you can extend the conditions in a smart collection with "Folder" but I've never found out what exactly I am expected to put there. Nothing useful seems to be working, afaict.
My suggestion would be to turn this around and instead of defining a solution with ‘virtual tags’ focus on how you can find “flower AND plant BUT NOT garden". The reason being is that you will develop far to many tags as you want to classify effectively searches.
To that end I’d suggest looking at John plug in that uses Google AI to keyword pictures. He also has plugs to help in searches.
https://johnrellis.com/lightroom/an...30.1999216272.1661950698-969619740.1661950698
Your desire to find something is based on a tool being able to parse and recognize objects in a photo. These are getting better but still have a ways to go IMHo
You're assuming I have added these keywords in the first place
I feel you're suggesting I should design my keywords to aid the tool, but I'd rather have the other way round. The tool should assist me instead.
If you put "Flower" under "Plant" in the Keyword (hierarchy list, but have "Garden" at the same level as "plant" then Plant will automatically be considered as an associated keyword for any image that has the Flower keyword. However, the Garden keyword will be independent of the other two and can be associated witht he same image or not as you choose.
If you export an image that has the Flower keyword, depending on your settings in the Flower and the Plant keywords you can choose wether or not Plant will in included in the exported keywords (tags). Again, Garden would be independent and would export if it was also assigned to the image.
The problem with nested keywords is that Lightroom treats them very unpredictably in searches. In filtering it's nearly alright, except that you can't make a "NOT keyword" filter. So only positive keywords are possible. In smart collections, filtering by keywords works completely weird. Something like Plant->Fower cannot be searched for. Instead you would have to search for "Flower", but there is no way to make it look for Flower specifically under Plant. Which will lead to unexpected behaviour when I also happen to have a Flower keyword under Sculptures that I *don't* want to search for. Even worse, it will happily also return results for Flowering and Cornflower even though that is absolutely not what I've typed in. Believe you me, I tried smart collections with *very* disappointing results - unless, like I said, I re-keyword my pictures for the sole purpose of getting Lightroom to do what I want.
---
Anyway, I digress. I guess the feature I'm looking for, is not possible without re-keywording a lot of pictures, and for new pictures in the future. Or by creating unstable results in smart collections where I can't switch from folder to folder.
I don't know if the Lightroom devs are reading along (if not, they probably should be!) because this keywording debacle has been bothering me not since when I created this topic, but for years now. Looking at the database structure of a catalog, it should be fairly easy to create functionality in Lightroom to build ubiqitous and predictable keyword filtering, applicable with the foundational operators AND, OR, NOT and XOR. That would help a bunch.