Cognitionis
Hector Llorens Portfolio

CCG SRL (Roth) how-to


CCG SRL tool is the best SRL tool for English (winner of SemEval).

Prerequisites: Charniak parser installed and running

The program needs 7 processes:

Snow using data/net/file1
Fex using  data/…/file1
SnowFex linking both
Snow using data/net/file2
Fex using  data/…/file2
SnowFex linking both
server-central.pl

REMEMBER: makeexec; chmod a+x srl-demo2/bin/snow ../fex bin/beamsearch/search
REMEMBER: Change paths (/home/myUser/ in ./srl-demo2/roles.sh and in ./ejecuta_todo.sh)

If you are using 64-bit (recompile all: beamsearch, snow and fex)
or you are usint Ubuntu >= 9.10 (recompile at least: snow) you need to recompile.

COMPILATION —————————
If 64 bit: You may need to install lib32 lib32std … rm -rf *.o
Both 32 and 64-bit: Since Ubuntu 9.10 you may also need to manually download and install
(dpkg -i) getlibs-all.deb and libstdc++5_3.3.6-17ubuntu1_i386.deb.

SNOW (cd Snow3.1; export CXX=g++-4.1; export SERVER=1; make clean; make; cp snow …../srl-demo2/bin/snow). If we do not do dat may be srl tool works but it missclassify roles.
FEX (I never recompiled but may be similar to snow)
BEAMSEARCH (regular compilation)
—————————————

To execute the server (1.8 GB RAM): sudo ./roles.sh.

To kill server: sudo ./kill_srl.sh

If you want you can execute: sudo ./ejecuta_todo.sh and then you do not need to execute Chariank first. (remember changing the paths –> and do not change to $scriptPath because needs the absolute path)

To test it: echo “I like apples” | ./srlclient-primitive.pl 1 1 | ./roth2conll -f rothcomplete

It does not need one sentence per line. It splits them very well.

If we want to input pre-splited sentences or pre-tokenized text we have to change the “1 1″ input parameters by “0 0″ (see readme)

HOWEVER, FOR PRE-SPLITTED SENTENCES LEAVE THEM (Double new lined):

1LINE\n\n1LINE\n\n1LINE

I like apples. Mr. John was in Paris at 10.20 a.m. The music of A. Berger is the greatest.—> splitted perfectly

The music that is made by A. Berger is the greatest one. —> splitted perfectly