Skip to main content
A deployment strategy is a self-contained directory under src/kapso/deployment/strategies/. Add one and the registry discovers it; no core code changes.

Strategy structure

Each strategy is a directory with these files:

Step 1: Create directory

Step 2: Implement runner

Create runner.py with a Runner class:

Step 3: Create configuration

Create config.yaml:

Step 4: Selector instruction

Create selector_instruction.txt for auto-selection:

Step 5: Adapter instruction

Create adapter_instruction.txt for code adaptation:

Step 6: Register strategy

Create __init__.py:
The strategy is auto-discovered by the registry.

Runner base class

Strategy registry

Strategies are auto-registered when discovered:

Using your strategy

Testing your strategy

Example: HTTP strategy

A strategy that deploys as an HTTP server:

Deployment architecture

How a strategy is discovered

Deployment strategies

The five that ship
Related pages: Deployment architecture · Deployment strategies · Deployment Kapso is an open-source framework by Leeroo that builds software toward measurable goals through experiment campaigns. Source code: github.com/Leeroo-AI/kapso · Install: pip install leeroo-kapso · Every page as plain text: llms.txt.