# ====================================== # TIME # ====================================== Rule "test 17:00" Match: [orth~"([012][0-9]|[1-9]):([0-6][0-9])"]; Eval: group(ne_TIME, 1); # ====================================== # DATES # ====================================== Rule "day number two digits" Match: [orth~"(0?[1-9]|[12][0-9]|3[01])"]; Eval: group(at_DAY_OF_MONTH_NUMBER, 1); Rule "ORDINAL as day number" Match: [orth~"(0?[1-9]|[12][0-9]|3[01]).*" && type~"ORDINAL"]; Eval: group(at_DAY_OF_MONTH_NUMBER, 1); Rule "year number four digits" Match: [orth~"(19[0-9][0-9]|2[01][0-9][0-9])"]; Eval: group(at_YEAR_NUMBER, 1); Rule "date: number MONTH_NAME year" Match: [type~"at_DAY_OF_MONTH_NUMBER"] [type~"MONTH_NAME"] [type~"at_YEAR_NUMBER"]?; Eval: group(ne_DATE, 1); # ======================================= # PERSON # ======================================= Rule "person: first_name and upper case" Match: [type~"FIRST_NAME"] [orth~"[A-Z].*"]; Eval: group(ne_PERSON, 1); # ======================================= # Testing purposes # ======================================= Rule "city: city of XXX" Match: [orth~"city"/i] [orth~"of"/i] [type~"CITY"]; Eval: group(ne_CITY, 3);