Summary
glazing xref extract aborts with:
✗ Error: Unknown lexlink resource type: VerbNet
(and the symmetric Unknown rolelink resource type: VerbNet for role-level links).
Root cause
In src/glazing/references/extractor.py, _index_propbank_mappings normalizes FrameNet's capitalization variants but matches VerbNet only in lowercase:
# lexlinks (~line 302)
if lexlink.resource == "verbnet": # lowercase only
target_dataset = "verbnet"
elif lexlink.resource in ["FrameNet", "Framenet"]:
target_dataset = "framenet"
else:
raise ValueError(f"Unknown lexlink resource type: {lexlink.resource}")
# rolelinks (~line 335) — same asymmetry
if rolelink.resource == "verbnet":
...
elif rolelink.resource in ["FrameNet", "Framenet", "framenet"]:
...
else:
raise ValueError(f"Unknown rolelink resource type: {rolelink.resource}")
But the PropBank frame files overwhelmingly use the capitalized form. In propbank-frames/frames/*.xml:
39821 resource="VerbNet"
11322 resource="FrameNet"
11211 resource="AMR"
56053 resource="PropBank"
4 resource="Framenet"
And src/glazing/types.py explicitly lists "VerbNet" (capitalized) as a valid ResourceType ("Variant capitalization found in some files"). So a VerbNet lex/rolelink is well-typed data that the extractor nonetheless rejects, falling through to the else and raising.
Reproduction
glazing init
glazing xref extract
# ValueError: Unknown lexlink resource type: VerbNet
Impact
xref extract cannot complete on the standard SemLink-annotated PropBank frames, so no cross-reference index is produced. This blocks any downstream consumer of references/SemLink mappings.
Suggested fix
Normalize VerbNet the way FrameNet is normalized (both branches), e.g.:
if lexlink.resource in ("verbnet", "VerbNet", "Verbnet"):
target_dataset = "verbnet"
A case-insensitive comparison (or reusing a single normalization helper over the ResourceType variants declared in types.py) would also cover the AMR resource (11,211 occurrences), which would otherwise raise here as well.
Found on glazing==0.3.0.
Summary
glazing xref extractaborts with:(and the symmetric
Unknown rolelink resource type: VerbNetfor role-level links).Root cause
In
src/glazing/references/extractor.py,_index_propbank_mappingsnormalizes FrameNet's capitalization variants but matches VerbNet only in lowercase:But the PropBank frame files overwhelmingly use the capitalized form. In
propbank-frames/frames/*.xml:And
src/glazing/types.pyexplicitly lists"VerbNet"(capitalized) as a validResourceType("Variant capitalization found in some files"). So aVerbNetlex/rolelink is well-typed data that the extractor nonetheless rejects, falling through to theelseand raising.Reproduction
Impact
xref extractcannot complete on the standard SemLink-annotated PropBank frames, so no cross-reference index is produced. This blocks any downstream consumer ofreferences/SemLink mappings.Suggested fix
Normalize VerbNet the way FrameNet is normalized (both branches), e.g.:
A case-insensitive comparison (or reusing a single normalization helper over the
ResourceTypevariants declared intypes.py) would also cover theAMRresource (11,211 occurrences), which would otherwise raise here as well.Found on
glazing==0.3.0.