mirror of
https://github.com/earendil-works/pi.git
synced 2026-06-18 15:54:04 +08:00
Instead of passing conversation as LLM messages (which makes the model try to continue it), serialize to text wrapped in <conversation> tags. - serializeConversation() formats messages as [User]/[Assistant]/[Tool result] - Tool calls shown as function(args) format - Tool results truncated to prevent bloat - Conversation wrapped in <conversation> tags in the prompt