Smartlist conditional logic (AND /OR), which includes MATCHING KEY and ADJACENT KEY

MrCee
MrCee Member Posts: 60 Advisor
edited January 2023 in Share Ideas for Traktor Pro

Smartlist conditional logic (AND /OR), which includes MATCHING KEY and ADJACENT KEY, needs to be included in Smartlist filtering. A few out there disagree with the logic regarding HIGHLIGHTING adjacent keys. I believe Native-Instruments has nailed it perfectly, and depending on your mixing style, if this development request is approved, you can exclude the keys you don't want matching.

As a long-time Traktor Pro user since the beginning, I'm currently on 3.7.1 337

I want to reach out to everyone who can key mix regardless of mixing in a semitone up or down at the time. You can be creative with it later. Right now, we need the functionality and, essentially, the upvotes!

The goal here is to achieve a Smartlist that can ultimately find the best match for the track that is playing in its current key, and the highlighted results should match the key that is currently playing. I have created a playlist for every key and adjacent key so far.

I wouldn't expect a Smartlist to completely re-design itself should the current key be moved up or down a semitone for the currently playing track. Here is what I propose…

If I created a Smartlist for the key 8d because the current track is playing in 8d, we can already make a Smartlist using KEY "IS MATCHING" 8d. Great.

On the other hand, I would like to see the same function for ADJACENT. i.e. using key "IS ADJACENT TO" 8d


It is possible to include every adjacent key to fit in GUI logic. But without the AND/OR conditions within the GUI, you cannot have multiple folder paths or genres and re-creating the exact Native-Instruments adjacent key list uses 9/10 fields in the GUI.

I've tried manually editing the collection.nml file with some success (adding an extra folder to be searched for a key that IS MATCHING can work if you understand query logic). The Adjacent keys need to be accessible in a Smartlist filter, and conditional logic (AND/OR) needs to help separate the query.

I see that the collection.nml file can find matching keys using the tilde ~ 

<SEARCH_EXPRESSION VERSION="1" QUERY="$KEY ~ 8d"></SEARCH_EXPRESSION>

You can also add to the query some further limited filtering, which is something easily obtained in the GUI…

<SEARCH_EXPRESSION VERSION="1" QUERY="$KEY ~ 8d &amp; $RELEASE % &quot;DJRC&quot;"></SEARCH_EXPRESSION>

What we cannot do directly in the GUI is add further criteria to the query. Programmatically it will work if edited carefully in the collection.nml…

When adding multiple sources to match, this is the INCORRECT query the GUI produces:

<SEARCH_EXPRESSION VERSION=" 1" QUERY="$RELEASE % &quot;DJRC&quot; | $FILEPATH % &quot;DJ CHARTS&quot; | $KEY ~ 8m"></SEARCH_EXPRESSION> RESULT: because of the constant OR CONDITIONS we do not get anything intelligible.

What we need to see at the most basic level can work when editing the collection.nml manually, so it should be built into GUI:

<SEARCH_EXPRESSION VERSION="1" QUERY="$RELEASE % &quot;DJRC&quot; | $FILEPATH % &quot;DJ CHARTS&quot; &amp; $KEY ~ 8d"></SEARCH_EXPRESSION>


The programmatically edited query works!

I have added 'OR' to include conditional logic, which includes text from a FILEPATH. I found that the order of execution for these queries is essential. Using OR | OR first, then AND tilde ~ last, for the matching key will work.


If the tilde ~ can match all keys similarly, please let me know what is the expression in a query to match Adjacent keys is? And how do we further group the query expressions using AND/OR?


Let's add this development request so that CONDITIONAL LOGIC for Smartlist filters works where "IS MATCHING ADJACENT KEY" is also available in the same fashion that "IS MATCHING KEY" within the GUI and we most certainly we need the addition of AND/OR functions.

Tagged:
68
68 votes

In Consideration · Last Updated

This idea has been reviewed by the TRAKTOR team. We will consider adding it to our roadmap.

«1

Comments

  • Demus
    Demus Member Posts: 152 Pro

    Kind of like the dynamic playlist from Traktor DJ 2 that is generate based on the Traktor Track playing in the master/Focus deck. That was my favorite feature from Traktor DJ 2. I would love to see this feature implemented into Traktor Pro 3/4

  • lord-carlos
    lord-carlos Member Posts: 2,331 Expert

    I also messed a bit around with the collection file to get better smart playlist.

    Would be cool if NI would allow to have more advanced filters :(

  • Oxy
    Oxy Member Posts: 88 Helper

    Would like a feature that highlights all compatible keys. +1, +2, +3, +5, +7 etc.

  • MrCee
    MrCee Member Posts: 60 Advisor

    See that was a different time and I've forgotten how that worked. It's been a while.

    Can I ask if the resulting key shifted a semitone down would re-generate the dynamic list to include all matches? And would that include every matching key depending on the resulting key of the current track including adjacent? It would be good to know. My old hardware does not run on MacOS but it would be interesting to know if you could add more.

  • MrCee
    MrCee Member Posts: 60 Advisor
    edited January 2023

    I'd like to know what you mean, are you working with energy levels? Maybe you could re-write this in open-key with major/minor (Dur/Moll) and solid example included that is relatable? It would help this be reviewed if you can. It just seems so far away from the O/P. Thanks.

  • shav
    shav Member Posts: 7 Member

    It would be great to be able to do more advanced search logic on the library. I put alot of tags into the comment field of my MP3s to organise my collection. For example, genre, subgenre, era, energy, etc... I'd like to be able to search using AND and OR criteria. For example "#house AND (#80s OR #90s)" to get all House music in collection from the 80s and 90s. This is a simple example but should explain the idea. Currently the search criteria seems to be based on AND logic only so searching for "#house #80s #90s" will return nothing

  • Kaiwan_NI
    Kaiwan_NI Administrator Posts: 2,562 admin

    @shav Merging your idea to a similar one we have here!

  • Oxy
    Oxy Member Posts: 88 Helper

    Traktor only highlights 'compatible keys' with 1up or down. But there are way more compatible keys.

    https://www.djtoptips.com/mixing-in-key-harmonic-mixing-dj-guide/

  • djk-tel
    djk-tel Member Posts: 2 Member

    Looks like there are using XSLT, XPath, XQuery styles.

    typically to group your Filters you surround them with brackets, those will be processed first

    ($VAR1 = ‘1’ | $VAR2 = ‘2’) & ($VAR3 = ‘3’ | $VAR3 = ‘5’)

    ($VAR1 = ‘1’ & $VAR2 = ‘2’) | ($VAR3 = ‘3’ & $VAR4 = ‘5’)

    According to this:


    and queries take precedence.

    Bool1 and Bool2 or Bool3 and Bool4 is the same as

    (Bool1 and Bool2) or (Bool3 and Bool4)

  • MrCee
    MrCee Member Posts: 60 Advisor

    It's a good point to mention and I understand that everyone will have a different formula when mixing the next key.

    If we bring this back to the basic idea of 'compatible keys' (1 semitone up or down) and if this logic is already nicely highlighted with a dedicated smart filter function for "Is Matching" then why don't we have "Is Matching Adjacent" filter also?

    Highlighting these 'compatible keys' is already being calculated in the backend as matching or adjacent are being highlighted. We need to bring this logic in to the query builder with AND / OR.

    If the (AND / OR) conditional was available in the query builder and "Is Matching" and "Is Adjacent" was also available as a basic query foundation, then you would have so many other fields in the query builder to work with for your precision style of key mixing.

  • MrCee
    MrCee Member Posts: 60 Advisor

    It's a good point to mention and I understand that everyone will have a different formula when mixing the next key.

    If we bring this back to the basic idea of 'compatible keys' (1 semitone up or down) and if this logic is already nicely highlighted with a dedicated smart filter function for "Is Matching" then why don't we have "Is Matching Adjacent" filter also?

    Highlighting these 'compatible keys' is already being calculated in the backend as matching or adjacent are being highlighted. We need to bring this logic in to the query builder with AND / OR.

    If the (AND / OR) conditional was available in the query builder and "Is Matching" and "Is Adjacent" was also available as a basic query foundation, then you would have so many other fields in the query builder to work with for your precision style of key mixing.

  • MrCee
    MrCee Member Posts: 60 Advisor

    The app won't recognise this and you will corrupt the collection.nml

    I don't recommend it, but if you would like to test this first before posting that would be great.

  • lord-carlos
    lord-carlos Member Posts: 2,331 Expert

    I messed around with it last year:

    Sady could not get brackets to work.

    I could have a bunch of ANDs and a single OR

    But would be cool if someone would take a second look and messed around some more.

    @MrCee Of course always make a backup of your collection. But mine never corrupted. Sometimes I broke the smart playlist, but nothing else happened.

  • M-L>N
    M-L>N Member Posts: 2 Member

    i like the concept, anything that will bring forward suitable adjacent tracks, but also it would be good to recognise not just adjacent, but also tracks that sound the same but not necessarily in the adjacent keys. Not sure how clever the programming can be in terms of recognising sound, like shazam, but some tracks have similar characteristics that could be well outside the adjacent keys, but will mix in perfectly without being out of key.

  • shav
    shav Member Posts: 7 Member

    Just upvoted on this. Definitely would appreciate the ability to have more advanced Boolean search criteria on the library. Not just on the keys but all fields of MP3 files. I somehow managed (I'm not a coder but know some basics) to hack together a desktop app to put multiple tag identifiers into the Comments field of my MP3s. Would be amazing to have the ability to perform advanced search across these tags for my files in the library.


Back To Top