Meta

class Meta(*, definition: Definition | None = None, subsets: List[str] | None = None, xrefs: List[Xref] | None = None, synonyms: List[Synonym] | None = None, comments: List | None = None, version: str | None = None, basicPropertyValues: List[Property] | None = None, deprecated: bool = False, standardized: bool = False)[source]

Bases: BaseModel, StandardizeMixin

Represents the metadata about a node or ontology.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

Attributes Summary

model_computed_fields

A dictionary of computed field names and their corresponding ComputedFieldInfo objects.

model_config

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

model_fields

Metadata about the fields defined on the model, mapping of field names to [FieldInfo][pydantic.fields.FieldInfo].

Methods Summary

standardize()

Standardize the metadata.

Attributes Documentation

model_computed_fields: ClassVar[dict[str, ComputedFieldInfo]] = {}

A dictionary of computed field names and their corresponding ComputedFieldInfo objects.

model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

model_fields: ClassVar[dict[str, FieldInfo]] = {'comments': FieldInfo(annotation=Union[List, NoneType], required=False), 'definition': FieldInfo(annotation=Union[Definition, NoneType], required=False), 'deprecated': FieldInfo(annotation=bool, required=False, default=False), 'properties': FieldInfo(annotation=Union[List[bioontologies.obograph.Property], NoneType], required=False, alias='basicPropertyValues', alias_priority=2), 'standardized': FieldInfo(annotation=bool, required=False, default=False, exclude=True), 'subsets': FieldInfo(annotation=Union[List[str], NoneType], required=False), 'synonyms': FieldInfo(annotation=Union[List[bioontologies.obograph.Synonym], NoneType], required=False), 'version': FieldInfo(annotation=Union[str, NoneType], required=False), 'xrefs': FieldInfo(annotation=Union[List[bioontologies.obograph.Xref], NoneType], required=False)}

Metadata about the fields defined on the model, mapping of field names to [FieldInfo][pydantic.fields.FieldInfo].

This replaces Model.__fields__ from Pydantic V1.

Methods Documentation

standardize() Self[source]

Standardize the metadata.