If it helps, these are brief notes I wrote for myself to help get my head round how this works:
An action needs two things to anchor it in the game world:
(i) a very basic description of how the action works in the game world → (e.g.) (Photographing) is an action applying to nothing/(one/two) (visible/touchable/carried/–) (thing(s)/value(s)) [and one…] [and requiring light].
NB confusingly, 'visible' here means 'anything the actor is allowed to refer to' (more formally, 'in scope for the actor') not the more usual 'visible to the actor'. So it includes for example the compass directions and even objects out-of-play if the scope rules judge them to be 'in scope' By default most objects not visible in the usual sense will be excluded from consideration by the scoping rules followed by grammar lines (see below), so there is usually a close but not complete alignment between 'in scope' and 'conventionally visible'. Without specifying 'visible/carried', 'touchable' is the default. 'carried' is a more restrictive form of 'touchable' and includes only things directly carried by the actor.
(ii) grammar line(s) to recognise the action in what is typed by the player and declare a (usually) more restricted scope for the objects and/or values the action can refer to. → (e.g) Understand “photograph [someone]” as photographing.
[somebody] / [someone] → synonyms == a person in scope for the actor => the [second] noun (rather than ‘the person understood’)
[something] / [thing] → synonyms == a thing in scope for the actor- thing here means Inform’s usual more restricted sense, not object, so excludes rooms, directions and regions
[things] → a list of one or more things in scope for the actor
[other things] → a list of one or more things in scope for the actor which are not the other thing mentioned (e.g. a container)
[things inside] → a list of one or more things in or on the other thing mentioned (e.g. a supporter/container)
[something preferably held] → as with [thing], but choose a held object over others with same name, try implied take if present but not held
[things preferably held] → as with [things], but choose a held object over others with same name, try implied take if present but not held
[text] → an unparsed sequence of words => a snippet called ‘the topic understood’ †
[a time period] → a period of time †† => a time called ‘the time understood’
[description of objects/values] → matching any description of objects ([open door]) within sight of the actor, or of values [even number]
→ [description of directions] references directions. NB directions are ‘visible’ but not ‘touchable’ (see above)
→ prefixing ‘any’ e.g. [any open door] removes the restriction that an object must be in scope for the actor (or, to think about it another way, brings all matching objects temporarily into scope for this action)
→ [any thing] will allow any thing, in or out of the game world == [anything]; similarly [anybody], [anyone]
→ [any (description of rooms)] allows reference to rooms, not otherwise mentionable in typed commands
→ [anywhere] == [any room]
→ the Index indicates which built-in values have a corresponding Understand token
=> for values, a value called ‘the (kind) understood’
=> for objects, the [second] noun
† this is something of an exception, for historical reasons, to the general ability to refer to a successfully-parsed grammar token as ‘the (kind) understood’, which here would otherwise be ‘the snippet understood’. Using ‘the noun’ and ‘the second noun’ to refer to the first and second object parsed are also exceptions. But we say for example ‘the number understood’ or ‘the time understood’ or ‘the colour understood’ for values. There is also ‘the person asked’ for constructions such as ‘Bob, open the box’.
NB it is also possible to extract values from the player’s command or other snippets through ‘if (snippet) includes “[kind of value]”’ following which ‘the (kind) understood’ contains the matched value. e.g. ‘if the player’s command includes “[number]”’ => (if matched) ‘the number understood’
†† this special token is provided because [a time], which follows the general [description of values] pattern, matches only specific times of day but does not match ‘21 minutes’ for example, even though this is also of kind time. However, the parsed value is still referred to as ‘the time understood’ rather than ‘the time period’ understood.