Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add new model: GPT-4o #459

Merged
merged 1 commit into from
May 13, 2024
Merged
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
9 changes: 8 additions & 1 deletion src/lib/providers/openai/models.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,12 @@ const gpt4 = {
completion: 0.00006, // $0.06 per 1000 tokens completion
max: 8192 // 8k max token buffer
}
const gpt4o = {
...chatModelBase,
prompt: 0.000005, // $0.005 per 1000 tokens prompt
completion: 0.000015, // $0.015 per 1000 tokens completion
max: 131072 // 128k max token buffer
}
const gpt432k = {
...chatModelBase,
prompt: 0.00006, // $0.06 per 1000 tokens prompt
Expand All @@ -96,6 +102,7 @@ export const chatModels : Record<string, ModelDetail> = {
'gpt-3.5-turbo-16k': { ...gpt3516k },
'gpt-3.5-turbo-16k-0613': { ...gpt3516k },
'gpt-4': { ...gpt4 },
'gpt-4o': { ...gpt4o },
'gpt-4-turbo-preview': { ...gpt4128kpreview },
'gpt-4-turbo-2024-04-09': { ...gpt4128kpreview },
'gpt-4-0314': { ...gpt4 },
Expand Down Expand Up @@ -200,4 +207,4 @@ export const imageModels : Record<string, ModelDetail> = {
}
}

</script>
</script>