picoclaw/pkg/agent
Zhaoyikaiii 740cdcaeaf
fix: remove redundant tools definitions from system prompt (#771)
* fix: remove redundant tools definitions from system prompt

Tools are already provided to the LLM via JSON schema through
ToProviderDefs(), so the text-based tools section in the system
prompt is redundant.

This removes the buildToolsSection() logic and the tools field
from ContextBuilder, reducing system prompt length while maintaining
the "ALWAYS use tools" rule reminder.

Fixes #731

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* fix: correct spelling 'initialized' (was 'initialised')

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-25 20:44:07 +08:00
..
context.go fix: remove redundant tools definitions from system prompt (#771) 2026-02-25 20:44:07 +08:00
context_cache_test.go fix: cache system prompt with mtime-based auto-invalidation (#607) 2026-02-25 15:27:45 +08:00
context_test.go fix: handle multi-tool-call orphan detection in sanitizeHistoryForProvider 2026-02-24 21:35:15 +08:00
instance.go fix: remove redundant tools definitions from system prompt (#771) 2026-02-25 20:44:07 +08:00
instance_test.go fix: Templates update (#485) 2026-02-19 19:16:37 +01:00
loop.go fix: remove redundant tools definitions from system prompt (#771) 2026-02-25 20:44:07 +08:00
loop_test.go feat(fmt): Fix formatting 2026-02-19 22:05:15 +02:00
memory.go Merge branch 'main' into fix-formatting 2026-02-20 20:02:53 +02:00
mock_provider_test.go feat(fmt): Fix formatting 2026-02-19 22:05:15 +02:00
registry.go feat(fmt): Run formatters 2026-02-18 21:48:23 +02:00
registry_test.go feat(fmt): Run formatters 2026-02-18 21:48:23 +02:00