Boolean search logic? (AND between Tags)

It seems when I do a tag search that the results are presented as a Boolean OR – show me the list of tracks that have either This Tag or That Tag.

I don’t see an easy way to get results that show me a list of only the tracks that have both This Tag and That Tag.

Hopefully I’m just blind or dumb. Maybe blind AND dumb. :smiley:

Cheers,
Jeff

4 Likes

Hi Jeff,

Neither blind NOR dumb (at least not because of this anyway :wink:).

I understand that the logic for Tags is as stated and don’t know of any way for a user to change it. Similarly with Focus I understand the logic is AND between tools and OR within tools.

So if you can focus on Tag 1, but then use a different Focus tool based on Tag 2’s criteria, then you might achieve a Tag 1 AND (content of Tag 2) Focus which you could bookmark.

The above is by way of a workaround, rather than where I expect Tags and Focus to end up. The capacity to specify Boolean operators for a Focus would be a great feature request.

I’ll drop a flag for @mike to let us know if the above is correct, and if there are any plans in this regard. If there is nothing further for Support to do here then I’ll turn it into a Feature Request for further comment by other users.

Bump. Any new info?

@andybob, I thought there was a feature request for boolean operators AND, OR, NOT in Focus and Tags, but can’t find it.

Coukd you turn this thread in a feature request?

1 Like

Long experience has shown that few users can manage Boolean logic. Not that they don’t understand it, but that as they add more criteria in logic expressions they rarely converge on the target, typically get further afield.

Which is why modern tools use sophisticated relevance algorithms instead. Outside of programming languages.

From the KB:

Tags are a great way to organize your collection, giving you quick access to just the right music. You can tag almost anything in Roon, and it’s easy to get started.

Roon’s Tags feature was designed to be fast, easy, and endlessly flexible. For example, you can use Tags to:

  • Organize music for a party (by tagging artists or genres)
  • Keep track of music from a certain source (ie, HD Tracks, or Bandcamp)
  • Remember context (ie, Recommended By Brian, or Music From Summer 2000)
  • Keep track of edits (ie, Artists That Need Better Photos)

So Roon propagates use of tags, which is fine, but give me in return the options to filter properly.
I use tags to categorise my collection a lot to find the music I want to hear.
Please tell me how to find songs which are tagged i.e. “female voices” AND “acoustic”.

Maybe users do understand Boolean logic, but don’t know how to use it.

1 Like

Ah, I had not seen this thread before. I’ve made comments in other threads about use of Tags. I agree, there needs to be some method of applying logic to tags to find the intersection of 2 (or more) tags rather than the sum of 2 (or more) tags. It really limits the value of Tags to a fairly simply query.

There may be a workaround - I have not thought through the logic. If you have a Tag called “Punk” and you have a Tag for “70s Music” and you want to hear Punk from the 70s, could you first bring up all the objects Tagged 70s Music, then hit the minus button, and Tag all of those songs “Not 70s Songs.” Then to find all 70s Punk, you bring up the objects under the Punk Tag, then click on “Not 70s Songs” and then click the minus on that?

Would that bring up all Punk that is not-not 70’s Punk with the double negative cancelling itself out?

The way I would do it is to use either Focus/Genre/Punk (or a custom Punk tag) combined with the Focus/Date tool. The logic between different Focus tools is AND.

That would address the specific use case where one of the criteria is a date. I was trying to illustrate a possible way to use Boolean AND logic between two tags.

But it is good to know that Focus is AND.

The logic within one category is OR, between categories it’s AND.
So in general what you are asking for is not possible.
It may be possible to do trickery.
For example, I don’t know because I never use Genres, find them useless, but is it possible to edit these and define new genres? If so, you could find all the albums tagged acoustic, edit them all to be of a genre “acoustic”, and then filter with the female tag.

But as I said, this is rare. In the original Sooloos marketing material, 10+ years ago, the example was Play all Miles Davis albums except the 70s funk — pretty cute but in all the years I have never done that.
And people make mistakes. The classical example in computer science is play all artists from Italy and France. None found. Should be OR.

So I’m not very agitated about this gap. The team made a choice many years ago, and I have never stubbed my toe against it.

Everyone has his own way to configure and use their music library, and I am aware it’s difficult for Roon to deliver a complete framework where everybody can define all own wishes.

Your suggestion works probably if an entire album is acoustic, which is not always true.
As far as I know it’s not possible to create genres at song level.

The way Focus now works “AND” & Tags OR is confusing.

In the meantime I’ll be waiting patiently for crazy ways Danny suggests :

1 Like

In the composition screen there are several filter categories of interest for Classical:

There are problems. The Period, Form and Instrumentation columns are not editable, nor is there a mapping from my tags so that I can fix them. They appear to be entirely populated from 3rd party metadata sources but are frequently empty:

This has been commented on in other threads that there is a lot of interest in the composition screen if obvious gaps in the logic were fixed. A further observation is that there is also no obvious way of doing much search on “Instrumentation” at all, let alone Boolean. For example. If I click focus I get pick list menus for Period, Composer and Form but not Instrumentation:

So for example if I want to do a search on Period=Modern AND Instrumentation=Vocal. I cannot do it because I cannot see any obvious way, even with a work around, of searching on Period=Modern AND Instrumentation=(Choir OR Opera OR Vocal Ensemble)

BTW. I sympathize with @AndersVinberg comment that Boolean logic often doesn’t work for a lot of users. But properly implemented I think this sort of pick list approach hides that you are actually doing a Boolean search and makes sense even to a very un-technical person such as me.

1 Like

1+ for Boolean AND to be implemented for tags.

1 Like

Glad I saw this topic.

Just my ignorance, but I can’t understand how to filter on a tag that might be in either the generated tags or my added tags. The drop down menu for tags let’s one check for “My tags” or “Shared tags”. I thought that shared tags would be what I wanted, but that doesn’t seem to be the case.

Thanks for any input.

Can you provide more detail as to what you want to do? If you are in the main track view, artist view, or album view, you can select a single Roon Tag and that will reduce the view to only objects within that tag – and it also does a good job by showing objects if a parent object has that tag - i.e. if you are at album view, it will also show albums where the artists on that album have that tag.

But as of now you cannot directly use one tag to filter another - i.e. as per the thread above, the Boolean logic is hard coded as OR.

Here’s what I am trying to do.

For example - I want to find all selections that have a tag of “Symphony” including all “Symphony” blue tags and all “Symphony” green tags. I can’t seem to get that to work. If I check the box “My Tags” in the tag drop down, then I get all the green tags that are “Symphony”, but none of the blue tags. It seems like checking the “Shared Tags” in the drop down menu should give me both green and blue tags that are “Symphony”, but that isn’t what happens.

All: there is a workaround to implement a bit of boolean logic here, but it’s not super fast with a large database. You can use the “NOT” function as a substitute for AND. Here’s how:

Say you want to have two “sets” of tags: you want to tag bands geographically, like “Chicago bands” “Seattle bands,” and “Manchester bands.” Then you want to have another set of tags for era, like “80s bands,” “90s bands,” or “70s” bands. (Bear with me, this is just an example, please don’t chime in and tell me Roon can already Focus on albums by date; I know that – this is just about an example use case that makes sense.

OK, so say you want to find all Chicago 80s Bands. Right now, if you go to the album, artist, or track browser, and Focus on Tags, then select Chicago Bands and 80s Bands as separate tags, you are going to get ALL Chicago Bands and ALL 80s Bands, not Chicago bands from the 80s. In other words Styx will show up because they are a Chicago band even though they are from the 70s, and Duran Duran will show up because they are an 80s band, and you won’t get just the cross section of Chicago bands from the 80s.

OK, so do this:

—Go to Artist view. Tag your Chicago Bands. Then Focus on Tag Chicago Bands. Click the minus sign so that you see all bands EXCEPT Chicago Bands. Select All. Tag all these artists with a new tag called “Not Chicago Bands” (you’ll come up with a better name once you see my logic). (This takes quite a long time - you are now applying a tag to almost all the artists in your collection, save the few Chicago bands in there).

—Reset view.

–Now with rest Artist view, seeing all artists, Tag your 80s Bands. Focus on Tag 80s Bands. Click the minus sign so that you see all bands EXCEPT 80s Bands. Tag all these artists as “Not 80s Bands”

Now that you have these tags, reset your view again so that all artists show. Focus on Tag Chicago Bands. Now, add the focus on Tag “Not 80s Bands.” Click the minus on the “Not 80s Bands.” The minus is “AND NOT” in effect, in boolean logic, I think. So now, viola, you have All Chicago Bands that are NOT NOT 80s Bands, i.e. All Chicago Bands that are 80s Bands! You have AND in your logic, by using NOT NOT AND.

It’s a workaround. Even with a modern quad core and a ton of RAM and a dual SSD Roon core, it’s not that fast. BUT IT SEEMS TO WORK, DOESN"T IT?

This shows my ignorance…what’s a “Blue tag?”

Thank you for your patience, but I feel we are failing to communicate.

My problem is not about multiple sets of tags. My problem is that one can’t use the information in the blue tags and green tags concurrently.

Maybe I am misunderstanding tags. Let me start with the most basic. In a selection that has a blue tag of “Symphony”, here I am assuming that the blue tags are the result of info that was embedded at the time of the rip, if I click on the blue “Symphony” tag that I get a screen that has all the albums that have a blue tag of “Symphony”. Great.

The problem is that not all symphonies are properly tagged as such in the embedded tags. In that case, I have made my own tag, a green tag, for “Symphony”. If while looking at a selection I click on the green “Symphony” tag, then I get all the green tags that are “Symphony”. Great.

This can also be done from the tag drop down menu, and in the case, one doesn’t have to find a selection that has the tag one wants. One merely has to check the tag in the list. Great.

What I can’t figure out is how to get, on the same screen, all the "Symphony"s that occur in both the green and blue tags.

If seems like you are telling me how to work with multiple conditional tags in the green tags, but I don’t think that addresses my use case.

Obviously, I just used “Symphony” as an example.

A blue tag is a tag with a blue color in the album display. A green tag has a green color. :laughing: