Revert "fix(ai): own Anthropic SSE parsing to avoid SDK JSON.parse hard-failures"

This reverts commit 4b926a30a2.
This commit is contained in:
Mario Zechner
2026-04-21 23:19:25 +02:00
parent 81de426f96
commit fc9220d2de
12 changed files with 124 additions and 430 deletions

View File

@@ -106,10 +106,10 @@ describe("totalTokens field", () => {
describe.skipIf(!process.env.ANTHROPIC_API_KEY)("Anthropic (API Key)", () => {
it(
"claude-sonnet-4-5 - should return totalTokens equal to sum of components",
"claude-3-5-haiku - should return totalTokens equal to sum of components",
{ retry: 3, timeout: 60000 },
async () => {
const llm = getModel("anthropic", "claude-sonnet-4-5");
const llm = getModel("anthropic", "claude-3-5-haiku-20241022");
console.log(`\nAnthropic / ${llm.id}:`);
const { first, second } = await testTotalTokensWithCache(llm, { apiKey: process.env.ANTHROPIC_API_KEY });