Auto-tag recursively for external file storage?

I’ve just loaded hundreds of thousands of file via external storage (local to the NAS on the LAN). Its a mix of docs, general files and photos dating back to 2006.

They are already sorted well, like the folder “photos” has “2023, 2022,2021” and so on and under that there’s things like “cats”, “new years eve” and so on…

what I want to do is, anytime a new photo(and file for non photos) goes into a folder, I want it to take all the tags that the parent folder has, recursively.

so img_23423492.jpg if in photos > 2008 > cats > spot
it should be auto-tagged with “2008,cats,spot”

any new photos or files put in there would also get those tags.

I have autotagger installed but I dont see any folder options or recursive options. I looked into using tagspace for this but it seems tagspace renames the file itself to include the tags or creates a sidecar file. I’m assuming the former is not good practice for long filenames and the latter wouldnt be supported by nextcloud since the tags are in a database.

any ideas? thx.