|
Code 9. Syntax and semantics of sublanguage for context-based version. |
| |
#com give/open, box, combination, allen, adjustable, special
give me ?the *type_and_size: p4[1],p4[2]
give me ?the *big_little adjustable ?wrench: 5,p4
give me ?the special ?wrench: 6,0
#com take/open, box, combination, allen, adjustable, special
take away ?the *type_and_size: p4[1],p4[2]
take away ?the *big_little adjustable ?wrench: 5,p4
take away ?the special ?wrench: 6,0
take away ?the *type ?wrench: p4,0
take ?the wrench away: 0,0
take it away: 0,0
#def type_and_size
open end ?wrench ?size *size: 1,p5
box end ?wrench ?size *size: 2,p5
combination ?wrench ?size *size: 3,p4
*allen ?wrench ?size *sizeallen: 4,p4
#def type
open end: 1
box end: 2
combination: 3
*allen: 4
adjustable: 5
special: 6
#def allen
allen
hex
#def size
ten: 10
twelve: 12
fourteen: 14
seventeen: 17
#def sizeallen
eight: 8
ten: 10
twelve: 12
#def big_little
big: 1
little: 2
|