Skip to content

🪢 Open source agent evals & observability: Trace, evaluate, and improve LLM applications with one open platform.

fix(model-prices): parse token creation counts by duration (#12382)

Hassieb Pakzade26a288dec36
diff --git a/packages/shared/src/server/otel/OtelIngestionProcessor.ts b/packages/shared/src/server/otel/OtelIngestionProcessor.ts
index 6d56394b9f..d18962ad32 100644
--- a/packages/shared/src/server/otel/OtelIngestionProcessor.ts
+++ b/packages/shared/src/server/otel/OtelIngestionProcessor.ts
@@ -2012,13 +2012,46 @@ export class OtelIngestionProcessor {
if ("anthropic" in parsed && "usage" in parsed["anthropic"]) {
const anthropicMetadata = parsed["anthropic"]["usage"] as Record<
string,
- number
+ unknown
>;
- usageDetails["input_cache_creation"] ??=
- anthropicMetadata["cache_creation_input_tokens"];
- usageDetails["input_cached_tokens"] ??=
- anthropicMetadata["cache_read_input_tokens"];
+ usageDetails["input_cache_creation"] ??= (
+ anthropicMetadata as Record<string, number>
+ )["cache_creation_input_tokens"];
+ usageDetails["input_cached_tokens"] ??= (
+ anthropicMetadata as Record<string, number>
+ )["cache_read_input_tokens"];
+
+ // Extract cache creation duration breakdown (5m and 1h TTLs)
+ if (
+ typeof anthropicMetadata["cache_creation"] === "object" &&
+ anthropicMetadata["cache_creation"] !== null
+ ) {
+ const cacheCreation = anthropicMetadata[
+ "cache_creation"
+ ] as Record<string, number>;
+
+ if (
+ typeof cacheCreation["ephemeral_5m_input_tokens"] === "number"
+ ) {
+ usageDetails["input_cache_creation_5m"] ??=
+ cacheCreation["ephemeral_5m_input_tokens"];
+ }
+ if (
+ typeof cacheCreation["ephemeral_1h_input_tokens"] === "number"
+ ) {
+ usageDetails["input_cache_creation_1h"] ??=
+ cacheCreation["ephemeral_1h_input_tokens"];
+ }
+
+ // Subtract duration-specific counts from total to avoid double counting
+ usageDetails["input_cache_creation"] = Math.max(
+ (usageDetails["input_cache_creation"] ?? 0) -
+ (usageDetails["input_cache_creation_5m"] ?? 0) -
+ (usageDetails["input_cache_creation_1h"] ?? 0),
+ 0,
+ );
+ }
}
// Bedrock provider metadata extraction
@@ -2050,6 +2083,8 @@ export class OtelIngestionProcessor {
(usageDetails["input"] ?? 0) -
(usageDetails["input_cached_tokens"] ?? 0) -
(usageDetails["input_cache_creation"] ?? 0) -
+ (usageDetails["input_cache_creation_5m"] ?? 0) -
+ (usageDetails["input_cache_creation_1h"] ?? 0) -
(usageDetails["input_cache_read"] ?? 0),
0,
);
diff --git a/web/src/__tests__/server/api/otel/otelMapping.servertest.ts b/web/src/__tests__/server/api/otel/otelMapping.servertest.ts
index 136191ec97..192724d85e 100644
--- a/web/src/__tests__/server/api/otel/otelMapping.servertest.ts
+++ b/web/src/__tests__/server/api/otel/otelMapping.servertest.ts
@@ -5779,13 +5779,230 @@ describe("OTel Resource Span Mapping", () => {
expect(
observationEvent?.body.usageDetails.input_cache_read,
).toBeUndefined(); // no double accounting
- expect(observationEvent?.body.usageDetails.input_cache_creation).toBe(
+
+ // Duration-specific cache creation tokens deducted from total
+ expect(observationEvent?.body.usageDetails.input_cache_creation).toBe(0);
+ expect(observationEvent?.body.usageDetails.input_cache_creation_5m).toBe(
2089,
);
+ expect(observationEvent?.body.usageDetails.input_cache_creation_1h).toBe(
+ 0,
+ );
+
expect(
observationEvent?.body.usageDetails.input_cache_write,
).toBeUndefined(); // no double accounting
});
+
+ it("should extract both 5m and 1h cache creation tokens from Anthropic provider metadata", async () => {
+ const traceId = "abcdef1234567890abcdef1234567891";
+ const spanId = "1234567890abcde0";
+
+ const vercelAIAnthropicSpanMixed = {
+ resource: {
+ attributes: [
+ {
+ key: "service.name",
+ value: { stringValue: "test-service" },
+ },
+ ],
+ },
+ scopeSpans: [
+ {
+ scope: {
+ name: "ai",
+ version: "4.0.0",
+ },
+ spans: [
+ {
+ traceId: Buffer.from(traceId, "hex"),
+ spanId: Buffer.from(spanId, "hex"),
+ name: "anthropic-generation",
+ kind: 1,
+ startTimeUnixNano: {
+ low: 1000000,
+ high: 406528574,
+ unsigned: true,
+ },
+ endTimeUnixNano: {
+ low: 2000000,
+ high: 406528574,
+ unsigned: true,
+ },
+ attributes: [
+ {
+ key: "gen_ai.usage.input_tokens",
+ value: {
+ intValue: { low: 5000, high: 0, unsigned: false },
+ },
+ },
+ {
+ key: "gen_ai.usage.output_tokens",
+ value: {
+ intValue: { low: 200, high: 0, unsigned: false },
+ },
+ },
+ {
+ key: "ai.response.providerMetadata",
+ value: {
+ stringValue: JSON.stringify({
+ anthropic: {
+ usage: {
+ input_tokens: 5000,
+ cache_creation_input_tokens: 3000,
+ cache_read_input_tokens: 1500,
+ cache_creation: {
+ ephemeral_5m_input_tokens: 2000,
+ ephemeral_1h_input_tokens: 1000,
+ },
+ output_tokens: 200,
+ service_tier: "standard",
+ },
+ },
+ }),
+ },
+ },
+ ],
+ status: {},
+ },
+ ],
+ },
+ ],
+ };
+
+ const events = await convertOtelSpanToIngestionEvent(
+ vercelAIAnthropicSpanMixed,
+ new Set(),
+ );
+
+ const observationEvent = events.find(
+ (e) => e.type === "generation-create" || e.type === "span-create",
+ );
+
+ expect(observationEvent).toBeDefined();
+
+ // input = 5000 - 1500 (cached) - 0 (cache_creation remainder) - 2000 (5m) - 1000 (1h) = 500
+ expect(observationEvent?.body.usageDetails.input).toBe(500);
+ expect(observationEvent?.body.usageDetails.output).toBe(200);
+
+ // Cache read tokens
+ expect(observationEvent?.body.usageDetails.input_cached_tokens).toBe(
+ 1500,
+ );
+
+ // Duration-specific: 5m + 1h = 3000 = total, so remainder = 0
+ expect(observationEvent?.body.usageDetails.input_cache_creation).toBe(0);
+ expect(observationEvent?.body.usageDetails.input_cache_creation_5m).toBe(
+ 2000,
+ );
+ expect(observationEvent?.body.usageDetails.input_cache_creation_1h).toBe(
+ 1000,
+ );
+ });
+
+ it("should handle Anthropic provider metadata without cache_creation sub-object (backward compatibility)", async () => {
+ const traceId = "abcdef1234567890abcdef1234567892";
+ const spanId = "1234567890abcde1";
+
+ const vercelAIAnthropicSpanLegacy = {
+ resource: {
+ attributes: [
+ {
+ key: "service.name",
+ value: { stringValue: "test-service" },
+ },
+ ],
+ },
+ scopeSpans: [
+ {
+ scope: {
+ name: "ai",
+ version: "3.0.0",
+ },
+ spans: [
+ {
+ traceId: Buffer.from(traceId, "hex"),
+ spanId: Buffer.from(spanId, "hex"),
+ name: "anthropic-generation",
+ kind: 1,
+ startTimeUnixNano: {
+ low: 1000000,
+ high: 406528574,
+ unsigned: true,
+ },
+ endTimeUnixNano: {
+ low: 2000000,
+ high: 406528574,
+ unsigned: true,
+ },
+ attributes: [
+ {
+ key: "gen_ai.usage.input_tokens",
+ value: {
+ intValue: { low: 10000, high: 0, unsigned: false },
+ },
+ },
+ {
+ key: "gen_ai.usage.output_tokens",
+ value: {
+ intValue: { low: 300, high: 0, unsigned: false },
+ },
+ },
+ {
+ key: "ai.response.providerMetadata",
+ value: {
+ stringValue: JSON.stringify({
+ anthropic: {
+ usage: {
+ input_tokens: 10000,
+ cache_creation_input_tokens: 4000,
+ cache_read_input_tokens: 2000,
+ output_tokens: 300,
+ service_tier: "standard",
+ },
+ },
+ }),
+ },
+ },
+ ],
+ status: {},
+ },
+ ],
+ },
+ ],
+ };
+
+ const events = await convertOtelSpanToIngestionEvent(
+ vercelAIAnthropicSpanLegacy,
+ new Set(),
+ );
+
+ const observationEvent = events.find(
+ (e) => e.type === "generation-create" || e.type === "span-create",
+ );
+
+ expect(observationEvent).toBeDefined();
+
+ // input = 10000 - 2000 (cached) - 4000 (cache_creation, no duration breakdown) = 4000
+ expect(observationEvent?.body.usageDetails.input).toBe(4000);
+ expect(observationEvent?.body.usageDetails.output).toBe(300);
+
+ // Cache tokens preserved as-is when no duration sub-object
+ expect(observationEvent?.body.usageDetails.input_cached_tokens).toBe(
+ 2000,
+ );
+ expect(observationEvent?.body.usageDetails.input_cache_creation).toBe(
+ 4000,
+ );
+
+ // Duration-specific keys should not be set
+ expect(
+ observationEvent?.body.usageDetails.input_cache_creation_5m,
+ ).toBeUndefined();
+ expect(
+ observationEvent?.body.usageDetails.input_cache_creation_1h,
+ ).toBeUndefined();
+ });
it("should extract all Bedrock cache token types from Vercel AI SDK provider metadata", async () => {
const traceId = "abcdef1234567890abcdef1234567890";
const spanId = "1234567890abcdef";
diff --git a/web/src/features/models/components/pricing-tiers/TierPrefillButtons.tsx b/web/src/features/models/components/pricing-tiers/TierPrefillButtons.tsx
index c0c17fb203..7f2fc08d15 100644
--- a/web/src/features/models/components/pricing-tiers/TierPrefillButtons.tsx
+++ b/web/src/features/models/components/pricing-tiers/TierPrefillButtons.tsx
@@ -48,6 +48,8 @@ export function TierPrefillButtons({
output_tokens: 0,
cache_creation_input_tokens: 0,
cache_read_input_tokens: 0,
+ input_cache_creation_5m: 0,
+ input_cache_creation_1h: 0,
...prices,
});
}}
diff --git a/worker/src/constants/default-model-prices.json b/worker/src/constants/default-model-prices.json
index 2cf013e7f0..f32874d4d2 100644
--- a/worker/src/constants/default-model-prices.json
+++ b/worker/src/constants/default-model-prices.json
@@ -1310,7 +1310,7 @@
"modelName": "claude-3-sonnet-20240229",
"matchPattern": "(?i)^(anthropic\/)?(claude-3-sonnet-20240229|anthropic\\.claude-3-sonnet-20240229-v1:0|claude-3-sonnet@20240229)$",
"createdAt": "2024-03-07T17:55:38.139Z",
- "updatedAt": "2025-12-12T15:00:06.513Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerId": "claude",
"pricingTiers": [
{
@@ -1326,6 +1326,8 @@
"output_tokens": 0.000015,
"cache_creation_input_tokens": 0.00000375,
"input_cache_creation": 0.00000375,
+ "input_cache_creation_5m": 0.00000375,
+ "input_cache_creation_1h": 0.000006,
"cache_read_input_tokens": 3e-7,
"input_cache_read": 3e-7
}
@@ -1536,7 +1538,7 @@
"modelName": "claude-3-5-sonnet-20240620",
"matchPattern": "(?i)^(anthropic\/)?(claude-3-5-sonnet-20240620|(eu\\.|us\\.|apac\\.)?anthropic\\.claude-3-5-sonnet-20240620-v1:0|claude-3-5-sonnet@20240620)$",
"createdAt": "2024-06-25T11:47:24.475Z",
- "updatedAt": "2025-12-12T15:00:06.513Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerId": "claude",
"pricingTiers": [
{
@@ -1552,6 +1554,8 @@
"output_tokens": 0.000015,
"cache_creation_input_tokens": 0.00000375,
"input_cache_creation": 0.00000375,
+ "input_cache_creation_5m": 0.00000375,
+ "input_cache_creation_1h": 0.000006,
"cache_read_input_tokens": 3e-7,
"input_cache_read": 3e-7
}
@@ -1743,7 +1747,7 @@
"modelName": "claude-3.5-sonnet-20241022",
"matchPattern": "(?i)^(anthropic\/)?(claude-3-5-sonnet-20241022|(eu\\.|us\\.|apac\\.)?anthropic\\.claude-3-5-sonnet-20241022-v2:0|claude-3-5-sonnet-V2@20241022)$",
"createdAt": "2024-10-22T18:48:01.676Z",
- "updatedAt": "2025-12-12T15:00:06.513Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerId": "claude",
"pricingTiers": [
{
@@ -1759,6 +1763,8 @@
"output_tokens": 0.000015,
"cache_creation_input_tokens": 0.00000375,
"input_cache_creation": 0.00000375,
+ "input_cache_creation_5m": 0.00000375,
+ "input_cache_creation_1h": 0.000006,
"cache_read_input_tokens": 3e-7,
"input_cache_read": 3e-7
}
@@ -1770,7 +1776,7 @@
"modelName": "claude-3.5-sonnet-latest",
"matchPattern": "(?i)^(anthropic\/)?(claude-3-5-sonnet-latest)$",
"createdAt": "2024-10-22T18:48:01.676Z",
- "updatedAt": "2025-12-12T15:00:06.513Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerId": "claude",
"pricingTiers": [
{
@@ -1786,6 +1792,8 @@
"output_tokens": 0.000015,
"cache_creation_input_tokens": 0.00000375,
"input_cache_creation": 0.00000375,
+ "input_cache_creation_5m": 0.00000375,
+ "input_cache_creation_1h": 0.000006,
"cache_read_input_tokens": 3e-7,
"input_cache_read": 3e-7
}
@@ -1797,7 +1805,7 @@
"modelName": "claude-3-5-haiku-20241022",
"matchPattern": "(?i)^(anthropic\/)?(claude-3-5-haiku-20241022|(eu\\.|us\\.|apac\\.)?anthropic\\.claude-3-5-haiku-20241022-v1:0|claude-3-5-haiku-V1@20241022)$",
"createdAt": "2024-11-05T10:30:50.566Z",
- "updatedAt": "2025-12-12T15:00:06.513Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerId": "claude",
"pricingTiers": [
{
@@ -1813,6 +1821,8 @@
"output_tokens": 0.000004,
"cache_creation_input_tokens": 0.000001,
"input_cache_creation": 0.000001,
+ "input_cache_creation_5m": 0.000001,
+ "input_cache_creation_1h": 0.0000016,
"cache_read_input_tokens": 8e-8,
"input_cache_read": 8e-8
}
@@ -1824,7 +1834,7 @@
"modelName": "claude-3.5-haiku-latest",
"matchPattern": "(?i)^(anthropic\/)?(claude-3-5-haiku-latest)$",
"createdAt": "2024-11-05T10:30:50.566Z",
- "updatedAt": "2025-12-12T15:00:06.513Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerId": "claude",
"pricingTiers": [
{
@@ -1840,6 +1850,8 @@
"output_tokens": 0.000004,
"cache_creation_input_tokens": 0.000001,
"input_cache_creation": 0.000001,
+ "input_cache_creation_5m": 0.000001,
+ "input_cache_creation_1h": 0.0000016,
"cache_read_input_tokens": 8e-8,
"input_cache_read": 8e-8
}
@@ -2141,7 +2153,7 @@
"modelName": "claude-3.7-sonnet-20250219",
"matchPattern": "(?i)^(anthropic\/)?(claude-3.7-sonnet-20250219|(eu\\.|us\\.|apac\\.)?anthropic\\.claude-3.7-sonnet-20250219-v1:0|claude-3-7-sonnet-V1@20250219)$",
"createdAt": "2025-02-25T09:35:39.000Z",
- "updatedAt": "2025-12-12T15:00:06.513Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerId": "claude",
"pricingTiers": [
{
@@ -2157,6 +2169,8 @@
"output_tokens": 0.000015,
"cache_creation_input_tokens": 0.00000375,
"input_cache_creation": 0.00000375,
+ "input_cache_creation_5m": 0.00000375,
+ "input_cache_creation_1h": 0.000006,
"cache_read_input_tokens": 3e-7,
"input_cache_read": 3e-7
}
@@ -2168,7 +2182,7 @@
"modelName": "claude-3.7-sonnet-latest",
"matchPattern": "(?i)^(anthropic\/)?(claude-3-7-sonnet-latest)$",
"createdAt": "2025-02-25T09:35:39.000Z",
- "updatedAt": "2025-12-12T15:00:06.513Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerId": "claude",
"pricingTiers": [
{
@@ -2184,6 +2198,8 @@
"output_tokens": 0.000015,
"cache_creation_input_tokens": 0.00000375,
"input_cache_creation": 0.00000375,
+ "input_cache_creation_5m": 0.00000375,
+ "input_cache_creation_1h": 0.000006,
"cache_read_input_tokens": 3e-7,
"input_cache_read": 3e-7
}
@@ -2551,7 +2567,7 @@
"modelName": "claude-sonnet-4-5-20250929",
"matchPattern": "(?i)^(anthropic\/)?(claude-sonnet-4-5(-20250929)?|(eu\\.|us\\.|apac\\.|global\\.)?anthropic\\.claude-sonnet-4-5(-20250929)?-v1(:0)?|claude-sonnet-4-5-V1(@20250929)?|claude-sonnet-4-5(@20250929)?)$",
"createdAt": "2025-09-29T00:00:00.000Z",
- "updatedAt": "2026-02-23T00:00:00.000Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerId": "claude",
"pricingTiers": [
{
@@ -2567,6 +2583,8 @@
"output_tokens": 0.000015,
"cache_creation_input_tokens": 0.00000375,
"input_cache_creation": 0.00000375,
+ "input_cache_creation_5m": 0.00000375,
+ "input_cache_creation_1h": 0.000006,
"cache_read_input_tokens": 3e-7,
"input_cache_read": 3e-7
}
@@ -2591,6 +2609,8 @@
"output_tokens": 0.0000225,
"cache_creation_input_tokens": 0.0000075,
"input_cache_creation": 0.0000075,
+ "input_cache_creation_5m": 0.0000075,
+ "input_cache_creation_1h": 0.000012,
"cache_read_input_tokens": 6e-7,
"input_cache_read": 6e-7
}
@@ -2602,7 +2622,7 @@
"modelName": "claude-sonnet-4-20250514",
"matchPattern": "(?i)^(anthropic\/)?(claude-sonnet-4(-20250514)?|(eu\\.|us\\.|apac\\.|global\\.)?anthropic\\.claude-sonnet-4(-20250514)?-v1(:0)?|claude-sonnet-4-V1(@20250514)?|claude-sonnet-4(@20250514)?)$",
"createdAt": "2025-05-22T17:09:02.131Z",
- "updatedAt": "2026-02-23T00:00:00.000Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerId": "claude",
"pricingTiers": [
{
@@ -2618,6 +2638,8 @@
"output_tokens": 0.000015,
"cache_creation_input_tokens": 0.00000375,
"input_cache_creation": 0.00000375,
+ "input_cache_creation_5m": 0.00000375,
+ "input_cache_creation_1h": 0.000006,
"cache_read_input_tokens": 3e-7,
"input_cache_read": 3e-7
}
@@ -2629,7 +2651,7 @@
"modelName": "claude-sonnet-4-latest",
"matchPattern": "(?i)^(anthropic\/)?(claude-sonnet-4-latest)$",
"createdAt": "2025-05-22T17:09:02.131Z",
- "updatedAt": "2025-12-12T15:00:06.513Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerId": "claude",
"pricingTiers": [
{
@@ -2645,6 +2667,8 @@
"output_tokens": 0.000015,
"cache_creation_input_tokens": 0.00000375,
"input_cache_creation": 0.00000375,
+ "input_cache_creation_5m": 0.00000375,
+ "input_cache_creation_1h": 0.000006,
"cache_read_input_tokens": 3e-7,
"input_cache_read": 3e-7
}
@@ -2656,7 +2680,7 @@
"modelName": "claude-opus-4-20250514",
"matchPattern": "(?i)^(anthropic\/)?(claude-opus-4(-20250514)?|(eu\\.|us\\.|apac\\.)?anthropic\\.claude-opus-4(-20250514)?-v1(:0)?|claude-opus-4(@20250514)?)$",
"createdAt": "2025-05-22T17:09:02.131Z",
- "updatedAt": "2026-02-23T00:00:00.000Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerId": "claude",
"pricingTiers": [
{
@@ -2672,6 +2696,8 @@
"output_tokens": 0.000075,
"cache_creation_input_tokens": 0.00001875,
"input_cache_creation": 0.00001875,
+ "input_cache_creation_5m": 0.00001875,
+ "input_cache_creation_1h": 0.00003,
"cache_read_input_tokens": 0.0000015,
"input_cache_read": 0.0000015
}
@@ -2835,7 +2861,7 @@
"modelName": "claude-opus-4-1-20250805",
"matchPattern": "(?i)^(anthropic\/)?(claude-opus-4-1(-20250805)?|(eu\\.|us\\.|apac\\.)?anthropic\\.claude-opus-4-1(-20250805)?-v1(:0)?|claude-opus-4-1(@20250805)?)$",
"createdAt": "2025-08-05T15:00:00.000Z",
- "updatedAt": "2026-02-23T00:00:00.000Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerId": "claude",
"pricingTiers": [
{
@@ -2851,6 +2877,8 @@
"output_tokens": 0.000075,
"cache_creation_input_tokens": 0.00001875,
"input_cache_creation": 0.00001875,
+ "input_cache_creation_5m": 0.00001875,
+ "input_cache_creation_1h": 0.00003,
"cache_read_input_tokens": 0.0000015,
"input_cache_read": 0.0000015
}
@@ -3128,7 +3156,7 @@
"modelName": "claude-haiku-4-5-20251001",
"matchPattern": "(?i)^(anthropic\/)?(claude-haiku-4-5-20251001|(eu\\.|us\\.|apac\\.|global\\.)?anthropic\\.claude-haiku-4-5-20251001-v1:0|claude-4-5-haiku@20251001)$",
"createdAt": "2025-10-16T08:20:44.558Z",
- "updatedAt": "2025-12-12T15:00:06.513Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerId": "claude",
"pricingTiers": [
{
@@ -3144,6 +3172,8 @@
"output_tokens": 0.000005,
"cache_creation_input_tokens": 0.00000125,
"input_cache_creation": 0.00000125,
+ "input_cache_creation_5m": 0.00000125,
+ "input_cache_creation_1h": 0.000002,
"cache_read_input_tokens": 1e-7,
"input_cache_read": 1e-7
}
@@ -3215,7 +3245,7 @@
"modelName": "claude-opus-4-5-20251101",
"matchPattern": "(?i)^(anthropic\/)?(claude-opus-4-5(-20251101)?|(eu\\.|us\\.|apac\\.)?anthropic\\.claude-opus-4-5(-20251101)?-v1(:0)?|claude-opus-4-5(@20251101)?)$",
"createdAt": "2025-11-24T20:53:27.571Z",
- "updatedAt": "2026-02-23T00:00:00.000Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerConfig": null,
"tokenizerId": "claude",
"pricingTiers": [
@@ -3232,6 +3262,8 @@
"output_tokens": 25e-6,
"cache_creation_input_tokens": 6.25e-6,
"input_cache_creation": 6.25e-6,
+ "input_cache_creation_5m": 6.25e-6,
+ "input_cache_creation_1h": 10e-6,
"cache_read_input_tokens": 0.5e-6,
"input_cache_read": 0.5e-6
}
@@ -3243,7 +3275,7 @@
"modelName": "claude-sonnet-4-6",
"matchPattern": "(?i)^(anthropic\\/)?(claude-sonnet-4-6|(eu\\.|us\\.|apac\\.)?anthropic\\.claude-sonnet-4-6-v1(:0)?|claude-sonnet-4-6)$",
"createdAt": "2026-02-18T00:00:00.000Z",
- "updatedAt": "2026-02-18T00:00:00.000Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerConfig": null,
"tokenizerId": "claude",
"pricingTiers": [
@@ -3260,6 +3292,8 @@
"output_tokens": 15e-6,
"cache_creation_input_tokens": 3.75e-6,
"input_cache_creation": 3.75e-6,
+ "input_cache_creation_5m": 3.75e-6,
+ "input_cache_creation_1h": 6e-6,
"cache_read_input_tokens": 3e-7,
"input_cache_read": 3e-7
}
@@ -3284,6 +3318,8 @@
"output_tokens": 22.5e-6,
"cache_creation_input_tokens": 7.5e-6,
"input_cache_creation": 7.5e-6,
+ "input_cache_creation_5m": 7.5e-6,
+ "input_cache_creation_1h": 12e-6,
"cache_read_input_tokens": 6e-7,
"input_cache_read": 6e-7
}
@@ -3295,7 +3331,7 @@
"modelName": "claude-opus-4-6",
"matchPattern": "(?i)^(anthropic\/)?(claude-opus-4-6|(eu\\.|us\\.|apac\\.)?anthropic\\.claude-opus-4-6-v1(:0)?|claude-opus-4-6)$",
"createdAt": "2026-02-09T00:00:00.000Z",
- "updatedAt": "2026-02-09T00:00:00.000Z",
+ "updatedAt": "2026-03-04T00:00:00.000Z",
"tokenizerConfig": null,
"tokenizerId": "claude",
"pricingTiers": [
@@ -3312,6 +3348,8 @@
"output_tokens": 25e-6,
"cache_creation_input_tokens": 6.25e-6,
"input_cache_creation": 6.25e-6,
+ "input_cache_creation_5m": 6.25e-6,
+ "input_cache_creation_1h": 10e-6,
"cache_read_input_tokens": 0.5e-6,
"input_cache_read": 0.5e-6
}