ACX format

From Apertium
Revision as of 13:43, 18 April 2008 by Francis Tyers (talk | contribs)
Jump to navigation Jump to search

The ACX format is used for describing equivalent characters in monodices. If a language has multiple methods of writing a character, for example with Romanian ș and ş, then you can use the file to define them as being equivalent. It can also be used in languages where the apostrophe is grammatically important (e.g. Catalan) to make sure that several different variants are accepted.

The format is defined in the file acx.rng which can be found in both the lttoolbox and apertium modules in SVN.


The program lt-comp takes one more argument, the ACX file, for example:

$ lt-comp lr ro-es.automorf.bin 
apostrophes@postblank 104 134
final@inconditional 24 479
main@standard 43130 81174

Example file

The file from apertium-es-ro.

<?xml version="1.0"?>
  <!-- Make apostrophe variants equal ' -->
  <char value="'">
    <equiv-char value="’"/>
    <equiv-char value="ʼ"/>

  <!-- Legacy values for characters with comma -->
  <char value="ț">
    <equiv-char value="ţ"/>
  <char value="Ț">
    <equiv-char value="Ţ"/>
  <char value="ș">
    <equiv-char value="ş"/>
  <char value="Ș">
    <equiv-char value="Ş"/>

  <!-- Orthographic variant -->
  <char value="â">
    <equiv-char value="î"/>