feat(affinity_flow_chatter): 增强动作思考过程在回复生成中的集成

添加了将动作思考过程集成到回复生成流程的功能:
- 在 generator_api 中新增逻辑,将 action_data 中的 thinking 字段内容添加到 extra_info
- 优化 plan_filter 中对 thinking 字段的处理逻辑,避免添加无意义的默认值
- 更新默认生成器提示词,移除冗余的关系信息块重复
- 在 planner 提示词中添加不对表情包消息回应的限制
This commit is contained in:
Windpicker-owo
2025-09-24 13:53:54 +08:00
parent 9ca8d5d1c0
commit 37f9b46bcf
5 changed files with 14 additions and 3 deletions

View File

@@ -120,6 +120,13 @@ async def generate_reply(
if not extra_info and action_data:
extra_info = action_data.get("extra_info", "")
# 如果action_data中有thinking添加到extra_info中
if action_data and (thinking := action_data.get("thinking")):
if extra_info:
extra_info += f"\n\n思考过程:{thinking}"
else:
extra_info = f"思考过程:{thinking}"
# 调用回复器生成回复
success, llm_response_dict, prompt = await replyer.generate_reply_with_context(
reply_to=reply_to,