Skip to content

OpenSematicLab Model

Entity

Bases: OswBaseModel

Source code in src/osw/model/entity.py
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
class Entity(OswBaseModel):
    rdf_type: Optional[Set[str]] = Field(None, title="Additional RDF type(s)")
    """
    Declares additional type(s) for this entity, e.g., to state that this entity has the same meaning as a term in a controlled vocabulary or ontology. This property is synonymous to the schema:additionalType and owl:sameAs. The default syntax is ontology:TermName. The ontology prefix has to be defined in the @context of the Entity, the category or any of the parent categories. The term name has to be a valid identifier in the ontology.
    """
    uuid: UUID = Field(default_factory=uuid4, title="UUID")
    iri: Optional[str] = Field(None, title="IRI")
    """
    The Internationalized Resource Identifier (IRI) of this entity
    """
    name: Optional[str] = Field(None, title="Technical name")
    """
    Technical / Machine compatible name
    """
    label: List[Label] = Field(..., min_items=1, title="Label(s)")
    """
    At least one label is required.
    """
    short_name: Optional[List[Label]] = Field(None, title="Short name(s)")
    """
    Abbreviation, Acronym, etc.
    """
    query_label: Optional[str] = Field(None, title="Query label")
    description: Optional[List[Description]] = Field(None, title="Description")
    image: Optional[str] = Field(None, title="Image")
    ordering_categories: Optional[List[str]] = Field(None, title="Ordering categories")
    """
    Ordering categories are used to categorize instances, e.g., according to their use but not their properties. When querying for instances of a here listed ordering category, this instance will be returned. Note: Ordering categories define no properties, while 'regular' categories define properties, which an instance assigns values to.
    """
    keywords: Optional[List[str]] = Field(None, title="Keywords / Tags")
    """
    Designated to the user defined categorization of this element
    """
    based_on: Optional[List[str]] = Field(None, title="Based on")
    """
    Other entities on which this one is based, e.g. when it is created by copying
    """
    statements: Optional[
        List[Union[ObjectStatement, DataStatement, QuantityStatement]]
    ] = Field(None, title="Statements")
    attachments: Optional[List[str]] = Field(None, title="File attachments")
    meta: Optional[Meta] = None

based_on = Field(None, title='Based on') class-attribute instance-attribute

Other entities on which this one is based, e.g. when it is created by copying

iri = Field(None, title='IRI') class-attribute instance-attribute

The Internationalized Resource Identifier (IRI) of this entity

keywords = Field(None, title='Keywords / Tags') class-attribute instance-attribute

Designated to the user defined categorization of this element

label = Field(..., min_items=1, title='Label(s)') class-attribute instance-attribute

At least one label is required.

name = Field(None, title='Technical name') class-attribute instance-attribute

Technical / Machine compatible name

ordering_categories = Field(None, title='Ordering categories') class-attribute instance-attribute

Ordering categories are used to categorize instances, e.g., according to their use but not their properties. When querying for instances of a here listed ordering category, this instance will be returned. Note: Ordering categories define no properties, while 'regular' categories define properties, which an instance assigns values to.

rdf_type = Field(None, title='Additional RDF type(s)') class-attribute instance-attribute

Declares additional type(s) for this entity, e.g., to state that this entity has the same meaning as a term in a controlled vocabulary or ontology. This property is synonymous to the schema:additionalType and owl:sameAs. The default syntax is ontology:TermName. The ontology prefix has to be defined in the @context of the Entity, the category or any of the parent categories. The term name has to be a valid identifier in the ontology.

short_name = Field(None, title='Short name(s)') class-attribute instance-attribute

Abbreviation, Acronym, etc.