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
2 changes: 1 addition & 1 deletion packages/openmemory-py/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ embeddings={
}
```

> uses MiniMax's `embo-01` model (1536 dimensions). for chat completions, MiniMax supports `MiniMax-M2.7` and `MiniMax-M2.5-highspeed` via OpenAI-compatible API.
> uses MiniMax's `embo-01` model (1536 dimensions). for chat completions, MiniMax supports `MiniMax-M3` (default), `MiniMax-M2.7`, and `MiniMax-M2.7-highspeed` via OpenAI-compatible API.

#### aws bedrock
```python
Expand Down
2 changes: 1 addition & 1 deletion packages/openmemory-py/src/openmemory/ai/minimax.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ def __init__(self, api_key: str = None, base_url: str = None):
self.client = AsyncOpenAI(api_key=self.api_key, base_url=self.base_url)

async def chat(self, messages: List[Dict[str, str]], model: str = None, **kwargs) -> str:
m = model or env.minimax_model or "MiniMax-M2.7"
m = model or env.minimax_model or "MiniMax-M3"
temperature = kwargs.pop("temperature", None)
if temperature is not None:
temperature = max(0.0, min(float(temperature), 1.0))
Expand Down
8 changes: 4 additions & 4 deletions packages/openmemory-py/tests/test_minimax.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ async def test_chat_default_model(self):
await adapter.chat([{"role": "user", "content": "test"}])

call_kwargs = adapter.client.chat.completions.create.call_args
assert call_kwargs.kwargs["model"] == "MiniMax-M2.7"
assert call_kwargs.kwargs["model"] == "MiniMax-M3"

@pytest.mark.asyncio
async def test_chat_custom_model(self):
Expand All @@ -87,10 +87,10 @@ async def test_chat_custom_model(self):

await adapter.chat(
[{"role": "user", "content": "test"}],
model="MiniMax-M2.5-highspeed",
model="MiniMax-M2.7-highspeed",
)
call_kwargs = adapter.client.chat.completions.create.call_args
assert call_kwargs.kwargs["model"] == "MiniMax-M2.5-highspeed"
assert call_kwargs.kwargs["model"] == "MiniMax-M2.7-highspeed"

@pytest.mark.asyncio
async def test_chat_temperature_clamping(self):
Expand Down Expand Up @@ -408,7 +408,7 @@ async def test_chat_real_api(self):
adapter = MiniMaxAdapter(api_key=api_key)
result = await adapter.chat(
[{"role": "user", "content": "Say 'hello' and nothing else."}],
model="MiniMax-M2.5-highspeed",
model="MiniMax-M2.7-highspeed",
temperature=0.0,
)
assert isinstance(result, str)
Expand Down
Loading