Glad to! I find puzzling out how to turn a visual structure into computer-readable instructions rather fun.
Unfortunately, the split between what you're calling "album artist" and "artist" isn't as big as you're hoping in our dataset: we'd probably consider "Bob Throat Lab Band" to be its own artist, and sort the album under that. It's not universal – if the "Lab Band" was still the single person who's just adopting the persona of a group, there's a chance we'd put the name in the artist credits, which would mean the structure you're hoping, but I wouldn't count on it. To give you that capability, though, I've included a check for a custom variable: if the album would normally be sorted under the Lab Band name or something else you don't want (check the
Album Artist Sort Order in the bottom pane, and if that's not there, the
Artist Sort Order, and
Artist fields, in that order, the latter of which are included for safety with incomplete tags), right click and add a new tag; in the dropdown at the top, ignore all the builtin names and type in
artistfolder; finally, in the list of values (there's an empty one at the top), write the folder you want to use, for example
Throat, Bob. You'll have to do that for every file in the album, but if you select the row with bold text and the CD icon before adding it, the new tag will automatically be shared across the entire thing. This is fully integrated in the Various Artists logic, so you can force an album to be treated as a compilation (or not) if you need to as well.
Likewise, the sortable name of the album isn't one of the variables the database stores – I've complained about that a couple times on here – but I've put in a function that will do a mostly-decent job of sticking the prefixes at the end. If it doesn't do something right, add a new tag like above, choose
albumsort (it is in the list this time), and enter the proper form. Unfortunately, by default you won't be able to see whether that's necessary until after you save something; I'd recommend adding the first following line to a script in the "Scripting" page of the options so it's more obvious. If you don't like the
Album Sort Order being included in every file, add the second as well which leaves only
Album if the sort order's not any different. If you do add the tagging script, I'd recommend replacing
$swapprefix(%album%) in the main file naming script with just
%album%, as leaving it in there causes hidden behaviour that might trip things up in the future.
Also, I made my best guess at the album identifiers, but I wouldn't be at all surprised if it's not exactly what you were wanting. If you can give a concrete example, I'll be happy to fix that part for you – or, indeed, any bit of this that you were imagining formatted differently. Finally, I didn't make adding the track artist be based on whether the album is a compilation or not, but rather on if it matches the artist for the rest of the album, so an artist who's only featured on a single track will show up in the filename; we put them in the artist field rather than the title, but if you'd rather the latter, there's a plugin ("Feat. Artists in Titles") for that.
$noop(Provide a means of manually specifying the folder with %artistfolder%)
$noop(%albumsort% provides better control, but isn't automatically set)
$noop(If %albumsort% is populated via a script, replace `$swapprefix(%album%)` with just %album%)
$noop(Guess at losslessness from the extension -- doesn't test MP4s)
$noop(Based on https://community.metabrainz.org/t/categorizing-lossless-music/258530/2)
$noop(Take the first single letter or character from each field)
$noop(Treat single-track albums as standalone recordings)
$noop(Note that this will not pull out single tracks that are said to be part of a larger album)
$noop(Neither will it recognize non-MusicBrainz albums as being proper albums /unless/ either %totaldiscs% and/or %totaltracks% has been set)
$noop(The track number is not checked for this purpose because I've come across single files on Soundcloud that have that field set for no reason)
$noop(Some of the ifs aren't necessary, but they're an easy way of adding spaces)
Disc $num(%discnumber%,2)$if(%discsubtitle%, %discsubtitle%)/
$if($ne(%_displayartist%,%artist%), - %artist%)
%artist% - %title%