Specific pattern matching for Kinds of Phrases

Here’s this stuff again, involving variables of kind “phrase (object, object) → pseudotruth state”. The tricky part is at the very end.

"Thought and Conversation Demo" by Matt Weiner



Use American dialect and the serial comma.

Front Parlor is a room. Jane is a woman in Front Parlor. Hartington is a man in Front Parlor. Alfred is a man in Front Parlor. The player is Alfred. Eliza is a woman in Front Parlor. Annie is a woman in Front Parlor.

The table is a supporter in the Front Parlor. The cat is on the table. The knife is in the Front Parlor.

A pseudotruth state is a kind of value. The pseudotruth states are oui and non.
	
To decide which pseudotruth state is si (top - object) overtops (bottom - object) (this is overtopping):
	if top is on bottom, decide on oui;
	decide on non.

Table of Desires
Desirer 	first relatum (object)	pseudorelation	second relatum (object)	sign
Eliza	cat	overtopping	the table	false
Hartington	knife	overtopping	the table	true

Every turn: 
	repeat through the Table of Desires:
		if the sign entry is true: 
			if the pseudorelation entry applied to the first relatum entry and the second relatum entry is non:
				say "[The desirer entry] says, 'I say! [The first relatum entry] [negative text of the pseudorelation entry] [the second relatum entry]!'";
		otherwise [the sign entry is false]:
			if the pseudorelation entry applied to the first relatum entry and the second relatum entry is oui:
				say "[The desirer entry] says, 'I say! [The first relatum entry] [positive text of the pseudorelation entry] [the second relatum entry]!'".

To say negative text of (generic pseudorelation - phrase (object, object) -> pseudotruth state): say "isn't [generic pseudorelation][run paragraph on]". 
					
To say negative text of (generic pseudorelation - overtopping): say "isn't on[run paragraph on]".

To say positive text of (generic pseudorelation - phrase (object, object) -> pseudotruth state): say "is [generic pseudorelation][run paragraph on]".

To say positive text of (generic pseudorelation - overtopping): say "is on[run paragraph on]".

test me with "z".

(Using the “pseudotruth states” of “oui” and “non” is a workaround for a bug; see here.)

Now, if I read section 11.3 of the documentation correctly, the more specific say phrase for overtopping should override the less specific say phrase for phrase (object, object) → pseudotruth state. But this is not happening.

I’d like to be able to work around this with an activity (sometime I’ll probably need something more powerful than “say” phrases anyway), but I’m having an additional problem there; when I try something like this:

[code]Printing negative text of something is an activity on phrase (object, object) → pseudotruth state.

Printing positive text of something is an activity on phrase (object, object) → pseudotruth state.

Printing negative text of something is an activity on phrase (object, object) → pseudotruth state.

Printing positive text of something is an activity on phrase (object, object) → pseudotruth state.[/code]

it doesn’t compile:

I thought (from 17.5 of the documentation) that “(called [variable name])” was what you needed at the beginning of a rule for an activity, but maybe the parentheses in the kind name are throwing the compiler off.

Related, is there any way to abbreviate a kind name, so I could write something like “A phrase (object, object) → pseudotruth state is a pseudorelation” and then just use “pseudorelation”? At the very least it’d save some typing.

The first problem is bug 368. The second one looks new though. There isn’t, that I know of, any way to abbreviate kind names.

Thanks EU! I may be putting the kinds of phrases through a workout, which is a good thing, I guess. I’ll report the second one.