add pixtral 12b
This commit is contained in:
parent
2f848de25b
commit
e0e3f7f32c
@ -1,5 +1,6 @@
|
||||
import { z } from "zod";
|
||||
import { createAzure } from '@ai-sdk/azure';
|
||||
import { mistral } from '@ai-sdk/mistral';
|
||||
import {
|
||||
convertToCoreMessages,
|
||||
streamText,
|
||||
@ -49,6 +50,7 @@ const anthropicVertex = createAnthropicVertex({
|
||||
const registry = experimental_createProviderRegistry({
|
||||
anthropicVertex,
|
||||
azure,
|
||||
mistral,
|
||||
});
|
||||
|
||||
function sanitizeUrl(url: string): string {
|
||||
@ -72,7 +74,7 @@ export async function POST(req: Request) {
|
||||
model: registry.languageModel(model),
|
||||
messages: convertToCoreMessages(messages),
|
||||
temperature: provider === "azure" ? 0.72 : 0,
|
||||
topP: 0,
|
||||
topP: provider === "mistral" ? 1 : 0,
|
||||
frequencyPenalty: 0,
|
||||
presencePenalty: 0,
|
||||
system: `
|
||||
|
||||
@ -71,7 +71,8 @@ import {
|
||||
Clock,
|
||||
Cpu,
|
||||
Network,
|
||||
ExternalLink
|
||||
ExternalLink,
|
||||
Camera
|
||||
} from 'lucide-react';
|
||||
import {
|
||||
HoverCard,
|
||||
@ -2370,6 +2371,7 @@ The o1-mini is a new OpenAI model that is optimized for reasoning tasks. Current
|
||||
|
||||
const models = [
|
||||
{ value: "azure:gpt4o-mini", label: "OpenAI", icon: Zap, description: "High speed, lower quality", color: "emerald" },
|
||||
{ value: "mistral:pixtral-12b-2409", label: "Mistral", icon: Camera, description: "Pixtral 12B", color: "blue" },
|
||||
{ value: "anthropicVertex:claude-3-5-sonnet@20240620", label: "Claude", icon: Sparkles, description: "High quality, lower speed", color: "indigo" },
|
||||
{ value: "openai/o1-mini", label: "Reasoning", icon: Flame, description: "Experimental model", color: "orange" },
|
||||
]
|
||||
@ -2398,6 +2400,10 @@ The o1-mini is a new OpenAI model that is optimized for reasoning tasks. Current
|
||||
return isSelected
|
||||
? '!bg-orange-500 !text-white hover:!bg-orange-600'
|
||||
: '!text-orange-700 hover:!bg-orange-100';
|
||||
case 'blue':
|
||||
return isSelected
|
||||
? '!bg-blue-500 !text-white hover:!bg-blue-600'
|
||||
: '!text-blue-700 hover:!bg-blue-100';
|
||||
default:
|
||||
return isSelected
|
||||
? 'bg-gray-500 text-white hover:bg-gray-600'
|
||||
|
||||
@ -12,6 +12,7 @@
|
||||
"@ai-sdk/azure": "^0.0.31",
|
||||
"@ai-sdk/cohere": "latest",
|
||||
"@ai-sdk/google": "^0.0.46",
|
||||
"@ai-sdk/mistral": "^0.0.41",
|
||||
"@ai-sdk/openai": "^0.0.58",
|
||||
"@e2b/code-interpreter": "^0.0.8",
|
||||
"@foobar404/wave": "^2.0.5",
|
||||
|
||||
@ -14,6 +14,9 @@ dependencies:
|
||||
'@ai-sdk/google':
|
||||
specifier: ^0.0.46
|
||||
version: 0.0.46(zod@3.23.8)
|
||||
'@ai-sdk/mistral':
|
||||
specifier: ^0.0.41
|
||||
version: 0.0.41(zod@3.23.8)
|
||||
'@ai-sdk/openai':
|
||||
specifier: ^0.0.58
|
||||
version: 0.0.58(zod@3.23.8)
|
||||
@ -252,6 +255,17 @@ packages:
|
||||
zod: 3.23.8
|
||||
dev: false
|
||||
|
||||
/@ai-sdk/mistral@0.0.41(zod@3.23.8):
|
||||
resolution: {integrity: sha512-UTVtdC61AF4KQWnM3VAoo6/gi7G1frL3qVlKyW5toiRAUjCdeqLJUF2ho2iO8yqf+qIT6j57jWT3o6pqREy3Wg==}
|
||||
engines: {node: '>=18'}
|
||||
peerDependencies:
|
||||
zod: ^3.0.0
|
||||
dependencies:
|
||||
'@ai-sdk/provider': 0.0.23
|
||||
'@ai-sdk/provider-utils': 1.0.19(zod@3.23.8)
|
||||
zod: 3.23.8
|
||||
dev: false
|
||||
|
||||
/@ai-sdk/openai@0.0.53(zod@3.23.8):
|
||||
resolution: {integrity: sha512-Wm4+EYG2Zl5WmhvZJrLhrBY+C46FEQmDjQ9ZB5h2DvRoJZNKtNiVNFMEQuyBK7QwivvlCSMJkPRBfFcbJgNLMQ==}
|
||||
engines: {node: '>=18'}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user