Re: [lkb] Getting Parse results from LKB
Bernhard Fisseni <[email protected]> Tue, 17 Oct 2006 13:04:11 +0200
| Newsgroups | gmane.comp.ai.lkb |
|---|---|
| Organization | Institut für Kommunikationswissenschaf ten – Abteilung Sprache und Komunikation –, Rheinische Friedrich-Wilhelms-Universität Bon n |
| Message-ID | <[email protected]> |
Hi Stephan, thanks very much for the unofficial server/client scripts. I'll play a=20 bit with them this week; they're probably more trustworthy than my LISP=20 system hacking would be for the moment. Cheers, Bernhard Scripsit Stephan Oepen di=C4=93 17.10.2006 9:41: > hi again, bernhard, >=20 >> Unsetting DISPLAY does not work for me =E2=80=94 LKB generates an erro= r >> message saying that the display cannot be accessed; with DISPLAY set, >> a graphic tree is shown, even for "do-parse-tty". >=20 > apologies, i now see that the LKB with DISPLAY unset does not work the > way i thought it would. we should try fixing that at some point, i.e. > essentially drop back into tty mode when there is no DISPLAY (on Un*x). >=20 > i believe getting SBCL to work with GG seems like your best option for > now. however, your query (and the one by shuly) prompted me to dig up > some old notes on the undocumented LSP (linguistic server protocol) in > the LKB. essentially, there is a way of talking an ASCII protocol to > the LKB over a socket connection. =20 >=20 > the protocol is old-fashioned: sequences of strings (with C escapes), > numbers, and symbols (say in C identifier syntax) for now. a command > is terminated by a form feed character. optionally, commands can be > prefixed with `wait' to request synchronous execution. this mode is > required for all commands that expect (a) return value(s). for each > command (synchronous or not), the client will see a numerical success > code (preceded by whatever else the command returned) plus a trailing > form feed (to allow both ends to synchronize cleanly). a preliminary > list of (non-)success codes is at the top of `lkb/src/glue/lsp.lsp'. >=20 > if you wanted to experiment, please see `lsp.lsp'. i just confirmed > that basic functionality (parsing inputs and retrieving parse tree(s), > AVM(s), or MRS(s)) is there. assuming a functional LKB installation, > try the following: >=20 > - launch the `server' script attached below; this should initialize > an LKB sans-GUI, load the ERG, and go into LSP server mode. >=20 > - create a socket connection to port 4712 and send commands from the > file `client' attached below. if you have nc(1) installed, simply >=20 > cat /tmp/client - | /usr/bin/nc localhost 4712 >=20 > however, LSP currently only works with Allegro CL, i.e. you would have > to rely on our pre-compiled binaries for the above. also, please note > that LSP remains officially unsupported for the time being :-). >=20 > best - oe >=20 > +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++= ++++++++ > +++ Universitetet i Oslo (IFI); Boks 1080 Blindern; 0316 Oslo; (+47) 22= 84 0125 > +++ CSLI Stanford; Ventura Hall; Stanford, CA 94305; (+1 650) 723 0= 515 > +++ --- [email protected]; [email protected]; [email protected] --= - > +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++= ++++++++ >=20 --=20 Bernhard Fisseni Uni: Institut fuer Kommunikationswissenschaften -- Sprache und Kommunikation -- Poppelsdorfer Allee 47 -- 53115 Bonn Raum 115 -- +49-228-73-5653 zu Hause: Steinweg 32 -- 53121 Bonn-Endenich, D -- +49-228-6203949