string_model.py
Run the Example
1
Set up your virtual environment
2
Install dependencies
3
Export your Xiaomi MiMo API key
4
Run the example
Save the code above as
string_model.py, then run:Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
Create a MiMo agent without importing the model class, using the model="xiaomi:<model-id>" string shorthand.
"""
Xiaomi MiMo String Model
========================
Create a MiMo agent without importing the model class, using the
`model="xiaomi:<model-id>"` string shorthand.
"""
from agno.agent import Agent
# ---------------------------------------------------------------------------
# Create Agent
# ---------------------------------------------------------------------------
agent = Agent(model="xiaomi:mimo-v2.5-pro", markdown=True)
# ---------------------------------------------------------------------------
# Run Agent
# ---------------------------------------------------------------------------
if __name__ == "__main__":
agent.print_response(
"Explain why tool-calling agents need conversation history.",
stream=True,
)
Set up your virtual environment
uv venv --python 3.12
source .venv/bin/activate
uv venv --python 3.12
.venv\Scripts\activate
Install dependencies
uv pip install -U agno openai
Export your Xiaomi MiMo API key
export MIMO_API_KEY="your_mimo_api_key_here"
$Env:MIMO_API_KEY="your_mimo_api_key_here"
Run the example
string_model.py, then run:python string_model.py
Was this page helpful?