OASIS XML Localisation Interchange File Format (XLIFF) TC

  • 1.  translate and xml:space

    Posted 04-22-2012 20:57
    Hi all, While working on the library for the toolkit I've run into a few questions. I'm posting on the main TC list because it's affecting more than the inline content. --- translate Currently we have a translate attribute in <unit>. We also have an <mrk translate='yes/no'> possible in the inline content. We need to specify the behavior for the case like: <unit id='1' translate='no'> <segment> <source>textA <mrk translate='yes'>textB</mrk></source> </segment> </unit> Logically I assume the user agent needs to translate 'textB'. Is that the behavior we all agree on? Note that in 1.2 the translate='no' attribute in trans-unit has been used to "lock" the <trans-unit>. Since there was no relationship described between translate='yes/no' and protected='yes/no' that was not incorrect. So my other question is: Do we need another attribute in 2.0's <unit> that would "lock" the unit in read-only mode regardless of its translate status? --- xml:space Currently we have xml:space on <source>/<target>. There are cases like this: <para>Text <span xml:space='preserve'>[ ]</span></para> That are not currently catered for. I assume we would need to allow xml:space in ,mrk> as well then. Is that something we should do? Any feedback welcome, -yves


  • 2.  RE: [xliff] translate and xml:space

    Posted 04-23-2012 00:42
    > -----Original Message----- > From: xliff@lists.oasis-open.org [ mailto:xliff@lists.oasis-open.org ] On Behalf > Of Yves Savourel > Sent: Sunday, April 22, 2012 5:57 PM > To: xliff@lists.oasis-open.org > Subject: [xliff] translate and xml:space Hi, > While working on the library for the toolkit I've run into a few questions. > I'm posting on the main TC list because it's affecting more than the inline > content. > > --- translate > > Currently we have a translate attribute in <unit>. We also have an <mrk > translate='yes/no'> possible in the inline content. > > We need to specify the behavior for the case like: > > <unit id='1' translate='no'> > <segment> > <source>textA <mrk translate='yes'>textB</mrk></source> > </segment> > </unit> > > Logically I assume the user agent needs to translate 'textB'. > Is that the behavior we all agree on? That translatable portion should be treated as a subflow and placed in its own segment. Don't add a "translate" attribute to <mrk> > Note that in 1.2 the translate='no' attribute in trans-unit has been used to > "lock" the <trans-unit>. Since there was no relationship described between > translate='yes/no' and protected='yes/no' that was not incorrect. > So my other question is: Do we need another attribute in 2.0's <unit> that > would "lock" the unit in read-only mode regardless of its translate status? There is no need to add a "lock" attribute. With "translate" we have enough. > --- xml:space > > Currently we have xml:space on <source>/<target>. There are cases like this: > > <para>Text <span xml:space='preserve'>[ ]</span></para> > > That are not currently catered for. I assume we would need to allow > xml:space in ,mrk> as well then. > Is that something we should do? Again, treat that portion that requires special space handling as a subflow. Regards, Rodolfo -- Rodolfo M. Raya rmraya@maxprograms.com Maxprograms http://www.maxprograms.com


  • 3.  RE: [xliff] translate and xml:space

    Posted 04-23-2012 08:41
    Hi Rodolfo, Yves, > -----Original Message----- > From: xliff@lists.oasis-open.org [ mailto:xliff@lists.oasis-open.org ] On Behalf > Of Rodolfo M. Raya > Sent: den 23 april 2012 02:42 > To: xliff@lists.oasis-open.org > Subject: RE: [xliff] translate and xml:space > > > -----Original Message----- > > From: xliff@lists.oasis-open.org [ mailto:xliff@lists.oasis-open.org ] > > On Behalf Of Yves Savourel > > Sent: Sunday, April 22, 2012 5:57 PM > > To: xliff@lists.oasis-open.org > > Subject: [xliff] translate and xml:space > > > Hi, > > > > > While working on the library for the toolkit I've run into a few questions. > > I'm posting on the main TC list because it's affecting more than the > > inline content. > > > > --- translate > > > > Currently we have a translate attribute in <unit>. We also have an > > <mrk translate='yes/no'> possible in the inline content. > > > > We need to specify the behavior for the case like: > > > > <unit id='1' translate='no'> > > <segment> > > <source>textA <mrk translate='yes'>textB</mrk></source> > > </segment> > > </unit> > > > > Logically I assume the user agent needs to translate 'textB'. > > Is that the behavior we all agree on? > > That translatable portion should be treated as a subflow and placed in its own > segment. Don't add a "translate" attribute to <mrk> > I think we really need the translate attribute on the <mrk> so that it can be used to mark that words or phrases should not be translated. But I do agree that setting translate=no on the unit and then unlocking a small part inside it feels wrong, and it is probably better served by breaking that part out as subflow. > > > Note that in 1.2 the translate='no' attribute in trans-unit has been > > used to "lock" the <trans-unit>. Since there was no relationship > > described between translate='yes/no' and protected='yes/no' that was not > incorrect. > > So my other question is: Do we need another attribute in 2.0's <unit> > > that would "lock" the unit in read-only mode regardless of its translate > status? > > There is no need to add a "lock" attribute. With "translate" we have enough. > In my opinion having a standard way of locking a segment or unit is important. Locking is different from not-translatable. This often lead to proprietary extensions or semantics. If something is translatable or not should be a linguistic decision. If It is locked or not is a process decision. A common case is that a file starts with some content set to translate=no. Then it is auto translated against a TM and all perfect matches are locked (in 1.2 by setting translate=no or proprietary way). Now it is hard to tell the two things apart in a tool neutral way. If we do not have a separate 'lock' attribute we should definitively define a state/state-qualifier pairing that means locked, or some other un-ambiguous solution separate from 'translate'. Looking at the draft we do not have any state metadata in the core at the moment. It looks like this might be covered by http://wiki.oasis-open.org/xliff/XLIFF2.0/FeatureTracking#XLIFF2.0.2BAC8-Feature.2BAC8-TranslationState.A.28Y8.29TranslationState . I'm not sure if the locked state would be better in core though. > > --- xml:space > > > > Currently we have xml:space on <source>/<target>. There are cases like > this: > > > > <para>Text <span xml:space='preserve'>[ ]</span></para> > > > > That are not currently catered for. I assume we would need to allow > > xml:space in ,mrk> as well then. > > Is that something we should do? > > Again, treat that portion that requires special space handling as a subflow. > I would disagree on this. All inline spanning elements in <source> and <target> must use the same xml:space semantics as their container. That is currently <mrk> and <pc>. The reason for this is that they must be able to span an arbitrary portion of the content in their container, and if they do not have the same space preservation semantics that get difficult. Regards, Fredrik Estreen


  • 4.  RE: [xliff] translate and xml:space

    Posted 04-23-2012 11:30
    Hi Rodolfo, Fredrik, all, >> That translatable portion should be treated as >> a subflow and placed in its own segment. >> Don't add a "translate" attribute to <mrk> > > I think we really need the translate attribute > on the <mrk> so that it can be used to mark that > words or phrases should not be translated. But > I do agree that setting translate=no on the unit > and then unlocking a small part inside it feels wrong, > and it is probably better served by breaking > that part out as subflow. Assuming we have a <mrk translate='no'> to represent non-translatable spans within its content, it would be logical to be able to use <mrk translate='yes'> to represent one or more translatable spans within their content. We could have cases like this: a) <p translate='no'>not to translate<span translate='yes'>to translate</span></p> b) <p><span translate='no'>not to translate<span translate='yes'>to translate</span></span></p> Representing a) with two units and no <mrk> and b) with one unit and two <mrk> seems inconsistent. Rodolfo's view of not having <mrk translate='yes no'> would means to use sub-flows for translatable spans inside non-translatable ones, and inline codes for non-translatable ones. To me that's misusing both sub-flows and inline codes. But more importantly it makes things very difficult for processes that annotate the content with translate/don't translate information after extraction. They can't create sub-flows for example as it would change the number of units. >> There is no need to add a "lock" attribute. With >> "translate" we have enough. > > In my opinion having a standard way of locking a segment > or unit is important. > Locking is different from not-translatable. I would tend to agree those are two distinct functions, and the translate='no' of 1.2 is blending both. >> That are not currently catered for. I assume we would >> need to allow xml:space in <mrk> as well then. >> Is that something we should do? > > Again, treat that portion that requires special space > handling as a subflow. I think it would be wrong to break apart a sentence because of a stylistic change. If we do that for xml:space why don't we do it for a span of italics inside a non-italics content? While the presence of a change in how spaces should be handled *may* indicate a true sub-flow, there is no way to be sure of it just by that. Cheers, -yves


  • 5.  Re: [xliff] translate and xml:space

    Posted 04-23-2012 12:05
    I'd second what Yves says. In addition, with the new translate attribute in HTML5, which will be in ITS 2.0, the behavior Yves describes is the way it works. To require a different mechanism for XLIFF seems a strange state of things. We should be working to unify, as much as possible, some of these little oddities of behavior into consistent models. If we are going to have identically names attributes for basic functionality across different, but related, specs, having them work a bit differently and requiring totally different mechanisms to achieve the same behavior is bad design from a user-centered perspective and it also invites implementers to ignore the mandated behavior in terms of the one that makes sense. So why intentionally implement a behavior they are likely to want to change? I think part of the problem, as Yves and Fredrik point out, is that translate=no can be overloaded for two different functions: (1) don't touch this thing and lock it (for whatever reason) and (2) don't translate this thing because it shouldn't be translated (e.g., it is a brand name or a legal text that applies to only one locale). In the case of the second one, it is entirely reasonable that you might set translate=no for a block but want to set it to yes for some portion of the inside because you are providing instruction to the translator about what to do (e.g., don't translate this except for this one bit). If you are using the attribute to lock the segment, that is a different story, and I agree that it doesn't make sense to lock it but then say that part of it is unlocked, because then you haven't really locked it. So it would make sense to split the functionality and use two different mechanisms because, even though they are similar, they are not the same thing. -Arle -- Arle Lommel Phone (U.S.): +1.707.709.8650 Skype: arle_lommel LinkedIn: http://www.linkedin.com/in/arlelommel On Apr 23, 2012, at 4:30, Yves Savourel <ysavourel@enlaso.com> wrote: > Hi Rodolfo, Fredrik, all, > >>> That translatable portion should be treated as >>> a subflow and placed in its own segment. >>> Don't add a "translate" attribute to <mrk> >> >> I think we really need the translate attribute >> on the <mrk> so that it can be used to mark that >> words or phrases should not be translated. But >> I do agree that setting translate=no on the unit >> and then unlocking a small part inside it feels wrong, >> and it is probably better served by breaking >> that part out as subflow. > > Assuming we have a <mrk translate='no'> to represent non-translatable spans within its content, it would be logical to be able to use <mrk translate='yes'> to represent one or more translatable spans within their content. > > We could have cases like this: > > a) <p translate='no'>not to translate<span translate='yes'>to translate</span></p> > > b) <p><span translate='no'>not to translate<span translate='yes'>to translate</span></span></p> > > Representing a) with two units and no <mrk> and b) with one unit and two <mrk> seems inconsistent. > > Rodolfo's view of not having <mrk translate='yes no'> would means to use sub-flows for translatable spans inside non-translatable ones, and inline codes for non-translatable ones. > > To me that's misusing both sub-flows and inline codes. But more importantly it makes things very difficult for processes that annotate the content with translate/don't translate information after extraction. They can't create sub-flows for example as it would change the number of units. > > >>> There is no need to add a "lock" attribute. With >>> "translate" we have enough. >> >> In my opinion having a standard way of locking a segment >> or unit is important. >> Locking is different from not-translatable. > > I would tend to agree those are two distinct functions, and the translate='no' of 1.2 is blending both. > > >>> That are not currently catered for. I assume we would >>> need to allow xml:space in <mrk> as well then. >>> Is that something we should do? >> >> Again, treat that portion that requires special space >> handling as a subflow. > > I think it would be wrong to break apart a sentence because of a stylistic change. If we do that for xml:space why don't we do it for a span of italics inside a non-italics content? While the presence of a change in how spaces should be handled *may* indicate a true sub-flow, there is no way to be sure of it just by that. > > Cheers, > -yves > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: xliff-unsubscribe@lists.oasis-open.org > For additional commands, e-mail: xliff-help@lists.oasis-open.org >