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.0.tar.gz (172.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.0-py3-none-any.whl (51.3 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: agentixx-0.1.0.tar.gz
  • Upload date:
  • Size: 172.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.0.tar.gz
Algorithm Hash digest
SHA256 c064a8449a71da5e08802149be2a2987314a84f6a5f09500d727ad448634b61a
MD5 bc6621c38a5f4f95308358141a13df0a
BLAKE2b-256 3a2bd24e401005f632a6693e4073ebd9503e7dbb4af9e930169bdab63413cc07

See more details on using hashes here.

File details

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

File metadata

  • Download URL: agentixx-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 51.3 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.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9df1a57c611f5cd747cd561b5dd78f8116edbb4ac650c736d1e711d82ce09425
MD5 728886a1687e3a692adf51b8b0aff208
BLAKE2b-256 3cad407ec4df4f68256ff7003dcc17bc08cba5c6e9b8464570d40bfb41d257e0

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