I fix it. This is new ini file:
[input-factors]
0
# mapping steps
[mapping]
0 T 0
1 T 1
[distortion-limit]
12
# feature functions
[feature]
Distortion
UnknownWordPenalty
WordPenalty
PhraseDictionaryBinary name=TranslationModel0 num-features=5 path=/mnt/models/ar-en/phrase-table/phrase-table input-factor=0 output-factor=0 table-limit=20
LexicalReordering num-features=6 name=LexicalReordering0 type=wbe-msd-bidirectional-fe-allff input-factor=0 output-factor=0 path=/mnt/models/ar-en/reordering-table/reordering-table.wbe-msd-bidirectional-fe.gz
IRSTLM name=LM0 order=5 factor=0 path=/mnt/models/ar-en/language-model/en.qblm.mm
PhraseDictionaryBinary name=TranslationModel1 num-features=5 path=/mnt/models/en-ar/phrase-table/phrase-table input-factor=0 output-factor=0 table-limit=20
LexicalReordering num-features=6 name=LexicalReordering1 type=wbe-msd-bidirectional-fe-allff input-factor=0 output-factor=0 path=/mnt/models/en-ar/reordering-model/reordering-table.wbe-msd-bidirectional-fe.gz
IRSTLM name=LM1 order=5 factor=0 path=/mnt/models/en-ar/language-model/ar.lm.d1.blm.mm
# core weights - not used
[weight]
Distortion0= 0
WordPenalty0= 0
TranslationModel0= 0 0 0 0 0
LexicalReordering0= 0 0 0 0 0 0
LM0= 0
TranslationModel1= 0 0 0 0 0
LexicalReordering1= 0 0 0 0 0 0
LM1= 0
[alternate-weight-setting]
id=ar-en ignore-ff=LM1,LexicalReordering1 ignore-decoding-path=1
Distortion0= 0.3
WordPenalty0= -1
TranslationModel0= 0.2 0.2 0.2 0.2 0.2
LexicalReordering0= 0.3 0.3 0.3 0.3 0.3 0.3
LM0= 0.5
id=en-ar ignore-ff=LM0,LexicalReordering0 ignore-decoding-path=0
Distortion0= 0.3
WordPenalty0= -1
TranslationModel1= 0.2 0.2 0.2 0.2 0.2
LexicalReordering1= 0.3 0.3 0.3 0.3 0.3 0.3
LM1= 0.5
Sample code for client is:
import xmlrpclib
client = xmlrpclib.ServerProxy('http://localhost:8080')
client.translate({'text': '<seg weight-setting="%s">%s</seg>' % ('en-ar', some_text)})
where "en-ar" is translation system which, in my case, translate from english to arabic (also i have other translation system "ar-en" (from arabic to english) as you can see from ini file).