Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions components/ai-elements/image.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import type { Experimental_GeneratedImage } from "ai";
import type { GeneratedFile } from "ai";
import { cn } from "@/lib/utils";

export type ImageProps = Experimental_GeneratedImage & {
export type ImageProps = GeneratedFile & {
className?: string;
alt?: string;
};
Expand Down
4 changes: 2 additions & 2 deletions components/elements/image.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import type { Experimental_GeneratedImage } from "ai";
import type { GeneratedFile } from "ai";
import { cn } from "@/lib/utils";

export type ImageProps = Experimental_GeneratedImage & {
export type ImageProps = GeneratedFile & {
className?: string;
alt?: string;
};
Expand Down
10 changes: 5 additions & 5 deletions lib/ai/models.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const mockUsage = {

export const chatModel = new MockLanguageModelV3({
doGenerate: async () => ({
finishReason: "stop",
finishReason: { unified: "stop", raw: "stop" },
usage: mockUsage,
content: [{ type: "text", text: "Hello, world!" }],
warnings: [],
Expand All @@ -25,7 +25,7 @@ export const chatModel = new MockLanguageModelV3({

export const reasoningModel = new MockLanguageModelV3({
doGenerate: async () => ({
finishReason: "stop",
finishReason: { unified: "stop", raw: "stop" },
usage: mockUsage,
content: [{ type: "text", text: "Hello, world!" }],
warnings: [],
Expand All @@ -41,7 +41,7 @@ export const reasoningModel = new MockLanguageModelV3({

export const titleModel = new MockLanguageModelV3({
doGenerate: async () => ({
finishReason: "stop",
finishReason: { unified: "stop", raw: "stop" },
usage: mockUsage,
content: [{ type: "text", text: "This is a test title" }],
warnings: [],
Expand All @@ -56,7 +56,7 @@ export const titleModel = new MockLanguageModelV3({
{ id: "1", type: "text-end" },
{
type: "finish",
finishReason: "stop",
finishReason: { unified: "stop", raw: "stop" },
usage: mockUsage,
},
],
Expand All @@ -66,7 +66,7 @@ export const titleModel = new MockLanguageModelV3({

export const artifactModel = new MockLanguageModelV3({
doGenerate: async () => ({
finishReason: "stop",
finishReason: { unified: "stop", raw: "stop" },
usage: mockUsage,
content: [{ type: "text", text: "Hello, world!" }],
warnings: [],
Expand Down
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@
"test": "export PLAYWRIGHT=True && pnpm exec playwright test"
},
"dependencies": {
"@ai-sdk/gateway": "2.0.0-beta.85",
"@ai-sdk/provider": "3.0.0-beta.27",
"@ai-sdk/react": "3.0.0-beta.162",
"@ai-sdk/gateway": "3.0.0",
"@ai-sdk/provider": "3.0.0",
"@ai-sdk/react": "3.0.1",
"@codemirror/lang-javascript": "^6.2.2",
"@codemirror/lang-python": "^6.1.6",
"@codemirror/state": "^6.5.0",
Expand All @@ -47,7 +47,7 @@
"@vercel/functions": "^2.0.0",
"@vercel/otel": "^1.12.0",
"@xyflow/react": "^12.10.0",
"ai": "6.0.0-beta.159",
"ai": "6.0.1",
"bcrypt-ts": "^5.0.2",
"class-variance-authority": "^0.7.1",
"classnames": "^2.5.1",
Expand Down
62 changes: 31 additions & 31 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion tests/prompts/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export function getResponseChunksByPrompt(
{ type: "text-start", id: "t1" },
{ type: "text-delta", id: "t1", delta: "Hello, world!" },
{ type: "text-end", id: "t1" },
{ type: "finish", finishReason: "stop", usage: mockUsage }
{ type: "finish", finishReason: { unified: "stop", raw: "stop" }, usage: mockUsage }
);

return chunks;
Expand Down
Loading