Spaces:
Sleeping
Sleeping
Download trauma/api/message/model.py from brestok/TraumaBackend: direct link, hf CLI and curl.
- Browser
- Download file 528 Bytes
-
https://huggingface.co/spaces/brestok/TraumaBackend/resolve/main/trauma/api/message/model.py
- Command line
-
hf download hf://spaces/brestok/TraumaBackend/trauma/api/message/model.py
-
curl -L -o model.py https://huggingface.co/spaces/brestok/TraumaBackend/resolve/main/trauma/api/message/model.py
528 Bytes
| from datetime import datetime | |
| from pydantic import Field | |
| from trauma.api.data.model import EntityModelExtended | |
| from trauma.api.message.dto import Author, Feedback | |
| from trauma.core.database import MongoBaseModel | |
| class MessageModel(MongoBaseModel): | |
| chatId: str | |
| author: Author | |
| text: str | |
| entities: list[EntityModelExtended] | None = None | |
| feedback: Feedback | None = None | |
| datetimeInserted: datetime = Field(default_factory=datetime.now) | |
| datetimeUpdated: datetime = Field(default_factory=datetime.now) | |