Representation of Verbs

This continues discussion from Adapting whatever verb the player has used in descriptive text but I thought it was getting a little threadjack-y to continue there. I had posted this bit of code to get I7’s representation of a verb given text containing the verb’s name:

To decide what verb is the null verb: (- nothing -).

To decide what verb is (T - a text) as a verb:
    let t be T in lower case;
    repeat with v running through verbs begin;
      if "verb [t]" is "[v]", decide on v;
    end repeat;
    decide on the null verb.

I’ve committed a couple of extensions to play with this… Verbs and Verbal Commands. “Verbs” is mostly just an improved version of the To decide what verb is... phrase above. Verbal Commands adds not-for-release commands: “verbs”, to list the adaptable verbs in play; “conjugate” to print their conjugation through the grammatical tenses and story viewpoints; and “meaning” to output what relation they correspond to, if any.

Details and oddities learned along the way: ni creates an I6 ConjugateVerb routine for every adaptable verb and the internal representation of verbs is that ConjugateVerb routine. When you repeat running through verbs as I did above, you’re iterating through the TableOfVerbs array that ni constructs. It apparently deliberately omits the contracted verbs defined in English Language, for reasons known only to itself. But, well, the order of the adaptable verbs you get by default is invariant, so in the Verbs extension I went ahead and hard-coded them:

To decide what verb is 're-verb: (- ConjugateVerb_74 -)

etc., and added them and the TableOfVerbs entries into an all-verbs list of verbs variable I could loop through, which is ugly but seems to work (though I’d more or less expect it to break upon the next I7 release).

Verbs have the default meaning Rel_Record_0, the equality relation. In fact, the VerbIsMeaningful routine the Standard rules uses as the definition of whether a verb is meaningful or meaningless simply tests for whether the meaning is Rel_Record_0. Thus if you test it, the verb “to be” is meaningless. And if you showme the meaning of a for-saying-only verb, you’re told it means the equality relation. (Verbal Commands’ meanings command codes around this.)

For verbs whose meaning is a property, showme the meaning of outputs “relation of objects: relation”. (Verbal Commands doesn’t attempt to code around this, 'cause I didn’t think it was worth the dependency on Text Capture it would take to intercept and interpret the showme output.)

These are the default adaptable verbs, by the way:

're, 've, achieve, appreciate, aren’t, arrive, be, be able to, be able to see, be able to touch, can’t, care, carry, close, conceal, contain, could, couldn’t, die, discover, do, don’t, drop, eat, enclose, feel, find, get, give, go, happen, have, haven’t, hear, hold, incorporate, jump, lack, lead, like, listen, lock, look, may, mayn’t, mean, might, mightn’t, must, mustn’t, need, open, pass, pick, provide, provoke, pull, push, put, relate, rub, say, search, see, seem, set, should, shouldn’t, smell, sniff, squeeze, support, switch, take, talk, taste, touch, turn, unlock, wait, wave, wear, win, won’t, would and wouldn’t

There are 86 listed there. auxiliary-have has its own representation at ConjugateVerb_1 independent of regular have; this is also omitted from the TableOfVerbs and the Verbs extension doesn’t add it. So a default game has routines for ConjugateVerb_0 through ConjugateVerb_86. [Edited: noticed an off-by-one error in what I’d written, which led me to noticing I’d missed adding “won’t” to all-verbs.]

6 Likes

Some further notes… if you check, you’ll see there’s a lot the list above does not have in common with the verbs page of the Project Index. The Project Index omits the contractions and lists lots of different forms of relation-verbs. This is what seems to be true:

You can add a for-saying-only verb with an auxiliary to have, but not an auxiliary to be.

To be heard is a verb. [won't compile]
To have a heart is a verb. [just fine]

You can use an auxiliary to be in property/relation verbs, but it won’t really be a verb in the same sense as the others: you can use it in your source, but it doesn’t get a ConjugateVerb routine, and can’t be used in adaptive text.

1 Like