Skip to content

Commit b407e28

Browse files
committed
update llm function access control
1 parent 855b0be commit b407e28

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
export const corsHeaders = {
22
"Access-Control-Allow-Origin": "*",
3-
"Access-Control-Allow-Headers": "authorization, x-client-info, apikey, content-type",
3+
"Access-Control-Allow-Headers": "authorization, x-client-info, apikey, content-type, user-agent",
4+
"Access-Control-Allow-Methods": "POST, GET, OPTIONS",
45
};

apps/web/supabase/functions/llm/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ Deno.serve(async (req) => {
2929
const needsToolCalling = requestBody.tools && requestBody.tool_choice !== "none";
3030

3131
const modelsToUse = needsToolCalling
32-
? ["anthropic/claude-haiku-4.5", "z-ai/glm-4.6"]
33-
: ["openai/chatgpt-4o-latest", "moonshotai/kimi-k2-0905"];
32+
? ["anthropic/claude-haiku-4.5", "openai/gpt-oss-120b:nitro"]
33+
: ["openai/chatgpt-4o-latest", "moonshotai/kimi-k2-0905:nitro"];
3434

3535
const { model: _, ...bodyWithoutModel } = requestBody;
3636

0 commit comments

Comments
 (0)