mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-29 08:44:59 +00:00
Add context windows and pricing for 1106 models
This commit is contained in:
parent
c8b95b486f
commit
5098be6172
1 changed files with 9 additions and 1 deletions
|
@ -7,6 +7,8 @@ from .model import Model
|
|||
known_tokens = {
|
||||
"gpt-3.5-turbo": 4,
|
||||
"gpt-4": 8,
|
||||
"gpt-4-1106-preview": 128,
|
||||
"gpt-3.5-turbo-1106": 16,
|
||||
}
|
||||
|
||||
|
||||
|
@ -41,6 +43,9 @@ class OpenAIModel(Model):
|
|||
elif tokens == 32:
|
||||
self.prompt_price = 0.06
|
||||
self.completion_price = 0.12
|
||||
elif tokens == 128:
|
||||
self.prompt_price = 0.01
|
||||
self.completion_price = 0.03
|
||||
|
||||
return
|
||||
|
||||
|
@ -48,7 +53,10 @@ class OpenAIModel(Model):
|
|||
self.edit_format = "whole"
|
||||
self.always_available = True
|
||||
|
||||
if tokens == 4:
|
||||
if self.name == "gpt-3.5-turbo-1106":
|
||||
self.prompt_price = 0.001
|
||||
self.completion_price = 0.002
|
||||
elif tokens == 4:
|
||||
self.prompt_price = 0.0015
|
||||
self.completion_price = 0.002
|
||||
elif tokens == 16:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue