[I7] Kinds as values

I’m going back to I7 now, and I find myself rusty.

The long and short of it is, I want to write some code that needs passing a kind as a variable. For instance, suppose I have this:

A precious object is a kind of thing. A diamond, a gold bar, and a Fabergé egg are kinds of precious object.

Ignoring for the moment that we could do this with just a property, can I write definitions that incorporate the kind as a variable? Pseudocode-wise, and assuming a game in which you would only carry one of these priceless treasures at a time:

To decide which object is a specific (kind K) clutched by (adventurer - a person) is relevant: decide on a random (thing of kind K).

The intent would be to be able to write things on the form of

After trying touching a specific diamond clutched by John:

Can this be done in I7 at present?

You can often do this by setting a property. Something like:

Precious-tag is a kind of value. The precious-tags are diamond-tag, gold-tag, jewel-tag.
A precious object has a precious-tag called the tag.
The tag of a gold bar is always gold-tag.
[and so on].

(EDIT-ADD: Yeah, you said “ignoring this”, but I have to say it for the next person who has this question.)

If this is insufficient, look at the extension “Object Kinds by Brady Garvin”.

Also, your example doesn’t really demonstrate the need for this. The way you’re asking it, you could just write

After trying touching a diamond clutched by John:

(You said there will be at most one of the “diamond” kind that fits that description.)

…you’re right. I’m overthinking things. Again. Thanks, zarf.