Details
-
Improvement
-
Resolution: Unresolved
-
None
-
None
-
High
-
IMPROVEMENT: detect structural tag-problems between sub-segments of a trans-unit, show them as a new AutoQA error category and fix them automatically on export
-
Empty show more show less
Description
OKAPI will wrap opening/closing tags in sub-segments (segments of a segmented trans-unit) in <it> tags instead of <bpt>/<ept>
<trans-unit> <source> ... <bpt id="27"><run27></bpt> ... <ept id="27"></run27></ept> ... <bpt id="26"><run26></bpt> .... <ept id="26"></run26></ept> ... </source> <seg-source> <mrk> ... <it id="27" pos="open"><run27></it> ... </mrk> <mrk> ... <it id="27" pos="close"></run27></it> ... <bpt id="26"><run26></bpt> .... <ept id="26"></run26></ept> ... </mrk> </seg-source> <target> <mrk> ... <it id="27" pos="open"><run27></it> ... </mrk> <mrk> ... <bpt id="26"><run26></bpt> ... <it id="27" pos="close"></run27></it> ... <ept id="26"></run26></ept> ... </mrk> </target> </trans-unit>
When in the pretranslation or the translation in t5 the order is changed, this may creates invalid markup causing OKAPI errors on export.
Solution
- detect such tags in the import and add an attribute to the internal tag "t5nextSubSegIdx" or "t5prevSugSegIdx" and a marker-class "t5subsegtag" that marks them as such "segment overlapping tags" and define the order they had in the original segment (in case we have more than one).
- In the auto-qa, add new category SUBSEGMENT_TAG_STRUCTURE_FAULTY = 'subseg_tag_structure_faulty'
- in the automatic tag-repair, add a second step to repair such problems by moving those tags to the outer borders of a segment
example-structure:
<segment1> ... <internal-tag1 class="... t5subseg t5subopen" t5subSegIdx="2" /> ... <internal-tag2 class="... t5subseg t5subopen" t5subSegIdx="1" /> ... </segment1> <segment2> ... <internal-tag1 class="... t5subseg t5subclose" t5subSegIdx="1" /> ... <internal-tag2 class="... t5subseg t5subclose" t5subSegIdx="2" /> ... </segment2>