tmx2cwb - encodes a pair of languages from a TMX file as a CWB corpus
tmx2cwb <-from=PT> <-to=EN> <-corpora=/corpora> <-registry=/usr/share/cwb/registry> <-toksource> <-toktarget> [file.tmx] tmx2cwb <-mono=PT> <-corpora=/corpora> <-registry=/usr/share/cwb/registry> <-tok> [file.tmx]
This program encodes a pair of languages extracted from a TMX file as a CWB corpus. Optionally it can tokenize the text (using basic tokenizing rules).
Accepted options are:
-from
-to
These two parameters are useful when more than two languages are available. They let the user to choose what languages to be encoded. When only two languages are present, they are used by default. If you want to force an order on those two languages, it is enough to specify one of the two options.
-mono
We know TMX are for translation memories. But you might want to encode a monolingual corpus from a TMX. We let you do that from tmx2cwb, using this switch, together with the language name to be encoded.
tmx2cwb
-corpora
Path to the directory where the corpus should be encoded. Defaults to the /corpora folder.
/corpora
-registry
Path to the CWB registry folder. The tool tries to guess it using the cwb-config command or the environment variable CORPUS_REGISTRY. If not, you will need to specify it.
cwb-config
CORPUS_REGISTRY
-toksource
-toktarget
These two options can be used to make the tool to tokenize the source and/or the target language. Note that the used rules are good for Portuguese, acceptable for Spanish, English, French and Italian, and should be quite bad for other languages.
-tok
When using the monolingual switch -mono described above, you might want to tokenize its source. Use this switch for that.
-v
Verbose mode
-h
Prints basic help information.
XML::TMX::CWB(3)
Alberto Manuel Brandão Simões, <ambs@cpan.org>
Copyright (C) 2010-2011 by Alberto Manuel Brandão Simões
To install XML::TMX::CWB, copy and paste the appropriate command in to your terminal.
cpanm
cpanm XML::TMX::CWB
CPAN shell
perl -MCPAN -e shell install XML::TMX::CWB
For more information on module installation, please visit the detailed CPAN module installation guide.