Skip to content

SWE-agent takes a GitHub issue and tries to automatically fix it, using your LM of choice. It can also be employed for offensive cybersecurity or competitive coding challenges. [NeurIPS 2024]

feat(models): natively support claude haiku (#9)

Montague Moran163a55b35bc4
diff --git a/sweagent/agent/models.py b/sweagent/agent/models.py
index 55394360..0ce735cd 100644
--- a/sweagent/agent/models.py
+++ b/sweagent/agent/models.py
@@ -294,12 +294,19 @@ class AnthropicModel(BaseModel):
"cost_per_input_token": 3e-06,
"cost_per_output_token": 1.5e-05,
},
+ "claude-3-haiku-20240307": {
+ "max_context": 200_000,
+ "max_tokens": 4096,
+ "cost_per_input_token": 2.5e-07,
+ "cost_per_output_token": 1.25e-06,
+ },
}
SHORTCUTS = {
"claude": "claude-2",
"claude-opus": "claude-3-opus-20240229",
"claude-sonnet": "claude-3-sonnet-20240229",
+ "claude-haiku": "claude-3-haiku-20240307",
}
def __init__(self, args: ModelArguments, commands: list[Command]):