Templates
A template is a pattern with slots to be filled in.
In computer language recognition, one can apply templates in two modes:
Terms:
In a "classical" template system, attributes are determined by their location in relation to some "base datum".
In recognition mode, the computer determines what the attribute is from where it occurs in the "pattern" currently being examined. It "reads" the attribute's value at this location.
(In the "bubble-sheet" example, the value is yes/no, depending on whether the bubble is blackened or not. In the HTML form example, the value is text that has been filled in by the user.)
In generation mode, the computer "somehow" assigns a value to the attribute.
A simple example of this is when a user signs in to an on-line site. The login mechanism retrieve the user's profile elements and puts the contents into a form for display.