<!DOCTYPE html>
<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body>
    Hi Stephanie,<br>
    Thanks, as always, for your quick and precise answers. One or two
    other follow-up questions below... but please do not feel obliged to
    answer, these are really just to help me understand things a little
    better, if you have a free minute.<br>
    Best wishes,<br>
    Graham.<br>
    <br>
    <br>
    <div class="moz-cite-prefix">Le 10/07/2026 à 08:43, Stephanie Evert
      a écrit :<br>
    </div>
    <blockquote type="cite"
      cite="mid:D9616B48-9385-45ED-A64E-1C34FD57CA5B@collocations.de">
      <meta http-equiv="content-type" content="text/html; charset=UTF-8">
      <table class="warning-bandeau-table"
style="font-size: 11px;border:solid 1px red; border-radius: 0.5rem; overflow: hidden; margin-top: 10px"
        border="0" cellspacing="0" cellpadding="0" align="left"
        width="100%">
        <tbody>
          <tr>
            <td style="background: #CCCCCC ;word-wrap:break-word">
              <div style="color:#222222;text-align:center;padding:2pt">
                <p style="color:#222222;"> <span
style="font-size:25px;line-height: 0;position:relative;top:5px;">⚠</span>
                  Ce courrier est envoyé par un correspondant externe</p>
              </div>
            </td>
          </tr>
        </tbody>
      </table>
      <meta http-equiv="content-type" content="text/html; charset=UTF-8">
      <div
style="overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;">Hi
        Graham!<br id="lineBreakAtBeginningOfMessage">
        <div><br>
          <blockquote type="cite">
            <div><span style="font-family: ArialMT;">I have a quick
                question regarding parallel corpora set up. Does the
                cwb-align command actually do the alignment, as I
                understand it does, from the terminal messages, and, if
                so, is it possible to override the cwb alignment to
                impose one's own alignment?</span></div>
          </blockquote>
          <div><br>
          </div>
          <div>Correct. cwb-align ist the actual sentence aligner and
            does indeed use a rather simplistic and old-fashioned
            algorithm. It outputs the alignment in a text format
            (basically listing start/end corpus positions of
            corresponding regions in source and target corpus), which is
            then indexed with cwb-align-encode for use with CWB.</div>
          <div><br>
          </div>
          <div>Which means that you can "simply" generate your own
            alignment in this text format and then run cwb-align-encode.
            You can also preview your alignment with cwb-align-show
            first to check that you've got the format right. </div>
        </div>
      </div>
    </blockquote>
    So as I understand this, given that my s tags are one-to-one
    correspondancse, it would be enough for me to upload an .align file
    reading 1 <TAB> 1, 2 <TAB> 2, etc.?<br>
    <br>
    <blockquote type="cite"
      cite="mid:D9616B48-9385-45ED-A64E-1C34FD57CA5B@collocations.de">
      <div
style="overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;">
        <div><br>
          <blockquote type="cite">
            <div><span style="font-family: ArialMT;"> I'm asking because
                I remember reading that the cwb-align command was not a
                very efficient aligner, and so far I prefer to do the
                alignment myself in advance, and to give cwb-align files
                with exactly the same number of alignment fields (s
                tags). Despite this, I have the impression that the
                command can knock this initial, hand-checked alignment
                out of kilter, which is a shame, and so an override
                flag, if it existed, would be nice.</span></div>
          </blockquote>
          <div><br>
          </div>
          <div>If you have a pre-alignment (which might be at a
            different level than sentences), you can indicate this to
            cwb-align, which will force the aligner to only consider
            sentence correspondences that are consistent with the
            pre-alignment. A trick I've sometimes used is to specify the
            same s-attribute that encodes the pre-alignment (keep in
            mind that there must be a single region for each
            pre-alignment block) as alignment grid, which keeps
            cwb-align from making any changes.</div>
        </div>
      </div>
    </blockquote>
    Does this mean that, since I specify alignment on s tags in
    cwb-align, I should be getting what I want to achieve anyway?
    <blockquote type="cite"
      cite="mid:D9616B48-9385-45ED-A64E-1C34FD57CA5B@collocations.de">
      <div
style="overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;">
        <div>
          <div><br>
          </div>
          <div>It is usually much easier, though, to use
            cwb-align-import from the CWB/Perl modules. This script is
            intended to import an external alignment given in terms of
            sentence IDs (which must be annotated in the corpus via an
            s-attribute). From its documentation:</div>
          <div><br>
          </div>
          <div>
            <blockquote type="cite">
              <div style="font-family: monospace; white-space: pre;">    As an example, the line

        id_1 id_2 id_3  <TAB>  id_2 id_3  [ <TAB> ... ]

    indicates that the first three sentences of the source corpus are
    aligned to the second and third sentence of the target corpus. Further
    TAB-delimited fields (e.g. specifying the confidence in an alignment
    bead) are silently ignored.</div>
            </blockquote>
          </div>
        </div>
      </div>
    </blockquote>
    My pre-alignement is tagged <s> ... </s> which
    generally, but not always, correspond to sentences. As I understand
    it, I'd need to tag it <s id="1"> ... </s>, etc. Is that
    right? If so, could it just, trivially, be a question of added the
    "id" attribute incrementally to the already present "s" tags in
    order to run cwb-align-import with my pre-aligned material?
    <blockquote type="cite"
      cite="mid:D9616B48-9385-45ED-A64E-1C34FD57CA5B@collocations.de">
      <div
style="overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;">
        <div>
          <div><br>
          </div>
          <br>
          <blockquote type="cite">
            <div><span
style="caret-color: rgb(0, 0, 0); font-family: ArialMT; font-size: 14px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;">A
                related question: what does the "no alignments found"
                message most often mean? I'm setting up a three-way
                corpus English-French-Polish. The source text is
                English, the French and Polish texts are translations
                but, since the alignments are based on the English, I
                would like to be able to provide the option for
                searching in one translated corpus, and looking for the
                equivalent in the other translated corpus. So far,
                things work perfectly Eng-Fre and Eng-Pol but I get the
                "no alignments found" message when searching in
                "Fre-Pol" and yet I think I've set it all up
                identically...</span><br
style="caret-color: rgb(0, 0, 0); font-family: ArialMT; font-size: 14px; font-style: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;">
            </div>
          </blockquote>
        </div>
        <br>
        <div>"no alignment found" is the message you get if a query
          match in your source corpus isn't aligned to the target
          corpus. Since alignments don't have to cover the corpus
          completely, this may well happen.</div>
        <div><br>
        </div>
        <div>However, if you always get the message, there's something
          wrong with the Fre-Pol alignment. Perhaps a first step would
          be to use cwb-align-decode on the French corpus to see which
          alignment beads you actually have.</div>
      </div>
    </blockquote>
    Thank you for this... I'll check again.
    <blockquote type="cite"
      cite="mid:D9616B48-9385-45ED-A64E-1C34FD57CA5B@collocations.de">
      <div
style="overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;">
        <div><br>
        </div>
        <div>Hope this helps,</div>
        <div>Stephanie</div>
      </div>
    </blockquote>
    <br>
  </body>
</html>