Constraint Grammar Manual
Next
Constraint Grammar Manual
3rd version of the CG formalism variant
Mr
.
Tino
Didriksen
GrammarSoft ApS
<
tino@didriksen.cc
>
Copyright © 2007-2010 GrammarSoft ApS
Table of Contents
1. Intro
Caveat Emptor
What this is...
Naming
Unicode
Dicussion, Mailing Lists, Bug Reports, etc...
2. License
GNU General Public License
Open Source Exception
Commercial/Proprietary License
3. Installation & Updating
Ubuntu / Debian
Fedora / Red Hat
Installing ICU
Getting & Compiling VISL CG-3
Updating VISL CG-3
Regression Testing
Cygwin
4. Contributing & Subversion Access
5. Compatibility and Incompatibilities
Gotcha's
Magic Readings
NOT and NEGATE
PREFERRED-TARGETS
Default Codepage / Encoding
Set Operator -
Scanning Past Point of Origin
>>> and <<<
Rule Application Order
Endless Loops
Visibility of Mapped Tags
Incompatibilites
Mappings
Baseforms & Mixed Input
6. Command Line Reference
vislcg3
cg-comp
cg-proc
cg3-autobin.pl
7. Grammar
INCLUDE
Sections
BEFORE-SECTIONS
SECTION
AFTER-SECTIONS
NULL-SECTION
Ordering of sections in grammar
--sections with ranges
8. Rules
DELIMIT
SUBSTITUTE
Named Rules
Rule Options
NEAREST
ALLOWLOOP
ALLOWCROSS
DELAYED
IMMEDIATE
LOOKDELAYED
LOOKDELETED
UNSAFE
SAFE
REMEMBERX
RESETX
KEEPORDER
VARYORDER
ENCL_INNER
ENCL_OUTER
ENCL_FINAL
ENCL_ANY
9. Contextual Tests
Position Element Order
NEGATE
CBARRIER
Spanning Window Boundaries
Span Both
Span Left
Span Right
X Marks the Spot
Set Mark
Jump to Mark
Attach To
Test Deleted/Delayed Readings
Look at Deleted Readings
Look at Delayed Readings
Scanning Past Point of Origin
--no-pass-origin, -o
No Pass Origin
Pass Origin
Nearest Neighbor
Dependencies
Relations
10. Parenthesis Enclosures
Example
Contextual Position L
Contextual Position R
Magic Tag _LEFT_
Magic Tag _RIGHT_
Magic Set _LEFT_
Magic Set _RIGHT_
Magic Set _PAREN_
11. Making use of Dependencies
SETPARENT
SETCHILD
Existing Trees in Input
Creating Trees from Grammar
Contextual Tests
Parent
Children
Siblings
Self
Deep Scan
All Scan
None Scan
12. Making use of Relations
ADDRELATION, ADDRELATIONS
SETRELATION, SETRELATIONS
REMRELATION, REMRELATIONS
Existing Relations in Input
Contextual Tests
Specific Relation
Any Relation
All Scan
None Scan
13. Making use of Probabilistic / Statistic Input
14. Templates
15. Sets
(*)
_S_DELIMITERS_
_S_SOFT_DELIMITERS_
Magic Set _TARGET_
Magic Set _MARK_
Magic Set _ATTACHTO_
Tag Unification
Top-Level Set Unification
16. Tags
Tag Order
Literal String Modifiers
Variable Strings
Numerical Matches
Tag Inversion
Fail-Fast Tag
17. Binary Grammars
Security of Binary vs. Textual
Loading Speed of Binary Grammars
How to...
Incompatibilities
vislcg / bincg / gencg
--grammar-info, --grammar-out, --statistics
18. Input Stream Commands
Exit
Flush
Ignore
Resume
19. Constraint Grammar Glossary
Baseform
Cohort
Contextual Target
Contextual Test
Dependency
Disambiguation Window
Mapping Tag
Mapping Prefix
Reading
Rule
Set
Tag
Wordform
20. Constraint Grammar Keywords
ADD
ADDRELATION
ADDRELATIONS
AFTER-SECTIONS
ALL
AND
APPEND
BARRIER
BEFORE-SECTIONS
CBARRIER
CONSTRAINTS
CORRECTIONS
DELIMIT
DELIMITERS
END
IF
IFF
INCLUDE
LINK
LIST
MAP
MAPPINGS
MAPPING-PREFIX
NEGATE
NONE
NOT
NULL-SECTION
PREFERRED-TARGETS
REMOVE
REMRELATION
REMRELATIONS
REPLACE
SECTION
SELECT
SET
SETCHILD
SETPARENT
SETRELATION
SETRELATIONS
SETS
SOFT-DELIMITERS
SUBSTITUTE
TARGET
TEMPLATE
TO
21. Drafting Board
Unifying Mapping Tags
MOVE, SWITCH
MATCH
ANCHOR, JUMP, EXECUTE
SETVARIABLE, REMVARIABLE
References
Index
List of Tables
16.1.
Valid Operators
16.2.
Comparison Truth Table