Miscellaneous

Control:
Parser Operations


  1. Program Flow:

    Meta-level predicates that implement convenient program flow options.

  2. Constituent Structure:

    Predicates that are used to state universally and existentially-quantified conditions over constituent structure.

  3. Miscellaneous:

    Predicates that iterate over lists and feature sets.

  4. Parser Operations:

    Declaring parser operations.


Contents

lower_panel_display_order
parser_operation
upper_panel_display_order


lower_panel_display_order(+[O1..On]) Declares parser operations O1 through On should be displayed in the order listed in the lower panel on the right.

Note:lower_panel_display_order/1 must be present in the principles file.

Example: See upper_panel_display_order.


+Name parser_operation +DisplayName
  with_components
    io          given_by +Levels,
    dep         given_by +Operations,
    controlType given_by +Type,
    ...
Declares predicate Name to be a parser operation. DisplayName is the pretty print version of Name to be used on the PAPPI display. Obligatory and optional components determine the environment under which Name will be called and terminated.

Note: Parser operations must be defined in the principles file only.

Here are the possible components:

Component Obligatory Parameters Description
io Yes Levels Determines the I/O parameters for this parser operation. Levels should be a non-empty list draw from the following structure levels:
ss S-structure
lf LF

(Valid levels are defined in pStrategies.pl.)

The list determines the arity and order of the parameters for the predicate Name. For instance:

Example Levels Call Structure
A filter f operating at S-structure: [ss] f(SS)
An operation t that computes LFs from S-structure: [ss,lf] t(SS,LF)

dep Yes Operations Operations should be a list of parser operations that must precede Name. In other words, Name cannot be invoked until all these operations are completed.
controlType Yes Type Current valid control types are filter, assigner, and generator.

If Filter Backtrack Optimization is checked in the Tracing menu (see below), parser operations with control type filter will succeed only once.

sCueFilter No None Used for dynamic parser operation ordering.
multipleDeps No None Reserved.
skippable No None Reserved.

Example: See upper_panel_display_order for an example.


upper_panel_display_order(+[O1..On]) Declares parser operations O1 through On should be displayed in the order listed in the upper panel on the right.

Note:upper_panel_display_order/1 must be present in the principles file. Example:

To activate licenseNPI as a parser operation, carry out the following sequence of steps:

  1. Add the following declaration to the principles file:

    licenseNPI parser_operation 'NPI Licensing'
    	with_components
    		io          given_by [ss],
    		dep         given_by resolveTraces,
    		controlType given_by filter.
    

    This declares that licenseNPI operates as a filter at S-structure. The 'NPI Licensing' string will be used in the PAPPI display.

  2. To make the operation visible in the PAPPI display, add licenseNPI to the following declaration in the principles file:

    upper_panel_display_order( 
    [thetaCriterion, dStructureCondition, 
     subjacency, whInSyntax, 
     sBarDeletion, caseFilter, traceCaseCondition,
     coindexSubjAndINFL, 
     conditionA, conditionB, conditionC, 
     ecp, control,
     licenseClitics, licenseObjectPro, 
     licenseNPI,
     ecpLF, 
     licenseOpVars, quantifierScoping,
     reanalyzeBoundProforms,
     licenseClausalArguments, licenseAdjuncts, 
     whCompRequirement]).
    

    This inserts licenseNPI in the display just above ecpLF and below licenseObjectPro.

Miscellaneous