Skip to main content

Sandboxed rollouts you call like typed Python (import as `agentix`)

Project description

Agentix

Sandboxed rollouts you call like typed Python.

Turn agents, tools, and scorers into Python callables. Package their dependencies into runtime images. Call them from evaluators, trainers, and orchestration code without writing a new runner for every pairing.

GitHub Stars Python 3.11+ Docs

Documentation | Quickstart | Cookbook | Architecture

The 10-Second Model

Agentix has two primitives:

  • Remote calls: client.remote(fn, *args, **kwargs) runs a Python callable inside a sandbox worker. The callable is serialized with stdlib pickle, Python's native callable reference mechanism.
  • Bundles: agentix build [path] packages a Python project and its declared dependencies into a deploy-ready runtime image.
from agentix import RuntimeClient
from app import run

async with RuntimeClient(sandbox.runtime_url) as client:
    result = await client.remote(run, input="hello")

The unit of composition is not a bespoke benchmark runner or agent adapter. It is a Python callable.

Why Agentix Exists

Agent experiments sprawl quickly. One agent needs a CLI wrapper. Another needs a Python harness. A benchmark needs repo setup, grading scripts, and logs. A training loop needs the same pieces batched across many sandboxes.

Agentix collapses that matrix into one execution contract: if Python can serialize the callable and the sandbox has its dependencies, the host can call it.

You have You expose You call
Claude Code, Codex, Aider, OpenHands, or an internal agent async def run(...) -> RunResult await client.remote(run, ...)
Shell, files, repo setup, or local tools async def run(command: str) -> BashResult await client.remote(bash_run, ...)
SWE-bench, MLE-Bench, or an internal evaluator async def score(...) -> Score await client.remote(score, ...)
Streaming or interactive workflows async def stream(...) -> AsyncIterator[Event] async for event in client.remote(stream, ...)

What Ships

  • Typed remote calls across the host-to-sandbox boundary.
  • Unary, streaming, and bidirectional call shapes inferred from callable signatures.
  • One runtime worker process today behind an internal worker backend boundary, so future pools or per-call isolation can stay API-compatible.
  • Bundle builds from normal Python projects and pyproject.toml dependencies.
  • Optional Nix system dependencies when a project includes default.nix.
  • Deployment backend plugins through the agentix.deployment entry point group.

Quickstart

Install the host framework and a deployment backend:

pip install agentixx agentix-deployment-docker

Create a remote callable:

# src/hello_agentix/__init__.py
async def run(input: str) -> str:
    return f"sandbox saw: {input}"

Build a bundle:

agentix build ./hello-agentix -o hello-agentix:0.1.0

Deploy it and call the callable:

import asyncio

from agentix import RuntimeClient
from agentix.deployment.base import SandboxConfig, session
from agentix.deployment.docker import DockerDeployment
from hello_agentix import run


async def main() -> None:
    deployment = DockerDeployment()
    config = SandboxConfig(image="hello-agentix:0.1.0")

    async with session(deployment, config) as sandbox:
        async with RuntimeClient(sandbox.runtime_url) as client:
            print(await client.remote(run, input="hello"))


asyncio.run(main())

Read the full quickstart for the package layout and runtime-image prerequisites.

Architecture

Host process
  RuntimeClient.remote(fn, ...)
    serializes callable with pickle
    detects unary / stream / bidi
    encodes args and kwargs
        |
        v
Sandbox
  agentix-server
        |
        v
  worker subprocess
    unpickles callable
    validates args
    calls fn(*args, **kwargs)

Remote calls use Socket.IO events for unary, streaming, and bidirectional shapes. HTTP is kept only for /health. Errors stay in-band.

Repository Map

Development

git clone https://github.com/Agentiix/Agentix
cd Agentix
pip install -e '.[dev]'
pytest
ruff check agentix/ tests/

Pair this repo with sibling backend/runtime repos checked out next to it when testing full sandbox rollouts.

Links

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

agentixx-0.1.5.tar.gz (177.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

agentixx-0.1.5-py3-none-any.whl (56.4 kB view details)

Uploaded Python 3

File details

Details for the file agentixx-0.1.5.tar.gz.

File metadata

  • Download URL: agentixx-0.1.5.tar.gz
  • Upload date:
  • Size: 177.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.4 {"installer":{"name":"uv","version":"0.11.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"TencentOS Server","version":"4.4","id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for agentixx-0.1.5.tar.gz
Algorithm Hash digest
SHA256 01727ca75e0f08fa591e1fa448d832025bf2c1c36fc6b0b8d786068f541227fc
MD5 1c73d09b5bfcd09283654e4d5b30e6a8
BLAKE2b-256 8925c05db6644443bc9a7c4b5305a8da0f4110ca17141161e029a67fc92e9c6b

See more details on using hashes here.

File details

Details for the file agentixx-0.1.5-py3-none-any.whl.

File metadata

  • Download URL: agentixx-0.1.5-py3-none-any.whl
  • Upload date:
  • Size: 56.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.4 {"installer":{"name":"uv","version":"0.11.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"TencentOS Server","version":"4.4","id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for agentixx-0.1.5-py3-none-any.whl
Algorithm Hash digest
SHA256 9537a88d43de5feadc18d629a6b70e403a857f2408cc2e85c15234ec4bd22b3b
MD5 09b86b899312f9bdf33749b894f381b6
BLAKE2b-256 084e53534dd50d196a834b94090b16fa5db670f8642b601bbd39c3b53d89f9f3

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page