Fix Anthropic API rejection when resubmitting aborted thinking blocks

- Convert thinking blocks with missing/empty signatures to text blocks
- Prevents 400 error: 'Invalid signature in thinking block'
- Occurs when stream is aborted mid-thinking and message is resubmitted
This commit is contained in:
Mario Zechner 2025-11-18 14:36:57 +01:00
parent 6680034a64
commit 387cc97bac
2 changed files with 18 additions and 5 deletions

View file

@ -2,6 +2,10 @@
## [Unreleased]
### Fixed
- **Anthropic Aborted Thinking**: Fixed error when resubmitting assistant messages with incomplete thinking blocks (from aborted streams). Thinking blocks without valid signatures are now converted to text blocks with `<thinking>` delimiters, preventing API rejection.
## [0.7.16] - 2025-11-17
### Fixed