myagent-ai 1.23.8 → 1.23.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/core/tool_dispatcher.py +8 -0
- package/package.json +1 -1
package/core/tool_dispatcher.py
CHANGED
|
@@ -196,9 +196,17 @@ class ToolDispatcher:
|
|
|
196
196
|
fskill = FileSendSkill()
|
|
197
197
|
fresult = await fskill.execute(
|
|
198
198
|
str(p), send_desc or f"文件: {p.name}",
|
|
199
|
+
stream_callback=stream_callback,
|
|
199
200
|
)
|
|
200
201
|
if fresult.get("success"):
|
|
201
202
|
logger.info(f"[{task_id}] CLI 自动发送文件: {p.name}")
|
|
203
|
+
if sent_files is not None and fresult.get("file_id"):
|
|
204
|
+
sent_files.append({
|
|
205
|
+
"id": fresult["file_id"],
|
|
206
|
+
"name": fresult.get("name", ""),
|
|
207
|
+
"size": fresult.get("size", 0),
|
|
208
|
+
"url": fresult.get("url", ""),
|
|
209
|
+
})
|
|
202
210
|
else:
|
|
203
211
|
result["output"] += f"\n[文件发送失败: {fresult.get('error', '')}]"
|
|
204
212
|
except Exception as e:
|