[Attempto] [Cannot use my own clex with APE]

Kaarel Kaljurand kaljurand at gmail.com
Sat Feb 21 01:00:01 CET 2015


Hi,

I can confirm this behavior. One fix is to increase the global stack
in make_exe (e.g. to global(500000)) and then recompile. Then this
worked:

$ wget https://raw.githubusercontent.com/Attempto/Clex/master/clex_lexicon.pl
...
$ ./ape.exe -ulexfile clex_lexicon.pl -text "John eats an apple." -solo drs
drs([A,B],[object(A,apple,countable,na,eq,1)-1/4,predicate(B,eat,named('John'),A)-1/2])

A better option is to compile the large lexicon into ape.exe, i.e.

curl https://raw.github.com/Attempto/Clex/master/clex_lexicon.pl >
lexicon/clex_lexicon.pl
sh make_exe.sh

(as shown in the README of https://github.com/Attempto/Clex)

An even better option is to provide only the lexicon entries that are
needed to parse the given input (using "ulextext"). This way APE does
not need to parse the whole lexicon every time when it is called.
Also, there is no need to compile any entries into the APE executable.
This is the approach taken in ACE View and AceWiki which manage the
complete lexicon entries in their application-specific database.

Best,
Kaarel

On Sat, Feb 21, 2015 at 12:02 AM, Mohammed Nasri
<mohammed.nasri at gmail.com> wrote:
> Hi,
>
> As described in the mail subject, I want to use my own clex file. I then run
> the following command :
>
> APE_Path/ape -ulexfile CLEX_PATH/my_own_clex.pl -text "John eats an apple."
> -solo drs
>
> But I get this error message : ERROR: error(resource_error(stack),global)
>
> Do someone have any suggestions ?
>
> I also add the -noclex option before -ulexfile but still the same error.
>
> For information, I use APE 6.6-110816 (The latest I think), and my own clex
> file was downloaded from : https://github.com/Attempto/Clex
>
> Thank you.
>
> ---------------
> Sincères salutations
> Mohammed NASRI
>
> _______________________________________________
> attempto mailing list
> attempto at lists.ifi.uzh.ch
> https://lists.ifi.uzh.ch/listinfo/attempto
>


More information about the attempto mailing list