NLP_tutorial/3-NLP_services/model/request_models.py
2025-04-09 09:39:40 +03:30

29 lines
432 B
Python

from typing import List, Dict, Tuple
from pydantic import BaseModel
class InputElement(BaseModel):
lang: str
text: str
class NREHType(BaseModel):
pos: str
class NRETType(BaseModel):
pos: str
class InputElementNRE(BaseModel):
text: str
h: NREHType
t: NRETType
InputNerType = List[InputElement]
InputOIEType = List[InputElement]
InputNREType = List[InputElementNRE]
InputSummaryType = List[str]