ner_manual: Apply tag with click/touch instead of select?

When using the ner_manual frontend interface for tagging documents, tags are currently only applied when the user selects a span in the word either by clicking, holding and moving the mouse, or by a long touch and subsequent selection.
This is a bit cumbersome, especially on mobile. Is it possible to switch the behavior so that the tag is applied to a token on a single click/touch?
Of course this won’t work for multi-token spans, but for these the original behavior can be kept, so all in all:

  • Click/Touch a token: Apply current tag to token
  • Select a span of tokens: Apply current tag to span

An alternative for multi-span tags that could work better for mobile would be to consider neighboring single-token spans with the same tag as a single span, and give the user the option to split it if this is not the desired behavior, e.g. by long-touching/double-clicking.

Yes, this is definitely asomething I've thought about a lot! One problem with the manual span selection on mobile is that most touchscreens are just really bad at text selection, so the user experience will always be subpar :disappointed:

That's an interesting idea – I hadn't thought of this. Although, I'm not sure we can make this work, since it'd pretty inconsistent with how it works on non-touch interfaces.

One option I wanted to explore is relying more on swipe gestures – for example, you could swipe over a span and it's auto-select. So, if the swipe starts on a token and ends on a token that'd produce a valid span with the first one, we can lock in the span in between. I haven't experimented with this in detail yet, but I think it should work!

One option I wanted to explore is relying more on swipe gestures – for example, you could swipe over a span and it’s auto-select. So, if the swipe starts on a token and ends on a token that’d produce a valid span with the first one, we can lock in the span in between. I haven’t experimented with this in detail yet, but I think it should work!

That sounds like a great idea, far better than my proposal :slight_smile:
On a related note, are there any plans for making the frontend source code available to Prodigy customers? I'd love to play around with it and maybe work on some modifications to tailor it more to our environment.

Okay, I can confirm that it works :tada:

It registers the selection in both directions and logs in the start and end token, given that it’s a valid selection. So in theory, you can just swipe across the screen to select a longer sequence. The only problem at the moment is that it can potentially interfer with native scrolling and the “drag to refresh” feature that some mobile browsers implement. But I should be able to fix that, too :slightly_smiling_face: