AF-1 / lms-dynamicplaylists

Dynamic Playlists - a plugin for Lyrion Music Server that lets you use smart playlists (dynamic playlists) to play continuous music mixes based on your selection criteria.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Dynamic Playlists

This plugin1 lets you play continuous music mixes based on selection criteria defined in so-called dynamic playlists (smart playlists).
Dynamic Playlists will keep adding small batches of tracks in random order to your current playlist (complete albums can be added in album order). It comes with a collection of built-in, ready-to-use dynamic playlists to get you started. Since the built-in dynamic playlists cannot cover all possible use cases, you'll probably want to create a dynamic playlist that's tailored to your very specific needs at some point using Dynamic Playlist Creator or a file with SQLite statements (see FAQ).
Some features are not enabled by default.

⬅️ Back to the list of all plugins




Screenshots - Context Menus2

While the Dynamic Playlists menu in the LMS home menu is easy to find, its context menus can easily be overlooked. You'll find the Dynamic Playlists menus in the context menus for artists, albums, genres, years (for years and decades) and static playlists. Some of them are presented below.

Players with Jivlite UI (Touch, piCorePlayer, SqueezePlay, Radio)

Players with Jivlite UI (Touch, piCorePlayer, SqueezePlay, Radio)



LMS Web UI - Default Skin

LMS Web UI - Default Skin



Material Web UI

Material Web UI



Features

  • Use your own custom dynamic playlist files/definitions directly in DPL without intermediary plugins - you don't have to install other plugins to get dynamic playlists. See FAQ.

  • Comes with more than 200 ready-to-use dynamic playlists (stand-alone + for context menus).

  • Multiple selection of genres, decades, years and static playlists.

  • Preselect multiple artists or albums from their context menu at your leisure. DPL remembers your preselection (until the next rescan/server restart) so that you can easily use it later with dynamic playlists that use preselection.

  • Use dynamic playlists to create static/normal playlists.

  • Queue dynamic playlists (see FAQ).

  • Create a Don't Stop the Music seed list and auto-start your DSTM mix.

  • Supports LMS virtual libraries.

  • Save dynamic playlists with (user input) parameters to LMS favourites (see FAQ).

  • New playlist parameters (see wiki).

  • Compatible with Dynamic Playlist Creator, Alternative Play Count and Custom Skip.

  • If you have installed the Alternative Play Count plugin, you will see some additional dynamic playlists that use the data from this plugin.




Requirements

  • LMS version >= 8.0
  • LMS database = SQLite


Installation

Dynamic Playlists is available from the LMS plugin library: LMS > Settings > Manage Plugins.

If you want to test a new patch that hasn't made it into a release version yet, you'll have to install the plugin manually.



Reporting a new issue

If you want to report a new issue, please read the FAQ first and then fill out this issue report template.

If you use this plugin and like it, perhaps you could give it a ⭐ so that other users can discover it (in their News Feed). Thank you.



FAQ

»How do I create / add my own custom dynamic playlist?«

  • If you prefer a GUI and want an easy way to create a custom dynamic playlist without having to deal with raw SQLite, take a look at the Dynamic Playlist Creator plugin that uses templates to create dynamic playlists and makes them available to DPL.

  • If you are familiar with database queries and SQLite, you can create a fully customized dynamic playlist in a plain text editor of your choice and use it directly in DPL.
    Dynamic playlist definitions are basically plain text files with an "sql" file extension that contain your playlist definition:

    • a couple of parameters (general parameters like the playlist name, group or category and user input parameters) and
    • the SQLite statement itself to fetch tracks from the LMS database.

    Whether you use a built-in dynamic playlist as a template or start from scratch, this will give you a great deal of freedom in creating dynamic playlists tailored to your specific needs.
    In any case please read the wiki for more information on the dynamic playlist format and the few playlist parameters that you should definitely include.
    Put your custom dynamic playlist file (with the sql file extension) in DPL's folder for custom dynamic playlists called DPL-custom-lists (in your LMS preferences folder unless you've changed its location in the settings).
    The new dynamic playlist should now be listed in DPL, either in the Not classified group or in other groups according to what the -- PlaylistGroups parameter in your playlist definition says.


»Can I save the results of a dynamic playlist as a static playlist?«

DPL allows you to save the result set of any dynamic playlist as a static playlist. There's a control icon in the Dynamic Playlists menu (web skins: default, dark default, classic) next to the names of dynamic playlists that looks a bit like an old floppy disk. In Material and jivelite GUI controllers, you get a new option “Save as static playlist“ in addition to Play and Add. You only need to set the maximum number of tracks (max. 4000) and name your static playlist. Dynamic playlists with user-input parameters will request that input first and show you the static playlist options (max. track no., playlist name, track sort order) at the end.
Depending on the complexity of your dynamic playlist and the max. track limit you set for your static playlist, saving it might take a while.


»What's preselection? How does it work?«
    »There's more than one DPL context menu item.«

DPL has playlist parameters that allow you to select multiple genres, decades, years and static playlists. But even the smallest music libraries have a large number of artists and albums that would result in poorly browsable, far too long selection lists.
The solution is to gather/select artists or albums first using the preselection context menu item and then start a dynamic playlist for preselected artists/albums.
So for artists and albums DPL will show a second context menu that allows you to preselect this artist/album while browsing your music library. DPL will remember your (pre)selection until the next LMS restart/rescan. You can't save your preselection permanently, it's a short-term thing. For anything more permanent, please create a custom dynamic playlist with Dynamic Playlist Creator.
Once you've finished preselecting artists/albums, go to DPL's home menu and use this selection with any dynamic playlist that makes use of the PlaylistPreselectedArtists or PlaylistPreselectedAlbums playlist parameter. There are some built-in dynamic playlists to get you started (in the Songs group). And it's very easy to add these playlist parameters to your custom dynamic playlists. Read this wiki section for more information.


»With which plugins does DPL work?«

DPL is compatible with Dynamic Playlist Creator, Alternative Play Count and Custom Skip.

If you're familiar with SQLite and know how to create custom dynamic playlists, you can use data from any LMS database table.


»How do I queue dynamic playlists?«
    »I've queued dynamic playlists and they disappeared.«

You can queue up to 5 dynamic playlists. When all tracks matching the search criteria for the active dynamic playlist have been added to your client playlist and you have queued dynamic playlists, DPL will add a short silent track and (a placeholder for) the next queued dynamic playlist to your client playlist. The silent track should help with a smooth transition so the last track before the new dynamic playlist isn't cut short.

Please note: The list with queued dynamic playlists is cleared when you restart the server.


»How does DPL work with the Don't Stop the Music plugin?«
    »What does the icon with the infinity symbol do?«
    »What does “Create DSTM seed list and play“ mean?«

The Don't Stop the Music (DSTM) plugin “will automatically add similar music to what you've been listening to ... once you've reached the end of your playlist“. DSTM takes a look at the existing tracks in your client's playlist (the seed list) to determine what kind of tracks to search for.

As long as Dynamic Playlists is active, i.e. playing a dynamic playlist, DSTM will not interfere or add any tracks.

But now you can use Dynamic Playlists to create a DSTM seed list from any dynamic playlist and start a DSTM mix for you. There's a preference setting if you prefer to skip playback of all seed list tracks (but the last one).


»How do I know whether DPL is still active?«
    »What causes DPL to no longer be active?«

To find out whether Dynamic Playlists is still active just enter the DPL menu from the Home/My Music menu. If it's still active, it will display the active dynamic playlist at the top of the DPL menu.
Some actions/events that stop DPL (= no longer active): clearing your client playlist, DPL no longer finds tracks for the active dynamic playlist, you told DPL to stop adding tracks...


»What does the PlaylistUseCache option do? Which dynamic playlists can use the cache?«

For dynamic playlists that can retrieve all tracks matching your search parameters in one initial database query, DPL loads all tracks into the cache, thus eliminating the need for further database queries. Subsequent batches of new tracks for the active dynamic playlist will be retrieved from the cache only, and added to a client's playlist much faster as a result.
Dynamic playlists that retrieve each batch of new tracks from a different, randomly chosen artist, album, genre, year, decade or static playlist are not suitable for cache use because not all tracks can be retrieved in one initial database query.


»I've added a dynamic playlist to my LMS favorites, but it no longer works.«
    »There are some dynamic playlists that I can't add to LMS favorites.«
    »DPL shows a favorite icon with a p (default skin) or an orange tint (classic skin) next to my dynamic playlists. Why?«

Prior to Dynamic Playlists 3, you could only save one-click dynamic playlists as favorites that don't ask for user input when you start them.

Now you can also add dynamic playlists with user input parameters.
By default, Dynamic Playlists will not let you save dynamic playlists as LMS favorites that ask users for volatile input at run-time (artist, album, genre(s) or playlist(s)) because those values could change after a rescan and break such favorites.
If you still want to add dynamic playlists with volatile parameter values (artist, album, genre(s) or playlist(s)) to LMS favorites, you can enable this in the plugin settings. However, keep in mind that such favorites may no longer work after a rescan and you'd have to delete and readd them. Therefore I suggest you choose a descriptive name so you'll remember what parameter values you chose (like "Alternative 80s rated").

If you always select the same artists, albums, genres or playlists, it's probably better to create a custom dynamic playlist with the actual artist/album/genre/playlist names. A favorite for such a one-click dynamic playlist is not affected by rescans.

This feature is limited to the LMS web UI ((Dark) Default and Classic skin), players with jivelite UI (Touch, Radio, SqueezePlay, piCorePlayer) and Material skin.

Please note: Changing the filename of a custom dynamic playlist alters its dynamic playlist id and thus invalidates any existing favorite for this dynamic playlist. The same applies to built-in dynamic playlists: If a plugin update changes the filename of a built-in dynamic playlist, you'll have to delete and readd favorites based on that dynamic playlist. Doesn't happen very often and always for good reasons.

The favorite icon with the p (default skin) or an orange tint (classic skin) just indicates that this dynamic playlist contains parameters that will ask for user input when you start it.


»The Not classified group in the DPL (home) menu has disappeared / doesn't show.«

The Not classified group in the DPL (home) menu and on settings pages will only be displayed if DPL found dynamic playlists without a playlist group name, i.e. if it's not empty.


»This built-in dynamic playlist is missing a feature that I really want.«

The collection of built-in dynamic playlists includes only a large but limited set of frequently used playlists that won't see regular additions or updates.
If you want to create custom dynamic playlists without bothering with SQLite statements, please try the Dynamic Playlist Creator plugin.
If you're familiar with SQLite, you can use the built-in dynamic playlists as a starting point for creating your own custom dynamic playlists.


»I don't want my dynamic playlist in the Not classified group. I want a custom group (name).«

The Not classified group is a catch-all group for all dynamic playlist that are not assigned to any playlist group. You can create your own custom playlist groups by entering a playlist group name in Dynamic Playlist Creator or by setting the -- PlaylistGroups: parameter in the file with your customized SQLite statement (see wiki).


»Does DPL handle online tracks?«

Dynamic Playlists will process online tracks that have been added to your LMS library as part of an album. LMS does not import single online tracks or tracks of online playlists as library tracks and therefore they won't be processed by Dynamic Playlists.


»Some dynamic playlists in the DPL menu are not listed in alphabetical order.«

In general, dynamic playlists in the DPL menu will always be listed in this order: 1. built-in, 2. custom/user-provided, 3. provided by other plugins. Dynamic playlists in the last two groups should be listed in alphabetical order.
Built-in dynamic playlists are listed in a 'content-based' order created by me. For example, I try to group dynamic playlists together that are about ratings, play count or genre/decade selection. If you don't like how I ordered the built-in dynamic playlists, don't forget that you can clone these playlists and even put them in a custom playlist group just by adding the corresponding parameter (see wiki).
Static (saved) playlists will always be ordered alphabetically.


»Can I use CLI commands to control DPL?«

Explained in the wiki.


»The Home > Dynamic Playlists menu doesn't show dynamic playlists for context menus. Why?«

By default the Home > Dynamic Playlists menu will only show dynamic playlists that don't include the -- PlaylistMenuListType:contextmenu parameter. Here you won't find any dynamic playlists that can be called from an item's context menu.
And context menus (= More menu in the web UI or click/touch-hold on jivelite players) will only show dynamic playlists for context menus. So there may be some overlap but this separation greatly helps reduce clutter.


»I want my dynamic playlist to use one of Custom Skip's filter sets.«

Use Dynamic Playlist Creator to create a custom dynamic playlist with a specific Custom Skip filter set that's enabled/disabled when your dynamic playlists starts/stops.
If you have created a custom dynamic playlist from scratch (raw SQLite), just add the necessary action/CLI playlist parameters to your file as described here.
If you only need one filter set for all dynamic playlists, create a Custom Skip filter set that will only be active if DPL plays a dynamic playlist. See Custom Skip Wiki.




Footnotes

  1. If you want localized strings in your language, please read this. Based on Erland's DynamicPlayList plugin.

  2. The screenshots might not correspond to the UI of the latest release in every detail.

About

Dynamic Playlists - a plugin for Lyrion Music Server that lets you use smart playlists (dynamic playlists) to play continuous music mixes based on your selection criteria.

License:GNU General Public License v3.0


Languages

Language:Perl 85.1%Language:HTML 14.4%Language:CSS 0.5%