Repository avatar
AI Tools
v0.1.1
active

sunfield

dev.sunfield/sunfield

Headless Blender 4.5 GPU sandboxes for AI agents: stateful bpy, AOV inspect & Cycles OptiX.

Documentation

Sunfield SDK, Remote MCP & SunfieldBench

Cloud 3D runtime for autonomous AI agents — "E2B / Browserbase for Blender."

Sunfield (sunfield.dev) runs warm, isolated headless Blender 4.5 GPU sandboxes (--network=none, read-only rootfs, cgroup limits) over a zero-install Streamable HTTP Remote MCP (https://sunfield.dev/mcp, OAuth 2.1) and typed Python SDK — with 2.4 ms stateful bpy execution, 392 ms automatic crash recovery, 459 ms multi-view EEVEE/Cycles inspection + exact BVHTree collision telemetry, 149 pre-cached CC0 Poly Haven assets, fork() scene branching, and elastic Cycles OptiX burst rendering behind hard max_cost_usd caps.

Sunfield Multi-Lighting Product Studio Cycles OptiX Proof One 4K product model branched via fork() across three studio lighting setups (Obsidian Tungsten · Daylight Loft · Amber Noir) on Sunfield Cycles OptiX AgX.

Sunfield Ground-Truth 4-Pass AOV Proof Frame-aligned ground truth from one headless Blender 4.5 camera pose: Cycles OptiX RGB · Wireframe topology · World normals · Linear Z-depth.


10-Second Setup: Hosted Remote MCP (No Local Blender or GPU)

Every new account starts with $1.00 in free GPU credits (~2,500 Cycles OptiX GPU-seconds, no credit card required).

Claude Code (1-Command OAuth 2.1)

claude mcp add --transport http sunfield https://sunfield.dev/mcp

Claude Code discovers OAuth 2.1 + PKCE automatically, opens a browser tab to claim your free credits, and exposes all 15 native MCP tools (sunfield_create_session, sunfield_exec, sunfield_inspect, sunfield_fork, sunfield_render, sunfield_search_assets, sunfield_stage_assets, sunfield_stash, sunfield_topup, etc.).

Cursor, Windsurf, or VS Code (mcp.json)

{
  "mcpServers": {
    "sunfield": {
      "url": "https://sunfield.dev/mcp"
    }
  }
}

Local STDIO Bridge (sunfield-mcp)

For MCP hosts that only support STDIO transport:

export SUNFIELD_API_KEY="sunfield_sk_..."  # claim at https://sunfield.dev/start
uvx sunfield-mcp

Python SDK Quickstart (sdk/python/)

uv add sunfield
export SUNFIELD_API_KEY="sunfield_sk_..."  # $1.00 free at https://sunfield.dev/start
import os
from sunfield import Sunfield

with Sunfield(api_key=os.environ["SUNFIELD_API_KEY"]) as sf:
    with sf.sessions.create(preset="studio") as s:
        s.stage_assets(["hdri.brown_photostudio_01"])
        s.exec(
            "load_hdri('assets/hdri.brown_photostudio_01/brown_photostudio_01_2k.hdr', strength=1.2)\n"
            "bpy.ops.mesh.primitive_torus_add(location=(0, 0, 0.45), major_radius=0.45, minor_radius=0.14)"
        )

        # Sub-second visual + exact BVHTree spatial feedback
        check = s.inspect(views=["camera", "iso_3q"], passes=["rgb", "depth", "normals"])
        assert check.telemetry["collisions"] == []

        # Metered Cycles OptiX render behind a hard dollar ceiling
        render = s.render(
            engine="cycles",
            samples=64,
            resolution=(1920, 1080),
            aov_passes=["rgb", "depth", "normals"],
            max_cost_usd=0.05,
        )
        render.save_all(sf, "./outputs/hero")
        print(f"Rendered in {render.actual_gpu_s:.2f}s (${render.actual_cost_usd:.5f})")

Runnable Examples (examples/)

  • examples/product_studio_agent.py — Autonomous product-shot loop: build/upload geometry, detect & auto-fix floating parts via inspect(), fork(3) studio lighting branches, and Cycles OptiX burst-render under $0.50.
  • examples/robotics_domain_rand.py — Robotics / Physical AI synthetic dataset loop: domain-randomize tabletop scenes, filter colliding grasps via BVHTree, and export RGB + linear Z-depth + world normals + instance segmentation + 3D world AABB JSON.
  • examples/claude_code_remote_mcp.md — Copy-paste Remote MCP configs and verification prompts for Claude Code, Cursor, Windsurf, and OpenAI Agents SDK.

SunfieldBench v0.1 (sunfieldbench/)

A deterministic 8-task benchmark suite for evaluating 3D agents and headless Blender infrastructure on spatial correctness (BVHTree zero-collision, zero-floating, frustum framing coverage), tmpfs crash recovery, multi-branch fork(), AOV completeness, and metered GPU cost:

# Inspect all 8 deterministic tasks offline
uv run --with sunfield python -m sunfieldbench --list

# Run live against https://sunfield.dev
export SUNFIELD_API_KEY="sunfield_sk_..."
uv run --with sunfield python -m sunfieldbench --run --out results.json

Live Measured Baseline (2026-12-06, https://sunfield.dev · RTX 3090 · 33s full suite)

TaskCategoryResultexec() RTTCold inspect()Cycles GPU-sCycles Cost
studio_product_groundingproduct_photographyPASS89.4 ms788 ms1.677 s$0.000671
collision_free_tabletoprobotics_syntheticPASS96.1 ms1,062 ms—$0.000000
multi_lighting_fork (3× fork)product_photographyPASS85.5 ms608 ms—$0.000000
camera_framing_precisionspatial_reasoningPASS64.3 ms803 ms—$0.000000
robotics_aov_completeness (4-pass)robotics_syntheticPASS66.5 ms1,227 ms1.706 s$0.000682
material_roughness_sweeplookdevPASS102.5 ms918 ms1.583 s$0.000633
stacked_contact_geometryspatial_reasoningPASS64.3 ms718 ms—$0.000000
budget_guardrail_probeinfrastructurePASS66.4 ms613 ms1.577 s$0.000631
Total (8 / 8, 100% pass)—8 / 876.0 ms med795 ms med6.543 s$0.002617

Measured end-to-end over public HTTPS against https://sunfield.dev (fresh --network=none Docker sandbox per task with isolated pre-warmed EEVEE shader cache; Cycles OptiX 32 spp @ 512×512 billed at $0.00040/GPU-s).


Links & Docs

License

MIT © 2026 Strange Metal, Inc. (Camera_01 and pocket_watch proof renders use CC0 assets from Poly Haven.)

PYPI
sunfield-mcp
Install Command
pip install sunfield-mcp

Remote