mirror of
https://github.com/xinnan-tech/xiaozhi-esp32-server.git
synced 2026-11-28 04:59:52 +01:00
- add feedback backend, H5/admin UI, CRM services, and deployment docs - add isolated local test compose on port 18007 with separate data paths - remove committed LLM secret and support provider-specific env overrides Co-Authored-By: Claude <noreply@anthropic.com>
34 lines
830 B
Python
34 lines
830 B
Python
"""智能体配置仓储接口"""
|
|
|
|
from abc import ABC, abstractmethod
|
|
from typing import List, Optional
|
|
|
|
from .entity import AgentConfig
|
|
|
|
|
|
class IAgentConfigRepository(ABC):
|
|
"""智能体配置仓储接口"""
|
|
|
|
@abstractmethod
|
|
async def get_by_id(self, config_id: str) -> Optional[AgentConfig]:
|
|
...
|
|
|
|
@abstractmethod
|
|
async def get_by_agent_id(self, agent_id: str) -> Optional[AgentConfig]:
|
|
...
|
|
|
|
@abstractmethod
|
|
async def list_all(self, status: Optional[int] = None) -> List[AgentConfig]:
|
|
...
|
|
|
|
@abstractmethod
|
|
async def list_page(self, page: int = 1, page_size: int = 20) -> dict:
|
|
...
|
|
|
|
@abstractmethod
|
|
async def save(self, config: AgentConfig) -> AgentConfig:
|
|
...
|
|
|
|
@abstractmethod
|
|
async def delete(self, config_id: str) -> bool:
|
|
...
|