Skip to content

Open-source status page, incident response and uptime monitoring

feat(ai): use Claude Haiku 5.5 (free) and Sonnet 5.5 (paid) (#2869)

Maximilian Kaske786563473711
diff --git a/apps/dashboard/src/lib/ai/create-ai-filter-handler.ts b/apps/dashboard/src/lib/ai/create-ai-filter-handler.ts
index a855c78bf..ef9e53ed0 100644
--- a/apps/dashboard/src/lib/ai/create-ai-filter-handler.ts
+++ b/apps/dashboard/src/lib/ai/create-ai-filter-handler.ts
@@ -61,14 +61,15 @@ export function createAIFilterHandler({
const result = streamObject({
model,
schema: outputSchema,
- messages: [
- {
- role: "system",
- content: staticPrompt,
- providerOptions: {
- anthropic: { cacheControl: { type: "ephemeral" } },
- },
+ // AI SDK v7 rejects system messages inside `messages`.
+ instructions: {
+ role: "system",
+ content: staticPrompt,
+ providerOptions: {
+ anthropic: { cacheControl: { type: "ephemeral" } },
},
+ },
+ messages: [
{
role: "user",
content: `Current date/time: ${now}\n\nQuery: ${query}`,
diff --git a/packages/ai/src/resolve-model.test.ts b/packages/ai/src/resolve-model.test.ts
index 21181ceaf..c9d7c6921 100644
--- a/packages/ai/src/resolve-model.test.ts
+++ b/packages/ai/src/resolve-model.test.ts
@@ -25,14 +25,14 @@ describe("resolveChatModel", () => {
test("gateway path: free plan resolves the cheaper model string", () => {
process.env.AI_GATEWAY_API_KEY = "gw-key";
expect(resolveChatModel({ plan: "free" })).toBe(
- "anthropic/claude-haiku-4.5",
+ "anthropic/claude-haiku-5.5",
);
});
test("gateway path: paid plan resolves the stronger model string", () => {
process.env.AI_GATEWAY_API_KEY = "gw-key";
expect(resolveChatModel({ plan: "team" })).toBe(
- "anthropic/claude-sonnet-5",
+ "anthropic/claude-sonnet-5.5",
);
});
diff --git a/packages/ai/src/resolve-model.ts b/packages/ai/src/resolve-model.ts
index 97916aea0..f81c47551 100644
--- a/packages/ai/src/resolve-model.ts
+++ b/packages/ai/src/resolve-model.ts
@@ -5,8 +5,8 @@ import type { LanguageModel } from "ai";
// Hosted openstatus.dev defaults, resolved through the Vercel AI Gateway as
// bare model strings. Free workspaces get the cheaper model because we pay for
// their inference; this tiering applies ONLY to the gateway path.
-const GATEWAY_MODEL_FREE = "anthropic/claude-haiku-4.5";
-const GATEWAY_MODEL_PAID = "anthropic/claude-sonnet-5";
+const GATEWAY_MODEL_FREE = "anthropic/claude-haiku-5.5";
+const GATEWAY_MODEL_PAID = "anthropic/claude-sonnet-5.5";
// `||` (not `??`) so empty / whitespace-only env values fall back instead of
// being passed through as a real value.