/
pepler-sys
/
SE_FastAPI_Example
Обзор
Документация
Войти
/
pepler-sys
/
SE_FastAPI_Example
Код
Запросы
2
Задачи
Вики
Пакеты
0
Релизы
0
CI/CD
Аналитика
Безопасность
feature/add-requirements
schemas.py
14 строк
386 B
Danil
refactor: добавили примеры (examples) в схемы запросов для Swagger
02 май 2026, 11:36
02 май 2026, 11:36
8d4820e
Код
Авторство
О чём код?
from pydantic import BaseModel, Field class SentimentRequest(BaseModel): text: str = Field( ..., min_length=1, max_length=1000, description="Текст для анализа", example="Мне очень нравится этот сервис!" # Новое поле ) class SentimentResponse(BaseModel): label: str score: float