Page MenuHomePhabricator

Instrument usage of ISBN barcode scanner
Open, Needs TriagePublic

Description

We want to know:

  1. Scanner button clicked
  2. Barcode read
  3. Resulting citation inserted

This will go into the VisualEditorFeatureUse schema alongside the existing tracking that was implemented in T221305.

Event Timeline

Stages we could instrument:

  • Click on the scanner button
  • Get a successful read OR close the dialog without a read

As successful ISBN read automatically submits the Citoid search form, so the next step would be

  • Insert a citation generated after use the tool

what sort of things they scan (presumably: 99.9% books, but let's confirm that)

The tool only reads ISBNs, which stands for International Standard Book Number[0], so...

0. https://en.wikipedia.org/wiki/International_Standard_Book_Number

Educational DVDs can get them too! Though I admit I didn’t bother to look up whether there’s any distinguishing characteristic in the code.

I suppose we could log the ISBN itself for later analysis, but that may require some privacy considerations? Or maybe just the ISBN prefix if that contains enough information.

what sort of things they scan (presumably: 99.9% books, but let's confirm that)

The tool only reads ISBNs, which stands for International Standard Book Number[0], so...

The scanner reads all EANs, so you could log all stuff before the /^97[89]/ filter to see whether there are users trying to cite something from their breakfast cereal box by scanning its barcode ...

The scanner reads all EANs, so you could log all stuff before the /^97[89]/ filter to see whether there are users trying to cite something from their breakfast cereal box by scanning its barcode ...

The problem that is that even if you point your camera at a valid ISBN you get a bunch of partial reads that are valid EANs, so filtering out everything except ISBNs is crucial to the scanner working sensibly.

So I think we should begin with the following

  1. Scanner button clicked
  2. Barcode read

We don't really need to log the close button as we can infer that from the drop off rate between 1 & 2.
We should then set an "Scanner used" flag that isn't cleared until the "auto" field is next changed. While this flag is set we should record:

  1. Citation inserted

I don't think we need to know if the ISBN lookup found results as that should almost always work, and we could get that data from the server logs anyway.

Change 493494 had a related patch set uploaded (by Esanders; owner: Esanders):
[mediawiki/extensions/Citoid@master] Barcode scanning

https://gerrit.wikimedia.org/r/493494

Test wiki created on Patch Demo by ESanders (WMF) using patch(es) linked to this task:

https://patchdemo.wmflabs.org/wikis/1fe72fc2e1/w/