price-builder-backend/schemas/schemas.py

23 lines
371 B
Python

from pydantic import BaseModel
class LaptopCreate(BaseModel):
processor: str
ram: int
os: str
ssd: int
display: float
class LaptopResponse(BaseModel):
id: int
processor: str
ram: int
os: str
ssd: int
display: float
class Config:
orm_mode = True
class PredictPriceResponse(BaseModel):
predicted_price: float