-
Notifications
You must be signed in to change notification settings - Fork 4
SmafPet
The SML XML interface to PET is enabled via the -tok=smaf option to PET.
SMAF XML can be sent directly to the PET input stream. Eg.
<smaf>
<lattice init='v0' final='v2'>
<edge type='pos' id='p1' deps='t1'><slot name="tag">NP1</slot></edge>
<edge type='token' id='t2' cfrom='2' cto='4' source='v1' target='v2'>go</edge>
<edge type='token' id='t1' cfrom='0' cto='1' source='v0' target='v1'>i</edge>
</lattice>
</smaf>
Alternatively the SMAF XML may be provided as the contents of a file. Syntax: '@' + FILENAME. Eg.
~/tmp/sample.smaf
SMAF configuration support (as in the LKB) is currently pending. At present only two, hard-coded, edge types are handled, allowing a simple token lattice in which tokens are optionally paired with POS tags.
-
type='token' where the token string is either the text-content of the XML element, or the contents of the surface slot;
-
type='pos' where the deps attribute points to a single token, and the tag specified via either the text-content of the XML element, or the contents of the tag slot.
Home | Forum | Discussions | Events