W3C home > Mailing lists > Public > public-multilingualweb-lt@w3.org > July 2012

RE: [ISSUE 34] Quality error category proposal

From: Yves Savourel <ysavourel@enlaso.com>
Date: Wed, 11 Jul 2012 08:24:14 +0200
To: "'Felix Sasaki'" <fsasaki@w3.org>, "'Phil Ritchie'" <philr@vistatec.ie>
CC: "'Arle Lommel'" <arle.lommel@dfki.de>, "'Multilingual Web LT Public List'" <public-multilingualweb-lt@w3.org>
Message-ID: <assp.05394496ed.assp.05395c560b.001f01cd5f2d$cbc4ece0$634ec6a0$@com>
Hi Felix, Arle, Phil, all,

There is something that doesn't feel right about that simple solution.
I still need to think more about it.

But meanwhile, I wanted to point out something else:

Obviously having multiple attribute on a span-like element is the less intrusive way to annotate in HTML5, and possibly in many XML formats. But this pauses a challenge in XLIFF 2.0.

In XLIFF 1.2 we would possibly use the ITS attribute directly in <mrk> and get something like this:

<target>Insert the <mrk mtype='x-itsqa' its:error="yes" its:errorInfo="Should be USB key" its:error????="URI to machine readable information">Pen Drive</span> in the USB port</target>

In XLIFF 2.0 the pattern to annotate a content is quite different.

Using attributes for annotation is not working very well when the data reaches a certain level of complexity.

- if the information is very short we would use the 'type' and 'value' attribute of <mrk> to hold the information.

- if the information is complex we would point to an outside element. So something like this:

  <target>Insert the <mrk id='m1' type='x-itsqa' ref="#qa1">Pen Drive</mrk> in the USB port</target>
 <its:qaEntry id="qa1">
  <its:qaNote>Should be USB key</its:Note>
  ... any extra info

In addition one thing that was not provided in 1.2 but is in 2.0: how to deal with overlapping spans.

Some background:

<mrk> can be used for many things, including annotating things that overlap: for example a QA annotation and a user comment:

<target>Insert <mrk id='m1' type="comment" value="Not sure about 'the pen'" >the <mrk id='m2' type='x-itsqa' ref="#qa1">Pen</mrk> Drive</mrk> in the USB port<target>

But such notation obviously doesn't work because it's not well-formed. (Remember that we can't control how annotations are created: XLIFF is just an input/output, we can only provide a way to represent these cases. And even if we had some control on the creation, <mrk> can be broken by segmentation, so there is no easy way to always use <mk>...</mrk>).

To represent non-well-formed annotations, we use the same principle as for inline spanning codes: we change the spanning element to two empty elements that indicate the start and end of the span:

<target>Insert <sm id='m1' type="comment" value="Not sure about 'the pen'"/>the <sm id='m2' type='x-itsqa' ref="#qa1"/>Pen<em rid='m1'/> Drive<em rid='m2'/> in the USB port<target>

So what's the problem? We can still use the ITS attribute no?
No, because the scope of the ITS local attributes is the content of the element where the attribute is. So when we use <sm/>...<em/> instead of <mrk>...<mrk> the scope on <sm/> is an empty content.

This is not an issue when we use type and value (the simple annotation) because the semantic of those attributes takes into account the <sm>/<em> notation.

In anycase, since we do have a way to point to an element somewhere else in the <unit>, it would be the natural way to annotate XLIFF 2.0 for 'complex' annotations, like the QA info.

Received on Wednesday, 11 July 2012 06:24:53 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 16:31:47 UTC