Skip to content
Open
Show file tree
Hide file tree
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
6 changes: 3 additions & 3 deletions docs/docs/usage-guide/changing_a_model.md
Original file line number Diff line number Diff line change
Expand Up @@ -164,12 +164,12 @@ key = ... # your Groq api key

### SambaNova

To use MiniMax-M2.7 model with SambaNova, for example, set:
To use MiniMax-M3 model with SambaNova, for example, set:

```toml
[config] # in configuration.toml
model = "sambanova/MiniMax-M2.7"
fallback_models = ["sambanova/MiniMax-M2.5"]
model = "sambanova/MiniMax-M3"
fallback_models = ["sambanova/MiniMax-M2.7"]
[sambanova] # in .secrets.toml
key = ... # your SambaNova api key
```
Expand Down
2 changes: 1 addition & 1 deletion pr_agent/algo/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -226,8 +226,8 @@
'groq/meta-llama/llama-4-scout-17b-16e-instruct': 131072,
'groq/llama-3.3-70b-versatile': 128000,
'groq/llama-3.1-8b-instant': 128000,
'sambanova/MiniMax-M3': 192000,
'sambanova/MiniMax-M2.7': 192000,
'sambanova/MiniMax-M2.5': 160000,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Action required

1. Removed model breaks configs 🐞 Bug ☼ Reliability

By deleting sambanova/MiniMax-M2.5 from MAX_TOKENS, any existing deployment still configured
with that model id will now raise an exception at runtime when token budgeting calls
get_max_tokens(). The default custom_model_max_tokens is non-positive, so there is no fallback
path and the agent fails fast.
Agent Prompt
## Issue description
`MAX_TOKENS` no longer contains `sambanova/MiniMax-M2.5`, but the codebase treats missing models as a hard error. This creates a breaking change for any user config that still references the removed model id (either as `config.model` or in `fallback_models`).

## Issue Context
`get_max_tokens(model)` raises if the model is not in `MAX_TOKENS` and `config.custom_model_max_tokens` is not positive. The default configuration sets `custom_model_max_tokens=-1`, so most users will hit the exception path.

## Fix Focus Areas
Choose one of these approaches:
- Re-add `sambanova/MiniMax-M2.5` into `MAX_TOKENS` (optionally comment as deprecated), so existing configs continue to work.
- Or add an alias/migration in `get_max_tokens()` (and any other model-normalization code) that maps `sambanova/MiniMax-M2.5` -> `sambanova/MiniMax-M2.7` (or keeps the old 160k cap) while preserving new recommended defaults.

References:
- pr_agent/algo/__init__.py[226-233]
- pr_agent/algo/utils.py[992-1013]
- pr_agent/settings/configuration.toml[30-35]

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@octo-patch please bring back this model 🙏

'sambanova/Meta-Llama-3.3-70B-Instruct': 128000,
'sambanova/gpt-oss-120b': 128000,
'sambanova/DeepSeek-V3.1': 128000,
Expand Down
2 changes: 1 addition & 1 deletion tests/unittest/test_litellm_api_key_guard.py
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,7 @@ async def test_sambanova_key_forwarded_for_non_ollama_model(self, monkeypatch):

assert litellm.api_key == sambanova_key
await handler.chat_completion(
model="sambanova/MiniMax-M2.7", system="sys", user="usr"
model="sambanova/MiniMax-M3", system="sys", user="usr"
)

assert mock_call.call_args[1].get("api_key") == sambanova_key
Expand Down
Loading