* Add type to DataPoint metadata * Add missing index_fields * Use DataPoint UUID type in pgvector create_data_points * Make _metadata mandatory everywhere
14 lines
316 B
Python
14 lines
316 B
Python
from cognee.infrastructure.engine import DataPoint
|
|
from cognee.modules.engine.models.EntityType import EntityType
|
|
|
|
|
|
class Entity(DataPoint):
|
|
__tablename__ = "entity"
|
|
name: str
|
|
is_a: EntityType
|
|
description: str
|
|
|
|
_metadata: dict = {
|
|
"index_fields": ["name"],
|
|
"type": "Entity"
|
|
}
|