feat: 初始化孕育无忧全栈项目基础代码结构
完成项目初始搭建,包含后端FastAPI+MongoDB服务、前端React+Vite项目的完整基础结构,添加各类配置文件与依赖清单,涵盖核心业务初始框架。
This commit is contained in:
21
backend/app/schemas/chat.py
Normal file
21
backend/app/schemas/chat.py
Normal file
@@ -0,0 +1,21 @@
|
||||
from datetime import datetime
|
||||
from typing import Optional
|
||||
|
||||
from pydantic import BaseModel
|
||||
|
||||
|
||||
class ChatMessageRequest(BaseModel):
|
||||
content: str
|
||||
|
||||
|
||||
class ChatMessageResponse(BaseModel):
|
||||
role: str
|
||||
content: str
|
||||
timestamp: datetime
|
||||
|
||||
|
||||
class ChatSessionResponse(BaseModel):
|
||||
id: str
|
||||
report_id: str
|
||||
messages: list[ChatMessageResponse]
|
||||
created_at: datetime
|
||||
Reference in New Issue
Block a user