⚠️ Warning: osmosis-ai is still in active development. APIs may change between versions.
Python SDK for Osmosis AI, a platform for training LLMs with reinforcement learning. Define custom reward functions, LLM-as-judge rubrics, and agent tools -- then use this SDK to build and test them locally before submitting training runs on managed GPU clusters.
Pick a training mode and follow the example repo:
| Local Rollout | Remote Rollout | |
|---|---|---|
| How it works | Osmosis manages the agent loop. You provide reward functions, rubrics, and MCP tools via a GitHub-synced repo. | You implement and host a RolloutAgentLoop server. Full control over agent behavior. |
| Best for | Standard tool-use agents, fast iteration, zero infrastructure | Custom agent architectures, complex orchestration, persistent environments |
| Example repo | osmosis-git-sync-example | osmosis-remote-rollout-example |
| Docs | Local Rollout Guide | Remote Rollout Guide |
Requires Python 3.10+. For development setup, see CONTRIBUTING.md.
- An LLM API key (e.g., OpenAI, Anthropic, Groq) -- required for
osmosis testandosmosis eval. See supported providers. - Osmosis account (optional) -- needed for platform features like
osmosis login, workspace management, and submitting training runs. Sign up at platform.osmosis.ai.
pip
pip install osmosis-ai # Core SDK
pip install osmosis-ai[server] # + FastAPI server for Remote Rollout
pip install osmosis-ai[mcp] # + MCP tool support for Local Rollout
pip install osmosis-ai[full] # All featuresuv
uv add osmosis-ai # Core SDK
uv add osmosis-ai[server] # + FastAPI server for Remote Rollout
uv add osmosis-ai[mcp] # + MCP tool support for Local Rollout
uv add osmosis-ai[full] # All featuresBoth modes share the same CLI tools: Test Mode | Eval Mode | CLI Reference
See CONTRIBUTING.md for development setup, testing, linting, and PR guidelines.
MIT License - see LICENSE file for details.