mirror of
https://github.com/tiennm99/goclaw.git
synced 2026-10-19 06:15:06 +00:00
fix(agent): deduplicate automatic media delivery
This commit is contained in:
1 parent
b6fb91b163
commit
4426f76140
5 files changed
+146
-15
No files matched your search
@@ -403,8 +403,8 @@ func (l *Loop) injectContext(ctx context.Context, req *RunRequest) (contextSetup
|
||||
// Inject agent key into context for tool-level resolution (multiple agents share tool registry)
|
||||
ctx = tools.WithToolAgentKey(ctx, l.id)
|
||||
|
||||
// Inject delivered media tracker so write_file and message tool can coordinate:
|
||||
// write_file(deliver=true) marks paths, message self-send guard checks before allowing.
|
||||
// Inject delivered media tracker so automatic output collection and direct
|
||||
// media sends can coordinate within this run.
|
||||
ctx = tools.WithDeliveredMedia(ctx, tools.NewDeliveredMedia())
|
||||
|
||||
// Security: truncate oversized user messages gracefully (feed truncation notice into LLM)
|
||||
|
||||
Reference in new issue
Block a user