Files
JARVIS/backend/app/schemas/conversation.py
DESKTOP-72TV0V4\caoxiaozhu d2447ee635 Add brain memory services and APIs
Introduce the backend pieces for brain memory ingestion, routing, and
system telemetry so the new knowledge workflows can project data into a
brain view. The supporting tests lock in the new behavior and keep the
expanded backend surface stable.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-22 13:47:34 +08:00

49 lines
938 B
Python

from pydantic import BaseModel
from datetime import datetime
class MessageCreate(BaseModel):
content: str
class MessageOut(BaseModel):
id: str
role: str
content: str
model: str | None
tokens_used: int | None
attachments: list[dict] | None = None
created_at: datetime
model_config = {"from_attributes": True}
class ConversationCreate(BaseModel):
title: str | None = None
class ConversationOut(BaseModel):
id: str
title: str | None
message_count: int
created_at: datetime
updated_at: datetime
model_config = {"from_attributes": True}
class ChatRequest(BaseModel):
message: str
conversation_id: str | None = None
agent_id: str | None = None
model_name: str | None = None
file_ids: list[str] = []
class ChatResponse(BaseModel):
conversation_id: str
message_id: str
content: str
agent_name: str
model_name: str | None = None