Skip to main content
Glama

OpenFactory

create_build

Create a new build from a recipe.

The recipe defines the base OS, features, packages, and configuration for the Linux image. The build is queued and its worktree prepared; by default YOU drive it from there with your own model -- OpenFactory runs no LLM for it. Call build_image(build_id), then drive its verification session: get_verification_session(build_id=...) names the VM and the claims a platform judge grades. Pass platform_agent=True to hand the build to OpenFactory's goal agent instead (metered platform AI).

By default the build also gets a chat, seeded with prompt (if given) and a recipe card, and linked so it shows up in the sidebar and opens the build panel. Pass create_chat=False to suppress that.

Interactive build-terminal agents that need the worktree path use prepare_harness_build instead.

The response includes a session_token — pass it to all subsequent tool calls (list_builds, get_build_status, etc.) to maintain session continuity.

Example recipe: { "name": "My Custom Server", "base_image": "debian-bookworm", "description": "A minimal web server", "os": { "features": ["ssh", "nginx"], "packages": ["htop", "vim"], "services": [ {"name": "ssh", "config": {"port": 22}} ] } }

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "recipe": "<recipe>"
    },
    "name": "create_build"
  }
}

Input Schema

NameRequiredDescriptionDefault
themeNoAn Omarchy theme id (GET /api/catalog/themes lists them, e.g. tokyo-night). It is recorded as the owner's choice and verified on the finished image; the recipe must apply it (GET /api/catalog/themes/{id} has its palette and bundle). Refused for firmware built by its own tooling (OpenWrt, Zephyr, GrapheneOS).
promptNoThe natural-language request this recipe came from, if there was one. Seeded as the opening user message of the build's chat, so the chat shows what was actually asked for rather than just the generated recipe.
recipeYes The build recipe as a JSON object (or a JSON string). Required fields: - name: Name for the build - base_image: Base OS (e.g., "ubuntu-26.04", "debian-trixie", "fedora-39" through "fedora-44", "elster-os") Optional fields: - use_case: Primary use case (e.g., "Development", "Research", "Production server") - description: Description of the build purpose - hardware: Hardware requirements (min_memory_gb, min_storage_gb) - os: OS settings. Put features, packages, services, networking, security, and users here. - scenarios: Post-build test scenarios
api_keyNoYour OpenFactory MCP API key (optional)
create_chatNoCreate a chat for this build, seeded with the prompt and a recipe card, and link it so the build is reachable from the sidebar and opens the build panel. Leave on unless you're generating bulk/QA builds that would spam the chat list.
session_tokenNoSession token from a previous tool response. IMPORTANT: Always pass the session_token from the most recent tool response to maintain session continuity.
platform_agentNoHave OpenFactory's own goal agent drive this build. It spends your plan's platform AI allowance and is metered against it. Omit it and YOU drive the build with your own model (build_image, then its verification session through get_verification_session).
installer_choiceNoWhen the installer combo is not yet supported: native, openfactory-installer, calamares, or live_only. If omitted and the combo is uncovered, this tool returns needs_input with a question.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden and does so: it discloses that the build is queued and a worktree prepared, that no LLM runs by default, that platform_agent is metered against the plan's AI allowance, that a chat is created and linked as a side effect, and that a missing installer combo yields needs_input. It also surfaces the session_token continuity requirement, which is invisible from the schema alone.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core action, then layered constraints and alternatives in a sensible order, and the example recipe is genuinely useful for constructing the required object. The cost is some redundancy: the platform_agent and create_chat paragraphs largely re-say what the schema already documents, which an agent will read anyway.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For an 8-parameter creation tool with real side effects, the description covers initiation, ownership of the drive loop, chat linkage, the token needed for follow-on calls, and the input-request edge case. An output schema exists, so it does not need to enumerate return fields, and it still flags the one return value (session_token) that changes subsequent behavior.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3; the description earns more by tying parameters into workflows the schema cannot express (prompt seeds the chat's opening message, create_chat controls the cascade, platform_agent changes who drives the build) and by giving a concrete example recipe object. It does restate a few schema descriptions near-verbatim, which caps it below a 5.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The opening sentence names a specific verb and resource ('Create a new build from a recipe') and is immediately followed by what the recipe governs (base OS, features, packages, configuration). It also distinguishes this tool from prepare_harness_build and from the platform_agent-driven path, so an agent can place it among siblings without opening schemas.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicit when-to-use and when-not: default behavior is that the calling agent drives the build itself via build_image then get_verification_session, while platform_agent=True hands it to OpenFactory's metered goal agent. It also states create_chat=False for bulk/QA builds to avoid chat spam and that interactive build-terminal agents needing the worktree path should use prepare_harness_build instead.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.