The **inscription** property refers to ‘inscriptions, markings and signatures on an object' and is of type ‘monolingual text’
When used as a qualifier with 'depicts' it refers to markings on the thing-that-is-depicted - example from wikidata https://www.wikidata.org/wiki/Q1136099 (see depicts > Province of New York > inscription, etc.)
The example I've been using to model this conceptually is band t-shirts - an image could depict a t-shirt with 'The Rolling Stones' written on it, and a user might want to find all images containing pictures of Rolling Stones t-shirts
I can think of 3 different ways of implementing this, all with drawbacks/tradeoffs
We can store the qualifier in the normal way like this `P180=Q131151[P1682=The Rolling Stones]` (see T193407), in which case we would only be able to find **exact matches**. For example searching for `haswbstatement:P180=Q131151[P1682=Stones]` won't match `P180=Q131151[P1682=The Rolling Stones]`.
Perhaps we could pass a regex to the `haswbstatement` keyword? Would require changes to the mapping of the `statement_keywords` field
Implement a specific elasticsearch solution just for this qualifier - for example we could store the inscription in a fulltext field, which would mean a partial match would work. It'd be tricky to do, because we'd need to treat one qualifier differently to all the others both when we were indexing and when we're searching. Also if we did it this way I'm not sure how to store the fact that the inscription relates to a particular 'depicts' tag (or even if that'd be possible) - so someone could try and search for pictures containing Rolling Stones t-shirts and some of their results would contains blank t-shirts plus some //other// object with the text 'The Rolling Stones' inscribed on it.
Another possible approach is to use the Wikidata Query Service (WDQS) to run a SPARQL query, and then use the ids as a filter for an elasticsearch query - basically we'd ask WDQS for all pictures depicting a t-shirt inscribed with 'The Rolling Stones', take all the resulting IDs, and then search elasticsearch for anything else we wanted to search for but only among the (max 1000) IDs we got from WDQS.
Note that this option depends on T194401
Option 1 is easiest, but only does exact matches unless the regex idea (option 1a) works, which might be difficult to implement on the frontend in a user-friendly way
Option 2 is tricky to implement, and may not return exactly correct data, but would probably be more performant than option 3
Option 3 is in-between, implementation-wise. Probably the slowest to run, results will be more accurate than option 2 but because of limitations with passing data between WDQS and elasticsearch it will be possible to miss stuff. This option depends on T194401
Wikidata currently contains **7** items with depicts statements that have inscription qualifiers out of a total of ~70k items with depicts statements (~0.01%)