feat: add request / response body logging to Claude batch API#1304
feat: add request / response body logging to Claude batch API#1304tasoo-oos wants to merge 9 commits into
Conversation
cubicj
left a comment
There was a problem hiding this comment.
The batch logging change looks good overall.
One unrelated change: redacted_thinking now exposes content.data only in the batch path, while the other Claude paths still render {{redacted_thinking}}. It also opens a backtick without closing it.
Could you check if that was intentional?
|
Done! I rolled it back to Changed redacted thinking text was intentional back then, except for the typo. But come to think of it, there would be almost no practical reason to add informational message inside That was clumsy change on my side, thanks for the feedback! |
cubicj
left a comment
There was a problem hiding this comment.
Verified the updated batch path. redacted_thinking now matches the regular Claude path again. Check, tests, and build pass on a trial merge with current origin/main.
Approving — thanks for the contribution!
PR Checklist
Note
This PR is a continuation of the pre-existing PR called #1263.
I seperated this PR from that because this PR introduces seperate feature based on the new batch API implementation.
Summary
Unlike Other streaming
Add request / response body logging logic to the claude batch API.
Related Issues
None
Changes
Before changes
Example images
After changes
Example images
anthropic.ts. Refer to Example images for more detail.Impact
No breaking changes
fetchNativenow has optional function parameterAdditional Notes
I renewed the API key so don't worry.
Currently testing.....
Footnotes
Modifies the behavior of prompting, requesting, or handling responses from AI models. ↩
Over 80% of the code is AI generated. ↩