refactor: 进一步重构agents目录结构 符合多agent架构
This commit is contained in:
@@ -23,7 +23,7 @@ from database.models import User as UserModel
|
||||
from services.auth_service import verify_token
|
||||
from services.memoir_state_service import get_or_create_state
|
||||
from services import asr_service, redis_service
|
||||
from app.agents.prompts.profile_prompts import format_user_profile_context
|
||||
from app.agents.chat.prompts_profile import format_user_profile_context
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
LEGACY_VOICE_SESSION_ID = "legacy"
|
||||
@@ -924,7 +924,7 @@ async def websocket_endpoint(
|
||||
|
||||
def _get_missing_profile_fields(user: UserModel) -> list:
|
||||
"""检查用户缺失的资料字段"""
|
||||
from app.agents.prompts.profile_prompts import get_missing_profile_fields
|
||||
from app.agents.chat.prompts_profile import get_missing_profile_fields
|
||||
return get_missing_profile_fields(
|
||||
birth_year=user.birth_year,
|
||||
birth_place=user.birth_place,
|
||||
@@ -935,7 +935,7 @@ def _get_missing_profile_fields(user: UserModel) -> list:
|
||||
|
||||
def _get_filled_profile_fields(user: UserModel) -> dict:
|
||||
"""获取用户已有的资料字段(中文展示)"""
|
||||
from app.agents.prompts.profile_prompts import PROFILE_FIELD_NAMES
|
||||
from app.agents.chat.prompts_profile import PROFILE_FIELD_NAMES
|
||||
filled = {}
|
||||
if user.birth_year:
|
||||
filled["birth_year"] = str(user.birth_year)
|
||||
@@ -1045,7 +1045,7 @@ async def process_user_message(
|
||||
# 构建用户资料上下文
|
||||
user_profile_context = ""
|
||||
if user:
|
||||
from app.agents.prompts.profile_prompts import format_user_profile_context
|
||||
from app.agents.chat.prompts_profile import format_user_profile_context
|
||||
user_profile_context = format_user_profile_context(
|
||||
birth_year=user.birth_year,
|
||||
birth_place=user.birth_place,
|
||||
|
||||
Reference in New Issue
Block a user