Annotations as filled template like "____ in the ____ with a ____"

I want to annotate documents such that each label is a triplet that fills a given template.
For example, given the text:
“Colonel Mustard was found holding the candlestick in the quiet reading-like room.”
I want my annotator to be able to fill the template:
____ in the ____ with a ____
Where ____ is either free-text or a dropdown of known labels.
So the correct answer would be:
Colonel Mustard in the library with the candlestick
And my output for this example would be (Colonel Mustard, library, candlestick)

Granted this is a contrived example, but hopefully you get my point.
As an extension, I would like to be able to add several filled prompts as answers if the given text requires it.
“Colonel Mustard was found holding the candlestick in the quiet reading-like room. Miss Scarlett was also there with a gun.”
Colonel Mustard in the library with the candlestick
Miss Scarlett in the library with the gun

Is this possible?

Hi @lewis.ripjar,

If I understand correctly, yes, this is totally doable. Just have three classifications that are all marked as required (or not, if you want to be able to leave them blank). Here I have set up an ontology as an example:

Then the labelers would see something like this:

If you want a dropdown instead of free text, just select a radio type for the classification.

Is this what you want to do?


Hi Juan,

Yes, this would satisfy the first scenario. But what about if there are multiple subjects in the text, like the second example? Is it possible to have several triplets for a single text?

Failing that, I guess I could make each text subject specific. For example:
“Considering the subject as Colonel Mustard, label the object and location in the following text.” But from what I see in Labelbox I can’t have example-level instructions like in Label Studio. Or is this possible with a custom editor?

Hi @lewis.ripjar, you could provide per-asset instructions in the Labelbox Editor by using Attachments. For example, you could add a text attachment to each asset specifying what task you want the labeler to perform. The labeler could then open the attachment within the Editor and will have the desired information readily available – no custom editor needed!

Additionally, you could go about labeling several triplets for a single text in a couple potential ways:

  • Create an entity tool that has three nested classifications (subject, place, object). Each time the entity tool is used to label a portion of the text, the labeler will be prompted to answer the nested classification questions.
  • Expanding on @jbuhler’s example above, if you know that you will only have a maximum of, say, 3 triplets per text asset, you could add more classifications and name the questions accordingly (i.e., subject_1, place_1, object_1, subject_2, place_2, object_2

If you have other ideas, please pose them here and I can help to assess their feasibility and provide potential methods to accomplish your goal.