[developers] spanish grammar/TDL documentation strings
Francis Bond
fcbond at gmail.com
Wed Nov 21 07:53:39 CET 2007
G'day,
I would be happy with either of the examples Emily showed.
On Nov 21, 2007 2:25 PM, Emily M. Bender <ebender at u.washington.edu> wrote:
> Sounds good to me, especially if the doc strings are allowed
> to span multiple comment lines, so long as they are continguous.
>
> For clarification, would it be:
>
> type-name := supertype1 & supertype2 & supertype 3 &
> ; documentation string
> ; more of the documentation string
> [ constraints ].
>
> or
>
> type-name :=
> ; documentation string
> ; more of the documentation string
> supertype1 & supertype2 & supertype 3 &
> [ constraints ].
>
> And separately, I'm sure that allowing comments mid-type-definition
> will be very much appreciated. For one thing, it will make it
> easier to debug by tinkering with particular constraints on
> types with large definitions...
Amen to that.
While we are talking of grammar documentation, ...
Within Jacy, and in consultation with the ERG and Norsource,
we (Chikara and I with I think with buy-in from Dan and Lars)
have been adding extra structure inside the comments.
The hope is that that the structure is minimilist enough
that grammar writers will be prepared to use it, but informative
enough that we can present it nicely. If the comment is moved
inside the type (currently we place them just before the type),
we could possibly also lose the <type>/<type> markup.
An example from within Jacy:
; <type val="ordinary-nohon-n-lex">
; <name-ja>普通名詞
; <name-en>Common Noun
; <description>Normal Japanese noun. Prototypically heads case-marked
phrases. Doesn't inflect.
; <ex>犬 が 吠える
; <ex>猫 の 犬 で ある
; <nex>犬 する
; <todo>
; </type>
<ex>Is an example that should parse with this type; <nex> is an
example that shouldn't.
We use this to prepare more human readable documentation, currently
for lexical types,
allthough we intend to also document rules.
The on-line documentation for JACY should be visible to the world
sometime soon,
along with the perl code and lisp patches to make it happen for other
grammars.
We combine the documentation with examples and frequency counts from
the lexicon
and treebanks to give a more informative picture
(see http://www2.nict.go.jp/x/x161/en/member/bond/pubs/2005-linc-lextypedb.pdf
for more information on an earlier version).
--
Francis Bond <http://www2.nict.go.jp/x/x161/en/member/bond/>
NICT Computational Linguistics Group
P.S. Actually in Japanese:
; <type val="ordinary-nohon-n-lex">
; <name-ja>普通名詞
; <description>日本語で一般的に普通名詞とよばれるもの。助詞を伴って主語・述語・目的語などになることができる。
; 活用はしない。
; <ex>犬 が 吠える
; <ex>猫 の 犬 で ある
; <nex>犬 する
; <todo>
; </type>
More information about the developers
mailing list