683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
|
print(" MATCH: @" + sRegex)
yield dGraph[dNode["<re_morph>"][sRegex]]
# token tags
if "tags" in dToken and "<tags>" in dNode:
for sTag in dNode["<tags>"]:
if sTag in dToken["tags"]:
if bDebug:
print(" MATCH: $" + sTag)
yield dGraph[dNode["<tags>"][sTag]]
# meta arc (for token type)
if "<meta>" in dNode:
for sMeta in dNode["<meta>"]:
# not regex here, we just search if <dNode["sType"]> exists within <sMeta>
if sMeta == "*":
if bDebug:
|
|
|
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
|
print(" MATCH: @" + sRegex)
yield dGraph[dNode["<re_morph>"][sRegex]]
# token tags
if "tags" in dToken and "<tags>" in dNode:
for sTag in dNode["<tags>"]:
if sTag in dToken["tags"]:
if bDebug:
print(" MATCH: /" + sTag)
yield dGraph[dNode["<tags>"][sTag]]
# meta arc (for token type)
if "<meta>" in dNode:
for sMeta in dNode["<meta>"]:
# not regex here, we just search if <dNode["sType"]> exists within <sMeta>
if sMeta == "*":
if bDebug:
|