Metadata: Support for hierarchical tags #1238

Open
opened 2026-02-20 00:08:55 -05:00 by deekerman · 6 comments
Owner

Originally created by @wonx on GitHub (Nov 29, 2021).

Describe the solution you'd like

I have an existing picture library which I have classified using tags / keywords. Since there are several thousands of them, I have organized in the form of a tree, using hierarchical tags. For instance, I have classified the place where a picture is taken using the following hierarchy:

  • Place/Country/Province/County/Municipality

I think it would be very useful if photoprism could support these hierarchical tags as well.

In my case, I have used Digikam for such task, but hierarchical tags are also supported in picture managers such as Lightroom or ACDSee. I'd would personally use Digikam because the way it writes metadata makes it compatible with most other picture managers.

Additional context

This feature request was an idea that came out from this other request: https://github.com/photoprism/photoprism/issues/747
There are some examples of hierarchical tags on that thread, but I'll be happy to provide more examples if needed.

Originally created by @wonx on GitHub (Nov 29, 2021). **Describe the solution you'd like** I have an existing picture library which I have classified using tags / keywords. Since there are several thousands of them, I have organized in the form of a tree, using hierarchical tags. For instance, I have classified the place where a picture is taken using the following hierarchy: - Place/Country/Province/County/Municipality I think it would be very useful if photoprism could support these hierarchical tags as well. In my case, I have used Digikam for such task, but hierarchical tags are also supported in picture managers such as Lightroom or ACDSee. I'd would personally use Digikam because the way it writes metadata makes it compatible with most other picture managers. **Additional context** This feature request was an idea that came out from this other request: https://github.com/photoprism/photoprism/issues/747 There are some examples of hierarchical tags on that thread, but I'll be happy to provide more examples if needed.
Author
Owner

@dvett01 commented on GitHub (Jan 12, 2022):

I just started with PhotoPrism and would also love to have hierarchical trees supported.

I am also using DigiKam to manage all my photos, i.e. set Geolocation Data, Tag Faces, set other hierarchical tags.
It would be great if the DigiKam Faces would also be supported within PhotoPrism as DigiKam is on of the most used OpenSource Tools for persoanl users out there.

@dvett01 commented on GitHub (Jan 12, 2022): I just started with PhotoPrism and would also love to have hierarchical trees supported. I am also using DigiKam to manage all my photos, i.e. set Geolocation Data, Tag Faces, set other hierarchical tags. It would be great if the DigiKam Faces would also be supported within PhotoPrism as DigiKam is on of the most used OpenSource Tools for persoanl users out there.
Author
Owner

@graciousgrey commented on GitHub (Jan 12, 2022):

@dvett01 that's planned as well: https://github.com/photoprism/photoprism/issues/747 :)

@graciousgrey commented on GitHub (Jan 12, 2022): @dvett01 that's planned as well: https://github.com/photoprism/photoprism/issues/747 :)
Author
Owner

@dinoschachten commented on GitHub (Apr 2, 2022):

This is pretty much my situation as well - and a feature I would gladly sponsor.

Coming from DigiKam I have developed a hierarchical tag structure to provide different types of information about each file.

PhotoPrism so far does not support hierarchies for labels or keywords - I understand the philosophy behind that with namespaces and everything, however I think hierarchies are extremely useful for properly and comprehensively labelling your media.

The way I think it should work is:

  • Create custom label categories that serve as different categories of information you want to provide for each file (=questions that need to be answered for each file)
  • Under each category you create your custom tags/labels (the answers to the questions, see example tree below)
  • These labels should allow hierarchies, perhaps even automatically assign the parent label if one of its sub-labels is assigned
  • Find files that are not properly labelled yet: Filter your media by "no categorised labels assigned" or even "some categorised labels missing" (meaning not from every category a label has been assigned: Some of the mandatory questions have not been answered for this file)
  • assign one or more labels from each category

I am absolutely open to alternatives to this, but so far I can't think of any other way to systematically, reliably and thoroughly label all media in my library.

Status (Category)

  • Unedited (label)
  • Edited/ready to use (label)

Subject (Category)

  • Equipment
    • Computer
    • Fire extinguisher
  • Animals
    • Dog
    • Mosquito
      • Aedes Albopictus
        • Egg
        • Larvae
        • Adult
  • Buildings
    • Town Hall
    • Home

Occasion/Topic (Category)

  • Birthday
    • Grandma's 14th Birthday
    • Dad's 50th Birthday
  • Wedding
    • Laura & Dale's Wedding
  • Project X
  • Grand Canyon exploration

Visual style/type (Category)

  • Portait
  • Detail/Macro/Close-up
  • Group photo
  • Documentary
  • Atmospheric
  • Abstract

Some more context in case you wonder "why would you even need that" 😄

Here is one example:
I took photos of several mosquito species in all of their development stages. All of the four species were photographed as eggs, larvae, pupae, adult. Some of these photos I have edited. Someone else is looking for a photo of the eggs of a specific species - but perhaps I forgot to label the photo(s) I edited as edited, or I labelled them as "eggs" and "mosquito" but forgot the specific species...

So in order to systematically tag all photos with all relevant tags (and not just those that randomly come to mind as I look at it), I have developed a structure similar to the one above that I can just click through, top to bottom. This makes media findable from several "perspectives", and provides necessary meta information, especially when operating a library with many users.

This may seem somewhat complex, but when building websites you might well find yourself in a situation where you perhaps need an atmospheric image that has already been edited beautifully, and you remember that some great ones were taken during that Grand Canyon exploration. You can find them efficiently if all that information is provided, and you can filter by those labels.

Without a hierarchical structure where I can just check the boxes under each category I invite human error and/or feel stressed while assigning tags/labels, essentially having to remember my mandatory information categories and visualise the label tree branches to assign both sub-labels and broader ones.

@dinoschachten commented on GitHub (Apr 2, 2022): This is pretty much my situation as well - and a feature I would gladly sponsor. Coming from DigiKam I have developed a hierarchical tag structure to provide different types of information about each file. PhotoPrism so far does not support hierarchies for labels or keywords - I understand the philosophy behind that with namespaces and everything, however I think hierarchies are extremely useful for properly and comprehensively labelling your media. The way I think it should work is: - Create custom label categories that serve as different categories of information you want to provide for each file (=questions that need to be answered for each file) - Under each category you create your custom tags/labels (the answers to the questions, see example tree below) - These labels should allow hierarchies, perhaps even automatically assign the parent label if one of its sub-labels is assigned - Find files that are not properly labelled yet: Filter your media by "no categorised labels assigned" or even "some categorised labels missing" (meaning not from every category a label has been assigned: Some of the mandatory questions have not been answered for this file) - assign one or more labels from each category I am absolutely open to alternatives to this, but so far I can't think of any other way to systematically, reliably and thoroughly label all media in my library. **Status** (Category) - Unedited (label) - Edited/ready to use (label) **Subject** (Category) - Equipment - - Computer - - Fire extinguisher - Animals - - Dog - - Mosquito - - - Aedes Albopictus - - - - Egg - - - - Larvae - - - - Adult - Buildings - - Town Hall - - Home **Occasion/Topic** (Category) - Birthday - - Grandma's 14th Birthday - - Dad's 50th Birthday - Wedding - - Laura & Dale's Wedding - Project X - Grand Canyon exploration **Visual style/type** (Category) - Portait - Detail/Macro/Close-up - Group photo - Documentary - Atmospheric - Abstract Some more context in case you wonder "why would you even need that" 😄 Here is one example: I took photos of several mosquito species in all of their development stages. All of the four species were photographed as eggs, larvae, pupae, adult. Some of these photos I have edited. Someone else is looking for a photo of the eggs of a specific species - but perhaps I forgot to label the photo(s) I edited as edited, or I labelled them as "eggs" and "mosquito" but forgot the specific species... So in order to systematically tag all photos with all relevant tags (and not just those that randomly come to mind as I look at it), I have developed a structure similar to the one above that I can just click through, top to bottom. This makes media findable from several "perspectives", and provides necessary meta information, especially when operating a library with many users. This may seem somewhat complex, but when building websites you might well find yourself in a situation where you perhaps need an atmospheric image that has already been edited beautifully, and you remember that some great ones were taken during that Grand Canyon exploration. You can find them efficiently if all that information is provided, and you can filter by those labels. Without a hierarchical structure where I can just check the boxes under each category I invite human error and/or feel stressed while assigning tags/labels, essentially having to remember my mandatory information categories and visualise the label tree branches to assign both sub-labels and broader ones.
Author
Owner

@JWCook commented on GitHub (Jul 9, 2022):

This would be an extremely useful feature that I would love to see. My use case is nature photography, somewhat similar to @dinoschachten's workflow. As far as I know, there are no existing self-hosted server-based photo management tools that support hierarchical keywords.

@JWCook commented on GitHub (Jul 9, 2022): This would be an extremely useful feature that I would love to see. My use case is nature photography, somewhat similar to @dinoschachten's workflow. As far as I know, there are no existing self-hosted server-based photo management tools that support hierarchical keywords.
Author
Owner

@dinoschachten commented on GitHub (Jul 10, 2022):

Exactly, @JWCook - DigiKam is outright overflowing with features, but somewhat cumbersome to work with, relying on each client to be set up and connected to both database and file shares (not running smoothly on macOS at all, because macOS is getting weirder and weirder in the way it accesses network shares).
There are many server-based solutions, the vast majority of which are very rudimentary or - even if mature - lack some fundamental features (Piwigo's refusal to add RAW support comes to mind).
PhotoPrism on the other hand understands the users' needs - I'm really excited to see this evolve. I can really recommend sponsoring them ;)

@dinoschachten commented on GitHub (Jul 10, 2022): Exactly, @JWCook - DigiKam is outright overflowing with features, but somewhat cumbersome to work with, relying on each client to be set up and connected to both database and file shares (not running smoothly on macOS at all, because macOS is getting weirder and weirder in the way it accesses network shares). There are many server-based solutions, the vast majority of which are very rudimentary or - even if mature - lack some fundamental features (Piwigo's refusal to add RAW support comes to mind). PhotoPrism on the other hand understands the users' needs - I'm really excited to see this evolve. I can really recommend sponsoring them ;)
Author
Owner

@sfatula commented on GitHub (Aug 11, 2022):

I also use Digikam and have added people metadata to all photos. It sure would be handy for these to show up on the PhtoPrism people tab so in my case at least, wouldn't even need people recognition by PhotoPrism as this was already done in digikam.

In my XMP sidecar file, as processed by exiftool, they show like this:

Tags List : People/Steve Fatula, People/Lena Fatula
Last Keyword XMP : People/Steve Fatula, People/Lena Fatula
Hierarchical Subject : People|Steve Fatula, People|Lena Fatula
Catalog Sets : People|Steve Fatula, People|Lena Fatula
Subject : Steve Fatula, Lena Fatula

For me, it would seem at least 100% reliable to use Tags List where we have People/somename. In this way, no recognition needed in PhotoPrism when this data is already there.

I really want them to show up on the people tab, not have to keyword search, etc.

@sfatula commented on GitHub (Aug 11, 2022): I also use Digikam and have added people metadata to all photos. It sure would be handy for these to show up on the PhtoPrism people tab so in my case at least, wouldn't even need people recognition by PhotoPrism as this was already done in digikam. In my XMP sidecar file, as processed by exiftool, they show like this: Tags List : People/Steve Fatula, People/Lena Fatula Last Keyword XMP : People/Steve Fatula, People/Lena Fatula Hierarchical Subject : People|Steve Fatula, People|Lena Fatula Catalog Sets : People|Steve Fatula, People|Lena Fatula Subject : Steve Fatula, Lena Fatula For me, it would seem at least 100% reliable to use Tags List where we have People/somename. In this way, no recognition needed in PhotoPrism when this data is already there. I really want them to show up on the people tab, not have to keyword search, etc.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/photoprism#1238
No description provided.