Skip to content

Commit 13849f3

Browse files
committed
Fix lint issues: organize imports, format route.ts/artifact.tsx, prefix unused param
1 parent f990ce0 commit 13849f3

File tree

3 files changed

+4
-10
lines changed

3 files changed

+4
-10
lines changed

app/(chat)/api/chat/route.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ import {
77
stepCountIs,
88
streamText,
99
} from "ai";
10-
import { getWeather } from "@/lib/ai/tools/get-weather";
1110
import { unstable_cache as cache } from "next/cache";
1211
import type { ModelCatalog } from "tokenlens/core";
12+
import { getWeather } from "@/lib/ai/tools/get-weather";
1313

1414
// Type definition for resumable stream context (feature currently disabled - requires Redis)
1515
type ResumableStreamContext = {
@@ -179,9 +179,7 @@ export async function POST(request: Request) {
179179
messages: convertToModelMessages(uiMessages),
180180
stopWhen: stepCountIs(5),
181181
experimental_activeTools:
182-
selectedChatModel === "chat-model-reasoning"
183-
? []
184-
: ["getWeather"],
182+
selectedChatModel === "chat-model-reasoning" ? [] : ["getWeather"],
185183
experimental_transform: smoothStream({ chunking: "word" }),
186184
tools: {
187185
getWeather,

components/artifact.tsx

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,7 @@ import { useSidebar } from "./ui/sidebar";
2828
import { VersionFooter } from "./version-footer";
2929
import type { VisibilityType } from "./visibility-selector";
3030

31-
export const artifactDefinitions = [
32-
textArtifact,
33-
codeArtifact,
34-
sheetArtifact,
35-
];
31+
export const artifactDefinitions = [textArtifact, codeArtifact, sheetArtifact];
3632
export type ArtifactKind = (typeof artifactDefinitions)[number]["kind"];
3733

3834
export type UIArtifact = {

lib/ai/prompts.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ About the origin of user's request:
2020
`;
2121

2222
export const systemPrompt = ({
23-
selectedChatModel,
23+
selectedChatModel: _selectedChatModel,
2424
requestHints,
2525
}: {
2626
selectedChatModel: string;

0 commit comments

Comments
 (0)