Spaces:
Running
Running
Update app/api/ask-ai/route.ts
Browse files- app/api/ask-ai/route.ts +1 -2
app/api/ask-ai/route.ts
CHANGED
@@ -19,7 +19,6 @@ import {
|
|
19 |
} from "@/lib/prompts";
|
20 |
import MY_TOKEN_KEY from "@/lib/get-cookie-name";
|
21 |
import { Page } from "@/types";
|
22 |
-
import { callAiRewritePrompt } from "@/app/actions/rewrite-prompt";
|
23 |
|
24 |
const ipAddresses = new Map();
|
25 |
|
@@ -98,7 +97,7 @@ export async function POST(request: NextRequest) {
|
|
98 |
? PROVIDERS[selectedModel.autoProvider as keyof typeof PROVIDERS]
|
99 |
: PROVIDERS[provider as keyof typeof PROVIDERS] ?? DEFAULT_PROVIDER;
|
100 |
|
101 |
-
|
102 |
|
103 |
// if (prompt?.length < 240) {
|
104 |
|
|
|
19 |
} from "@/lib/prompts";
|
20 |
import MY_TOKEN_KEY from "@/lib/get-cookie-name";
|
21 |
import { Page } from "@/types";
|
|
|
22 |
|
23 |
const ipAddresses = new Map();
|
24 |
|
|
|
97 |
? PROVIDERS[selectedModel.autoProvider as keyof typeof PROVIDERS]
|
98 |
: PROVIDERS[provider as keyof typeof PROVIDERS] ?? DEFAULT_PROVIDER;
|
99 |
|
100 |
+
const rewrittenPrompt = prompt;
|
101 |
|
102 |
// if (prompt?.length < 240) {
|
103 |
|