diff options
| author | aarne <unknown> | 2004-09-16 14:47:18 +0000 |
|---|---|---|
| committer | aarne <unknown> | 2004-09-16 14:47:18 +0000 |
| commit | ecc132dccfc7617ed413f21ee37539475081f8ec (patch) | |
| tree | f6fe589eb3881e36b9a94d36aaba49fe4d4087e4 /grammars/video/README | |
| parent | 7769d0fb00a34fb4499017a4aec01a59246b69a1 (diff) | |
Karin C's example
Diffstat (limited to 'grammars/video/README')
| -rw-r--r-- | grammars/video/README | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/grammars/video/README b/grammars/video/README new file mode 100644 index 000000000..796a2c08a --- /dev/null +++ b/grammars/video/README @@ -0,0 +1,53 @@ +Video dialogue grammars by Karin Cavallin. + +Reconstructed in GF 2 with multiple inheritance. AR 16/9/2004 + +Example usage (test Swedish generation and parsing, and Prolog +generation) + + > i allSwe.gf + > i allProlog.gf + + > gr -cat=DMove | l -tr -lang=allSwe | p -cat=DMove -lang=allSwe | l -lang=allProlog + vill du använda svenska eller engelska + ask ([language (X)]) + +The intended use of that grammar is in dialogue systems to program a +video recorder. Queries in Swedish are translated to Prolog. + +The original grammar is written in GF 1.2 and includes. There is a +very nice modular structure, which could not be reproduced with the +single inheritance straightjacket of GF 2.0. But now we can finally +do this again! + + +Map of abstract syntax inheritances. + + all + / \ + / \ + specUser specSystem + / \ / \ + genUser specific genSystem + | / | | \ | + | / | | \ | + | / channel time weekday | + | | | + | | | + -----general ------------------ + + +The map was obtained by: + +grep abstract *.gf */*.gf + +all.gf:abstract all = specUser,specSystem ** { +Channel/channel.gf:abstract channel = { +Shared/general.gf:abstract general = { +Shared/specific.gf:abstract specific = general, weekday, time, channel ** { +System/genSystem.gf:abstract genSystem = general ** { +System/specSystem.gf:abstract specSystem = specific, genSystem ** { +Time/time.gf:abstract time = { +User/genUser.gf:abstract genUser = general ** { +User/specUser.gf:abstract specUser = specific, genUser ** { +Weekday/weekday.gf:abstract weekday = { |
