[developers] Expanding a grammar with defaults

Francis Bond fcbond at gmail.com
Thu Feb 26 05:03:20 CET 2009

2009/2/26 Francis Bond <fcbond at gmail.com>

> G'day,
> we want to use the KRG, which uses defaults, with PET.  Does anyone know
> how to dump a version of the grammar with the defaults expanded out so that
> we can flop it?

Actually, I have asked this before, and was pointed to

I think we need something like:

 (defun output-all-for-pet (&optional dir)
  (setf dir (cond (dir (get-directory-name dir))
#+:allegro        ((sys:getenv "LKB_OUTPUT_DIR")
           (get-directory-name (sys:getenv "LKB_OUTPUT_DIR")))
          (t "./")))
  (output-types :tdl (concatenate 'string dir "exp-types.tdl"))
  (output-lex :tdl (concatenate 'string dir "exp-lexicon.tdl")
  (output-grules :tdl (concatenate 'string dir "exp-grules.tdl")))

So, unless anyone has done this recently and knows all the answers, we can
probably forge ahead with this for now, ...

Francis Bond <http://www2.nict.go.jp/x/x161/en/member/bond/>
NICT Language Infrastructure Group
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.delph-in.net/archives/developers/attachments/20090226/cf8da0c1/attachment.html>

More information about the developers mailing list