Re: [lkb] generation ranking in LKB
Stephan Oepen <[email protected]> Sat, 10 Jul 2010 12:00:55 +0200
| Newsgroups | gmane.comp.ai.lkb |
|---|---|
| Message-ID | <[email protected]> |
any number will activate n-best selective unpacking, so you can choose how many realizations you want returned (at most). as for the specific model, it's the ‘combined’ model from the EMNLP paper; however, just now i'm not sure the MEM file has been updated for the change in ERG rule identifiers. in principle, that model should be retrained, i guess. we have been a little slack about this in recent ERG releases ... cheers, oe On 10. juli 2010, at 11.44, Xuchen Yao <[email protected]> wrote: > Hi Stephan, > > Thanks for the reply! I wasn't taking advantage of this ranking > mechanism until your response. > > I've seen the big "bnc.blm" file at your prompt. May I further know > the actual ranking used is based on language models or MaxEnt? I > want to have an impression of how well it should work according to > the result of your original paper. > > BTW, The number "42" in > > (generate-from-mrs > (mrs::extract-mrs (first *parse-record*)) > :nanalyses 42) > > was a bit confusing at first but after digging into the code, I saw > you wanted to "have some cake and eat some", so I guess I should > always use "42" here.;-) > > Xuchen > > On 07/10/2010 11:15 AM, Stephan Oepen wrote: >> hi xuchen, >> >> i am assuming you are thinking of generation using the ERG here? the >> following lines in the `script' file enable realization ranking: >> >> #+(and :tsdb :logon) >> (tsdb::read-model (lkb-pathname (parent-directory) "jhpstg.g.mem")) >> #+(and :tsdb :logon) >> (setf *unpacking-scoring-hook* #'tsdb::mem-score-configuration) >> >> the reason this is only supported in the LOGON tree is its dependency >> on the CMU LM toolkit and the actual language model, which were >> deemed >> too space-consuming to be included in the general LKB SVN. >> >> so, assuming you are actually in the LOGON tree, you should be able >> to >> use realization ranking. it will be turned on by default when >> running >> in [incr tsdb()], i.e. batch generating. for interactive use, i >> think >> you would have to pass the optional :nanalyses argument. e.g. >> >> LKB(22): (do-parse-tty "kim gave the big angry dog a bone.") >> 720 >> 375 >> -1 >> 30937 >> 10 >> LKB(23): (generate-from-mrs >> (mrs::extract-mrs (first *parse-record*)) >> :nanalyses 42) >> ("Kim gave the angry big dog a bone." >> "Kim gave the big angry dog a bone." >> "Kim gave a bone to the angry big dog." >> "Kim gave a bone to the big angry dog.") >> 86312 >> 2780 >> 728 >> 3008 >> 800 >> 337 >> 635 >> LKB(24): (loop for edge in *gen-record* collect (edge-score edge)) >> (2.20243 1.8947849 1.7799873 1.4181345) >> >> too bad the adjective ordering ends up unnatural in this example, but >> the model appears to be doing something (useful). >> >> best - oe >> >> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ >> +++++++++++ >> +++ Universitetet i Oslo (IFI); Boks 1080 Blindern; 0316 Oslo; (+47) 2284 0125 >> +++ --- [email protected]; [email protected]; http://www.emmtee.net/oe/ >> --- >> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ >> +++++++++++ >>