You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -120,29 +116,24 @@ Guidelines for identifying obsolete tool calls:
120
116
3. Failed or incorrect tool attempts that were immediately corrected (e.g., reading a file from the wrong path, then reading from the correct path)
121
117
122
118
DO NOT prune:
123
-
${protectedToolsText}
124
-
- Tool calls that modified state (edits, writes, etc.)
125
119
- Tool calls whose outputs are actively being discussed
126
120
- Tool calls that produced errors still being debugged
127
-
- Tool calls where the user explicitly indicated they want to retain the information (e.g., "save this", "remember this", "keep this for later", "don't output anything else but save this")
128
121
- Tool calls that are the MOST RECENT activity in the conversation (these may be intended for future use)
129
122
130
123
IMPORTANT: Available tool call IDs for analysis: ${unprunedToolCallIds.join(", ")}
131
124
132
-
The session history below may contain tool calls with IDs not in the available list above. These are either:
133
-
1. Protected tools (marked with callID "<protected>")
134
-
2. Already-pruned tools (marked with callID "<already-pruned>")
125
+
The session history below may contain tool calls with IDs not in the available list above, these cannot be pruned. These are either:
126
+
1. Protected tools (marked with toolCallID "<protected>")
127
+
2. Already-pruned tools (marked with toolCallID "<already-pruned>")
135
128
136
129
ONLY return IDs from the available list above.
137
130
138
-
Session history:
131
+
Session history (each tool call has a "toolCallID" field):
139
132
${messagesJson}
140
133
141
134
You MUST respond with valid JSON matching this exact schema:
142
135
{
143
136
"pruned_tool_call_ids": ["id1", "id2", ...],
144
137
"reasoning": "explanation of why these IDs were selected"
145
-
}
146
-
147
-
Return ONLY the tool call IDs from the available list above that should be pruned.`
0 commit comments