Skip to content

Event/entity filtering from AMR output #208

@elizlee

Description

@elizlee
  • Events: ignore events with uninformative PB frames, e.g. "to be" (be-02), "to have" (have-03)
    Example:
"event": {
                    "text": "have",
                    "mention_id": null,
                    "entity": null,
                    "doc_id": "L0C04CA23",
                    "span": [
                        304,
                        338
                    ],
                    "confidence": 0.6699219935060171,
                    "qnode_id": "Q76664561",
                    "description": "to experience something, to be a target of something",
                    "from_query": "have-org-role-91"
                },
  • Events: prevent duplicate events in the same claim sentence
    Example:
{
                "event": {
                    "text": "saying",
                    "mention_id": null,
                    "entity": null,
                    "doc_id": "L0C04CA23",
                    "span": [
                        1153,
                        1161
                    ],
                    "confidence": 0.8630922945557871,
                    "qnode_id": "Q3026787",
                    "description": "short, usually meaningful phrase, such as a maxim, proverb, motto, or adage",
                    "from_query": "say-01"
                },
                "args": {}
            },
            {
                "event": {
                    "text": "saying",
                    "mention_id": null,
                    "entity": null,
                    "doc_id": "L0C04CA23",
                    "span": [
                        1153,
                        1161
                    ],
                    "confidence": 0.8630922945557871,
                    "qnode_id": "Q3026787",
                    "description": "short, usually meaningful phrase, such as a maxim, proverb, motto, or adage",
                    "from_query": "say-01"
                },
                "args": {}
            },
  • Entities: ignore arguments with PB labels, which imply that they are events and not entities
    Example:
"A0": {
                        "type": {
                            "text": "research",
                            "mention_id": null,
                            "entity": null,
                            "doc_id": "L0C04CA23",
                            "span": [
                                283,
                                293
                            ],
                            "confidence": 1.0,
                            "qnode_id": "Q42240",
                            "description": "systematic study undertaken to increase knowledge",
                            "from_query": "research-01"
                        }
                    }

Examples are from /nas/gaia/users/elee/phase3_test/cdse_dryrun_id_match/WORKING/en/isi_ttl_output/output.json.
Reproduce by running the cdse-covid pipeline with input /nas/gaia/users/elee/phase3_test/cdse_dryrun_id_match/WORKING/en/ttl_output/claim_all.json through all steps until convert_claims_to_json.py is finished. Observe the json output.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions