Grew main page

Grew basic rules

A rewrite rule in grew is defined by

  • a pattern (with one positive any number of negative clauses),
  • a sequence of commands.

Rule example

rule accuser {
  match {
    V [cat=V, lemma="accuser"];
    O [];
    D [cat=D, lemma="de"];
    DO [cat=V, m = inf | part];
 
    V -[obj]-> O;
    V -[de_obj]-> D;
    D -[obj]-> DO
    }
  commands {
    add_edge DO -[suj]-> O
  }
}