branch: elpa/gptel
commit 4ca50d72556f4cf68d40272cad799742440d8c84
Author: Karthik Chikmagalur <[email protected]>
Commit: Karthik Chikmagalur <[email protected]>
gptel-anthropic: Fix reasoning parsing bug
* gptel-anthropic.el (gptel-curl--parse-stream): Ensure that the
reasoning-block termination check only fires when we are actually
at the end of a reasoning block.
---
gptel-anthropic.el | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gptel-anthropic.el b/gptel-anthropic.el
index 95ef4feb03..659ba652e9 100644
--- a/gptel-anthropic.el
+++ b/gptel-anthropic.el
@@ -111,7 +111,7 @@ information if the stream contains it. Not my best work, I
know."
(error (pop (plist-get info :tool-use)))) ;TODO: nreverse
:tool-use list
(plist-put info :partial_json nil))
- ((plist-get info :reasoning-block) ;End of reasoning block
+ ((eq (plist-get info :reasoning-block) 'in) ;End of reasoning
block
(plist-put info :reasoning-block t)))) ;Signal end of reasoning
stream to filter
((looking-at "message_delta")