Skip to content

Coreference

Go back to the Sentence Object.

Coreference Object

KEYTYPEDESCRIPTIONCONSTRAINTS
sourcestringsource word that makes the coreference query-
indexintindex of the source wordindex >= 0
precisionfloatprecision indices based on how the algorithm found the coreference. Higher is better0 <= precision <= 1
referenceReference Objectdescribes the best match for the coreference query

Reference Object

KEYTYPEDESCRIPTIONCONSTRAINTS
sourcestringsource word of the reference object-
lemmastringlemma of the reference-
idintdatabase id of the referenceid > 0. Unique for each reference object created
categorylist of stringreference's categories-
category_parentlist of stringparent categories of reference's categories

import Tabs from '@theme/Tabs'; import TabItem from '@theme/TabItem';

<Tabs> <TabItem value="py" label="Python">

[
    {
        "index": 0,
        "precision": 0.3,
        "reference":
        {
            "category":
            [
                "human"
            ],
            "category_parent":
            [
                "PERSON"
            ],
            "id": 0,
            "lemma": "USER",
            "source": "USER"
        },
        "source": "je"
    },
    {
        "index": 1,
        "precision": 0.6,
        "reference":
        {
            "category":
            [
                "dog"
            ],
            "category_parent":
            [
                "ANIMAL"
            ],
            "id": 179,
            "lemma": "chien",
            "source": "chien"
        },
    "source": "le"
    }
]

</TabItem> <TabItem value="json" label="JSON">

[
	{
		"index": 0,
		"precision": 0.3,
		"reference": {
			"category": ["human"],
			"category_parent": ["PERSON"],
			"id": 0,
			"lemma": "USER",
			"source": "USER"
		},
		"source": "je"
	},
	{
		"index": 1,
		"precision": 0.6,
		"reference": {
			"category": ["dog"],
			"category_parent": ["ANIMAL"],
			"id": 179,
			"lemma": "chien",
			"source": "chien"
		},
		"source": "le"
	}
]

</TabItem> </Tabs>

register-sticky