penman.models.amr

AMR semantic model definition.

penman.models.amr.model = <penman.model.Model object>

The AMR model is an instance of Model using the roles, normalizations, and reifications defined in this module.

penman.models.amr.roles = {':ARG0': {'type': 'frame'}, ':ARG1': {'type': 'frame'}, ':ARG2': {'type': 'frame'}, ':ARG3': {'type': 'frame'}, ':ARG4': {'type': 'frame'}, ':ARG5': {'type': 'frame'}, ':accompanier': {'type': 'general'}, ':age': {'type': 'general'}, ':beneficiary': {'type': 'general'}, ':calendar': {'type': 'date'}, ':cause': {'shortcut': True, 'type': 'general'}, ':century': {'type': 'date'}, ':concession': {'type': 'general'}, ':condition': {'type': 'general'}, ':conj-as-if': {'type': 'conjunction'}, ':consist-of': {'type': 'general'}, ':cost': {'shortcut': True, 'type': 'general'}, ':day': {'type': 'date'}, ':dayperiod': {'type': 'date'}, ':decade': {'type': 'date'}, ':degree': {'type': 'general'}, ':destination': {'type': 'general'}, ':direction': {'type': 'general'}, ':domain': {'type': 'general'}, ':duration': {'type': 'general'}, ':employed-by': {'shortcut': True, 'type': 'general'}, ':era': {'type': 'date'}, ':example': {'type': 'general'}, ':extent': {'type': 'general'}, ':frequency': {'type': 'general'}, ':instrument': {'type': 'general'}, ':li': {'type': 'general'}, ':location': {'type': 'general'}, ':manner': {'type': 'general'}, ':meaning': {'shortcut': True, 'type': 'general'}, ':medium': {'type': 'general'}, ':mod': {'type': 'general'}, ':mode': {'type': 'general'}, ':month': {'type': 'date'}, ':name': {'type': 'general'}, ':op[0-9]:': {'type': 'op'}, ':ord': {'type': 'general'}, ':part': {'type': 'general'}, ':path': {'type': 'general'}, ':polarity': {'type': 'general'}, ':polite': {'type': 'general'}, ':poss': {'type': 'general'}, ':prep-against': {'type': 'preposition'}, ':prep-along-with': {'type': 'preposition'}, ':prep-amid': {'type': 'preposition'}, ':prep-among': {'type': 'preposition'}, ':prep-as': {'type': 'preposition'}, ':prep-at': {'type': 'preposition'}, ':prep-by': {'type': 'preposition'}, ':prep-for': {'type': 'preposition'}, ':prep-from': {'type': 'preposition'}, ':prep-in': {'type': 'preposition'}, ':prep-in-addition-to': {'type': 'preposition'}, ':prep-into': {'type': 'preposition'}, ':prep-on': {'type': 'preposition'}, ':prep-on-behalf-of': {'type': 'preposition'}, ':prep-out-of': {'type': 'preposition'}, ':prep-to': {'type': 'preposition'}, ':prep-toward': {'type': 'preposition'}, ':prep-under': {'type': 'preposition'}, ':prep-with': {'type': 'preposition'}, ':prep-without': {'type': 'preposition'}, ':purpose': {'type': 'general'}, ':quant': {'type': 'quantity'}, ':quarter': {'type': 'date'}, ':role': {'shortcut': True, 'type': 'general'}, ':scale': {'type': 'quantity'}, ':season': {'type': 'date'}, ':snt[0-9]:': {'type': 'snt'}, ':source': {'type': 'general'}, ':subevent': {'type': 'general'}, ':subset': {'shortcut': True, 'type': 'general'}, ':superset': {'shortcut': True, 'type': 'general'}, ':time': {'type': 'general'}, ':timezone': {'type': 'date'}, ':topic': {'type': 'general'}, ':unit': {'type': 'quantity'}, ':value': {'type': 'general'}, ':weekday': {'type': 'date'}, ':year': {'type': 'date'}, ':year2': {'type': 'date'}}

The roles are the edge labels of reifications. The purpose of roles in a Model is mainly to define the set of valid roles, but they map to arbitrary data which is not used by the Model but may be inspected or used by client code.

penman.models.amr.normalizations = {':domain-of': ':mod', ':mod-of': ':domain'}

Normalizations are like role aliases. If the left side of the normalization is encountered by Model.canonicalize_role() then it is replaced with the right side.

penman.models.amr.reifications = [(':accompanier', 'accompany-01', ':ARG0', ':ARG1'), (':age', 'age-01', ':ARG1', ':ARG2'), (':beneficiary', 'benefit-01', ':ARG0', ':ARG1'), (':beneficiary', 'receive-01', ':ARG2', ':ARG0'), (':cause', 'cause-01', ':ARG1', ':ARG0'), (':concession', 'have-concession-91', ':ARG1', ':ARG2'), (':condition', 'have-condition-91', ':ARG1', ':ARG2'), (':cost', 'cost-01', ':ARG1', ':ARG2'), (':degree', 'have-degree-92', ':ARG1', ':ARG2'), (':destination', 'be-destined-for-91', ':ARG1', ':ARG2'), (':duration', 'last-01', ':ARG1', ':ARG2'), (':employed-by', 'have-org-role-91', ':ARG0', ':ARG1'), (':example', 'exemplify-01', ':ARG0', ':ARG1'), (':extent', 'have-extent-91', ':ARG1', ':ARG2'), (':frequency', 'have-frequency-91', ':ARG1', ':ARG2'), (':instrument', 'have-instrument-91', ':ARG1', ':ARG2'), (':li', 'have-li-91', ':ARG1', ':ARG2'), (':location', 'be-located-at-91', ':ARG1', ':ARG2'), (':manner', 'have-manner-91', ':ARG1', ':ARG2'), (':meaning', 'mean-01', ':ARG1', ':ARG2'), (':mod', 'have-mod-91', ':ARG1', ':ARG2'), (':name', 'have-name-91', ':ARG1', ':ARG2'), (':ord', 'have-ord-91', ':ARG1', ':ARG2'), (':part', 'have-part-91', ':ARG1', ':ARG2'), (':polarity', 'have-polarity-91', ':ARG1', ':ARG2'), (':poss', 'own-01', ':ARG0', ':ARG1'), (':poss', 'have-03', ':ARG0', ':ARG1'), (':purpose', 'have-purpose-91', ':ARG1', ':ARG2'), (':role', 'have-org-role-91', ':ARG0', ':ARG2'), (':source', 'be-from-91', ':ARG1', ':ARG2'), (':subevent', 'have-subevent-91', ':ARG1', ':ARG2'), (':subset', 'include-91', ':ARG2', ':ARG1'), (':superset', 'include-91', ':ARG1', ':ARG2'), (':time', 'be-temporally-at-91', ':ARG1', ':ARG2'), (':topic', 'concern-02', ':ARG0', ':ARG1'), (':value', 'have-value-91', ':ARG1', ':ARG2'), (':quant', 'have-quant-91', ':ARG1', ':ARG2')]

Reifications are a particular kind of transformation that replaces an edge relation with a new node and two outgoing edge relations, one inverted. They are used when the edge needs to behave as a node, e.g., to be modified or focused.