mirror of
https://github.com/xinnan-tech/xiaozhi-esp32-server.git
synced 2026-11-28 04:59:52 +01:00
fix: device schema问题
This commit is contained in:
parent
ad4ec572bd
commit
2565944051
1 changed files with 12 additions and 0 deletions
|
|
@ -2,6 +2,8 @@ from datetime import datetime
|
||||||
from typing import Optional, List
|
from typing import Optional, List
|
||||||
from pydantic import BaseModel, Field
|
from pydantic import BaseModel, Field
|
||||||
|
|
||||||
|
from schemas.agent import AgentConfigResponse
|
||||||
|
|
||||||
|
|
||||||
# ==================== Request Schemas ====================
|
# ==================== Request Schemas ====================
|
||||||
|
|
||||||
|
|
@ -58,3 +60,13 @@ class DeviceBoundAgentsResponse(BaseModel):
|
||||||
device_id: str
|
device_id: str
|
||||||
agents: List[AgentBindingResponse] = []
|
agents: List[AgentBindingResponse] = []
|
||||||
|
|
||||||
|
|
||||||
|
class DeviceAgentResolveResponse(BaseModel):
|
||||||
|
"""Response for resolving agent by device and wake_word"""
|
||||||
|
device_id: str
|
||||||
|
agent_id: str
|
||||||
|
owner_id: Optional[str] = None
|
||||||
|
is_default: bool
|
||||||
|
match_type: str = Field(..., description="How agent was matched: 'wake_word' or 'default'")
|
||||||
|
agent_config: AgentConfigResponse
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue