ForcePilot/backend/package/yuxi/agents/middlewares/__init__.py
Kris 90b16ce9b1 feat(agents): add channel tool middleware support
新增渠道工具中间件,支持从对话渠道加载并执行对应Agent工具:
1. 新增ChannelToolMiddleware中间件实现工具注入逻辑
2. 扩展BaseContext增加channel_type和channel_tools字段
3. 在内置聊天机器人和深度代理中注册渠道工具中间件
4. 导出中间件到包公共接口
2026-05-21 10:19:37 +08:00

19 lines
773 B
Python

from .attachment_middleware import inject_attachment_context, save_attachments_to_fs
from .channel_tool_middleware import ChannelToolMiddleware
from .context_middlewares import context_aware_prompt, context_based_model
from .dynamic_tool_middleware import DynamicToolMiddleware
from .runtime_config_middleware import RuntimeConfigMiddleware
from .summary_middleware import SummaryOffloadMiddleware, create_summary_offload_middleware
__all__ = [
"ChannelToolMiddleware",
"DynamicToolMiddleware",
"RuntimeConfigMiddleware",
"SummaryOffloadMiddleware",
"context_aware_prompt",
"context_based_model",
"create_summary_offload_middleware",
"inject_attachment_context", # 已废弃,使用 save_attachments_to_fs
"save_attachments_to_fs",
]