branch: elpa/gptel
commit 8889e27c5b53478248b05a660778ae744848c1cd
Author: Karthik Chikmagalur <[email protected]>
Commit: Karthik Chikmagalur <[email protected]>
gptel-rewrite: Ignore reasoning output correctly
* gptel-rewrite.el (gptel--rewrite-callback): Ignore reasoning
content or tool call confirmation/results when running
gptel-rewrite. Reasoning content and tool results will continue
to be ignored, but tool call confirmations eventually need to be
handled.
---
gptel-rewrite.el | 1 +
1 file changed, 1 insertion(+)
diff --git a/gptel-rewrite.el b/gptel-rewrite.el
index ebc1c2a8dc..e7e1ab939b 100644
--- a/gptel-rewrite.el
+++ b/gptel-rewrite.el
@@ -414,6 +414,7 @@ INFO is the async communication channel for the rewrite
request."
(message (concat "LLM response error: %s. Rewrite in buffer %s
canceled.")
(plist-get info :status) (plist-get info :buffer))
(gptel--rewrite-callback 'abort info))
+ ((consp response)) ;reasoning or tool calls -- don't care and not
implemented, respectively
(t (let ((proc-buf (cdr-safe (plist-get info :context))) ;finished
successfully
(mkb (propertize "<mouse-1>" 'face 'help-key-binding)))
(with-current-buffer proc-buf