Spaces:
Runtime error
Runtime error
Commit
·
64c321d
1
Parent(s):
c0aa75e
Update schemas.py
Browse files- schemas.py +3 -3
schemas.py
CHANGED
@@ -2,6 +2,7 @@ from pydantic import BaseModel
|
|
2 |
from datetime import datetime
|
3 |
|
4 |
class SentimentResultBase(BaseModel):
|
|
|
5 |
positive_score: float
|
6 |
negative_score: float
|
7 |
neutral_score: float
|
@@ -11,9 +12,8 @@ class SentimentResultCreate(SentimentResultBase):
|
|
11 |
|
12 |
class SentimentResult(SentimentResultBase):
|
13 |
id: int
|
|
|
14 |
created_at: datetime
|
15 |
-
|
16 |
-
text_id: int
|
17 |
-
|
18 |
class Config:
|
19 |
from_attributes = True
|
|
|
2 |
from datetime import datetime
|
3 |
|
4 |
class SentimentResultBase(BaseModel):
|
5 |
+
text: str
|
6 |
positive_score: float
|
7 |
negative_score: float
|
8 |
neutral_score: float
|
|
|
12 |
|
13 |
class SentimentResult(SentimentResultBase):
|
14 |
id: int
|
15 |
+
text: str
|
16 |
created_at: datetime
|
17 |
+
|
|
|
|
|
18 |
class Config:
|
19 |
from_attributes = True
|